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

Reverse geocaching returns null #7531

Closed
1 of 3 tasks
utrack opened this issue Feb 29, 2024 · 5 comments
Closed
1 of 3 tasks

Reverse geocaching returns null #7531

utrack opened this issue Feb 29, 2024 · 5 comments

Comments

@utrack
Copy link

utrack commented Feb 29, 2024

The bug

Hi team!

I'm using the latest release v1.97.0 via Docker Compose - except for the ML image, which is main-openvino.
My Compose (from v1.95.1) is slightly modified, I'm running containers as a non-root user (no issues with the mounts' permissions, I've fixed them).

I've realized that the map view is missing a lot of photos, so I've started the 'extract metadata' job.
My logs are full of these messages:

immich_microservices     | [Nest] 7  - 02/29/2024, 2:38:30 PM    WARN [MetadataRepository] Response from database for reverse geocoding latitude: 63.789032, longitude: -18.0456314 was null

It feels like a timeout is happening, since every such request takes a couple of minutes to complete if I look at the logs.
How can I debug that? :)

The OS that Immich Server is running on

Arch

Version of Immich Server

v1.9.7

Version of Immich Mobile App

Platform with the issue

  • Server
  • Web
  • Mobile

Your docker-compose.yml content

version: "3.8"

#
# WARNING: Make sure to use the docker-compose.yml of the current release:
#
# https://github.com/immich-app/immich/releases/latest/download/docker-compose.yml
#
# The compose file on main may not be compatible with the latest release.
#

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
      - /etc/localtime:/etc/localtime:ro
      - /opt/docked/immich/passwd:/etc/passwd
    env_file:
      - .env
    ports:
      - 2283:3001
    group_add:
      - 989
      - 985
    user: "1004:1004"
    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
      - /etc/localtime:/etc/localtime:ro
      - /opt/docked/immich/passwd:/etc/passwd
    user: "1004:1004"
    group_add:
      - 989
      - 985
    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}-openvino
    image: ghcr.io/immich-app/immich-machine-learning:main-openvino
      #user: "1004:1004"
      #group_add:
      #- 989
      #- 985
    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:
      - model-cache:/cache
      - /opt/docked/immich/passwd:/etc/passwd
    env_file:
      - .env
    restart: always

  redis:
    container_name: immich_redis
    image: redis:6.2-alpine
      #user: "1004:1004"
    restart: always

  database:
    container_name: immich_postgres
    image: tensorchord/pgvecto-rs:pg14-v0.2.0@sha256:90724186f0a3517cf6914295b5ab410db9ce23190a2d9d0b9dd6463e3fa298f0
    environment:
      POSTGRES_PASSWORD: ${DB_PASSWORD}
      POSTGRES_USER: ${DB_USERNAME}
      POSTGRES_DB: ${DB_DATABASE_NAME}
    volumes:
      - /mnt/hdd/immich/pgdb:/var/lib/postgresql/data
    restart: always
    user: "1004:1004"

volumes:
  pgdata:
  model-cache:

Your .env content

# You can find documentation for all the supported env variables at https://immich.app/docs/install/environment-variables

# The location where your uploaded files are stored
UPLOAD_LOCATION=/mnt/hdd/immich
PUID=

# The Immich version to use. You can pin this to a specific version like "v1.71.0"
IMMICH_VERSION=release

# Connection secret for postgres. You should change it to a random password
DB_PASSWORD=<secret :) >

# The values below this line do not need to be changed
###################################################################################
DB_HOSTNAME=immich_postgres
DB_USERNAME=postgres
DB_DATABASE_NAME=immich

REDIS_HOSTNAME=immich_redis
PUID=1004
PGID=1001
LOG_LEVEL=debug

Reproduction steps

1. Try to run the Extract Metadata job
2. Wait for the logs for a couple of minutes

Additional information


@mmomjian
Copy link
Contributor

mmomjian commented Mar 1, 2024

The coordinate you gave looks like a relatively remote location in Iceland. I forget the exact radius, but this message prints when a named city is not found within a certain distance of the image. You can probably check a few other coordinates and you’ll find they are all in distant locations.

