Infinite login loop with Nvidia proprietary graphics

I had similar issue with my laptop which was having Nvidia GTX 950M(almost close to what you have). My advice even if the proprietary Nvidia drivers might perform better - it's better to stick to the opensource versions as they seems to be more compatible(at least in my case for 2 machines during the last 6 months)

Here are the steps

Generally you should use the drivers from the official Ubuntu repositories. Because you are having problems, using the latest drivers might be better. Install the latest official stable NVIDIA drivers for the GEFORCE GTX 960M.

Based on this link you should install nvidia-361(which support GTX 960M). M is the mobile varient - on desktops you will find no M at the end of the model.

First uninstall the currently installed NVIDIA drivers.Boot the computer, when the GRUB menu appears ...

Highlight the Ubuntu menu entry and press the E key.Add nouveau.modeset=0 to the end of the linux line. Press F10 to boot the Ubuntu operating system.

When the login screen appears press Ctrl+Alt+F1.Enter your user name and the password, then execute :

sudo apt-get purge nvidia*  
sudo reboot  

Now install the latest official stable NVIDIA drivers.Boot the computer, when the GRUB menu appears ...

Highlight the Ubuntu menu entry and press the E key.Add nouveau.modeset=0 to the end of the linux line. Press F10 to boot the Ubuntu operating system.

When the login screen appears press Ctrl+Alt+F1. Enter your user name and the password, then execute :

sudo add-apt-repository ppa:graphics-drivers/ppa
sudo apt-get update
sudo apt-get install nvidia-361 nvidia-prime
sudo reboot  

Note : Maybe it is explicitly necessary to select the NVIDIA adapter in BIOS. When you want to use drivers 361, adding the PPA is not necessary. In this case the terminal commands you have to perform are these :

sudo apt-get update
sudo apt-get install nvidia-361
sudo reboot

In case you have installed the nvidia driver from their site then uninstall it as per that instructions.Uninstall that driver by running, as root, sh ./NVIDIA-Linux-x86_64-361.28.run and follow the on screen instructions.

Note : The solution I have provide has been tested on Ubuntu 14.04 LTS and Ubuntu 15.10 for two GPUs.