Skip to content

Commit

Permalink
Runs on CPU
Browse files Browse the repository at this point in the history
  • Loading branch information
muedavid committed Oct 24, 2022
1 parent 9900af3 commit 4fe2f3a
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion blenderproc/python/renderer/RendererUtility.py
Original file line number Diff line number Diff line change
Expand Up @@ -756,4 +756,6 @@ def set_render_devices(use_only_cpu: bool = False, desired_gpu_device_type: Unio
break

if not found:
raise RuntimeError(f"No GPU could be found with the specified device types: {desired_gpu_device_type}")
bpy.context.scene.cycles.device = "CPU"
bpy.context.preferences.addons['cycles'].preferences.compute_device_type = "NONE"
print("Using only the CPU for rendering")

0 comments on commit 4fe2f3a

Please sign in to comment.