Git Product home page Git Product logo

eft's Introduction

This repository contains pseudo-GT 3D human pose data produced by Exemplar Fine-Tuning (EFT) method, published in 3DV 2021. The 3D pose data is in the form of SMPL parameters, and this can be used as a supervision to train a 3D pose estimation algiritm (e.g., SPIN or HMR). We found that our EFT dataset is sufficient to build a model that is comparable to the previous SOTA algorithms without using any other indoor 3D pose dataset. See our paper for more details.

This repository also contains the pre-trained 3D pose estimation model trained with our EFT dataset and monocular motion capture demo tools. See README_bodymocap.

News:

  • We have released the EFT fitting codes. See the README_run_eft file:

  • We have released FrankMocap by which you can obtain both 3D body+hand outputs. The body module is the same as this repository's model. We encourage to use FrankMocap for body pose estimation.

Installing Requirements

It is convenient and safe to use conda environment

conda create -n venv_eft python=3.6
conda activate venv_eft
pip install -r requirements.txt

Download EFT Fitting data (json formats)

This repository only provides corresponding SMPL parameters for public 2D keypoint datasets (such as COCO, MPII). You need to download images from the original dataset website.

Run the following script to download our EFT fitting data:

sh scripts/download_eft.sh 
  • The EFT data will be saved in ./eft_fit/(DB_name).json. Each json file contains a version EFT fitting for a public dataset.
  • See Data Format for details
  • Currently available EFT fitting outputs:
Dataset Name SampleNum Manual Filtering File Name
COCO2014-12kp 28344 No COCO2014-Part-ver01.json
COCO2014-6kp 79051 No COCO2014-All-ver01.json
COCO2014-Val 10510 Yes COCO2014-Val-ver10.json
MPII 14361 No MPII_ver01.json
PoseTrack 28856 No PoseTrack_ver01.json
LSPet-Train 2946 Yes LSPet_ver01.json
LSPet-Test 2433 Yes LSPet_test_ver10.json
OCHuman-Train 2495 Yes OCHuman_train_ver10.json
OCHuman-Test 1783 Yes OCHuman_test_ver10.json
  • COCO2014-All-ver01.json: COCO 2014 training set by selecting the samples 6 keypoints or more keypoints are annotated.
  • COCO2014-Part-ver01.json: COCO 2014 training set by selecting the sample that 12 limb keypoints or more are annotated.
  • COCO2014-Val-ver10.json: COCO 2014 val set.
  • MPII_ver01.json : MPII Keypoint Dataset
  • PoseTrack_ver01.json : PoseTrack Dataset by selecting the sample that 12 limb keypoints or more are annotated.
  • LSPet: LSPet Dataset
  • OCHuman : OCHuman Dataset
  • Note that the number of samples are fewer than the original sample numbers in each DB, since we automatically (or manually) filtered out bad samples
  • Manual Filtering: Manual quality check and filtering is done to keep high quality results only. See paper for details

Download Other Required Data

  • SMPL Model (Neutral model: basicModel_neutral_lbs_10_207_0_v1.0.0.pkl):

    • Download in the original website. You need to register to download the SMPL data.
    • Put the file in: ./extradata/smpl/basicModel_neutral_lbs_10_207_0_v1.0.0.pkl
    • Copy the smpl pkl file to a different name (SMPL_NEUTRAL.pkl). You need both files:
    cp ./extradata/smpl/basicModel_neutral_lbs_10_207_0_v1.0.0.pkl ./extradata/smpl/SMPL_NEUTRAL.pkl
    
  • Densepose (optional, for Densepose rendering):

    • Run the following script
        sh scriptsdownload_dp_uv.sh    
    
    • Files are saved in ./extradata/densepose_uv_data/

Download Images from Original Public DB website

Visualize EFT Fitting Results

Run EFT Fitting by yourself

Model Zoo

  • We also share pre-trained models trained with diverse dataset.
  • Plaese see "scripts/download_model_zoo.sh"

Motion Capture Demo

