Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Result not same as image provided #216

Open
BukuBukuChagma opened this issue Feb 9, 2024 · 6 comments
Open

Result not same as image provided #216

BukuBukuChagma opened this issue Feb 9, 2024 · 6 comments

Comments

@BukuBukuChagma
Copy link

So I don't know if I'm doing something wrong here or its suppose to be like this, when I provide a image in which I'm standing straight, in the body model it somehow translate to somewhat different from another angle. How to correct his? For example:

image
image

Why am I tilted? Why are the hands in not parallel to the body as in the image? Am I doing something wrong?

@fenghe12
Copy link

hello may i ask how did you use an image of a person as a input of smpl model and generate 3d representation?thanks!

@whl-007
Copy link

whl-007 commented Aug 16, 2024

hello may i ask how did you use an image of a person as a input of smpl model and generate 3d representation?thanks!你好,请问你是如何使用一个人的图像作为SMPL模型的输入并生成3D表示的?谢谢!2谢谢!
Hello!Can you use own RGB images? I haven't found a way to use SMPLX to turn my own RGB images into SMPLX fits. Can you tell me where I should find the code?

@whl-007
Copy link

whl-007 commented Aug 16, 2024

So I don't know if I'm doing something wrong here or its suppose to be like this, when I provide a image in which I'm standing straight, in the body model it somehow translate to somewhat different from another angle. How to correct his? For example:

image image

Why am I tilted? Why are the hands in not parallel to the body as in the image? Am I doing something wrong?

So I don't know if I'm doing something wrong here or its suppose to be like this, when I provide a image in which I'm standing straight, in the body model it somehow translate to somewhat different from another angle. How to correct his? For example:

image image

Why am I tilted? Why are the hands in not parallel to the body as in the image? Am I doing something wrong?

Hello!Can you use own RGB images? I haven't found a way to use SMPLX to turn my own RGB images into SMPLX fits. Can you tell me where I should find the code?

@BukuBukuChagma
Copy link
Author

@whl-007
Clone the github repo of smplify-x. Install all the dependencies and requirements as mentioned in the repo. Once everything is setup, you can use the command mentioned in their README which im linking below in screenshot.

image

@BukuBukuChagma BukuBukuChagma closed this as not planned Won't fix, can't repro, duplicate, stale Aug 16, 2024
@whl-007
Copy link

whl-007 commented Aug 19, 2024

@whl-007 Clone the github repo of smplify-x. Install all the dependencies and requirements as mentioned in the repo. Once everything is setup, you can use the command mentioned in their README which im linking below in screenshot.

image

