Rtx 3060 can support cuda with pytorch

This is a relevant question that I didn’t think I needed to check before buying GeForce RTX 3060 :').

I researched a lot (after having the new machine, of course) on how to use PyTorch with a RTX 3060 card, specially with older versions or torch (0.4.0) and torchvision (0.2.1), but no luck with that. RTX 3060 and these packages apparently doesn’t have compatibility with the same versions of CUDA and cuDNN. I tried to do this by using different combinations with compiled versions available in conda, but didn’t work, maybe it could work if you recompile from source these packages.

After all this, actually I was able to use RTX 3060 effectively with latest versions of all these dependencies with two methods:

  1. Using a conda env, and latest versions published in pytorch site (Start Locally | PyTorch):
conda create -n rtx_3060 python=3.6.5
conda activate rtx_3060
conda install pytorch torchvision torchaudio cudatoolkit=11.1 -c pytorch -c nvidia
  1. Using LambdaLabs (Install TensorFlow & PyTorch for the RTX 3090, 3080, 3070):
LAMBDA_REPO=$(mktemp) && \
wget -O${LAMBDA_REPO} https://lambdalabs.com/static/misc/lambda-stack-repo.deb && \
sudo dpkg -i ${LAMBDA_REPO} && rm -f ${LAMBDA_REPO} && \
sudo apt-get update && sudo apt-get install -y lambda-stack-cuda

Reboot your machine.

LAMBDA_REPO=$(mktemp) && \
wget -O${LAMBDA_REPO} https://lambdalabs.com/static/misc/lambda-stack-repo.deb && \
sudo dpkg -i ${LAMBDA_REPO} && rm -f ${LAMBDA_REPO} && \
sudo apt-get update && \
sudo apt-get --yes upgrade && \
sudo apt-get install --yes --no-install-recommends lambda-server && \
sudo apt-get install --yes --no-install-recommends nvidia-headless-455 && \
sudo apt-get install --yes --no-install-recommends lambda-stack-cuda

Reboot your machine.

*** The good thing about this method is that if you have your current environment messed up, lambda-stack is going to actually fix it.

Cheers.

Update: Gist created because of this post PyTorch on RTX 3060 · GitHub

1 Like