You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
TL;DR: Is it / could it be possible to enforce which GPU will be used (e.g. by env variable)?
I compiled dataviz from sources and ran examples. All of them except gui were displaying blank window.
After some time I discovered DVZ_LOG_LEVEL and noticed the following output:
prybicki@titan:/tmp/datoviz$ ./manage.sh demo mandelbrot
19:02:28.075 D vklite.c:0137: found device #0: Intel(R) UHD Graphics (CML GT2)
19:02:28.075 D vklite.c:0137: found device #1: NVIDIA GeForce RTX 3060 Laptop GPU
19:02:28.075 D vklite.c:0137: found device #2: llvmpipe (LLVM 12.0.0, 256 bits)
I have a dual-gpu machine, with NVIDIA gpu active (I'm using Linux Mint builtin feature to switch between them, which I guess uses prime). I thought that dataviz may choose the first device (Intel), while the second is active and that causes blank window (?).
I modified vklite.c:0137 to skip gpus 0 and 2. After that, all examples worked correctly!
Therefore, my suggestion is to provide (or document/expose) a way to select which GPU is used. For example, cuda driver (libcuda) respects env variable CUDA_VISIBLE_DEVICES which allows to influence which GPU is selected as the default. Perhaps it is possible to implement similar mechanism in datoviz?
The text was updated successfully, but these errors were encountered:
The logic for choosing the best GPU automatically might fail in your case. Does the logging output (with level 0) give you some information? I'd be curious to understand why device 1 isn't considered as the "best" GPU on your system. Feel free to investigate if you have some time, I'm happy to help...
In any case, Datoviz should provide an environment variable as you suggest, i.e. DVZ_GPU_INDEX=1 ./myapp. Perhaps this could be implemented directly in dvz_gpu_best() reporting with log_debug() when the automatic GPU selection is overridden by the environment variable. I'll try to do it soon, otherwise please feel free to have a go and propose a PR :)
TL;DR: Is it / could it be possible to enforce which GPU will be used (e.g. by env variable)?
I compiled dataviz from sources and ran examples. All of them except gui were displaying blank window.
After some time I discovered DVZ_LOG_LEVEL and noticed the following output:
I have a dual-gpu machine, with NVIDIA gpu active (I'm using Linux Mint builtin feature to switch between them, which I guess uses prime). I thought that dataviz may choose the first device (Intel), while the second is active and that causes blank window (?).
I modified vklite.c:0137 to skip gpus 0 and 2. After that, all examples worked correctly!
Therefore, my suggestion is to provide (or document/expose) a way to select which GPU is used. For example, cuda driver (libcuda) respects env variable CUDA_VISIBLE_DEVICES which allows to influence which GPU is selected as the default. Perhaps it is possible to implement similar mechanism in datoviz?
The text was updated successfully, but these errors were encountered: