GUI for visualization and interactive editing of SMPL-family body models ie. SMPL, SMPL-X, MANO, FLAME.

Overview

Body Model Visualizer

Introduction

This is a simple Open3D-based GUI for SMPL-family body models. This GUI lets you play with the shape, expression, and pose parameters of SMPL, SMPL-X, MANO, FLAME body models. Features include:

  • Interactive editing of shape, expression, pose parameters
01_model_editing.mp4
  • Visualize body model joints and joint names
02_visualize_joints.mp4
  • Simple IK solver to match an input pose
03_simple_ik.mp4
  • Save edited model parameters
04_save_params.mp4
  • View controls
05_viewing.mp4
  • Lighting controls
06_lighting.mp4
  • Material settings
07_material.mp4

Even though there are existing Blender/Unity plugins for these models, our main audience here is researchers who would like to quickly edit/visualize body models without the need to install a graphics software.

Installation

Clone the repo and install the requirements (use python3.9).

pip install -r requirements.txt

Download the SMPL, SMPL-X, MANO, FLAME body models:

Copy downloaded files under data/body_models, this folder should look like:

data
└── body_models
    ├── flame
    │   ├── FLAME_FEMALE.pkl
    │   ├── FLAME_MALE.pkl
    │   ├── FLAME_NEUTRAL.pkl
    │   ├── flame_dynamic_embedding.npy
    │   └── flame_static_embedding.pkl
    ├── mano
    │   ├── MANO_LEFT.pkl
    │   └── MANO_RIGHT.pkl
    ├── smpl
    │   ├── SMPL_FEMALE.pkl
    │   ├── SMPL_MALE.pkl
    │   └── SMPL_NEUTRAL.pkl
    └── smplx
        ├── SMPLX_FEMALE.npz
        ├── SMPLX_MALE.npz
        └── SMPLX_NEUTRAL.npz

Finally, run:

python main.py

Guidelines

Saved model parameters

File > Save Model Params lets you save the edited body model parameters. Output is a pickled python dictionary with below keys:

dict_keys(['betas', 'expression', 'gender', 'body_model', 
           'joints', 'body_pose', 'global_orient'])
