Last active
January 31, 2024 23:56
-
-
Save msaroufim/d004ad12adf1353610ad2794fb5fb858 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git clone https://github.com/pytorch/pytorch | |
conda install ccache -c conda-forge | |
pip install ninja | |
cd pytorch | |
git submodule deinit -f . | |
git clean -xdf | |
python setup.py clean | |
git submodule update | |
DEBUG=1 USE_DISTRIBUTED=0 USE_MKLDNN=0 BUILD_TEST=0 USE_FBGEMM=0 USE_NNPACK=0 USE_QNNPACK=0 USE_XNNPACK=0 USE_FLASH_ATTENTION=0 USE_MEM_EFF_ATTENTION=0 python setup.py develop |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Key things to keep in mind when building PyTorch from source
With all of this you should be able to build PyTorch in less than 15 min
Also https://github.com/pytorch/pytorch/blob/main/CONTRIBUTING.md is long but worth just booking a few hours to read end to end