diff --git a/README.md b/README.md index 4c9bd4c8..035bb271 100644 --- a/README.md +++ b/README.md @@ -52,7 +52,11 @@ ``` 2. Install the dependencies: - + + There are two ways of installing dependencies. + + 1. Using a script (Linux & Conda only) + **Before running the following command there are somethings to note:** - By adding `--new-env`, a new conda environment named `trellis` will be created. If you want to use an existing conda environment, please remove this flag. - By default the `trellis` environment will use pytorch 2.4.0 with CUDA 11.8. If you want to use a different version of CUDA (e.g., if you have CUDA Toolkit 12.2 installed and do not want to install another 11.8 version for submodule compilation), you can remove the `--new-env` flag and manually install the required dependencies. Refer to [PyTorch](https://pytorch.org/get-started/previous-versions/) for the installation command. @@ -83,6 +87,42 @@ --demo Install all dependencies for demo ``` + 2. Using pip (Cross-platform & venv): + + **Note:** Preinstall CUDA SDK 12.4 and Python 3.10, 3.11, or 3.12. These versions are crucial. Other combinations may cause issues and will be discussed later. + + Steps: + + - **Create a virtual environment in the `Venv` directory:** + ```sh + python -m v Venv + ``` + + - **Activate the virtual environment:** + + On Windows, + ```cmd + Venv\Scripts\activate + ``` + On non-Windows, + ```sh + source ./Venv/Scripts/activate + ``` + + - **Install package using pip:** This may take a while. + ```sh + pip install -r requirements.txt + ``` + + - **Install extra packages with dependencies on PyTorch:** + ```sh + pip install -r requirements_extra.txt + ``` + + **Known Issues** + + 1. The ROCm platform is not supported. Additional work may be necessary to resolve these issues. + ## 🤖 Pretrained Models diff --git a/requirements.txt b/requirements.txt new file mode 100644 index 00000000..f2735367 --- /dev/null +++ b/requirements.txt @@ -0,0 +1,39 @@ +--extra-index-url https://download.pytorch.org/whl/cu124 +torch==2.5.1+cu124 +torchvision==0.20.1+cu124 +xformers==0.0.28.post3 + +pillow==10.2.0 +imageio==2.37.0 +imageio-ffmpeg==0.6.0 +tqdm==4.67.1 +easydict==1.13 +opencv-python-headless==4.11.0.86 +scipy==1.15.1 +ninja==1.11.1.3 +rembg==2.0.61 +onnxruntime==1.20.1 +trimesh==4.6.0 +xatlas==0.0.9 +pyvista==0.44.2 +pymeshfix==0.17.0 +igraph==0.11.8 +transformers==4.48.1 +wheel==0.45.1 + +git+https://github.com/EasternJournalist/utils3d.git@9a4eb15e4021b67b12c460c7057d642626897ec8 + +https://github.com/bdashore3/flash-attention/releases/download/v2.7.1.post1/flash_attn-2.7.1.post1+cu124torch2.5.1cxx11abiFALSE-cp310-cp310-win_amd64.whl; sys_platform == 'win32' and python_version == '3.10' +https://github.com/bdashore3/flash-attention/releases/download/v2.7.1.post1/flash_attn-2.7.1.post1+cu124torch2.5.1cxx11abiFALSE-cp311-cp311-win_amd64.whl; sys_platform == 'win32' and python_version == '3.11' +https://github.com/bdashore3/flash-attention/releases/download/v2.7.1.post1/flash_attn-2.7.1.post1+cu124torch2.5.1cxx11abiFALSE-cp312-cp312-win_amd64.whl; sys_platform == 'win32' and python_version == '3.12' +flash-attn; sys_platform != 'win32' + +--find-links https://nvidia-kaolin.s3.us-east-2.amazonaws.com/torch-2.5.1_cu124.html +kaolin + +git+https://github.com/NVlabs/nvdiffrast.git + +spconv-cu124==2.3.8 + +gradio==4.44.1 +gradio_litmodel3d==0.0.1 diff --git a/requirements_extra.txt b/requirements_extra.txt new file mode 100644 index 00000000..f2c1bdf1 --- /dev/null +++ b/requirements_extra.txt @@ -0,0 +1,2 @@ +git+https://github.com/JeffreyXiang/diffoctreerast.git +git+https://github.com/autonomousvision/mip-splatting.git#subdirectory=submodules/diff-gaussian-rasterization/