Can you print the logs of a few more? I don’t think this is a timeout, it’s just logging this for each picture it finds that isn’t near a city.

@diy97
Copy link

diy97 commented Mar 1, 2024

I also have this problem here。
[Nest] 221 - 03/01/2024, 10:32:12 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4289694444444, longitude: 106.657030555556 was null
[Nest] 221 - 03/01/2024, 10:32:12 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4302222222222, longitude: 106.657483333333 was null
[Nest] 221 - 03/01/2024, 10:32:13 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4302222222222, longitude: 106.657483333333 was null
[Nest] 221 - 03/01/2024, 10:32:13 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4302277777778, longitude: 106.657491666667 was null
[Nest] 221 - 03/01/2024, 10:32:13 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4302277777778, longitude: 106.657491666667 was null
[Nest] 221 - 03/01/2024, 10:32:13 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4302277777778, longitude: 106.657491666667 was null
[Nest] 221 - 03/01/2024, 10:32:14 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4302277777778, longitude: 106.657491666667 was null
[Nest] 221 - 03/01/2024, 10:32:14 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4289416666667, longitude: 106.657019444444 was null
[Nest] 221 - 03/01/2024, 10:32:14 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4289472222222, longitude: 106.657055555556 was null
[Nest] 221 - 03/01/2024, 10:32:14 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4289416666667, longitude: 106.657019444444 was null
[Nest] 221 - 03/01/2024, 10:32:15 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4289416666667, longitude: 106.657019444444 was null
[Nest] 221 - 03/01/2024, 10:32:15 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4289416666667, longitude: 106.657019444444 was null
[Nest] 221 - 03/01/2024, 10:32:15 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4288777777778, longitude: 106.657066666667 was null
[Nest] 221 - 03/01/2024, 10:32:15 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4289416666667, longitude: 106.657019444444 was null
[Nest] 221 - 03/01/2024, 10:32:15 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4288694444444, longitude: 106.657069444444 was null
[Nest] 221 - 03/01/2024, 10:32:15 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4288694444444, longitude: 106.657063888889 was null
[Nest] 221 - 03/01/2024, 10:32:17 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4289416666667, longitude: 106.657019444444 was null
[Nest] 221 - 03/01/2024, 10:32:18 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4320805555556, longitude: 106.660069444444 was null
[Nest] 221 - 03/01/2024, 10:32:18 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4320805555556, longitude: 106.660069444444 was null
[Nest] 221 - 03/01/2024, 10:32:19 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4320611111111, longitude: 106.659541666667 was null
[Nest] 221 - 03/01/2024, 10:32:19 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4320805555556, longitude: 106.660069444444 was null
[Nest] 221 - 03/01/2024, 10:32:19 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4286972222222, longitude: 106.656888888889 was null
[Nest] 221 - 03/01/2024, 10:32:20 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4320638888889, longitude: 106.659505555556 was null
[Nest] 221 - 03/01/2024, 10:32:21 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4295416666667, longitude: 106.656347222222 was null
[Nest] 221 - 03/01/2024, 10:32:21 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4292388888889, longitude: 106.656441666667 was null
[Nest] 221 - 03/01/2024, 10:32:22 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 29.5688583333333, longitude: 101.995416666667 was null
[Nest] 221 - 03/01/2024, 10:32:23 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 29.5739444444444, longitude: 101.992916666667 was null
[Nest] 221 - 03/01/2024, 10:32:23 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 29.5636361111111, longitude: 101.979780555556 was null
[Nest] 221 - 03/01/2024, 10:32:27 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 30.1473055555556, longitude: 100.617413888889 was null
[Nest] 221 - 03/01/2024, 10:32:27 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 29.3896972222222, longitude: 100.149977777778 was null
[Nest] 221 - 03/01/2024, 10:32:27 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 29.3896972222222, longitude: 100.149977777778 was null
[Nest] 221 - 03/01/2024, 10:32:28 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 29.3896972222222, longitude: 100.149977777778 was null
[Nest] 221 - 03/01/2024, 10:32:28 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 29.3896972222222, longitude: 100.149977777778 was null
[Nest] 221 - 03/01/2024, 10:32:28 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 29.38805, longitude: 100.148616666667 was null
[Nest] 221 - 03/01/2024, 10:32:28 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 29.3885194444444, longitude: 100.149125 was null
[Nest] 221 - 03/01/2024, 10:32:29 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 29.3896972222222, longitude: 100.149977777778 was null
[Nest] 221 - 03/01/2024, 10:32:34 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4295888888889, longitude: 106.656258333333 was null
[Nest] 221 - 03/01/2024, 10:32:34 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4295388888889, longitude: 106.656827777778 was null
[Nest] 221 - 03/01/2024, 10:32:36 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 33.1960138888889, longitude: 103.893097222222 was null
[Nest] 221 - 03/01/2024, 10:32:49 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4281081944444, longitude: 106.657180777778 was null
[Nest] 221 - 03/01/2024, 10:32:49 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4281654166667, longitude: 106.6571655 was null
[Nest] 221 - 03/01/2024, 10:32:50 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4280738611111, longitude: 106.657394388889 was null
[Nest] 221 - 03/01/2024, 10:32:50 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4281654166667, longitude: 106.6571655 was null
[Nest] 221 - 03/01/2024, 10:32:50 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4280738611111, longitude: 106.657394388889 was null
[Nest] 221 - 03/01/2024, 10:32:50 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4282131111111, longitude: 106.65715025 was null
[Nest] 221 - 03/01/2024, 10:32:50 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4282131111111, longitude: 106.65715025 was null
[Nest] 221 - 03/01/2024, 10:33:11 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4289, longitude: 106.6564 was null
[Nest] 221 - 03/01/2024, 10:33:12 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4289, longitude: 106.6564 was null
[Nest] 221 - 03/01/2024, 10:33:16 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 30.087, longitude: 101.4808 was null
[Nest] 221 - 03/01/2024, 10:33:27 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.429, longitude: 106.657 was null
[Nest] 221 - 03/01/2024, 10:33:28 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.429, longitude: 106.657 was null
[Nest] 221 - 03/01/2024, 10:33:31 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4289, longitude: 106.6571 was null
[Nest] 221 - 03/01/2024, 10:33:32 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 29.5636, longitude: 101.9798 was null
[Nest] 221 - 03/01/2024, 10:33:32 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 29.574, longitude: 101.9917 was null
[Nest] 221 - 03/01/2024, 10:33:37 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 29.5734, longitude: 101.9931 was null
[Nest] 221 - 03/01/2024, 10:33:37 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 29.5734, longitude: 101.9931 was null
[Nest] 221 - 03/01/2024, 10:33:37 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 29.574, longitude: 101.9916 was null
[Nest] 221 - 03/01/2024, 10:33:42 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 29.3897, longitude: 100.15 was null
[Nest] 221 - 03/01/2024, 10:33:42 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 29.3881, longitude: 100.1486 was null
[Nest] 221 - 03/01/2024, 10:33:42 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 29.3897, longitude: 100.15 was null
[Nest] 221 - 03/01/2024, 10:33:42 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 30.1594, longitude: 100.5795 was null
[Nest] 221 - 03/01/2024, 10:33:42 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 29.3897, longitude: 100.15 was null
[Nest] 221 - 03/01/2024, 10:33:45 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 29.3897, longitude: 100.15 was null
[Nest] 221 - 03/01/2024, 10:34:06 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 33.196, longitude: 103.8931 was null
[Nest] 221 - 03/01/2024, 10:34:07 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 33.1688, longitude: 103.8848 was null
[Nest] 221 - 03/01/2024, 10:34:07 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 33.1688, longitude: 103.8848 was null
[Nest] 221 - 03/01/2024, 10:34:09 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 33.1614, longitude: 103.8784 was null
[Nest] 221 - 03/01/2024, 10:34:09 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 33.1614, longitude: 103.8784 was null
[Nest] 221 - 03/01/2024, 10:34:09 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 33.16, longitude: 103.8804 was null
[Nest] 221 - 03/01/2024, 10:34:12 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 33.1589, longitude: 103.8763 was null
[Nest] 221 - 03/01/2024, 10:34:12 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 33.1601, longitude: 103.8803 was null
[Nest] 221 - 03/01/2024, 10:34:29 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.43695, longitude: 106.653525 was null
[Nest] 221 - 03/01/2024, 10:34:30 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 30.0864694444444, longitude: 101.480308333333 was null
[Nest] 221 - 03/01/2024, 10:34:30 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 30.0849944444444, longitude: 101.480427777778 was null
[Nest] 221 - 03/01/2024, 10:34:30 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 30.0870333333333, longitude: 101.480822222222 was null
[Nest] 221 - 03/01/2024, 10:34:30 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 30.0870333333333, longitude: 101.480733333333 was null
[Nest] 221 - 03/01/2024, 10:34:30 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 30.3243805555556, longitude: 101.524466666667 was null
[Nest] 221 - 03/01/2024, 10:34:32 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 30.054675, longitude: 101.482119444444 was null
[Nest] 221 - 03/01/2024, 10:35:23 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 30.0871361111111, longitude: 101.481436111111 was null
[Nest] 221 - 03/01/2024, 10:35:24 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 30.0870388888889, longitude: 101.480688888889 was null
[Nest] 221 - 03/01/2024, 10:35:24 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 30.0870388888889, longitude: 101.480688888889 was null
[Nest] 221 - 03/01/2024, 10:35:24 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 30.0870194444444, longitude: 101.480658333333 was null
[Nest] 221 - 03/01/2024, 10:35:24 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 30.0870194444444, longitude: 101.480658333333 was null
[Nest] 221 - 03/01/2024, 10:35:24 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 30.4399972222222, longitude: 101.544083333333 was null
[Nest] 221 - 03/01/2024, 10:35:25 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 30.4399972222222, longitude: 101.544083333333 was null
[Nest] 221 - 03/01/2024, 10:35:25 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 30.4399972222222, longitude: 101.544083333333 was null
[Nest] 221 - 03/01/2024, 10:35:25 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 30.4399972222222, longitude: 101.544083333333 was null
[Nest] 221 - 03/01/2024, 10:35:26 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 30.3238277777778, longitude: 101.525516666667 was null
[Nest] 221 - 03/01/2024, 10:35:26 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4327111111111, longitude: 106.6549 was null
[Nest] 221 - 03/01/2024, 10:35:26 AM WARN [MetadataRepository] Response from database for reverse geocoding latitude: 31.4327111111111, longitude: 106.6549 was null

