Select specific GPU for Zivid Software

Zivid Knowledge Base has been moved!

This site is getting deprecated and will no longer be updated. Please head to our new website to find the latest and greatest in Zivid documentation.



This article demonstrates how to specify a computational device for Zivid Software. You should consider this if you have multiple GPUs and want to use a specific one. This can be one integrated GPU and one or more dedicated GPUs.

Make sure that the ​GPU Requirements for Zivid are met.

Instructions

  1. Download the Config.yml file. The config file contains the following information:

    __version__: 4
    Configuration:
      ComputeDevice:
        SelectionFilter: ""
        Type: Any
        Vendor: Any
      DriverConfig:
        ToshibaTeli:
          VersionCheck: yes
      Logging:
        Asynchronous: yes
        CrashHandler: no
        Directory: ""
        Enabled: yes
        FlushOnExit: yes
        HistorySize: 7
        MaxFileSizeMB: 10
        MaxTotalSizeMB: 100
        RotationCount: 0
        WriteInterval: 200
  2. Place the config file in the following directory:

    Windows
    mkdir -p %LOCALAPPDATA%\Zivid\API
    move %HOMEPATH%\Downloads\Config.yml %LOCALAPPDATA%\Zivid\API\
    
    Ubuntu
    mkdir -p $HOME/.config/Zivid/API
    mv ~/Downloads/Config.yml $HOME/.config/Zivid/API/
  3. The desired GPU (if it is known) is assigned by changing the config file ComputeDevice parameters:
    1. If you have a single GPU per vendor (e.g. an integrated Intel GPU and a dedicated Nvidia GPU), change Type to GPU and Vendor to Nvidia, Intel or AMD, e.g.

        ComputeDevice:
          SelectionFilter: ""
          Type: GPU
          Vendor: Nvidia
    2. If you have multiple GPUs of the same vendor (e.g. two AMD GPUs), write something in the selection filter, e.g. “fkdjf“ and leave Type and Vendor as Any, e.g.

        ComputeDevice:
          SelectionFilter: "fkdjf"
          Type: Any
          Vendor: Any

      Start Zivid Studio. An error message like this should appear:


      Change the SelectionFilter to any unique part of the string that describes the desired available devices, e.g.

        ComputeDevice:
          SelectionFilter: "620"
          Type: Any
          Vendor: Any
  4. To verify the changes, re-launch Zivid Studio and go to Help > About Zivid Studio > System Info > Compute Device Info. The selected device can be seen under Device info.

(Unsupported) Run SDK on CPU only

It is possible to run the Zivid SDK on a Intel chip set using their OpenCL runtime (https://software.intel.com/content/www/us/en/develop/tools/opencl-cpu-runtime.html) and the following configuration:

__version__: 4
Configuration:
  ComputeDevice:
    Type: CPU


Warning

  • Capture time will be greatly increased when using CPU-only instead of GPU and is not a recommended mode for most applications.
  • This feature is not supported and not well tested. Please contact customersuccess@zivid.com if you have issues.