Render Not Working In Google Colab

Hello, does someone know why when i render a file in google colab i don’t get a .png output?
i saw this video on how to do it
but in the video it says saved at render.png, but in mine i don’t see anything related to “saved” and no output is generated…
i do know it gets rendered but idk why the png is not saved…
this is what i get:


Thanks

yeah… same problem for me too. Has colab shut down the blender action, or are we just the 2 people who didn’t get it to work?

Hi. Here are valuable video tutorials (and ready-to-use scripts) that should help you:

I’m in the same boat.

The last time I was able to successfully access OPTIX rendering was October 30, 2021.

I can get CUDA rendering using Blender 2.9.3 and 3.0 — sometimes it works, and sometimes it doesn’t — but no OPTIX.

  • Blender 2.93 OPTIX — Error: Found no Cycles device of the specified type
  • Blender 3.0 OPTIX — Device does not support queues.

Search results for the “queues” error haven’t yet offered a solution, or even an explanation. I’ve noticed that Google returns fewer results on this topic than Duck Duck Go, for whatever reason.

I’ve seen some suggestions that the issue has to do with Colab trying to push back against crypto mining.

I’ve also seen mention that upgrading from Free to a Pro plan might help, but I haven’t seen this verified.

As a Mac user on an older laptop, Colab has been a godsend, but if I have to start paying for renders, I’d probably be better off using a dedicated Blender render farm instead.

I found a solution. Run these commands before running Blender. These update the Nvidia drivers as Colab’s are out of date. I found the solution here: https://github.com/googlecolab/colabtools/issues/2827

!sudo apt install libnvidia-gl-510 nvidia-dkms-510 nvidia-kernel-source-510 libnvidia-compute-510 libnvidia-extra-510 nvidia-compute-utils-510 libnvidia-decode-510 libnvidia-encode-510 nvidia-utils-510 xserver-xorg-video-nvidia-510 libnvidia-cfg1-510 libnvidia-fbc1-510

!sudo apt install nvidia-driver-510-server --yes

Hopefully this works for you!

2 Likes

Just created an account to say Thank You! It totally works!!

1 Like

Awesome! Can’t wait to give it a try!

Sadly, it didn’t work for me.

When I tried to update the drivers, it reported back:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 nvidia-dkms-510 : Depends: nvidia-kernel-common-510 (= 510.73.08-0ubuntu1) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 nvidia-driver-510-server : Depends: libnvidia-gl-510-server (= 510.73.08-0ubuntu0.18.04.1) but it is not going to be installed
                            Depends: nvidia-dkms-510-server (<= 510.73.08-1)
                            Depends: nvidia-dkms-510-server (>= 510.73.08)
                            Depends: nvidia-kernel-common-510-server (<= 510.73.08-1) but it is not going to be installed
                            Depends: nvidia-kernel-common-510-server (>= 510.73.08) but it is not going to be installed
                            Depends: nvidia-kernel-source-510-server (= 510.73.08-0ubuntu0.18.04.1) but it is not going to be installed
                            Depends: libnvidia-compute-510-server (= 510.73.08-0ubuntu0.18.04.1) but it is not going to be installed
                            Depends: libnvidia-extra-510-server (= 510.73.08-0ubuntu0.18.04.1) but it is not going to be installed
                            Depends: nvidia-compute-utils-510-server (= 510.73.08-0ubuntu0.18.04.1) but it is not going to be installed
                            Depends: libnvidia-decode-510-server (= 510.73.08-0ubuntu0.18.04.1) but it is not going to be installed
                            Depends: libnvidia-encode-510-server (= 510.73.08-0ubuntu0.18.04.1) but it is not going to be installed
                            Depends: nvidia-utils-510-server (= 510.73.08-0ubuntu0.18.04.1) but it is not going to be installed
                            Depends: xserver-xorg-video-nvidia-510-server (= 510.73.08-0ubuntu0.18.04.1) but it is not going to be installed
                            Depends: libnvidia-cfg1-510-server (= 510.73.08-0ubuntu0.18.04.1) but it is not going to be installed
                            Depends: libnvidia-fbc1-510-server (= 510.73.08-0ubuntu0.18.04.1) but it is not going to be installed
                            Recommends: libnvidia-compute-510-server:i386 (= 510.73.08-0ubuntu0.18.04.1) but it is not installable
                            Recommends: libnvidia-decode-510-server:i386 (= 510.73.08-0ubuntu0.18.04.1) but it is not installable
                            Recommends: libnvidia-encode-510-server:i386 (= 510.73.08-0ubuntu0.18.04.1) but it is not installable
                            Recommends: libnvidia-fbc1-510-server:i386 (= 510.73.08-0ubuntu0.18.04.1) but it is not installable
                            Recommends: libnvidia-gl-510-server:i386 (= 510.73.08-0ubuntu0.18.04.1) but it is not installable
E: Unable to correct problems, you have held broken packages.

And when I tried (for the hack of it) to render using OPTIX, I got:

