Skip to content

Commit

Permalink
chore: Update installation guide and requirements.txt
Browse files Browse the repository at this point in the history
  • Loading branch information
ZhengChong committed Jul 23, 2024
1 parent bb344d8 commit 446279a
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 26 deletions.
27 changes: 27 additions & 0 deletions INSTALL.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Installation

## 1. Create A Conda Environment
```shell
conda create -n catvton python==3.9.0
conda activate catvton
```

## 2. Install Requirments
```shell
cd CatVTON-main # or your path to CatVTON project dir
pip install -r requirements.txt
```
**For inference only, the above packages are enough**.

## 3. Detectron2 & DensePose
If you want to deploy the gradio app with automatic mask generation, you need to install **Detectron2 & DensePose** by following commands:
```shell
# Detectron2
git clone https://github.com/facebookresearch/detectron2.git
python -m pip install -e detectron2
# DensePose
pip install git+https://github.com/facebookresearch/detectron2@main#subdirectory=projects/DensePose
```
When installing, ensure that the runtime CUDA version for PyTorch aligns with the CUDA version of your system; otherwise, errors may occur.

If there is a misalignment, the solution is to reinstall PyTorch with a CUDA version that matches your system's version. For more information on installing PyTorch with the correct CUDA version, you can visit the [PyTorch Get Started page for previous versions](https://pytorch.org/get-started/previous-versions/).
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,11 @@
- **`2024/7/21`**: Our [**Inference Code**](https://github.com/Zheng-Chong/CatVTON/blob/main/inference.py) and [**Weights** 🤗](https://huggingface.co/zhengchong/CatVTON) are released.
- **`2024/7/11`**: Our [**Online Demo**](http://120.76.142.206:8888) is released 😁.

## Installation
An [Installation Guide](https://github.com/Zheng-Chong/CatVTON/INSTALL.md) is provided to help build the conda environment for CatVTON. When deploying the app, you will need Detectron2 & DensePose, but these are not required for inference on datasets. Install the packages according to your needs.

## Deployment (Gradio App)

To deploy the Gradio App for CatVTON on your own mechine, just run the following command, and checkpoints will be automaticly download from HuggingFace.

```PowerShell
Expand Down
32 changes: 6 additions & 26 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,38 +1,18 @@
accelerate==0.31.0
asposestorage==1.0.2
caffe2==0.8.1
cityscapesscripts==2.2.3
cloudpickle==3.0.0
diffusers==0.29.2
docutils==0.21.2
fvcore==0.1.5.post20221221
gradio==4.38.1
gradio==4.39.0
huggingface_hub==0.23.4
joblib==1.4.2
matplotlib==3.9.1
mock==5.1.0
numexpr==2.10.1
numpy==2.0.1
onnx==1.16.1
opencv_contrib_python==4.10.0.84
numpy==1.26.4
opencv_python==4.10.0.84
opencv_python_headless==4.10.0.84
Pillow==10.4.0
psutil==6.0.0
pycocotools==2.0.8
pillow==10.3.0
PyYAML==6.0.1
PyYAML==6.0.1
recommonmark==0.7.1
scipy==1.14.0
scipy==1.13.1
setuptools==51.0.0
Shapely==2.0.5
skimage==0.0
Sphinx==7.4.7
sphinx_rtd_theme==2.0.0
tabulate==0.9.0
termcolor==2.4.0
scikit-image==0.24.0
torch==2.1.2
torchvision==0.16.2
tqdm==4.66.4
transformers==4.27.3
xformers==0.0.23.post1
Ninja==1.11.1.1

0 comments on commit 446279a

Please sign in to comment.