Comments
  • Follow the instructions, encounter segmentation error after running

    Follow the instructions, encounter segmentation error after running "python main.py"

    Hi, thanks for the great work. I set the environment as the instructions. But when I run the main.py file, it reports "Segmentation Fault" Here is the packages I've installed as following

    addict               2.4.0
    anyio                3.4.0
    argon2-cffi          21.3.0
    argon2-cffi-bindings 21.2.0
    attrs                21.2.0
    Babel                2.9.1
    backcall             0.2.0
    bleach               4.1.0
    certifi              2021.10.8
    cffi                 1.15.0
    charset-normalizer   2.0.9
    chumpy               0.70
    cycler               0.11.0
    debugpy              1.5.1
    decorator            5.1.0
    defusedxml           0.7.1
    deprecation          2.1.0
    entrypoints          0.3
    fonttools            4.28.5
    idna                 3.3
    ipdb                 0.13.9
    ipykernel            6.6.0
    ipython              7.30.1
    ipython-genutils     0.2.0
    ipywidgets           7.6.5
    jedi                 0.18.1
    Jinja2               3.0.3
    joblib               1.1.0
    json5                0.9.6
    jsonschema           4.3.2
    jupyter-client       7.1.0
    jupyter-core         4.9.1
    jupyter-packaging    0.11.1
    jupyter-server       1.13.1
    jupyterlab           3.2.5
    jupyterlab-pygments  0.1.2
    jupyterlab-server    2.10.1
    jupyterlab-widgets   1.0.2
    kiwisolver           1.3.2
    loguru               0.5.3
    MarkupSafe           2.0.1
    matplotlib           3.5.1
    matplotlib-inline    0.1.3
    mistune              0.8.4
    nbclassic            0.3.4
    nbclient             0.5.9
    nbconvert            6.3.0
    nbformat             5.1.3
    nest-asyncio         1.5.4
    notebook             6.4.6
    numpy                1.21.5
    open3d               0.14.1
    packaging            21.3
    pandas               1.3.5
    pandocfilters        1.5.0
    parso                0.8.3
    pexpect              4.8.0
    pickleshare          0.7.5
    Pillow               8.4.0
    pip                  21.2.4
    prometheus-client    0.12.0
    prompt-toolkit       3.0.24
    ptyprocess           0.7.0
    pycparser            2.21
    Pygments             2.10.0
    pyparsing            3.0.6
    pyrsistent           0.18.0
    python-dateutil      2.8.2
    pytz                 2021.3
    PyYAML               6.0
    pyzmq                22.3.0
    requests             2.26.0
    scikit-learn         1.0.2
    scipy                1.7.3
    Send2Trash           1.8.0
    setuptools           58.0.4
    six                  1.16.0
    smplx                0.1.28
    sniffio              1.2.0
    terminado            0.12.1
    testpath             0.5.0
    threadpoolctl        3.0.0
    toml                 0.10.2
    tomlkit              0.8.0
    torch                1.10.1
    tornado              6.1
    tqdm                 4.62.3
    traitlets            5.1.1
    typing_extensions    4.0.1
    urllib3              1.26.7
    wcwidth              0.2.5
    webencodings         0.5.1
    websocket-client     1.2.3
    wheel                0.37.0
    widgetsnbextension   3.5.2
    opened by AndyVerne 2
  • Installation error -- no matching distribution found for open3d

    Installation error -- no matching distribution found for open3d

    Running through the installation instructions yields an error in my WSL env:

    (test) root@mypc:~/body-model-visualizer# pip install -r requirements.txt
    Collecting ipdb==0.13.9
      Using cached ipdb-0.13.9.tar.gz (16 kB)
    Collecting joblib==1.1.0
      Using cached joblib-1.1.0-py2.py3-none-any.whl (306 kB)
    Collecting loguru==0.5.3
      Using cached loguru-0.5.3-py3-none-any.whl (57 kB)
    Collecting matplotlib==3.5.1
      Using cached matplotlib-3.5.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.whl (11.3 MB)
    Collecting numpy==1.21.5
      Using cached numpy-1.21.5-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl (15.7 MB)
    ERROR: Could not find a version that satisfies the requirement open3d==0.14.1 (from -r requirements.txt (line 6)) (from versions: 0.10.0.0, 0.11.0, 0.11.1, 0.11.2,0.12.0, 0.13.0)
    ERROR: No matching distribution found for open3d==0.14.1 (from -r requirements.txt (line 6))
    (test) root@mypc:~/body-model-visualizer# 
    

    I can manually run pip install open3d, but that installs version 0.13.0. I assume this has something to do with my janky WSL setup, but I've been trying to debug it for a while and have not had any luck yet. I'm wondering if this is a bug in your repo's latest version?

    opened by domattioli 0
  • How to use saved .pkl parameters file?

    How to use saved .pkl parameters file?

    I have modified the smpl model and saved the pkl file,but i not load it in SMPL code. `def ready_arguments(fname_or_dict):

    if not isinstance(fname_or_dict, dict):
        #dd = pickle.load(open(fname_or_dict))
        dd = pickle.load(open(fname_or_dict,"rb"),encoding='iso-8859-1')
    else:
        dd = fname_or_dict
        
    backwards_compatibility_replacements(dd) `
    

    UnpicklingError invalid load key, '\x27'. File "/home/lrd/data/lrd/body-model-visualizer-filer/SMPL_python_v.1.1.0/smpl/smpl_webuser/serialization.py", line 81, in ready_arguments dd = pickle.load(open(fname_or_dict,"rb"),encoding='iso-8859-1') File "/home/lrd/data/lrd/body-model-visualizer-filer/SMPL_python_v.1.1.0/smpl/smpl_webuser/serialization.py", line 117, in load_model dd = ready_arguments(fname_or_dict) File "/home/lrd/data/lrd/body-model-visualizer-filer/SMPL_python_v.1.1.0/smpl/smpl_webuser/hello_world/hello_smpl.py", line 48, in <module> m = load_model( '/home/lrd/data/lrd/body-model-visualizer-filer/abc.pkl' )

    sometimes,it is other error. I don't konw how to use this saved parameters.

    opened by LRuid 0
  • Not able to load the saved parameters

    Not able to load the saved parameters

    Hi,

    I successfully run the GUI, change the joint rotation, and saved the parameters. However, I cannot load the .pkl file.

    Tried using

    import pickle
    
    file_name = '../subject2_Tpose.pkl'
    
    with open(file_name, 'rb') as f:  
        subject2_Tpose = pickle.load(f)  
        
    

    and

    import torch
    
    subject2_Tpose = torch.load(file_name)
    

    Both return the same error:

    UnpicklingError: A load persistent id instruction was encountered,
    but no persistent_load function was specified.
    

    The torch version is the same as where I ran the main.py. Any solution for this?

    opened by SizheAn 0
  • How can I visualize my own smpl model?

    How can I visualize my own smpl model?

    I already have some smpl pkl file and I want to use this application to view the model. It seems the codes can only modify based on the original smpl model. Thank you so mush if you could help with this!

    opened by kkpetra 0
