Package Details: python-pytorch-opt-cuda12.9 2.10.0-2

Git Clone URL: https://aur.archlinux.org/python-pytorch-cuda12.9.git (read-only, click to copy)
Package Base: python-pytorch-cuda12.9
Description: Tensors and Dynamic neural networks in Python with strong GPU acceleration (Maxwell/Pascal/Volta support) (with CUDA 12.9 and AVX2 CPU optimizations)
Upstream URL: https://pytorch.org
Licenses: BSD-3-Clause-Modification
Conflicts: python-pytorch
Provides: python-pytorch, python-pytorch-cuda, python-pytorch-cuda12.9
Submitter: piernov
Maintainer: piernov
Last Packager: piernov
Votes: 0
Popularity: 0.000000
First Submitted: 2025-10-19 10:58 (UTC)
Last Updated: 2026-02-05 12:58 (UTC)

Required by (341)

Sources (46)

Latest Comments

skualos commented on 2026-01-18 07:26 (UTC) (edited on 2026-01-18 07:26 (UTC) by skualos)

Thanks @pieronv. A virtual env is much better solution, I didn't know the packages were shipped with the CUDA dependencies included. I already have it up and running :) In the meantime, pytorch has been compiling with a single process for about 24h now, but it hasn't reached the failure point yet (just over 3700).

I think my ccache is working fine. But even when I just run makepkg --noprepare, all the third party git repos get updated anyway, which I think in turn triggers re-compiling of most files ?

piernov commented on 2026-01-17 11:05 (UTC)

@skualos You can try. If your ccache is working properly and your environment doesn't change, the next build should go through the already built objects pretty fast. But the stuff staring around the mid-3000s is extremely demanding, I have not investigated why.

Alternatively I'd suggest using a virtual environment with e.g. uv and using the PyTorch packages for CUDA 12.6. These still support Pascal for now.

skualos commented on 2026-01-17 10:50 (UTC)

@piernov Thanks for the info. I only have 32GiB of memory... Do you think compiling could work with a single process and 32 GiB ? That could take a few days to complete I imagine.

The only alternative I see for now is using a pre-built docker image. But I'd prefer to avoid docker if possible. Any other suggestions ? Maybe it's time for a laptop with a GPU newer than Pascal :'( lol

piernov commented on 2026-01-17 10:32 (UTC)

@skualos

nvcc error   : '"$CICC_PATH/cicc"' died due to signal 9 (Kill signal)

OoM killer triggered most likely.

Building this requires insane amounts of RAM especially with several of jobs in parallel. We're talking about likely more than a hundred or two GiB. Good luck.

skualos commented on 2026-01-17 04:36 (UTC)

I've been trying to compile python-pytorch-cuda12.9 for a few days now and would really appreciate some help. I was able to makepkg and install cuda-12.9, cudnn9.10-cuda12.9 and nccl-cuda12.9 But when compiling python-pytorch-cuda12.9, for the first couple times it would crash so bad that it would freeze my whole graphical session. I was able to solve that setting MAX_JOBS=10 instead of 20 on the PKGBUILD file.

But now, after several hours of build, I get the below error. I'm not really sure how to debug or fix that. Full logs are here

