Hardware acceleration on Machine Learning
I recently moved my server from a Mini PC to a PC with Nvidia GPU.
The migration was smooth using Backup and Restore, now I am trying to enable Hardware acceleration.
It worked on Immich server but it is not working on Machine Learning, I noticed that I am missing -cuda on my Machine Learning image on my Docker Compose so I added that and Pulled and restarted my server.
After changing the image on Machine Learning, Immich is now asking me to setup credentials again. So I removed -cuda and pulled and restarted again, after that Immich is working again.
Here is parts of my the Docker Compose I tried when enabling hardware accel
services:
immich-server:
container_name: immich_server
image: ghcr.io/immich-app/immich-server:${IMMICH_VERSION:-release}
extends:
file: hwaccel.transcoding.yml
service: nvenc # set to one of [nvenc, quicksync, rkmpp, vaapi, vaapi-wsl] for accelerated transcoding
immich-machine-learning:
container_name: immich_machine_learning
# For hardware acceleration, add one of -[armnn, cuda, rocm, openvino, rknn] to the image tag.
# Example tag: ${IMMICH_VERSION:-release}-cuda
image: ghcr.io/immich-app/immich-machine-learning:${IMMICH_VERSION:-release}-cuda
extends: # uncomment this section for hardware acceleration - see https://immich.app/docs/features/ml-hardware-acceleration
file: hwaccel.ml.yml
service: cuda # set to one of [armnn, cuda, rocm, openvino, openvino-wsl, rknn] for accelerated inference - use the
ports:
The migration was smooth using Backup and Restore, now I am trying to enable Hardware acceleration.
It worked on Immich server but it is not working on Machine Learning, I noticed that I am missing -cuda on my Machine Learning image on my Docker Compose so I added that and Pulled and restarted my server.
After changing the image on Machine Learning, Immich is now asking me to setup credentials again. So I removed -cuda and pulled and restarted again, after that Immich is working again.
Here is parts of my the Docker Compose I tried when enabling hardware accel
services:
immich-server:
container_name: immich_server
image: ghcr.io/immich-app/immich-server:${IMMICH_VERSION:-release}
extends:
file: hwaccel.transcoding.yml
service: nvenc # set to one of [nvenc, quicksync, rkmpp, vaapi, vaapi-wsl] for accelerated transcoding
immich-machine-learning:
container_name: immich_machine_learning
# For hardware acceleration, add one of -[armnn, cuda, rocm, openvino, rknn] to the image tag.
# Example tag: ${IMMICH_VERSION:-release}-cuda
image: ghcr.io/immich-app/immich-machine-learning:${IMMICH_VERSION:-release}-cuda
extends: # uncomment this section for hardware acceleration - see https://immich.app/docs/features/ml-hardware-acceleration
file: hwaccel.ml.yml
service: cuda # set to one of [armnn, cuda, rocm, openvino, openvino-wsl, rknn] for accelerated inference - use the
-wsl version for WSL2 where applicableports:
- '3003:3003'
volumes: - model-cache:/cache
env_file: - .env
restart: always
healthcheck:
disable: false