Releases(v0.1)
Owner
Muhammed Kocabas
Muhammed Kocabas
Flame Graphs visualize profiled code

Flame Graphs visualize profiled code

Brendan Gregg 14.1k Jan 3, 2023
This is a super simple visualization toolbox (script) for transformer attention visualization ✌

Trans_attention_vis This is a super simple visualization toolbox (script) for transformer attention visualization ✌ 1. How to prepare your attention m

Mingyu Wang 3 Jul 9, 2022
Interactive Data Visualization in the browser, from Python

Bokeh is an interactive visualization library for modern web browsers. It provides elegant, concise construction of versatile graphics, and affords hi

Bokeh 17.1k Dec 31, 2022
Interactive Data Visualization in the browser, from Python

Bokeh is an interactive visualization library for modern web browsers. It provides elegant, concise construction of versatile graphics, and affords hi

Bokeh 14.7k Feb 13, 2021
Interactive Data Visualization in the browser, from Python

Bokeh is an interactive visualization library for modern web browsers. It provides elegant, concise construction of versatile graphics, and affords hi

Bokeh 14.7k Feb 18, 2021
SummVis is an interactive visualization tool for text summarization.

SummVis is an interactive visualization tool for analyzing abstractive summarization model outputs and datasets.

Robustness Gym 246 Dec 8, 2022
Learning Convolutional Neural Networks with Interactive Visualization.

CNN Explainer An interactive visualization system designed to help non-experts learn about Convolutional Neural Networks (CNNs) For more information,

Polo Club of Data Science 6.3k Jan 1, 2023
A dashboard built using Plotly-Dash for interactive visualization of Dex-connected individuals across the country.

Dashboard For The DexConnect Platform of Dexterity Global Working prototype submission for internship at Dexterity Global Group. Dashboard for real ti

Yashasvi Misra 2 Jun 15, 2021
Graphical display tools, to help students debug their class implementations in the Carcassonne family of projects

carcassonne_tools Graphical display tools, to help students debug their class implementations in the Carcassonne family of projects NOTE NOTE NOTE The

null 1 Nov 8, 2021
Fast data visualization and GUI tools for scientific / engineering applications

PyQtGraph A pure-Python graphics library for PyQt5/PyQt6/PySide2/PySide6 Copyright 2020 Luke Campagnola, University of North Carolina at Chapel Hill h

pyqtgraph 3.1k Jan 8, 2023
Fast data visualization and GUI tools for scientific / engineering applications

PyQtGraph A pure-Python graphics library for PyQt5/PyQt6/PySide2/PySide6 Copyright 2020 Luke Campagnola, University of North Carolina at Chapel Hill h

pyqtgraph 2.3k Feb 13, 2021
Fast data visualization and GUI tools for scientific / engineering applications

PyQtGraph A pure-Python graphics library for PyQt5/PyQt6/PySide2/PySide6 Copyright 2020 Luke Campagnola, University of North Carolina at Chapel Hill h

pyqtgraph 2.3k Feb 17, 2021
An interactive GUI for WhiteboxTools in a Jupyter-based environment

whiteboxgui An interactive GUI for WhiteboxTools in a Jupyter-based environment GitHub repo: https://github.com/giswqs/whiteboxgui Documentation: http

Qiusheng Wu 105 Dec 15, 2022
Boltzmann visualization - Visualize the Boltzmann distribution for simple quantum models of molecular motion

Boltzmann visualization - Visualize the Boltzmann distribution for simple quantum models of molecular motion

null 1 Jan 22, 2022
Debugging, monitoring and visualization for Python Machine Learning and Data Science

Welcome to TensorWatch TensorWatch is a debugging and visualization tool designed for data science, deep learning and reinforcement learning from Micr

Microsoft 3.3k Dec 27, 2022
China and India Population and GDP Visualization

China and India Population and GDP Visualization Historical Population Comparison between India and China This graph shows the population data of Indi

Nicolas De Mello 10 Oct 27, 2021
Exploratory analysis and data visualization of aircraft accidents and incidents in Brazil.

Exploring aircraft accidents in Brazil Occurrencies with aircraft in Brazil are investigated by the Center for Investigation and Prevention of Aircraf

Augusto Herrmann 5 Dec 14, 2021
Farhad Davaripour, Ph.D. 1 Jan 5, 2022
Apache Superset is a Data Visualization and Data Exploration Platform

Superset A modern, enterprise-ready business intelligence web application. Why Superset? | Supported Databases | Installation and Configuration | Rele

The Apache Software Foundation 50k Jan 6, 2023