Giter VIP home page Giter VIP logo

towards-implicit-text-guided-shape-generation's Introduction

Towards Implicit Text-Guided 3D Shape Generation

Towards Implicit Text-Guided 3D Shape Generation (CVPR2022)

Code for the paper [Towards Implicit Text-Guided 3D Shape Generation], CVPR 2022.

This code is based on IM-Net https://github.com/czq142857/IM-NET-pytorch

Authors: Zhengzhe Liu, Yi Wang, Xiaojuan Qi, Chi-Wing Fu

Installation

Requirements

  • Python 3.8.8
  • Pytorch 1.10.0
  • CUDA 11.3
  • h5py
  • scipy
  • mcubes
  • pytorch_lamb

Data Preparation

OR

  • Download the dataset.

  • unzip it to "generator" folder.

python 2_gather_256vox_16_32_64.py.py 

Pretrained Model

We provide pretrained models for each training step. Still download it here. Put them to "generation/checkpoint/color_all_ae_64/"

Inference

(1) Text-Guided Shape Generation

python main.py --res64 --sample_dir samples/im_ae_out --start 0 --end 7454 --high_resolution

You can generate coarse shapes fast by removing "--high_resolution"

(2) Diversified Generation

python main.py --div --sample_dir samples/im_ae_out --start 0 --end 7454 --high_resolution

Others:

(1) Auto-Encoder

python main.py --ae --sample_dir samples/im_ae_out --start 0 --end 7454

Training Generation Model

sh train.sh

Manipulation

Trained Model

We provide trained models here. Put them to "mainpulation/checkpoint/color_all_ae_64/"

Inference

python main.py --color_chair --sample_dir samples/im_ae_out --start 0 --end 10 --high_resolution
python main.py --color_table --sample_dir samples/im_ae_out --start 0 --end 10 --high_resolution
python main.py --shape_chair --sample_dir samples/im_ae_out --start 0 --end 10 --high_resolution
python main.py --shape_table --sample_dir samples/im_ae_out --start 0 --end 10 --high_resolution

You can generate coarse shapes fast by removing "--high_resolution"

Training Manipulation Model

Put the above "div.model64-199_raw.pth" in the generation-model set to "mainpulation/checkpoint/color_all_ae_64/" as the initialization model.

python main.py --color_chair --train --epoch 150 --sample_vox_size 64
python main.py --shape_chair --train --epoch 150 --sample_vox_size 64
python main.py --color_table --train --epoch 150 --sample_vox_size 64
python main.py --shape_table --train --epoch 150 --sample_vox_size 64

Contact

If you have any questions or suggestions about this repo, please feel free to contact me ([email protected]).

towards-implicit-text-guided-shape-generation's People

Contributors

liuzhengzhe avatar

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.