This video shows how to locally install Tencent Hunyuan3D-1 model for 3D generation.
Code:
conda create -n ai python=3.9 -y && conda activate ai
conda remove cuda-compiler
conda install gcc_linux-64=11.2.0 gxx_linux-64=11.2.0 -y
conda install cuda=11.8 -c nvidia -y
conda install pytorch=2.0.1 torchvision==0.15.2 pytorch-cuda=11.8 -c pytorch -c nvidia -y
conda install -c iopath iopath -y
conda install -c bottler nvidiacub -y
conda install pytorch3d -c pytorch3d -y
conda install anaconda::cmake -y
conda install conda-forge::lit-nlp -y
conda install anaconda::numpy=1.23.5 -y
git clone https://github.com/tencent/Hunyuan3D-1 && cd Hunyuan3D-1
#From below remove, pytorch3 from env_install.sh file.
chmod a+x env_install.sh
./env_install.sh
pip install huggingface_hub
huggingface-cli login
mkdir weights
huggingface-cli download tencent/Hunyuan3D-1 --local-dir ./weights
mkdir weights/hunyuanDiT
huggingface-cli download Tencent-Hunyuan/HunyuanDiT-v1.1-Diffusers-Distilled --local-dir ./weights/hunyuanDiT
python3 main.py --text_prompt "a lovely rabbit" --save_folder ./outputs/test/ --max_faces_num 90000 --do_texture_mapping --do_render
python3 main.py --image_prompt "/home/Ubuntu/images/komodo.png" --save_folder ./outputs/test/ --max_faces_num 90000 --do_texture_mapping --do_render
No comments:
Post a Comment