When I put the convolutional layer to cuda, I meet the error

username: huahangc
cooked: <pre><code class="lang-auto">import torch

a = torch.rand(1, 1, 10, 10)
b = torch.nn.Conv2d(1, 1, 1, 1)
b.cuda()(a.cuda())
</code></pre>
<p>raise <code>python: symbol lookup error: /home/hh/anaconda3/envs/aio/lib/python3.10/site-packages/torch/lib/../../nvidia/cudnn/lib/libcudnn_cnn_infer.so.8: undefined symbol: _ZN15TracebackLoggerC1EPKc, version libcudnn_ops_infer.so.8</code>, but if i use the <code>nn.Linear</code> this error wont appear. How can I solve that?<br>
`Collecting environment information…<br>
PyTorch version: 2.1.2+cu121<br>
Is debug build: False<br>
CUDA used to build PyTorch: 12.1<br>
ROCM used to build PyTorch: N/A</p>
<p>OS: Ubuntu 20.04.6 LTS (x86_64)<br>
GCC version: (Ubuntu 9.4.0-1ubuntu1~20.04.1) 9.4.0<br>
Clang version: Could not collect<br>
CMake version: version 3.21.0<br>
Libc version: glibc-2.31</p>
<p>Python version: 3.10.12 (main, Jul  5 2023, 18:54:27) [GCC 11.2.0] (64-bit runtime)<br>
Python platform: Linux-5.15.0-76-generic-x86_64-with-glibc2.31<br>
Is CUDA available: True<br>
CUDA runtime version: 11.3.58<br>
CUDA_MODULE_LOADING set to: LAZY<br>
GPU models and configuration: GPU 0: NVIDIA A100-PCIE-40GB<br>
Nvidia driver version: 525.125.06<br>
cuDNN version: Probably one of the following:<br>
/usr/local/cuda-11.3/targets/x86_64-linux/lib/libcudnn.so.8<br>
/usr/local/cuda-11.3/targets/x86_64-linux/lib/libcudnn_adv_infer.so.8<br>
/usr/local/cuda-11.3/targets/x86_64-linux/lib/libcudnn_adv_train.so.8<br>
/usr/local/cuda-11.3/targets/x86_64-linux/lib/libcudnn_cnn_infer.so.8<br>
/usr/local/cuda-11.3/targets/x86_64-linux/lib/libcudnn_cnn_train.so.8<br>
/usr/local/cuda-11.3/targets/x86_64-linux/lib/libcudnn_ops_infer.so.8<br>
/usr/local/cuda-11.3/targets/x86_64-linux/lib/libcudnn_ops_train.so.8<br>
HIP runtime version: N/A<br>
MIOpen runtime version: N/A<br>
Is XNNPACK available: True</p>
<p>CPU:<br>
Architecture:                    x86_64<br>
CPU op-mode(s):                  32-bit, 64-bit<br>
Byte Order:                      Little Endian<br>
Address sizes:                   46 bits physical, 48 bits virtual<br>
CPU(s):                          64<br>
On-line CPU(s) list:             0-63<br>
Thread(s) per core:              2<br>
Core(s) per socket:              16<br>
Socket(s):                       2<br>
NUMA node(s):                    2<br>
Vendor ID:                       GenuineIntel<br>
CPU family:                      6<br>
Model:                           79<br>
Model name:                      Intel(R) Xeon(R) CPU E5-2683 v4 @ 2.10GHz<br>
Stepping:                        1<br>
CPU MHz:                         1200.000<br>
CPU max MHz:                     3000.0000<br>
CPU min MHz:                     1200.0000<br>
BogoMIPS:                        4199.65<br>
Virtualization:                  VT-x<br>
L1d cache:                       1 MiB<br>
L1i cache:                       1 MiB<br>
L2 cache:                        8 MiB<br>
L3 cache:                        80 MiB<br>
NUMA node0 CPU(s):               0-15,32-47<br>
NUMA node1 CPU(s):               16-31,48-63<br>
Vulnerability Itlb multihit:     KVM: Mitigation: VMX disabled<br>
Vulnerability L1tf:              Mitigation; PTE Inversion; VMX conditional cache flushes, SMT vulnerable<br>
Vulnerability Mds:               Mitigation; Clear CPU buffers; SMT vulnerable<br>
Vulnerability Meltdown:          Mitigation; PTI<br>
Vulnerability Mmio stale data:   Mitigation; Clear CPU buffers; SMT vulnerable<br>
Vulnerability Retbleed:          Not affected<br>
Vulnerability Spec store bypass: Mitigation; Speculative Store Bypass disabled via prctl and seccomp<br>
Vulnerability Spectre v1:        Mitigation; usercopy/swapgs barriers and __user pointer sanitization<br>
Vulnerability Spectre v2:        Mitigation; Retpolines, IBPB conditional, IBRS_FW, STIBP conditional, RSB filling, PBRSB-eIBRS Not affected<br>
Vulnerability Srbds:             Not affected<br>
Vulnerability Tsx async abort:   Mitigation; Clear CPU buffers; SMT vulnerable<br>
Flags:                           fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp lm constant_tsc arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc cpuid aperfmperf pni pclmulqdq dtes64 monitor ds_cpl vmx smx est tm2 ssse3 sdbg fma cx16 xtpr pdcm pcid dca sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand lahf_lm abm 3dnowprefetch cpuid_fault epb cat_l3 cdp_l3 invpcid_single pti intel_ppin ssbd ibrs ibpb stibp tpr_shadow vnmi flexpriority ept vpid ept_ad fsgsbase tsc_adjust bmi1 hle avx2 smep bmi2 erms invpcid rtm cqm rdt_a rdseed adx smap intel_pt xsaveopt cqm_llc cqm_occup_llc cqm_mbm_total cqm_mbm_local dtherm ida arat pln pts md_clear flush_l1d</p>
<p>Versions of relevant libraries:<br>
[pip3] numpy==1.26.2<br>
[pip3] torch==2.1.2<br>
[pip3] triton==2.1.0<br>
[conda] cudatoolkit               11.1.1              ha002fc5_10    conda-forge<br>
[conda] numpy                     1.26.2                   pypi_0    pypi<br>
[conda] torch                     2.1.2                    pypi_0    pypi<br>
[conda] triton                    2.1.0                    pypi_0    pypi<br>
`</p>

username: ptrblck
cooked: <p>Your locally installed cuDNN library seems to be conflicting with the one installed from the PyPI wheels. Remove the global cuDNN library entirely or drop the path to it from <code>LD_LIBRARY_PATH</code>.</p>