@ShuokaiPan   Don’t bother with NVidia repositories and apt-get.  There is a better way.
Download the Ubuntu 16.04 drivers from NVidia website here:
http://www.nvidia.com/object/unix.html 2
It is a “run” file, so you just run it with bash and it will do a full uninstall and reinstall of the driver.
Then download NVidia CUDA Docker image here and run “nvidia-smi” inside the Docker image:
https://hub.docker.com/r/nvidia/cuda/tags/ 3
Let us know what the output shows.