diff --git a/easybuild/easyconfigs/p/PyTorch-bundle/PyTorch-bundle-2.1.2-foss-2023a-CUDA-12.1.1.eb b/easybuild/easyconfigs/p/PyTorch-bundle/PyTorch-bundle-2.1.2-foss-2023a-CUDA-12.1.1.eb index 2ed110edd50..581b953ab89 100644 --- a/easybuild/easyconfigs/p/PyTorch-bundle/PyTorch-bundle-2.1.2-foss-2023a-CUDA-12.1.1.eb +++ b/easybuild/easyconfigs/p/PyTorch-bundle/PyTorch-bundle-2.1.2-foss-2023a-CUDA-12.1.1.eb @@ -39,12 +39,9 @@ exts_list = [ 'source_urls': ['https://github.com/pytorch/data/archive'], 'sources': [{'download_filename': 'v%(version)s.tar.gz', 'filename': '%(name)s-%(version)s.tar.gz'}], 'checksums': ['ef9bbdcee759b53c3c9d99e76eb0a66da33d36bfb7f859a25a9b5e737a51fa23'], - }), ('torchtext', '0.16.2', { - 'patches': [ - 'torchtext-0.14.1_use-system-libs.patch', - ], + 'patches': ['torchtext-0.14.1_use-system-libs.patch'], 'source_urls': ['https://github.com/pytorch/text/archive'], 'sources': [{'download_filename': 'v%(version)s.tar.gz', 'filename': '%(name)s-%(version)s.tar.gz'}], 'checksums': [ @@ -54,6 +51,8 @@ exts_list = [ ], }), ('torchvision', '0.16.2', { + 'preinstallopts': 'WITH_CUDA=1', + 'installopts': '-v', 'patches': ['torchvision-0.16.2_ffmpeg-6.0-fix.patch'], 'source_urls': ['https://github.com/pytorch/vision/archive'], 'sources': [{'download_filename': 'v%(version)s.tar.gz', 'filename': '%(name)s-%(version)s.tar.gz'}], @@ -64,11 +63,16 @@ exts_list = [ ], }), ('torchaudio', '2.2.1', { + 'installopts': '--no-use-pep517 -v', + 'patches': ['torchaudio-2.2.1_use-external-sox.patch'], + 'preinstallopts': 'rm -r third_party/{sox,ffmpeg/multi} && USE_CUDA=1 USE_OPENMP=1 USE_FFMPEG=1 FFMPEG_ROOT="$EBROOTFFMPEG"', 'source_urls': ['https://github.com/pytorch/audio/archive'], 'sources': [{'download_filename': 'v%(version)s.tar.gz', 'filename': '%(name)s-%(version)s.tar.gz'}], - 'checksums': ['5f2a9cda9369ff348d1d7ca2c0a1f01afc9ebff1a13df9775c22aa5c43f5b0f1'], - 'preinstallopts': 'USE_FFMPEG=1', - 'installopts': '--no-use-pep517', + 'checksums': [ + {'torchaudio-2.2.1.tar.gz': '5f2a9cda9369ff348d1d7ca2c0a1f01afc9ebff1a13df9775c22aa5c43f5b0f1'}, + {'torchaudio-2.2.1_use-external-sox.patch': + 'fc97b2bdf0ab16b9c4706bf2a31dd72d0ecb09e4af2f9c4a34e18fca8e0d165d'}, + ], }), ('pytorch-ignite', '0.4.13', { 'modulename': 'ignite', diff --git a/easybuild/easyconfigs/p/PyTorch-bundle/torchaudio-2.2.1_use-external-sox.patch b/easybuild/easyconfigs/p/PyTorch-bundle/torchaudio-2.2.1_use-external-sox.patch new file mode 100644 index 00000000000..72d47e2c34d --- /dev/null +++ b/easybuild/easyconfigs/p/PyTorch-bundle/torchaudio-2.2.1_use-external-sox.patch @@ -0,0 +1,14 @@ +Author: Jasper Grimm +use external Sox library instead of fetching and building at build time +diff -Nru audio-2.2.1.orig/CMakeLists.txt audio-2.2.1/CMakeLists.txt +--- audio-2.2.1.orig/CMakeLists.txt 2024-02-29 12:56:03.027016456 +0000 ++++ audio-2.2.1/CMakeLists.txt 2024-02-29 12:56:35.286922379 +0000 +@@ -167,7 +167,7 @@ + + add_subdirectory(src/libtorchaudio) + if (BUILD_SOX) +- add_subdirectory(third_party/sox) ++ # add_subdirectory(third_party/sox) + add_subdirectory(src/libtorchaudio/sox) + endif() + if (USE_FFMPEG)