@diy97
Copy link

diy97 commented Mar 1, 2024

Places only displays 12 addresses

@utrack
Copy link
Author

utrack commented Mar 1, 2024

Hm, you're right! Apologies @mmomjian

I've enabled the debug log and it turns out that most of null locations are either remote or in the sea, everything else was geocoded successfully...
The only non-remote null place I've found is 53.183239, 44.0651321, which is in Kamenka's bounds, but I guess that's too small of a town for the database.

However, I've found another interesting thing - sometimes the lookups do hang for a minute or two, and it's always the same pair of coordinates... I'll look into the Postgres index situation and open a new bug if I find something. :)

Not closing this issue since there are reports from other people as well; handing it over to you.

@utrack
Copy link
Author

utrack commented Mar 1, 2024

Hm, is it possible to geocode points like 63°32'54.0"N 19°45'00.0"W as near Lake Holtsós or maybe near Skógar (that town to the east, which I think can be the closest one)?

I think that'll require looking for the nearest geo feature unbound by any radius, but if the point is farther than (radius) then add near prefix to it. And for the lakes, geo DB should have the lakes/geo features, but that might explode the size of the DB I guess

@immich-app immich-app locked and limited conversation to collaborators Mar 1, 2024
@jrasm91 jrasm91 converted this issue into discussion #7556 Mar 1, 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

3 participants