OpenChatKit
OpenChatKit copied to clipboard
Conda takes too long to install dependencies
Describe the bug
One user reported conda env create -f environment.yml taking over 60 minutes. We need a better solution.
To Reproduce Steps to reproduce the behavior:
- Run
conda env create -f environment.ymlfrom the root of the repo.
Expected behavior Should finish in a "reasonable" amount of time.
+1 on this.
After some research, many projects seem to be recommending mamba for faster installation (see this article for more details). I just tested it, and it does seem much faster.
Installing mamba itself takes about 30 seconds.
time conda install mamba -n base -c conda-forge
...
real 0m29.866s
user 0m20.274s
sys 0m2.779s
Installing the entire environment.yml takes about 2.5 minutes.
time mamba env create -f environment.yml -n OpenChatKit-Test
...
real 2m22.678s
user 2m20.410s
sys 0m10.147s
Normal conda commands appear to work just fine with this environment. I'm going to do a short training run and make sure it succeeds before updating the README.
For now, if others are running into this issue, please give mamba a try.
- Install mamba in base so it's available in all environments.
conda install mamba -n base -c conda-forge
- Create a new environment by running this command from the root of the repo:
mamba env create -f environment.yml -n OpenChatKit-Test
Training ran fine. I'll update the README to suggest using mamba.