def current_device():
 _lazy_init()
 return torch._C._cuda_getDevice()

def current_device ( ) : _lazy_init ( ) return torch . _C . _cuda_getDevice ( )
returns an adbdevice instance for the currently-selected device .