Citation

@inproceedings{joo2020eft,
  title={Exemplar Fine-Tuning for 3D Human Pose Fitting Towards In-the-Wild 3D Human Pose Estimation},
  author={Joo, Hanbyul and Neverova, Natalia and Vedaldi, Andrea},
  booktitle={3DV},
  year={2020}
}

License

CC-BY-NC 4.0. See the LICENSE file.

References

The body mocap code is a modified version of SPIN, and the majority of this code is borrowed from it.

eft's People

Contributors

arturojreal avatar jhugestar avatar realblack0 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

eft's Issues

Get animated output as .fbx

Hello Thank you for the work. Is there a fast way of getting estimated animation as .fbx (or any other format)? To import to 3d software.

Output format and rescaling

Hello,

in the documentation you say that when prediction 3d coordinates, the X and Y are "aligned to input image".
Could you please explain this in detail? Does it mean that the model outputs something in the range [-1, 1] or [0, 1] and you rescale it based on the image size?

If I wanted to rescale them in the range [-1, 1], should I just divide them by the image width and height respectively? Or do you perform a square cropping (e.g., 256x256) and one should divide the output accordingly?

Also, does [0, 0] correspond to the top left corner of the image?

about the data of parm_cam in render

i use the pose&shape label get the vertices ,then i want to use the parm_cam to render the mesh in this camera view,like SPIN redner,but i make the [s,x,y] to [x,y,2×5000/224×s],but the render view is not true
test_shape
can you help me?

which version of posetrack is used by eft

hello,
I really appreciate this work, thanks very much.

And I have a question here, some data provide by eft is come from posetrack, and there are two version of posetrack, that is posetrack2018(82G) and posetrack2017(34G). I want to know which version of posetrack is used here, it's a hard work to download all of the data.

OpenGL.error.GLError

First, I encountered the bug 'ImportError: cannot import name 'ModelOutput''. Then, I modified the code from 'from smplx.body_models import ModelOutput' to 'from smplx.body_models import SMPLOutput' in smpl.py. Finally, I encountered the bug
OpenGL.error.GLError: GLError(
err = 1282,
description = b'invalid operation',
baseOperation = glGetUniformLocation,
cArguments = (3, b'ModelMat\x00'),
result = -1
)
and I don't know how to solve it. Could you please help me?

About EFT Fitting data format

What‘s “gt_keypoint_2d” means in EFT Fitting data?The first 25 are openpose keypoints, and the last 24 are smpl keypoints?

fps?

hey!

I wonder what are the approx fps for webcam atm? would be useful to know for gui mode on and off especially

A Potential "Bug" for weakProjection

Thanks for releasing the fitting code! I found that the implementation of weakProjection_gpu is "not" correct.
In simple terms, in your implementation, the projection is computed as s*pts + t. In the original HMR/SPIN implementation, it implies that the projection should be s*(pts + t). In this way, this projection can be perfectly converted to perspective projection by setting the camera translation to [tx, ty, 2*f/s * img_res].

https://github.com/MandyMo/pytorch_HMR/blob/7bf18d619aeafd97e9df7364e354cd7e9480966f/src/util.py#L117

Anyway, it a fitting procedure, the network's parameters will be updated to output the correct t under this projection.

Visualising the prediction

Hello,

In the demo there is dual person prediction despite there being only one person. I'd appreciative any pointers as to how to address that issue.

Thank you.

model weights for the pre-trained SPIN model

Hello, Dr Joo.
First of all, thanks for the impressive and inspiring work that your team have made :-)
Since one of the main applications of EFT is a 'post-processing', would it be possible for you to release the pre-trained model weight of SPIN, which is trained on your own loss formula?
Definitely I could get the pre-trained SPIN model weight via SPIN GitHub, but as your paper suggest the better formula to calculate the 2D joint reproduction loss, I'd like to request the pre-trained SPIN weight on your way if it doesn't bother you that much!

Use EFT as a Post-processing method in my test videos

