Skip to content

Latest commit

 

History

History
77 lines (48 loc) · 2.13 KB

File metadata and controls

77 lines (48 loc) · 2.13 KB

🤔 About

Various utilities to manage photos. Supported photo formats are PNG, JPG and HEIC.


🔹DuplicatePhotosFinder

Process photos from a given folder (and all its sub-folders), and generate a csv file reporting all duplicates.

DuplicatePhotosFinder [--directory <directory>] [--output <filename>.csv]

    directory: The path of the directory to process. Current directory by default.

    output: The path of the output csv file to generate. Default is ./duplicate.csv.


🔹SortPhotos

Sort photos into folders named using date and location from photo Exif data.

SortPhotos [--directory <directory>] [--output <output>] [--location] [--undefined <name>] [--copy]

    directory: The path of the directory to process. Current directory by default.

    output: The path of the directory to copy or move sorted photo into. Default is ./SORTED.

    location: Use location in addition to date to name folders.

    undefined: The folder name to use when Exif data cannot be retrieved. Modification date will be used in such case. Default is UNDEFINED.

    copy: Copy the photos instead of moving them.

📝 Implementation

LANGUAGE EDITOR OS

⚙ Installation

Clone the repository and go to the project directory.

git clone https://github.com/ZooterOne/File-Utils
cd File-Utils/PythonUtils

Setup the Python environment.

python -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt 

🏃‍♂️ Run script

python <script>.py <parameters>

🧪 Run tests

python -m unittest -v

💡 Future developments

  • Use perceptual hash algorithm to detect duplicate photos.