RuntimeError: Unexpected error from cudaGetDeviceCount()

Based on this issue other users were running into the same error message if

  • their setup was broken due to a driver/library mismatch (rebooting seemed to solve the issue)
  • their installed drivers didn’t match the user-mode driver inside a docker container (and forward compatibility failed due to the usage of non-server GPUs)

Was your setup working before and if so, what changed?