改变本用户cuda环境位置
vim ~/.bashrc
# 注释掉或删除旧的 CUDA 路径 # export PATH=/usr/local/cuda-11.2/bin:$PATH # export LD_LIBRARY_PATH=/usr/local/cuda-11.2/lib64:$LD_LIBRARY_PATH # 添加新的 Conda 环境 CUDA 路径 export CUDA_HOME=~/anaconda3/envs/tf_gpu export PATH=$CUDA_HOME/bin:$PATH export LD_LIBRARY_PATH=$CUDA_HOME/lib:$LD_LIBRARY_PATH
source ~/.bashrc # 或者对应的配置文件