ECON
[CVPR'23, Highlight] ECON: Explicit Clothed humans Optimized via Normal integration
Top Related Projects
PyTorch3D is FAIR's library of reusable components for deep learning with 3D data
This is the code for Deformable Neural Radiance Fields, a.k.a. Nerfies.
Instant neural graphics primitives: lightning fast NeRF and more
Make human motion capture easier.
SMPL-X
A Strong and Easy-to-use Single View 3D Hand+Body Pose Estimator
Quick Overview
ECON (Explicit Clothing and Occlusion Network) is a deep learning-based framework for reconstructing 3D human models from single images, including clothing and occlusions. It aims to generate high-fidelity 3D human reconstructions with accurate body shape, pose, and clothing, even in challenging scenarios with occlusions.
Pros
- Handles complex clothing and occlusions in 3D human reconstruction
- Produces high-quality results from single images
- Supports various body shapes and poses
- Open-source implementation with pre-trained models available
Cons
- Requires significant computational resources for training and inference
- May struggle with extreme poses or highly unusual clothing
- Limited to single-person reconstruction
- Dependency on specific deep learning frameworks and libraries
Code Examples
# Load and preprocess input image
image = load_image("input.jpg")
preprocessed = preprocess_image(image)
# Run ECON inference
results = econ_model.infer(preprocessed)
# Extract 3D mesh and texture
mesh = results.get_mesh()
texture = results.get_texture()
# Visualize the reconstructed 3D human model
viewer = Viewer(width=1024, height=768)
viewer.add_mesh(mesh, texture=texture)
viewer.show()
# Export the 3D model to a file
export_mesh(mesh, texture, "output.obj")
Getting Started
-
Clone the repository:
git clone https://github.com/YuliangXiu/ECON.git cd ECON -
Install dependencies:
pip install -r requirements.txt -
Download pre-trained models:
bash scripts/download_models.sh -
Run inference on a sample image:
python demo.py --input_path path/to/image.jpg --output_path path/to/output
For more detailed instructions and advanced usage, refer to the repository's README and documentation.
Competitor Comparisons
PyTorch3D is FAIR's library of reusable components for deep learning with 3D data
Pros of PyTorch3D
- More comprehensive 3D deep learning library with a wider range of functionalities
- Better documentation and community support
- Seamless integration with PyTorch ecosystem
Cons of PyTorch3D
- Steeper learning curve for beginners
- Heavier and more resource-intensive
- May include unnecessary features for specific use cases
Code Comparison
ECON (for human body mesh reconstruction):
econ = ECON(args).to(device)
verts_pr, faces_pr, _ = econ.forward(images)
PyTorch3D (for rendering a 3D mesh):
renderer = MeshRenderer(
rasterizer=MeshRasterizer(cameras=cameras, raster_settings=raster_settings),
shader=HardPhongShader(device=device, cameras=cameras)
)
images = renderer(meshes_world=meshes, cameras=cameras, lights=lights)
Summary
PyTorch3D is a more comprehensive 3D deep learning library with broader functionality and better documentation. However, it may be overkill for specific tasks like human body mesh reconstruction, where ECON provides a more focused solution. PyTorch3D offers seamless integration with the PyTorch ecosystem but comes with a steeper learning curve and higher resource requirements. ECON, on the other hand, is more lightweight and tailored for specific use cases in 3D human body reconstruction.
This is the code for Deformable Neural Radiance Fields, a.k.a. Nerfies.
Pros of nerfies
- More established project with higher star count and contributor base
- Focuses on novel view synthesis for deformable scenes
- Provides pre-trained models and demo videos
Cons of nerfies
- Less recent updates compared to ECON
- Narrower scope, specifically for NeRF-based applications
- May require more computational resources for training and inference
Code comparison
ECON:
def forward(self, x):
x = self.encoder(x)
x = self.decoder(x)
return x
nerfies:
def render_rays(ray_batch,
network_fn,
network_query_fn,
N_samples,
retraw=False,
lindisp=False,
perturb=0.,
N_importance=0,
network_fine=None,
white_bkgd=False,
raw_noise_std=0.,
verbose=False):
# ... (implementation details)
Summary
ECON is a more recent project focusing on 3D human reconstruction, while nerfies is an established project for novel view synthesis of deformable scenes. ECON offers a broader scope for human-centric 3D tasks, while nerfies provides a specialized solution for NeRF-based applications. The code comparison shows that ECON has a simpler forward pass structure, while nerfies implements more complex ray rendering functionality.
Instant neural graphics primitives: lightning fast NeRF and more
Pros of instant-ngp
- Faster rendering and training times for 3D scenes and objects
- Supports a wider range of applications, including volumetric rendering and neural radiance fields
- More extensive documentation and examples provided
Cons of instant-ngp
- Requires more computational resources and specialized hardware (e.g., CUDA-enabled GPUs)
- Less focused on human body reconstruction and clothing estimation
- Steeper learning curve for beginners due to its broader scope
Code Comparison
ECON (Python):
def forward(self, x):
feat = self.encoder(x)
return self.regressor(feat)
instant-ngp (CUDA C++):
__global__ void render_kernel(
const uint32_t n_elements,
const uint32_t n_training_images,
const TrainingXForm* training_xforms,
// ... (other parameters)
) {
// Rendering logic
}
ECON focuses on human body reconstruction and clothing estimation, while instant-ngp is a more general-purpose framework for neural graphics primitives. ECON's code is primarily in Python, making it more accessible for machine learning researchers. instant-ngp, on the other hand, uses CUDA C++ for high-performance rendering and training, which allows for faster execution but requires more specialized knowledge to use and modify.
Make human motion capture easier.
Pros of EasyMocap
- More comprehensive documentation and tutorials
- Supports multi-view capture and reconstruction
- Includes tools for data preprocessing and visualization
Cons of EasyMocap
- Potentially more complex setup and configuration
- May require more computational resources for multi-view processing
- Less focus on end-to-end learning approaches
Code Comparison
EasyMocap example:
from easymocap.dataset import CONFIG
from easymocap.smplmodel import SMPLModel
dataset = MviewDataset(path, cams, out=out)
smpl = SMPLModel(model_path=CONFIG['smplmodel'])
ECON example:
from lib.model.smpl import SMPL
from lib.dataset.mesh_util import SMPLX
smpl = SMPL()
smplx = SMPLX()
EasyMocap provides a more structured approach to dataset handling and model initialization, while ECON offers a simpler interface for SMPL and SMPLX models. EasyMocap's code suggests a focus on multi-view processing, whereas ECON's example highlights its emphasis on different body models.
SMPL-X
Pros of smplx
- More comprehensive body model, including hands and facial expressions
- Better documentation and examples for usage
- Wider adoption in the research community
Cons of smplx
- More complex to use and integrate
- Requires more computational resources
- Less focused on clothing and garment simulation
Code Comparison
ECON example:
from lib.model.smpl import SMPL
smpl = SMPL(model_path, gender='neutral')
vertices = smpl(pose, shape)
smplx example:
import smplx
model = smplx.create(model_path, model_type='smplx')
output = model(betas=shape, expression=expression, return_verts=True)
vertices = output.vertices
Summary
ECON focuses on efficient clothing simulation, while smplx provides a more detailed full-body model. ECON is simpler to use but less comprehensive, whereas smplx offers more features at the cost of complexity. The choice between them depends on the specific requirements of the project, such as the need for detailed facial expressions or clothing simulation.
A Strong and Easy-to-use Single View 3D Hand+Body Pose Estimator
Pros of FrankMocap
- More comprehensive documentation and usage instructions
- Wider range of supported input types (images, videos, webcams)
- Larger community and support base due to Facebook backing
Cons of FrankMocap
- Heavier computational requirements
- Less focus on clothing estimation
- Potentially more complex setup process
Code Comparison
ECON example:
from lib.model import ECON
model = ECON(args)
verts_3d, faces, uv_verts_2d, uv_faces = model(images)
FrankMocap example:
from frankmocap import FrankMocap
mocap = FrankMocap()
body_pose_results = mocap.regress(input_path)
Key Differences
- ECON focuses on estimating 3D human shape and clothing, while FrankMocap primarily targets body pose estimation
- ECON provides more detailed clothing reconstruction, including UV mapping
- FrankMocap offers a broader range of applications beyond clothing estimation
Use Cases
- ECON: Virtual try-on, detailed clothing analysis, 3D avatar creation
- FrankMocap: Motion capture, pose estimation for various applications, general-purpose body tracking
Performance
- ECON may be more efficient for clothing-specific tasks
- FrankMocap likely performs better in real-time applications and diverse scenarios
Community and Support
- FrankMocap has a larger user base and more frequent updates
- ECON may offer more specialized support for clothing-related inquiries
Convert
designs to code with AI
Introducing Visual Copilot: A new AI model to turn Figma designs to high quality code using your components.
Try Visual CopilotREADME
ECON: Explicit Clothed humans Optimized via Normal integration
Yuliang Xiu · Jinlong Yang · Xu Cao · Dimitrios Tzionas · Michael J. Black
CVPR 2023 (Highlight)
ECON is designed for "Human digitization from a color image", which combines the best properties of implicit and explicit representations, to infer high-fidelity 3D clothed humans from in-the-wild images, even with loose clothing or in challenging poses. ECON also supports multi-person reconstruction and SMPL-X based animation.
Applications
![]() | ![]() |
|---|---|
| "3D guidance" for SHHQ Dataset | multi-person reconstruction w/ occlusion |
![]() | ![]() |
| "All-in-One" Blender add-on | SMPL-X based Animation (Instruction) |
News :triangular_flag_on_post:
- [2024/09/16] ð Bending leg issues [1,2,3,4] get resolved with Sapiens, details in Bending legs.
- [2023/08/19] We released TeCH, which extends ECON with full texture support.
- [2023/06/01] Lee Kwan Joong updates a Blender Addon (Github, Tutorial).
- [2023/04/16]
is ready to use!
- [2023/02/27] ECON got accepted by CVPR 2023 as Highlight (top 10%)!
- [2023/01/12] Carlos Barreto creates a Blender Addon (Download, Tutorial).
- [2023/01/08] Teddy Huang creates install-with-docker for ECON .
- [2023/01/06] Justin John and Carlos Barreto creates install-on-windows for ECON .
- [2022/12/22]
is now available, created by Aron Arzoomand.
- [2022/12/15] Both demo and arXiv are available.
Key idea: d-BiNI
d-BiNI jointly optimizes front-back 2.5D surfaces such that: (1) high-frequency surface details agree with normal maps, (2) low-frequency surface variations, including discontinuities, align with SMPL-X surfaces, and (3) front-back 2.5D surface silhouettes are coherent with each other.
| Front-view | Back-view | Side-view |
|---|---|---|
![]() | ![]() | ![]() |
Please consider cite BiNI if it also helps on your project
@inproceedings{cao2022bilateral,
title={Bilateral normal integration},
author={Cao, Xu and Santo, Hiroaki and Shi, Boxin and Okura, Fumio and Matsushita, Yasuyuki},
booktitle={Computer Vision--ECCV 2022: 17th European Conference, Tel Aviv, Israel, October 23--27, 2022, Proceedings, Part I},
pages={552--567},
year={2022},
organization={Springer}
}
Table of Contents
Instructions
- See installion doc for Docker to run a docker container with pre-built image for ECON demo
- See installion doc for Windows to install all the required packages and setup the models on Windows
- See installion doc for Ubuntu to install all the required packages and setup the models on Ubuntu
- See magic tricks to know a few technical tricks to further improve and accelerate ECON
- See testing to prepare the testing data and evaluate ECON
Demos
-
Quick Start
# For single-person image-based reconstruction (w/ l visualization steps, 1.8min)
python -m apps.infer -cfg ./configs/econ.yaml -in_dir ./examples -out_dir ./results
# For multi-person image-based reconstruction (see config/econ.yaml)
python -m apps.infer -cfg ./configs/econ.yaml -in_dir ./examples -out_dir ./results -multi
# To generate the demo video of reconstruction results
python -m apps.multi_render -n <file_name>
-
Animation with SMPL-X sequences (ECON + HybrIK-X)
# 1. Use HybrIK-X to estimate SMPL-X pose sequences from input video
# 2. Rig ECON's reconstruction mesh, to be compatible with SMPL-X's parametrization (-dress for dress/skirts).
# 3. Animate with SMPL-X pose sequences obtained from HybrIK-X, getting <file_name>_motion.npz
# 4. Render the frames with Blender (rgb-partial texture, normal-normal colors), and combine them to get final video
python -m apps.avatarizer -n <file_name>
python -m apps.animation -n <file_name> -m <motion_name>
# Note: to install missing python packages into Blender
# blender -b --python-expr "__import__('pip._internal')._internal.main(['install', 'moviepy'])"
wget https://download.is.tue.mpg.de/icon/econ_empty.blend
blender -b --python apps.blender_dance.py -- normal <file_name> 10 > /tmp/NULL
Please consider cite HybrIK-X if it also helps on your project
@article{li2023hybrik,
title={HybrIK-X: Hybrid Analytical-Neural Inverse Kinematics for Whole-body Mesh Recovery},
author={Li, Jiefeng and Bian, Siyuan and Xu, Chao and Chen, Zhicun and Yang, Lixin and Lu, Cewu},
journal={arXiv preprint arXiv:2304.05690},
year={2023}
}
-
Gradio Demo
We also provide a UI for testing our method that is built with gradio. This demo also supports pose&prompt guided human image generation! Running the following command in a terminal will launch the demo:
git checkout main
python app.py
This demo is also hosted on HuggingFace Space
-
Full Texture Generation
Method 1: ECON+TEXTure
Please firstly follow the TEXTure's installation to setup the env of TEXTure.
# generate required UV atlas
python -m apps.avatarizer -n <file_name> -uv
# generate new texture using TEXTure
git clone https://github.com/YuliangXiu/TEXTure
cd TEXTure
ln -s ../ECON/results/econ/cache
python -m scripts.run_texture --config_path=configs/text_guided/avatar.yaml
Then check ./experiments/<file_name>/mesh for the results.
Please consider cite TEXTure if it also helps on your project
@article{richardson2023texture,
title={Texture: Text-guided texturing of 3d shapes},
author={Richardson, Elad and Metzer, Gal and Alaluf, Yuval and Giryes, Raja and Cohen-Or, Daniel},
journal={ACM Transactions on Graphics (TOG)},
publisher={ACM New York, NY, USA},
year={2023}
}
Method 2: TeCH
Please check out our new paper, TeCH: Text-guided Reconstruction of Lifelike Clothed Humans (Page, Code)
Please consider cite TeCH if it also helps on your project
@inproceedings{huang2024tech,
title={{TeCH: Text-guided Reconstruction of Lifelike Clothed Humans}},
author={Huang, Yangyi and Yi, Hongwei and Xiu, Yuliang and Liao, Tingting and Tang, Jiaxiang and Cai, Deng and Thies, Justus},
booktitle={International Conference on 3D Vision (3DV)},
year={2024}
}
More Qualitative Results
![]() |
|---|
| Challenging Poses |
![]() |
| Loose Clothes |
Citation
@inproceedings{xiu2023econ,
title = {{ECON: Explicit Clothed humans Optimized via Normal integration}},
author = {Xiu, Yuliang and Yang, Jinlong and Cao, Xu and Tzionas, Dimitrios and Black, Michael J.},
booktitle = {Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR)},
month = {June},
year = {2023},
}
Acknowledgments
We thank Lea Hering and Radek DanÄÄek for proof reading, Yao Feng, Haven Feng, and Weiyang Liu for their feedback and discussions, Tsvetelina Alexiadis for her help with the AMT perceptual study.
Here are some great resources we benefit from:
- ICON for SMPL-X Body Fitting
- BiNI for Bilateral Normal Integration
- MonoPortDataset for Data Processing, MonoPort for fast implicit surface query
- rembg for Human Segmentation
- Sapiens for normal estimation
- MediaPipe for full-body landmark estimation
- PyTorch-NICP for non-rigid registration
- smplx, PyMAF-X, PIXIE for Human Pose & Shape Estimation
- CAPE and THuman for Dataset
- PyTorch3D for Differential Rendering
Some images used in the qualitative examples come from pinterest.com.
This project has received funding from the European Unionâs Horizon 2020 research and innovation programme under the Marie SkÅodowska-Curie grant agreement No.860768 (CLIPE Project).
Contributors
Kudos to all of our amazing contributors! ECON thrives through open-source. In that spirit, we welcome all kinds of contributions from the community.
Contributor avatars are randomly shuffled.
License
This code and model are available for non-commercial scientific research purposes as defined in the LICENSE file. By downloading and using the code and model you agree to the terms in the LICENSE.
Disclosure
MJB has received research gift funds from Adobe, Intel, Nvidia, Meta/Facebook, and Amazon. MJB has financial interests in Amazon, Datagen Technologies, and Meshcapade GmbH. While MJB is a part-time employee of Meshcapade, his research was performed solely at, and funded solely by, the Max Planck Society.
Contact
For technical questions, please contact yuliang.xiu@tue.mpg.de
For commercial licensing, please contact ps-licensing@tue.mpg.de
Top Related Projects
PyTorch3D is FAIR's library of reusable components for deep learning with 3D data
This is the code for Deformable Neural Radiance Fields, a.k.a. Nerfies.
Instant neural graphics primitives: lightning fast NeRF and more
Make human motion capture easier.
SMPL-X
A Strong and Easy-to-use Single View 3D Hand+Body Pose Estimator
Convert
designs to code with AI
Introducing Visual Copilot: A new AI model to turn Figma designs to high quality code using your components.
Try Visual Copilot







