Enable face import feature not respecting orientation when drawing bounding boxes #4635

Closed
opened 2026-02-05 10:45:22 +03:00 by OVERLORD · 2 comments
Owner

Originally created by @farwestnz on GitHub (Oct 26, 2024).

The bug

I'm testing the Enable Face Import feature to read EXIF data from my existing photos (I have the in-built face recognition disabled).

It is picking up the faces and names and they are visible in the info panel.

There is a small bug when drawing the boxes around the faces relating to photo orientation.

When I import a photo with normal orientation, the boxes are shown over the correct face in the correct location. When I import a photo with a rotation instruction then the boxes are drawn where the face would be if the photo was upside down. (In both cases the photo displays the right way up in Immich.)

The photos were mostly originally taken on iPhone.

Examining two files with different behavior in exiftool shows this variation (the first works, and the second results in boxes in the wrong place):
Orientation : Horizontal (normal)
Orientation : Rotate 180

Since the bounding boxes are used to select content for the person's featured photo, there is a practical downside to this behavior.

The OS that Immich Server is running on

Ubuntu 20.04.6 LTS

Version of Immich Server

v1.118.2

Version of Immich Mobile App

N/A

Platform with the issue

  • Server
  • Web
  • Mobile

Your docker-compose.yml content

services:
  immich-server:
    container_name: immich_server_test
    image: ghcr.io/immich-app/immich-server:${IMMICH_VERSION:-release}
    volumes:
      - ${UPLOAD_LOCATION}:/usr/src/app/upload
      - /media/truenas/photos/2024/:/media/truenas/photos:ro
      - /etc/localtime:/etc/localtime:ro
    env_file:
      - .env
    ports:
      - 2284:2283
    depends_on:
      - redis
      - database
    restart: always

  immich-machine-learning:
    container_name: immich_machine_learning_test
    image: ghcr.io/immich-app/immich-machine-learning:${IMMICH_VERSION:-release}
    volumes:
      - model-cache:/cache
    env_file:
      - .env
    restart: always

  redis:
    container_name: immich_redis_test
    image: redis:6.2-alpine@sha256:b6124ab2e45cc332e16398022a411d7e37181f21ff7874835e0180f56a09e82a
    restart: always

  database:
    container_name: immich_postgres_test
    image: tensorchord/pgvecto-rs:pg14-v0.2.0@sha256:90724186f0a3517cf6914295b5ab410db9ce23190a2d9d0b9dd6463e3fa298f0
    env_file:
      - .env
    environment:
      POSTGRES_PASSWORD: ${DB_PASSWORD}
      POSTGRES_USER: ${DB_USERNAME}
      POSTGRES_DB: ${DB_DATABASE_NAME}
    volumes:
      - pgdata:/var/lib/postgresql/data
    restart: always

volumes:
  pgdata:
  model-cache:

Your .env content

################################################################################### 
# Database
###################################################################################

DB_HOSTNAME=immich_postgres_test
DB_USERNAME=postgres
DB_PASSWORD=postgres
DB_DATABASE_NAME=immich


###################################################################################
# Redis
###################################################################################

REDIS_HOSTNAME=immich_redis_test


###################################################################################
# Upload File Location
#
# This is the location where uploaded files are stored.
###################################################################################

UPLOAD_LOCATION=/var/containerscratchdata/immich2


###################################################################################
# Typesense
###################################################################################
TYPESENSE_API_KEY=xxxxxxxxxxx

PUBLIC_LOGIN_PAGE_MESSAGE=

###################################################################################
# Immich Version - Optional
#
# This allows all immich docker images to be pinned to a specific version. By default,
# the version is "release" but could be a specific version, like "v1.59.0".
###################################################################################

IMMICH_VERSION=release

TZ=Pacific/Auckland

Reproduction steps

  1. add path to external library and trigger scan
  2. open photo
  3. open photo information pane
  4. hover over face icon to see bounding box

Relevant log output

No response

Additional information

No response