[3717/7529] /usr/bin/ccache /opt/cuda/bin/nvcc 
-forward-unknown-to-host-compiler 
-ccbin=/usr/bin/g++-14 
-DAT_PER_OPERATOR_HEADERS 
-DFLASHATTENTION_DISABLE_ALIBI 
-DFLASHATTENTION_DISABLE_SOFTCAP 
-DFLASH_NAMESPACE=pytorch_flash 
-DFMT_HEADER_ONLY=1 
-DGFLAGS_IS_A_DLL=0 
-DGLOG_USE_GFLAGS 
-DGLOG_USE_GLOG_EXPORT 
-DHAVE_MALLOC_USABLE_SIZE=1 
-DHAVE_MMAP=1 
-DHAVE_SHM_OPEN=1 
-DHAVE_SHM_UNLINK=1 
-DIDEEP_USE_MKL 
-DMINIZ_DISABLE_ZIP_READER_CRC32_CHECKS 
-DONNXIFI_ENABLE_EXT=1 
-DONNX_ML=1 
-DONNX_NAMESPACE=onnx_torch 
-DPROTOBUF_USE_DLLS 
-DTORCH_CUDA_BUILD_MAIN_LIB 
-DTORCH_CUDA_USE_NVTX3 
-DUNFUSE_FMA 
-DUSE_C10D_GLOO 
-DUSE_C10D_MPI 
-DUSE_C10D_NCCL 
-DUSE_CUDA 
-DUSE_CUFILE 
-DUSE_DISTRIBUTED 
-DUSE_EXTERNAL_MZCRC 
-DUSE_FLASH_ATTENTION 
-DUSE_MEM_EFF_ATTENTION 
-DUSE_NCCL 
-DUSE_RPC 
-DUSE_TENSORPIPE 
-D_FILE_OFFSET_BITS=64 
-Dtorch_cuda_EXPORTS 
-I/home/starch/builds/aur/python-pytorch-cuda12.9/src/pytorch-cuda/build/aten/src 
...
-I/home/starch/builds/aur/python-pytorch-cuda12.9/src/pytorch-cuda/torch/csrc/api/include 
-isystem /home/starch/builds/aur/python-pytorch-cuda12.9/src/pytorch-cuda/build/third_party/gloo 
...
-isystem /home/starch/builds/aur/python-pytorch-cuda12.9/src/pytorch-cuda/cmake/../third_party/cudnn_frontend/include 
-DLIBCUDACXX_ENABLE_SIMPLIFIED_COMPLEX_OPERATIONS 
-Xfatbin 
-compress-all 
-DONNX_NAMESPACE=onnx_torch 
-gencode arch=compute_52,code=sm_52 
...
-gencode arch=compute_121,code=sm_121 
-Xcudafe 
--diag_suppress=cc_clobber_ignored,--diag_suppress=field_without_dll_interface,--diag_suppress=base_class_has_different_dll_interface,--diag_suppress=dll_interface_conflict_none_assumed,--diag_suppress=dll_interface_conflict_dllexport_assumed,--diag_suppress=bad_friend_decl 
--expt-relaxed-constexpr 
--expt-extended-lambda 
-Xfatbin 
-compress-all 
-Wno-deprecated-gpu-targets 
--expt-extended-lambda 
-DCUB_WRAPPED_NAMESPACE=at_cuda_detail 
-DCUDA_HAS_FP16=1 
-D__CUDA_NO_HALF_OPERATORS__ 
-D__CUDA_NO_HALF_CONVERSIONS__ 
-D__CUDA_NO_HALF2_OPERATORS__ 
-D__CUDA_NO_BFLOAT16_CONVERSIONS__ 
-DC10_NODEPRECATED 
-O3 
-DNDEBUG 
-std=c++17 
-Xcompiler=-fPIC   
-march=x86-64 
-DMKL_HAS_SBGEMM 
-DMKL_HAS_SHGEMM 
-DTORCH_USE_LIBUV 
-DCAFFE2_USE_GLOO 
-Xcompiler 
-Wall 
-Wextra 
-Wdeprecated 
-Wunused 
-Wno-unused-parameter 
-Wno-missing-field-initializers 
-Wno-array-bounds 
-Wno-unknown-pragmas 
-Wno-strict-overflow 
-Wno-strict-aliasing 
-Wredundant-move 
-Wno-maybe-uninitialized 
-MD 
-MT caffe2/CMakeFiles/torch_cuda.dir/__/aten/src/ATen/native/cuda/TensorModeKernel.cu.o 
-MF caffe2/CMakeFiles/torch_cuda.dir/__/aten/src/ATen/native/cuda/TensorModeKernel.cu.o.d 
-x cu 
-c /home/starch/builds/aur/python-pytorch-cuda12.9/src/pytorch-cuda/aten/src/ATen/native/cuda/TensorModeKernel.cu 
-o caffe2/CMakeFiles/torch_cuda.dir/__/aten/src/ATen/native/cuda/TensorModeKernel.cu.o

ninja: build stopped: subcommand failed.

ERROR Backend subprocess exited when trying to invoke build_wheel
==> ERROR: A failure occurred in build().
Aborting...