conda activate ./env
python <file>
python -m pip install <package>
conda install <library>
conda deactivate
Setup
- Download Miniforge3 (Conda installer) for macOS arm64 chips (M1, M1 Pro, M1 Max).
- Install Miniforge3 into home directory.
chmod +x ~/Downloads/Miniforge3-MacOSX-arm64.sh
sh ~/Downloads/Miniforge3-MacOSX-arm64.sh
source ~/miniforge3/bin/activate
- Restart terminal.
- Make and activate Conda environment. Note: Python 3.8 is the most stable for using the following setup.
conda create --prefix ./env python=3.8
conda activate ./env
- Install must have packages.
conda install pytorch-nightly::pytorch torchvision torchaudio -c pytorch-nightly
conda install pandas numpy matplotlib scikit-learn notebook
- https://colab.research.google.com/github/ - open any notebook from github in colab select GPU and train faster
jupyter nbconvert --clear-output --inplace notebook.ipynb
- clear notebook output in all cells