Comments (5)
Could you provide more details, or give a short code snippet, about how you do the conversion? Do you get an error when you do the conversion, or does the output looks off when you use it to pose SMPL?
Using a function like this should be enough to do the conversion from rotation matrix to axis angle.
from 4d-humans.
@geopavlakos Thank you so much for your comments! I think I did exactly that and it's still erroring out. The code snippet is blow:
converted_poses = []
for pose in smpl_p["body_pose"].astype(float):
pose = torch.Tensor(pose)
rotVec = rotation_matrix_to_angle_axis(pose)
converted_poses.append(rotVec)
global_orient = torch.tensor(smpl_p["global_orient"])
# print(global_orient[0])
converted_poses.append(rotation_matrix_to_angle_axis(global_orient[0]))
dictionary = {
"poses": torch.cat(converted_poses).tolist(),
"betas": smpl_p["betas"].astype(float).tolist(),
"cam_intrinsics": intrinsics,
"cam_extrinsics": estimate_extrinsics_cv2(cam_p).tolist()
}
Another thing that I am unsure that could cause issues may be estimating the extrinsics to the person from 4Dhumans, and here's a code snippet:
def estimate_extrinsics_cv2(translation):
tra_pred = translation
cam_extrinsics = np.eye(4)
cam_extrinsics[:3, 3] = tra_pred
return cam_extrinsics.astype(float)
Thanks and hopefully this could work out : )
from 4d-humans.
I believe that you are appending the global orientation parameters at the end of the pose parameters, whereas they are typically the first three values of the standard 72 SMPL pose parameters, so that could be the problem.
Also, what do you mean with erroring out. Do you get an actual error, or does the mess output look weird?
from 4d-humans.
@geopavlakos Thanks so much for pointing that out! I tried but I think it's still not working. Basically, the error from humannerf is as follows:
Traceback (most recent call last):
File "train.py", line 45, in <module>
main()
File "train.py", line 39, in main
train_dataloader=train_loader, prog_loader = prog_loader)
File "core/train/trainers/human_nerf/trainer.py", line 215, in train_batch_wise
self.train(batch_idx,batch,prog_loader, epoch, train_dataloader)
File "core/train/trainers/human_nerf/trainer.py", line 233, in train
div_indices=data['patch_div_indices'],batch = batch)
File "core/train/trainers/human_nerf/trainer.py", line 148, in get_loss
rgb = net_output['rgb']
KeyError: 'rgb'
And I think this is because the ray is not able to intersect bbox, basically the orientation/extrinsics are off...
from 4d-humans.
Hmm, I am not sure what is the expected input format for the humannerf code, so not sure if I can help with this error. If you have a working code example that converts the output of a similar network, e.g., SPIN, to the expected format, we could help to do the mapping to 4D Humans.
from 4d-humans.
Related Issues (20)
- Evaluation of 3DPW HOT 2
- About the learning rate HOT 1
- Multi gpu training HOT 1
- Visualization of the reconstructed human mesh HOT 2
- Unable to download hmr2_data.tar.gz HOT 2
- A colab error about tracking HOT 2
- The meaning of 'NUM_TRAIN_SAMPLES', 'NUM_TEST_SAMPLES' and the question of the discriminator.
- PHALP tracker taking lot of CPU utilization HOT 1
- Can not import expand_bbox_to_aspect_ratio from hmr2.datasets.utills HOT 1
- about the training data,do you use EFT fits or what? HOT 6
- how about using smpl 49 keypoints(like spin did) instead of your smpl 44 keypoints? will the result be worse? HOT 2
- Is it easy to train this work with 4 V100 24G or 8 3090 24G? (no A100) HOT 1
- Error of downloading training dataset HOT 1
- Is there any specific reason for choosing Detectron2 as human detection model? HOT 1
- Using 4 V100-16, and set batchsize=1, torch.cuda.OutOfMemoryError:
- Have you tried to use a smaller backbone? HOT 1
- use SMPLX model with hands and feet? HOT 2
- Pseudo labels generation
- evaluation datasets image HOT 3
- download problem of hmr2.0a_model.tar.gz HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from 4d-humans.