Thanks for your great work!
As we all know ,the mesh result of PE may not fit the origin videos well,so i want to use EFT as Post-processing method to get better result.
So if i already have the 2d keypoints and smpl parameters got from PE,how can i use EFT to Fine tune?

COCO annto id

Hi thank you for sharing this great dataset first!
But I just found that annotId doesn't match the image's name in COCO annotation provided (both all and part)
I think they should match each other? The smpl param I parsed seems do not match well either.
Or did I miss something?

The annotation from COCO:
1

The annotation from eft:
2

The smpl param parsed by me:
3

JOINT_REGRESSOR_TRAIN_EXTRA_SMPLX

Hi, thanks for releasing the training code! Recently, I want to modify this code to support smplx-based fitting by introducing extra hand or facial landmarks, could u share the JOINT_REGRESSOR_TRAIN_EXTRA_SMPLX for smplx-based fitting? It seems that you have already tried similar things.

OpenGL.error.GLError

when I run the demo visEFTFit.py , my parser definition is:

parser = argparse.ArgumentParser()
parser.add_argument('--img_dir',default="../demo/images/demo.png", type=str , help='Folder path where input image files exist')
parser.add_argument('--fit_data',default="../eft_fit/MPII_ver01.json", type=str, help='EFT data json fortmat')
parser.add_argument('--smpl_dir',default="../extradata/smpl", type=str , help='Folder path where smpl pkl files exist')
parser.add_argument('--onbbox',action="store_true", help="Show the 3D pose on bbox space")
parser.add_argument('--rendermode',default="geo", help="Choose among geo, normal, densepose")
parser.add_argument('--render_dir',default="render_eft", help="Folder to save rendered images")
parser.add_argument('--waitforkeys',action="store_true", help="If true, it will pasue after each visualizing each sample, waiting for any key pressed")
parser.add_argument('--turntable',action="store_true", help="If true, show turn table views")
parser.add_argument('--multi',action="store_true", help='If True, show all available fitting people per image. Default, visualize a single person at each time')
args = parser.parse_args()

I get error like this:

freeglut (foo): fgInitGL2: fghGenBuffers is NULL
Traceback (most recent call last):
File "E:/human_pose_estimation/eft/demo/visEFTFit.py", line 436, in
renderer = getRenderer(args.rendermode)
File "E:/human_pose_estimation/eft/demo/visEFTFit.py", line 52, in getRenderer
renderer = meshRenderer.meshRenderer()
File "E:\human_pose_estimation\eft\renderer\meshRenderer.py", line 37, in init
glRenderer.init(self, width, height, name, 'geo', color_size, ms_rate)
File "E:\human_pose_estimation\eft\renderer\glRenderer.py", line 34, in init
glEnable(GL_DEPTH_CLAMP)
File "D:\ProgramFiles\Anaconda3\lib\site-packages\OpenGL\platform\baseplatform.py", line 415, in call
return self( *args, **named )
File "src\errorchecker.pyx", line 58, in OpenGL_accelerate.errorchecker._ErrorChecker.glCheckError
OpenGL.error.GLError: GLError(
err = 1280,
description = b'\xce\xde\xd0\xa7\xc1\xd0\xbe\xd9',
baseOperation = glEnable,
cArguments = (GL_DEPTH_CLAMP,)
)

code for the fitting procedure

Hi,
Thanks for a great job!
Is there any plan to release to code for the fitting procedure? (or I may have missed it?)
Best regards,
-Thibault

About coco data

I have downloaded the json formats data. According to my test, the length of COCO2014-Part-ver01.json is 28,062 and that of COCO2014-All-ver01.json is 74,834. This is not consistent with the picture .Maybe there's something wrong about the name of the file.
image

how to render results by pytorch3d?

Hi, I notice that the repository only renders results with OpenGL, could you give me some suggestions on how to use pytorch3d to visualize the output results?

3DHP smpl parameters

Thank you for your release!

Do you get smpl parameters for 3DHP using Mosh? Could you share these parameters please?

Thank you again!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.