Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Search not working #9220

Closed
1 of 3 tasks
it-global-architect opened this issue May 2, 2024 · 0 comments
Closed
1 of 3 tasks

Search not working #9220

it-global-architect opened this issue May 2, 2024 · 0 comments

Comments

@it-global-architect
Copy link

The bug

Hello,

  • My search is not working and I can see this error in the log:
immich_server            |     at async /usr/src/app/dist/repositories/search.repository.js:108:23
immich_server            |     at async EntityManager.transaction (/usr/src/app/node_modules/typeorm/entity-manager/EntityManager.js:73:28)
immich_server            |     at async SearchRepository.searchSmart (/usr/src/app/dist/repositories/search.repository.js:92:9)] QueryFailedError: pgvecto.rs: The given vector is invalid for input.
immich_server            | ADVICE: Check if dimensions and scalar type of the vector is matched with the index.
  • When I run the smart search job I see a lot of errors like this:
immich_microservices     | [Nest] 8  - 05/02/2024, 11:04:00 AM   ERROR [JobService] Unable to run job handler (smartSearch/smart-search): QueryFailedError: pgvecto.rs: The given vector is invalid for input.
immich_microservices     | ADVICE: Check if dimensions and scalar type of the vector is matched with the index.
immich_microservices     | [Nest] 8  - 05/02/2024, 11:04:00 AM   ERROR [JobService] QueryFailedError: pgvecto.rs: The given vector is invalid for input.
immich_microservices     | ADVICE: Check if dimensions and scalar type of the vector is matched with the index.
immich_microservices     |     at PostgresQueryRunner.query (/usr/src/app/node_modules/typeorm/driver/postgres/PostgresQueryRunner.js:219:19)
immich_microservices     |     at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
  • Smart search job makes my GPU work well as you can see in the attached picture
    image

  • Machine learning clip model is set to: ViT-B-32__openai

  • Database has vectors as you can see in the attached picture
    image

  • Server version: v1.103.1

  • My docker compose is pretty standard:

  • Error when search:
    image

The OS that Immich Server is running on

Ubuntu 22.04

Version of Immich Server

v1.103.1

Version of Immich Mobile App

v1.103.1

Platform with the issue

  • Server
  • Web
  • Mobile

Your docker-compose.yml content

name: immich

services:
  immich-server:
    container_name: immich_server
    image: ghcr.io/immich-app/immich-server:${IMMICH_VERSION:-release}
    command: ['start.sh', 'immich']
    volumes:
      - ${UPLOAD_LOCATION}:/usr/src/app/upload
      - ${LIBRARY_LOCATION}:/usr/src/app/upload/library
      - /etc/localtime:/etc/localtime:ro
    env_file:
      - .env
    ports:
      - 2283:3001
    depends_on:
      - redis
      - database
    restart: always

  immich-microservices:
    container_name: immich_microservices
    image: ghcr.io/immich-app/immich-server:${IMMICH_VERSION:-release}
    extends: # uncomment this section for hardware acceleration - see https://immich.app/docs/features/hardware-transcoding
      file: hwaccel.transcoding.yml
      service: quicksync # set to one of [nvenc, quicksync, rkmpp, vaapi, vaapi-wsl] for accelerated transcoding
    command: ['start.sh', 'microservices']
    volumes:
      - ${UPLOAD_LOCATION}:/usr/src/app/upload
      - ${LIBRARY_LOCATION}:/usr/src/app/upload/library
      - /etc/localtime:/etc/localtime:ro
    env_file:
      - .env
    depends_on:
      - redis
      - database
    restart: always

  immich-machine-learning:
    container_name: immich_machine_learning
    # For hardware acceleration, add one of -[armnn, cuda, openvino] to the image tag.
    # Example tag: ${IMMICH_VERSION:-release}-cuda
    image: ghcr.io/immich-app/immich-machine-learning:${IMMICH_VERSION:-release}
    extends: # uncomment this section for hardware acceleration - see https://immich.app/docs/features/ml-hardware-acceleration
      file: hwaccel.ml.yml
      service: openvino # set to one of [armnn, cuda, openvino, openvino-wsl] for accelerated inference - use the `-wsl` version for WSL2 where applicable
    volumes:
      - ./volumes/model-cache:/cache
    env_file:
      - .env
    restart: always

  redis:
    container_name: immich_redis
    image: registry.hub.docker.com/library/redis:6.2-alpine@sha256:84882e87b54734154586e5f8abd4dce69fe7311315e2fc6d67c29614c8de2672
    restart: always

  database:
    container_name: immich_postgres
    image: registry.hub.docker.com/tensorchord/pgvecto-rs:pg14-v0.2.0@sha256:90724186f0a3517cf6914295b5ab410db9ce23190a2d9d0b9dd6463e3fa298f0
    environment:
      POSTGRES_PASSWORD: ${DB_PASSWORD}
      POSTGRES_USER: ${DB_USERNAME}
      POSTGRES_DB: ${DB_DATABASE_NAME}
    volumes:
      - ${DB_DATA_LOCATION}:/var/lib/postgresql/data
    restart: always

Your .env content

########## PATH SETTINGS####################
UPLOAD_LOCATION=/mnt/nas/program_files/immich/
LIBRARY_LOCATION=/mnt/nas/midia/images/immich/
#
###### DB SETTINGS ########
DB_PASSWORD=[REMOVED FOR PRIVACY]
DB_HOSTNAME=immich_postgres
DB_USERNAME=immich
DB_DATABASE_NAME=immichdb
DB_DATA_LOCATION=./postgres
#
# The Immich version to use. You can pin this to a specific version like "v1.71.0"
IMMICH_VERSION=release
REDIS_HOSTNAME=immich_redis

Reproduction steps

1.Open the search
2.Type something
3.Server error message
...

Relevant log output

No response

Additional information

No response

@immich-app immich-app locked and limited conversation to collaborators May 2, 2024
@bo0tzz bo0tzz converted this issue into discussion #9221 May 2, 2024

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant