Solution: High Sierra 10.13.6 (17G14019) Web Driver and Cuda Driver installed successfully on Mac but it freezes and restart

Hi I have iMac 27’’ Late 2013. (NVIDIA GeForce GTX 775M)

OS High Sierra (17G14019) and NVIDIA Web Driver 387. and Cuda Driver 418.105 successfully installed. But after few hours of usage the the machine froze.

And before this had installed the latest Cuda 418.163, with it the machine used to restart with kernel panic error. So properly uninstalled, as guided on the website and installed the driver and Cuda 418.105 driver.

But now the machine is freezing, so pls help which Cuda driver should be used for smooth functioning.