Slashdot Mirror


Does Anyone Make a Photo De-Duplicator For Linux? Something That Reads EXIF?

postbigbang writes "Imagine having thousands of images on disparate machines. many are dupes, even among the disparate machines. It's impossible to delete all the dupes manually and create a singular, accurate photo image base? Is there an app out there that can scan a file system, perhaps a target sub-folder system, and suck in the images-- WITHOUT creating duplicates? Perhaps by reading EXIF info or hashes? I have eleven file systems saved, and the task of eliminating dupes seems impossible."

6 of 243 comments (clear)

  1. fdupes -rd by Anonymous Coward · · Score: 5, Informative

    I've had the same problem as I stupidly try to make the world a better place by renaming or putting them in sub-directories.

    fdupes will do a bit-wise comparison. -r = recurse. -d = delete.

    fdupes would be the fastest way.

  2. Re:write it yourself by Anonymous Coward · · Score: 5, Informative

    ExifTool is probably your best start:

    http://www.sno.phy.queensu.ca/~phil/exiftool/

  3. findimagedupes in Debian by nemesisrocks · · Score: 5, Interesting

    whatever you decide on, it could probably be done in a hundred lines of perl

    Funny you mention perl.

    There's a tool written in perl called "findimagedupes" in Debian. Pretty awesome tool for large image collections, because it could identify duplicates even if they had been resized, or messed with a little (e.g. adding logos, etc). Point it at a directory, and it'll find all the dupes for you.

  4. General case by xaxa · · Score: 5, Informative

    For the general case (any file), I've used this script:


    #!/bin/sh

    OUTF=rem-duplicates.sh;

    echo "#! /bin/sh" > $OUTF;

    find "$@" -type f -print0 |
        xargs -0 -n1 md5sum |
            sort --key=1,32 | uniq -w 32 -d --all-repeated=separate |
                sed -r 's/^[0-9a-f]*( )*//;s/([^a-zA-Z0-9./_-])/\\\1/g;s/(.+)/#rm \1/' >> $OUTF;

    chmod a+x $OUTF; ls -l $OUTF

    It should be straightforward to change "md5sum" to some other key -- e.g. EXIF Date + some other EXIF fields.

    (Also, isn't this really a question for superuser.com or similar?)

  5. Re:Don't reinvent the wheel: fdupes, md5deep, gqvi by rwa2 · · Score: 5, Informative

    Yeah, this Ask Slashdot should really be about teaching people how to search for packages in aptitude or whatever your package manager is...
    Here are some others:

    findimagedupes
    Finds visually similar or duplicate images
    findimagedupes is a commandline utility which performs a rough "visual diff" to
    two images. This allows you to compare two images or a whole tree of images and
    determine if any are similar or identical. On common image types,
    findimagedupes seems to be around 98% accurate.
    Homepage: http://www.jhnc.org/findimaged...

    fslint :

    kleansweep :
    File cleaner for KDE
    KleanSweep allows you to reclaim disk space by finding unneeded files. It can
    search for files basing on several criterias; you can seek for:
    * empty files
    * empty directories
    * backup files
    * broken symbolic links
    * broken executables (executables with missing libraries)
    * dead menu entries (.desktop files pointing to non-existing executables)
    * duplicated files ...
    Homepage: http://linux.bydg.org/~yogin/

    komparator :
    directories comparator for KDE
    Komparator is an application that searches and synchronizes two directories. It
    discovers duplicate, newer or missing files and empty folders. It works on
    local and network or kioslave protocol folders.
    Homepage: http://komparator.sourceforge....

    backuppc : (just in case this was related to your intended use case for some reason)
    high-performance, enterprise-grade system for backing up PCs
    BackupPC is disk based and not tape based. This particularity allows features #
    not found in any other backup solution:
    * Clever pooling scheme minimizes disk storage and disk I/O. Identical files
        across multiple backups of the same or different PC are stored only once
        resulting in substantial savings in disk storage and disk writes. Also known
        as "data deduplication".

    I bet if you throw Picasa at your combined images directory, it might have some kind of "similar image" detection too, particularly since its sorts everything by exif timestamp.

    That said, I've never had to use any of this stuff, because my habit was to rename my camera image dumps to a timestamped directory (e.g. 20140123_DCIM ) to begin with, and upload it to its final resting place on my main file server immediately, so I know all other copies I encounter on other household machines are redundant.

  6. Re:Seriously? by zakkie · · Score: 5, Informative

    See my earlier contrivution: geeqie. It will even scan for image similarity not just rudimentary hashing. Someone else mentioned gqview & that it was out of date - geeqie is what gqview became.