Answer the question
In order to leave comments, you need to log in
How to sort a large number of photos?
Good afternoon. I decided to make myself a copy of the family archive. After collecting from all sources, you will get a large nested structure of folders, photos and video content (about 100 gigabytes). It is necessary to sort the photos into an ordered structure (let's say - Camera / YYYY / MM / DD). For processing, the idea was to write a small program (worth debian). At the moment, the algorithm is as follows:
1. Find all jpg in the selected folder.
2. For each jpg, check the headers (I can be wrong, but they seem to be in jpg) for integrity (you never know the file is damaged or the file is not a photo, but just a file with the jpg extension).
3. Write information about each file (name and relative path, hash, exif tags) to a csv file (or something similar).
4.Find duplicates and apply filters (for example, there should be all exif tags).
5.Copy/move the remaining files to the specified folder structure.
How would it be better to implement it, is it possible to optimize the algorithm?
Answer the question
In order to leave comments, you need to log in
From the series: "how to make everything true in the console":
1. find
2. Here you need to clarify. do you mean exif? But there are many options here - a photo saved without exif, etc. The simplest - exiv2
3. Information - exiv2
4. By duplicates - jdupes (it's better than fdupes).
5. find + exec mv
Wrap everything in sh and debug.
How would it be better to implement it, is it possible to optimize the algorithm?
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question