Make sure you have installed the latest NVIDIA drivers.
Boot the VM into Safe Mode to see if it still restarts. If not, then it might be a driver related issue.
Open Event Viewer and look for related System and Application logs.
Uninstall and then reinstall the NVIDIA GPU driver extensions to ensure they are correctly configured.
Use Azure diagnostics to gather more information about the VM’s health and performance.