Blender 3.2.1 (hash a2d59b2dac9e built 2022-07-05 23:53:28)
Read blend: /content/drive/MyDrive/Blender/Blends/d-man-nft-wk52.blend
F0727 20:25:48.091647   814 device.cpp:389] Device does not support queues.
*** Check failure stack trace: ***
    @          0x2f733bd  (unknown)
    @          0x2f752c3  (unknown)
    @          0x2f72f4d  (unknown)
    @          0x2f75b99  (unknown)
    @          0x2f945d0  ccl::Device::gpu_queue_create()
    @          0x3978289  ccl::PathTraceWorkGPU::PathTraceWorkGPU()
    @          0x39728d4  ccl::PathTraceWork::create()
    @          0x396bf82  (unknown)
    @          0x396c266  ccl::PathTrace::PathTrace()
    @          0x38dc8fc  ccl::Session::Session()
    @          0x2f0ee45  ccl::BlenderSession::create_session()
    @          0x2f0fa00  ccl::BlenderSession::reset_session()
    @          0x2f077ed  (unknown)
    @          0xc3b0004  (unknown)
    @          0xc36a468  _PyObject_MakeTpCall
    @          0x11d48af  _PyEval_EvalFrameDefault
    @          0xc428af4  (unknown)
    @          0x11d485a  _PyEval_EvalFrameDefault
    @          0xc428af4  (unknown)
    @          0xc36a0ef  PyVectorcall_Call
    @          0x1c46bf8  (unknown)
    @          0x1bb77a6  (unknown)
    @          0x25bdab9  (unknown)
    @          0x25be6f4  RE_engine_render
    @          0x25c24e7  (unknown)
    @          0x25c4c70  (unknown)
    @          0x25c5846  RE_RenderAnim
    @          0x11d923c  (unknown)
    @          0xc07de27  BLI_args_parse
    @          0x10d5c10  main
    @     0x7fead0af3c87  __libc_start_main
    @          0x11d6bbc  (unknown)

And CUDA gave me:

Blender 3.2.1 (hash a2d59b2dac9e built 2022-07-05 23:53:28)
Read blend: /content/drive/MyDrive/Blender/Blends/d-man-nft-wk52.blend
CUDA cuInit: Unknown CUDA error value
F0727 20:22:23.156404   760 device.cpp:389] Device does not support queues.
*** Check failure stack trace: ***
    @          0x2f733bd  (unknown)
    @          0x2f752c3  (unknown)
    @          0x2f72f4d  (unknown)
    @          0x2f75b99  (unknown)
    @          0x2f945d0  ccl::Device::gpu_queue_create()
    @          0x3978289  ccl::PathTraceWorkGPU::PathTraceWorkGPU()
    @          0x39728d4  ccl::PathTraceWork::create()
    @          0x396bf82  (unknown)
    @          0x396c266  ccl::PathTrace::PathTrace()
    @          0x38dc8fc  ccl::Session::Session()
    @          0x2f0ee45  ccl::BlenderSession::create_session()
    @          0x2f0fa00  ccl::BlenderSession::reset_session()
    @          0x2f077ed  (unknown)
    @          0xc3b0004  (unknown)
    @          0xc36a468  _PyObject_MakeTpCall
    @          0x11d48af  _PyEval_EvalFrameDefault
    @          0xc428af4  (unknown)
    @          0x11d485a  _PyEval_EvalFrameDefault
    @          0xc428af4  (unknown)
    @          0xc36a0ef  PyVectorcall_Call
    @          0x1c46bf8  (unknown)
    @          0x1bb77a6  (unknown)
    @          0x25bdab9  (unknown)
    @          0x25be6f4  RE_engine_render
    @          0x25c24e7  (unknown)
    @          0x25c4c70  (unknown)
    @          0x25c5846  RE_RenderAnim
    @          0x11d923c  (unknown)
    @          0xc07de27  BLI_args_parse
    @          0x10d5c10  main
    @     0x7f41d3bffc87  __libc_start_main
    @          0x11d6bbc  (unknown)

So… :cry: :crying_cat_face: :skull_and_crossbones:

Yep, I am getting the same error now. Investigating…

This worked for me. This will first remove all the old Nvidia drivers, and then replace the drivers. Tested it with a Tesla T4 machine.

!sudo apt-get purge nvidia*
!sudo add-apt-repository ppa:graphics-drivers/ppa -y
!sudo apt-get update
!sudo apt install nvidia-driver-510 nvidia-dkms-510 -y
1 Like

It worked!

I still can’t use OPTIX:

Blender 3.2.1 (hash a2d59b2dac9e built 2022-07-05 23:53:28)
Read blend: /content/drive/MyDrive/Blender/Blends/d-man-nft-wk52.blend
F0728 04:11:37.977604 13858 device.cpp:389] Device does not support queues.

but CUDA is now rendering some of my test files, so I’m back in business.

Attached is my updated .ipynb file. Feel free to suggest tweaks or to share yours.

BlenderColab.ipynb (6.0 KB)

Make sure you are using a OPTIX-enabled GPU. I believe some of the GPUs in the Colab pool do not support OPTIX. The NVIDIA Tesla T4 I am connected to works with Optix just fine.

Getting an OPTIX GPU seems to be luck-of-the-draw, and I haven’t gotten one of those in a long, long time. :cry:

But the CUDA machines are still much, much faster than my laptop, so I’m just grateful that I can once again use Colabs. :smile:

Thanks again for your help!

1 Like

Not a problem!