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

How to use this for my own images not anything from test set #15

Open
Vamshigoud784 opened this issue Feb 20, 2020 · 2 comments
Open

How to use this for my own images not anything from test set #15

Vamshigoud784 opened this issue Feb 20, 2020 · 2 comments

Comments

@Vamshigoud784
Copy link

Hi, Gul.
I have done the following things:
Pre-processing and fitting python scripts

Python 2 environment with the following installed:
    OpenDr
    Chumpy
    OpenCV
SMPL related
    Download SMPL for python and set SMPL_PATH
        Fix the naming: mv basicmodel_m_lbs_10_207_0_v1.0.0 basicModel_m_lbs_10_207_0_v1.0.0
        Do the following changes in the code smpl_webuser/verts.py:

    - v_template, J, weights, kintree_table, bs_style, f,
    + v_template, J_regressor, weights, kintree_table, bs_style, f,
    - if sp.issparse(J):
    -     regressor = J
    -     J_tmpx = MatVecMult(regressor, v_shaped[:,0])
    -     J_tmpy = MatVecMult(regressor, v_shaped[:,1])
    -     J_tmpz = MatVecMult(regressor, v_shaped[:,2])
    + if sp.issparse(J_regressor):
    +     J_tmpx = MatVecMult(J_regressor, v_shaped[:,0])
    +     J_tmpy = MatVecMult(J_regressor, v_shaped[:,1])
    +     J_tmpz = MatVecMult(J_regressor, v_shaped[:,2])
    +     assert(ischumpy(J_regressor))
    -     assert(ischumpy(J))
    + result.J_regressor = J_regressor

    Download neutral SMPL model and place under models folder of SMPL
    Download SMPLify and set SMPLIFY_PATH
Voxelization related
    Download binvox executable and set BINVOX_PATH
    Download binvox python package and set BINVOX_PYTHON_PATH

Question:
When i have executed the file fitting/fit_surreal.py it is creating an obj and some mat files .but if i want to use my own image to get the prediction . what standards should i follow or what all should i pass in order to get an obj with prediction?

@gulvarol
Copy link
Owner

Hi, please use the demo scripts to run the test on your own images:
https:/gulvarol/bodynet/tree/master/demo

@Vamshigoud784
Copy link
Author

Thanks Gul for quick response.
i have built the torch with cuda 10 and installed luarocks and when i ran demo.lua i have got this error:
th> demo.lua
[string "_RESULT={ demo.lua}"]:1: attempt to index global 'demo' (a nil value)
stack traceback:
/home/bigthinx/torch/install/share/lua/5.2/trepl/init.lua:506: in function '__index'
[string "_RESULT={ demo.lua}"]:1: in main chunk
[C]: in function 'xpcall'
/home/bigthinx/torch/install/share/lua/5.2/trepl/init.lua:661: in function 'repl'
...hinx/torch/install/lib/luarocks/rocks/trepl/scm-1/bin/th:204: in main chunk
[C]: in ?
[0.0004s]
th>

in order to resolve that what i need to install? i'm new with lua and never used it before.

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

2 participants