Originally created by @farwestnz on GitHub (Oct 26, 2024). ### The bug I'm testing the Enable Face Import feature to read EXIF data from my existing photos (I have the in-built face recognition disabled). It is picking up the faces and names and they are visible in the info panel. There is a small bug when drawing the boxes around the faces relating to photo orientation. When I import a photo with normal orientation, the boxes are shown over the correct face in the correct location. When I import a photo with a rotation instruction then the boxes are drawn where the face would be if the photo was upside down. (In both cases the photo displays the right way up in Immich.) The photos were mostly originally taken on iPhone. Examining two files with different behavior in exiftool shows this variation (the first works, and the second results in boxes in the wrong place): Orientation : Horizontal (normal) Orientation : Rotate 180 Since the bounding boxes are used to select content for the person's featured photo, there is a practical downside to this behavior. ### The OS that Immich Server is running on Ubuntu 20.04.6 LTS ### Version of Immich Server v1.118.2 ### Version of Immich Mobile App N/A ### Platform with the issue - [X] Server - [X] Web - [ ] Mobile ### Your docker-compose.yml content ```YAML services: immich-server: container_name: immich_server_test image: ghcr.io/immich-app/immich-server:${IMMICH_VERSION:-release} volumes: - ${UPLOAD_LOCATION}:/usr/src/app/upload - /media/truenas/photos/2024/:/media/truenas/photos:ro - /etc/localtime:/etc/localtime:ro env_file: - .env ports: - 2284:2283 depends_on: - redis - database restart: always immich-machine-learning: container_name: immich_machine_learning_test image: ghcr.io/immich-app/immich-machine-learning:${IMMICH_VERSION:-release} volumes: - model-cache:/cache env_file: - .env restart: always redis: container_name: immich_redis_test image: redis:6.2-alpine@sha256:b6124ab2e45cc332e16398022a411d7e37181f21ff7874835e0180f56a09e82a restart: always database: container_name: immich_postgres_test image: tensorchord/pgvecto-rs:pg14-v0.2.0@sha256:90724186f0a3517cf6914295b5ab410db9ce23190a2d9d0b9dd6463e3fa298f0 env_file: - .env environment: POSTGRES_PASSWORD: ${DB_PASSWORD} POSTGRES_USER: ${DB_USERNAME} POSTGRES_DB: ${DB_DATABASE_NAME} volumes: - pgdata:/var/lib/postgresql/data restart: always volumes: pgdata: model-cache: ``` ### Your .env content ```Shell ################################################################################### # Database ################################################################################### DB_HOSTNAME=immich_postgres_test DB_USERNAME=postgres DB_PASSWORD=postgres DB_DATABASE_NAME=immich ################################################################################### # Redis ################################################################################### REDIS_HOSTNAME=immich_redis_test ################################################################################### # Upload File Location # # This is the location where uploaded files are stored. ################################################################################### UPLOAD_LOCATION=/var/containerscratchdata/immich2 ################################################################################### # Typesense ################################################################################### TYPESENSE_API_KEY=xxxxxxxxxxx PUBLIC_LOGIN_PAGE_MESSAGE= ################################################################################### # Immich Version - Optional # # This allows all immich docker images to be pinned to a specific version. By default, # the version is "release" but could be a specific version, like "v1.59.0". ################################################################################### IMMICH_VERSION=release TZ=Pacific/Auckland ``` ### Reproduction steps 1. add path to external library and trigger scan 2. open photo 3. open photo information pane 4. hover over face icon to see bounding box ### Relevant log output _No response_ ### Additional information _No response_
Author
Owner

@bo0tzz commented on GitHub (Oct 26, 2024):

Dupe: #12440

@bo0tzz commented on GitHub (Oct 26, 2024): Dupe: #12440
Author
Owner

@farwestnz commented on GitHub (Oct 26, 2024):

Ah, so it is. Sorry, I did try a few searches but didn't spot it.

@farwestnz commented on GitHub (Oct 26, 2024): Ah, so it is. Sorry, I did try a few searches but didn't spot it.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: immich-app/immich#4635