how to check the cuda version in linux code example Example 1: cuda version check nvcc --version Example 2: check for cuda version nvidia-smi nvcc --version