Giter Club home page Giter Club logo

ppim-migrator's Introduction

Note

There was an issue with immich versions between v1.91.0 and v1.92.x Make sure to use an immich version higher or equal to 1.93.x

PyPI version

Photoprism to Immich migrator

This tool can migrate albums and favorites from Photoprism to Immich. It does not migrate your photo files.

Prerequisites

  1. The tool will only work if you keep the same file structure in immich that you already had in photoprism. This is the case if you take the originals folder from photoprism and use it in immich as external library.
  2. Photoprism and Immich must both be running at the same time, because the tool communicates with both APIs.

How it works

ppim-migrator-diagram

Migrate favorites

  1. The tool fetches all photos with a favorite tag from your photoprism instance
  2. For each photo, it retrieves the original filename and its respective path
  3. It connects to immich, tries to find the photo by filename and validates potential candidates on the immich side by comparing the file path
  4. If a match was found, it marks the photo on immich as favorite

Migrate album

  1. The tool fetches all photos of a certain album from your photoprism instance
  2. For each photo, it retrieves the original filename and its respective path
  3. It connects to immich, tries to find the photo by filename and validates potential candidates on the immich side by comparing the file path
  4. If a match was found, it creates a new album in immich and adds the matched photos

Installation

pip install ppim-migrator

Configuration

Create a config.yaml file in the working directory where you want to run the command.

photoprism:
  base_url: https://photoprism.example.com
  username: 
  password: 
immich:
  base_url: https://immich.example.com
  api_key: 

Usage

Migrate all favorites from photoprism to immich

python -m ppim-migrator migrate-favorites

Migrate a certain album from photoprism to immich

To get an album-id just open the album in photoprism. The id is part of the url. Example:

  • Url, when opening the album: https://photoprism.example.com/library/albums/aqrcixa2uf1q45iq/view The album-id would be aqrcixa2uf1q45iq
python -m ppim-migrator migrate-album <album-id-here>

ppim-migrator's People

Contributors

v411e avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

berkcelc elduty

ppim-migrator's Issues

Searching on Immich give no match

Hi thanks for sharing your work. I have tried Immich and a crucial step is the migration from Photoprism, because I have a lot of photos (~ 190'000).

The connection between the two systems works, but it seems that the search is giving nothing (I'm not a programmer), for favorites and albums. Can it be that with the change in release V1.91.0, the search results (or search key) are also changed and now they don't work.

Can you make a try to confirm that?

Thanks for this!

Just wanted to say thank you! This helped me migrate my data over to immich. Cheers!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.