BBrother
V2EX  ›  问与答

请教一下如何在 docker 容器中添加宿主机的 opencl 环境?

  •  
  •   BBrother · Jan 11, 2023 · 1542 views
    This topic created in 1241 days ago, the information mentioned may be changed or developed.

    我想在 jellyfin 开启颜色映射,根据官方文档的说法,安装了 amd 的 opencl 然后在 docker-compose.yml 中添加了 privileged: true 选项,但是 ffmpeg 报错:

    Failed to get number of OpenCL platforms: -1001.
    Device creation failed: -19.
    Failed to set value 'opencl=ocl:.0,device_vendor=Advanced Micro Devices' for option 'init_hw_device': No such device
    Error parsing global options: No such device
    

    请问一下如何解决?

    3 replies    2023-01-12 14:05:19 +08:00
    julyclyde
        1
    julyclyde  
       Jan 12, 2023   ❤️ 1
    需要传 device 进去吧

    不用 docker 最方便
    BBrother
        2
    BBrother  
    OP
       Jan 12, 2023
    @julyclyde #1 不知道咋传已经吧 /dev/dri/renderD128 传进去了,dri 下还有个 card0 之前也试过,传进去没有。
    BBrother
        3
    BBrother  
    OP
       Jan 12, 2023
    有人能帮帮我吗
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   2737 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 34ms · UTC 12:33 · PVG 20:33 · LAX 05:33 · JFK 08:33
    ♥ Do have faith in what you're doing.