Problem with cuda

My program is showing that cuda is available when running the command torch.cuda.available()
but when I try to run my model on cuda by typing model.cuda() it is not running and showing cuda is not found. Can anyone explain me how to run my model on gpu.

Command is torch.cuda.is_available() I tried reinstalling pytorch on my laptop and the gpu I am using is gtx 1050 ti,os ->windows 10,platform -> Anaconda(Jupyter) and I also tried different commands then also my problem is not solved

Which driver and CUDA version are you using?
Did CUDA work before?
If you’ve just installed all drivers etc., did you restart your machine?

I solved this problem by reinstalling with cuda version 10.0
Before I installed pytorch with cuda version 9.0. It not worked properly and my model not utilized gpu.
Previous version detected my gpu by it is not able to utilize it.
So I suggest to be in latest version of cuda
Thanks for helping me.

Note that You have to manually turn on the GPU for the first in your nvidia control panel.
In control panel you have an option to auto select when needed, Nvidia gpu and integrated gpu.
select Nvidia GPU.
Because cuda is not automatically turn on the GPU.