FULL INSTALLATION INSTRUCTIONS with CONDA
miquel-espinosa opened this issue · 0 comments
miquel-espinosa commented
I found extremely tricky to get all the dependencies right, to install detectron2
and then Matcher
.
So I am leaving here the instructions to set up the environment.
# Create conda env
conda create --name matcher python==3.9 -y
conda activate matcher
# Install torch
pip install torch torchvision
# Install gcc and g++ with conda
conda install -c conda-forge pybind11
conda install -c conda-forge gxx
conda install -c anaconda gcc_linux-64
conda upgrade -c conda-forge --all
# Install detectron2 (specific version)
pip install 'git+https://github.com/facebookresearch/detectron2.git@v0.6'
# Install matcher
git clone https://github.com/aim-uofa/Matcher.git
cd Matcher
pip install -r requirements.txt
# Install additional packages (nvitop is optional)
pip install scikit-learn tensorboardX nvitop
# Download models
mkdir models
cd models
wget https://dl.fbaipublicfiles.com/segment_anything/sam_vit_h_4b8939.pth
wget https://github.com/UX-Decoder/Semantic-SAM/releases/download/checkpoint/swint_only_sam_many2many.pth
wget https://dl.fbaipublicfiles.com/dinov2/dinov2_vitl14/dinov2_vitl14_pretrain.pth