"Hello, thank you for your response. So far, I have followed your instructions. I obtained the EHF.zip file, extracted it, and got the data for the image shown below. I used 01_img.jpg as the input and 01_2Djnt.json as the JSON file, but I encountered the following error:
Traceback (most recent call last):
File "/homesmplify-x-master/smplifyx/main-origin.py", line 290, in
main(**args)
File "/home/smplify-x-master/smplifyx/main-origin.py", line 246, in main
fit_single_frame(img, keypoints[[person_id]],
File "/home/smplify-x-master/smplifyx/fit_single_frame.py", line 120, in fit_single_frame
assert (len(data_weights) ==
AssertionError: Number of Body pose prior weights 4 does not match the number of data term weights 5
Additionally, I am unsure how to generate the JSON file from my image. I used the OpenPose source code, but the JSON file I obtained does not match the format of the 01_2Djnt.json file provided. I hope you can help clarify my doubts. Thank you very much."
image

My json file show:
{"keypoints": [[1449.0, 1469.0], [1534.0, 1737.0], [1272.0, 1737.0], [834.0, 1913.0], [482.0, 2002.0], [1711.0, 1737.0], [2150.0, 1825.0], [2588.0, 1913.0], [1535.0, 2625.0], [1359.0, 2626.0], [1273.0, 3161.0], [1272.0, 3695.0], [1710.0, 2626.0], [1624.0, 3161.0], [1624.0, 3695.0], [1448.0, 1468.0], [1536.0, 1468.0], [1360.0, 1469.0], [1623.0, 1469.0], [1624.0, 3961.0], [1711.0, 3874.0], [1623.0, 3783.0], [1184.0, 3874.0], [1097.0, 3873.0], [1359.0, 3695.0]]}

01_2Djnt.json file show:{"version":1.2,"people":[{"pose_keypoints_2d":[770.464,287.608,0.823277,790.065,334.916,0.671029,734.564,253.339,0.550223,695.431,214.197,0.563718,608.983,163.598,0.813454,847.126,385.5,0.662132,894.449,527.425,0.766871,781.892,507.847,0.729679,765.583,618.759,0.610898,708.468,610.604,0.556925,682.372,838.977,0.699029,679.115,1059.22,0.756149,825.938,626.921,0.562926,887.919,842.237,0.734691,943.375,1060.84,0.596494,759.043,251.71,0.844282,803.124,266.377,0.872308,739.472,240.287,0.247655,852.034,276.177,0.893368,959.706,1121.2,0.438599,977.649,1113.05,0.470517,938.491,1073.89,0.419639,631.811,1126.09,0.400877,622.021,1113.04,0.402617,693.792,1072.25,0.643139],"face_keypoints_2d":[738.952,247.045,0.089555,736.653,254.601,0.125376,734.353,264.456,0.142024,732.054,276.283,0.200632,734.682,291.395,0.230267,737.638,304.535,0.201998,745.194,332.459,0.278642,753.407,340.344,0.383774,763.92,344.943,0.332458,777.06,344.943,0.324587,792.172,337.715,0.432238,803.342,325.232,0.403625,815.168,315.705,0.423042,826.338,307.163,0.449559,832.908,297.308,0.488293,837.507,285.153,0.417282,840.464,270.698,0.294766,745.194,236.204,0.60619,752.422,236.532,0.742564,758.663,239.161,0.761214,765.891,243.76,0.724853,771.476,249.016,0.61468,785.602,251.973,0.581771,797.1,251.973,0.619972,807.941,252.958,0.664435,818.782,255.915,0.606848,827.652,262.814,0.61164,777.389,257.886,0.438152,775.746,268.07,0.339376,766.548,295.994,0.392756,764.577,302.893,0.486197,757.678,299.936,0.478495,760.306,305.192,0.58014,763.92,308.477,0.653194,769.176,308.806,0.511776,773.775,309.792,0.302411,750.451,249.673,0.71045,756.035,248.031,0.745266,762.277,251.644,0.671651,765.562,257.557,0.689411,758.663,257.886,0.758231,753.079,254.929,0.763183,795.129,267.413,0.701816,800.714,262.485,0.820026,808.269,263.142,0.714692,813.197,268.398,0.755492,807.941,270.698,0.730473,800.385,270.041,0.794726,748.151,310.449,0.400039,754.721,312.748,0.626283,760.635,314.391,0.6321,763.591,316.033,0.622115,768.19,315.705,0.564361,775.089,318.661,0.523215,783.631,320.304,0.251461,774.104,325.56,0.614065,767.862,326.217,0.706827,763.263,325.889,0.75772,758.335,325.56,0.768014,752.75,321.29,0.568902,750.122,313.405,0.521505,759.978,318.661,0.64907,763.591,319.319,0.634286,768.19,319.647,0.649023,780.346,320.633,0.3115,767.862,320.633,0.627485,763.591,320.961,0.738216,759.649,320.304,0.741162,758.335,252.301,0.682655,804.327,265.442,0.630357],"hand_left_keypoints_2d":[779.602,511.908,0.522801,752.64,492.837,0.538731,717.786,477.712,0.593758,690.824,472.451,0.645635,669.781,467.848,0.778695,705.949,519.141,0.804446,680.303,540.843,0.78207,663.205,556.625,0.799778,648.737,572.408,0.829955,717.129,539.527,0.747385,689.509,561.228,0.814414,668.466,578.326,0.777825,652.025,593.451,0.872193,731.596,552.022,0.773824,707.265,577.011,0.739739,688.852,592.136,0.727564,672.411,604.631,0.811094,742.775,565.174,0.724793,721.732,584.902,0.723509,709.237,596.082,0.779121,696.085,603.973,0.815069],"hand_right_keypoints_2d":[608.335,162.063,0.634607,594.151,163.531,0.777358,579.477,160.596,0.76749,565.781,154.237,0.811211,552.575,149.346,0.845225,582.411,124.889,0.750621,568.716,108.259,0.734522,555.02,96.0307,0.666811,544.259,89.672,0.600209,582.411,120.487,0.781987,565.292,101.9,0.762481,550.618,90.1611,0.725097,538.879,81.8459,0.748945,582.901,119.509,0.652711,566.27,101.9,0.585516,553.553,91.1394,0.55302,540.835,82.335,0.63448,582.411,119.02,0.478096,569.694,105.813,0.412964,562.846,97.9872,0.298483,553.553,90.6502,0.270408],"pose_keypoints_3d":[],"face_keypoints_3d":[],"hand_left_keypoints_3d":[],"hand_right_keypoints_3d":[]}]}

@whl-007
Copy link

whl-007 commented Aug 20, 2024

I find some errors in smplifyx
/fit_single_frame.py from line 108 to 120, data_weights‘s shape is 5,but body_pose_prior_weights‘s shape is 4 so that this will raise an error: AssertionError: Number of Body pose prior weights 4 does not match the number of data term weights 5 if data_weights is None:
data_weights = [1, ] * 5

if body_pose_prior_weights is None:
    body_pose_prior_weights = [4.04 * 1e2, 4.04 * 1e2, 57.4, 4.78]

msg = (
    'Number of Body pose prior weights {}'.format(
        len(body_pose_prior_weights)) +
    ' does not match the number of data term weights {}'.format(
        len(data_weights)))
assert (len(data_weights) ==
        len(body_pose_prior_weights)), msg

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants