johannes.wilde wrote: ↑Sat Apr 25, 2020 10:26 am
Hardware device selection string has the wrong length, must be 2 instead of 1
I am getting the same error, which is related to this property in the scene cfg file:
As Dade explained in another post, with Cuda each Nvidia card is listed twice, both as OpenCL device and as Cuda device.
I think this is probably not yet supported in the BlendLuxCore addon, and unfortunately I'm not able to suggest a workaround. (*)
Let's wait for B.Y.O.B.'s suggestions about this.
(*) If this is suitable for you, you might try the following:
- export the scene from Blender in text format
- edit the above mentioned row in the "render.cfg" file, adding a digit to the right-hand-side
- render using LuxcoreUI with the standalone version
At step 2, you need to choose the Cuda device, not the openCL one.
Devices are listed in the log like this:
Code: Select all
[LuxRays][24.218] OpenCL Platform 0: NVIDIA Corporation
[LuxRays][24.218] OpenCL Platform 1: Advanced Micro Devices, Inc.
[LuxRays][24.218] CUDA driver version: 10.20
[LuxRays][24.218] CUDA device count: 1
[LuxRays][24.218] Device 0 name: Native
[LuxRays][24.218] Device 0 type: NATIVE_THREAD
[LuxRays][24.218] Device 0 compute units: 1
[LuxRays][24.218] Device 0 preferred float vector width: 4
[LuxRays][24.218] Device 0 max allocable memory: 17592186044415MBytes
[LuxRays][24.218] Device 0 max allocable memory block size: 17592186044415MBytes
[LuxRays][24.218] Device 0 has out of core memory support: 0
[LuxRays][24.218] Device 1 name: GeForce GTX 970
[LuxRays][24.218] Device 1 type: OPENCL_GPU
[LuxRays][24.218] Device 1 compute units: 13
[LuxRays][24.218] Device 1 preferred float vector width: 1
[LuxRays][24.218] Device 1 max allocable memory: 4096MBytes
[LuxRays][24.218] Device 1 max allocable memory block size: 1024MBytes
[LuxRays][24.218] Device 1 has out of core memory support: 0
[LuxRays][24.218] Device 2 name: Intel(R) Core(TM) i7-4770 CPU @ 3.40GHz
[LuxRays][24.218] Device 2 type: OPENCL_CPU
[LuxRays][24.218] Device 2 compute units: 8
[LuxRays][24.218] Device 2 preferred float vector width: 8
[LuxRays][24.218] Device 2 max allocable memory: 16323MBytes
[LuxRays][24.218] Device 2 max allocable memory block size: 4080MBytes
[LuxRays][24.218] Device 2 has out of core memory support: 0
[LuxRays][24.218] Device 3 name: GeForce GTX 970
[LuxRays][24.234] Device 3 type: CUDA_GPU
[LuxRays][24.234] Device 3 compute units: 128
[LuxRays][24.234] Device 3 preferred float vector width: 1
[LuxRays][24.234] Device 3 max allocable memory: 4096MBytes
[LuxRays][24.234] Device 3 max allocable memory block size: 17592186044415MBytes
[LuxRays][24.234] Device 3 has out of core memory support: 1
Traceback (most recent call last):
File "C:\Users\Alessandro\AppData\Roaming\Blender Foundation\Blender\2.82\scripts\addons\BlendLuxCore\engine\base.py", line 83, in render_final
final.render(self, depsgraph)
File "C:\Users\Alessandro\AppData\Roaming\Blender Foundation\Blender\2.82\scripts\addons\BlendLuxCore\engine\final.py", line 49, in render
_render_layer(engine, depsgraph, statistics, layer)
File "C:\Users\Alessandro\AppData\Roaming\Blender Foundation\Blender\2.82\scripts\addons\BlendLuxCore\engine\final.py", line 61, in _render_layer
engine.session = engine.exporter.create_session(depsgraph, engine=engine, view_layer=view_layer)
File "C:\Users\Alessandro\AppData\Roaming\Blender Foundation\Blender\2.82\scripts\addons\BlendLuxCore\export\__init__.py", line 251, in create_session
return pyluxcore.RenderSession(renderconfig)
RuntimeError: Hardware device selection string has the wrong length, must be 3 instead of 2
ERROR: Hardware device selection string has the wrong length, must be 3 instead of 2
Info: Compiling OpenCL kernels (just once, takes a few minutes)
Error: Hardware device selection string has the wrong length, must be 3 instead of 2
In this case, my string would have length 3, and the CUDA_GPU device is the last listed, so I would use: