Added a flag to deactivate CUDA.