git clone https://github.com/amirhertz/spaghetti && cd spaghetti
conda env create -f environment.yml
conda activate spaghetti
Install Pytorch. The installation during development and testing was pytorch==1.9.0 cudatoolkit=11.1
Download pre-trained models
python download_weights.py
Run demo
python demo.py --model_name chairs_large --shape_dir samples
or
python demo.py --model_name airplanes --shape_dir samples
User controls
python shape_inversion.py --model_name <model_name> --source training --mesh_path --num_samples <num_samples>
python shape_inversion.py --model_name <model_name> --source random --mesh_path --num_samples <num_samples>
python shape_inversion.py --model_name <model_name> --mesh_path <mesh_path>
For example, to add the provided sample chair to the exiting chairs in the demo:
python shape_inversion.py --model_name chairs_large --mesh_path ./assets/mesh/example.obj
Coming soon.