Linux find duplicate image

Open source duplicate image finder for Linux?

Is there a free and open source duplicate image finder for Linux based systems? Finding exact duplicates (based on content, not file name) is sufficient for me, but the ability to find similar images would certainly be great, too.

1 Answer 1

Digikam

Add all the photos to your collection. In the menu, select “Tools / Find duplicates”. This will look for duplicates accross your whole collection.

Findimagedupes

A command line tool. Pass all the images you want to compare on the command line.

Geeqie (formerly gqview)

In the menu, select “File / Find duplicate”. Drag and drop image files do the duplicates window. You can drop directories to add their contents recursively.

Fdupes

A command line tool to find byte-for-byte duplicates in a directory tree.

findimagedups will also descend hierarchies, does not require byte-level duplication and (more importantly) can keep records to speed up future runs (because the initial pass over a large stash of images can take a long time).

I think jdupes (github.com/jbruchon/jdupes) would be a good update / addition to this list. It is based on fdupes but advertises speed and feature improvements.

You must log in to answer this question.

Linked

Hot Network Questions

Subscribe to RSS

To subscribe to this RSS feed, copy and paste this URL into your RSS reader.

Site design / logo © 2023 Stack Exchange Inc; user contributions licensed under CC BY-SA . rev 2023.7.14.43533

Linux is a registered trademark of Linus Torvalds. UNIX is a registered trademark of The Open Group.
This site is not affiliated with Linus Torvalds or The Open Group in any way.

By clicking “Accept all cookies”, you agree Stack Exchange can store cookies on your device and disclose information in accordance with our Cookie Policy.

Источник

How to Find and Remove Duplicate Photos in Linux

Clicked too many similar photos? Have saved the same photo in different folders? I know that feel.

You click photos on camera, send it through WhatsApp. Now you back up the images and you have two copies of the photos from the gallery and WhatsApp. It is annoying, cluttered and takes extra space unnecessarily.

Читайте также:  Linux mysql import dump

I came across this issue while going through my father-in-law’s photo collection. Here’s what I did to find the duplicate photos and remove thm.

Find and remove duplicate photos with digiKam

digiKam is a free and open source utility for managing photo collections. It is primarily aimed at photographers but you do not need to be a professional camera person for using it.

Let me show you how you can use this tool for finding duplicate photos and if you feel like it, remove the duplicate ones.

Step 1

First thing first, install digiKam. It is a popular application and you should be able to install it from the software center or using the package manager of your distribution.

digikam software center

Step 2

When you start digiKam for the first time, it asks for the location of your image collection. Then it creates a SQLite database and then imports the images.

digikam initial setup 1

  • digikam initial setup 2
  • digikam initial setup 3
  • Step 3

    Now that you have imported your photos, go to Tools->Find Duplicates from the file menu.

    find duplicates digikam

    Step 4

    It will take some time depending on the number of images you have in your collection. After that, you should see all the photos that have duplicate images in the left sidebar. It also shows the duplicate photos for the selected image in the right sidebar.

    duplicate images found with digikam

    In the screenshot above, there are four copies of the same photo that I have selected in the left sidebar. You can see one of the images is labelled as ‘Reference image’. But it is up to you to believe which is original and which is duplicate.

    By default, the duplicate photos are divided into sections based on their location, i.e. folders. You may change that by going to View->Separate Items in the file menu.

    To delete the duplicate photos, select the image(s) in the right sidebar and then hit the delete button.

    You can repeat this by selecting the image in the left sidebar and then delete the duplicates one by one. Too time taking? There is a trick to delete multiple duplicates at a time.

    Deleting multiple duplicates images in digiKam

    If you want to delete duplicate photos for more than images at the same time, select all the images from the left sidebar.

    Now, go to the file menu -> View -> Sort Items and select By Similarity.

    remove multiple duplicate photos

    This will put all the referenced images at the bottom. You can select all the images in the right sidebar that are NOT labelled as duplicate and press the delete button.

    Bonus Tip: There is a trash bin for restoring deleted photos

    Accident happens. It is common to accidentally delete the wrong photos. This is why images are never really deleted by digiKam immediately. Instead, it creates a hidden .dtrash folder in the same folder where your photos are stored and moves the ‘deleted’ photos here.

    Читайте также:  Top команда в линуксе

    Even on the application interface, you can see the Trash folder. You can find your ‘deleted’ photos here and restore the ones you want.

    trash option digikam

    I hope you like this quick tutorial on finding and removing duplicate images in Linux. On a similar note, you may want to know about using GUI tools for finding duplicate files in your Linux system.

    Have questions or suggestions? Please leave a comment below.

    Источник

    How to detect duplicates of photos (even if the duplicate is of lower resolution) and how to keep only the higher-res copy?

    The upshot / meaning of this exercise would be to include in the initial photo selection also photos received in WhatsApp — as long as these are unique and no higher-res copy exists elsewhere (on my phone / computer).

    Further related links / resources:

    • https://www.linux.com/learn/how-sort-and-remove-duplicate-photos-Linux
    • http://www.visipics.info/index.php?title=Main_Page («VisiPics has been tested successfully with Wine on Linux»)
    • https://www.howtogeek.com/117559/how-to-banish-duplicate-photos-with-visipic/
    • https://pictureecho.com/ (Windows only)
    • https://www.techpout.com/best-duplicate-photo-finder-and-cleaner-software/
    • https://web.archive.org/web/20201126221814/https://blogs.systweak.com/5-duplicate-photo-finder-tools-to-delete-duplicate-photos/
    • https://softwarerecs.stackexchange.com/questions/40552/i-need-a-program-that-can-find-duplicate-images-different-resolutions-and-repl
    • https://stackoverflow.com/questions/13091603/find-duplicate-images-of-different-sizes
    • https://www.mindgems.com/products/VS-Duplicate-Image-Finder/VSDIF-About.htm
    • https://www.microsoft.com/en-us/p/duplicate-cleaner-free/9nblggh4rrr3
    • https://sourceforge.net/projects/gdupfinder/

    3 Answers 3

    I had the same use-case, and I wrote up a nifty little script to achieve that end.

    Have a look if this Python script helps you too:

    Some time ago, in Ubuntu 10.04, I was using DupeGuru Picture Edition for that. It was pretty good at finding duplicates in various sizes & resolutions. Seems that since version 4.0 of DupeGuru, the Picture Edition as a separate application is gone, but its functionality has been incorporated into the main application as «Picture Mode». You can try it, however currently only packages for Ubuntu 16.04 and 18.04 are available, there’s no build for 20.04.

    The package for 18.04 works under 20.04, but some additional fixes after installation are needed. You need to do the following commands:

    cd /usr/share/dupeguru/core/pe sudo ln -s _block.cpython-36m-x86_64-linux-gnu.so _block.cpython-38-x86_64-linux-gnu.so sudo ln -s _cache.cpython-36m-x86_64-linux-gnu.so _cache.cpython-38-x86_64-linux-gnu.so cd /usr/share/dupeguru/qt/pe sudo ln -s _block_qt.cpython-36m-x86_64-linux-gnu.so _block_qt.cpython-38-x86_64-linux-gnu.so 

    After this, DupeGuru works perfectly.

    Источник

    Is there a way to find duplicate images in Ubuntu? [duplicate]

    I am wondering if there is a way to compare folders in Ubuntu? I have tried to organize my photo folders many times. and for this reason I have several folders that contain the same files (maybe a couple of extra ones) and it would be great to have a tool to figure out which files are extra and which files are identical. P.S. I have just found an application that works well. It’s called FSlint. Here is a link to it with a detailed description: http://www.addictivetips.com/ubuntu-linux-tips/clean-up-ubuntu-remove-duplicates-with-fslint-filesystem-lint/

    I initially voted to close it as a duplicate but now I don’t think it’s a duplicate because it’s about finding images.

    4 Answers 4

    diff will help you find duplicate files in two different directories, but if your mess is greater or if, for any other reason, you want to find duplicate (exact) image files in a whole directory, including subdirectories, you can use the gthumb image browser viewer, which is probably already installed in your system.

    Читайте также:  Create at job linux

    Gthumb provides a tool to search for duplicate media/audio/video/images/text/all files in a directory. To do this, just select your directory in the view mode that displays a left pane with your directory tree, and then, from the menu select Edit>Find duplicates. a dialogue window shows the duplicates and lets you choose which file(s) to delete. This procedure is visual and helpful in many cases; but it is slow, if you have too many duplicate files to delete.

    Thanks for the answer. Can gthumb also compare 2 folders and tell me which files are the same or different in them?

    I don’t think so. Use diff for that or . there are other tools, I can’t recall their names, for that purpose.

    If you want to use gThumb, the following may be practical or not depending on the amount of files you have: You can put both directories inside a new directory; then use gThumb to find duplicates in that new dir; then you proceed to browse the results and/or delete the copies you want according to which directory they belong to.

    Hey Robert. I must say that Gthumb is a great application, but I have just found 10.000 duplicates and deleting them one by one seems to be a tedious task to do. 🙂 I need to find another way.

    Источник

    How can I find duplicate photos?

    Add all the photos to your collection. In the menu, select Tools / Find duplicates. This will look for duplicates across your whole collection.

    findimagedupes Install via the software center

    A command line tool. Pass all the images you want to compare on the command line.

    Geeqie (formerly GQview) Install via the software center

    In the menu, select File / Find duplicate. Drag and drop image files do the duplicates window. You can drop directories to add their contents recursively. For visual comparison of images, there are specific, non-default options on a drop-down menu. The «custom» level of similarity allows restricting pairings only to the highest degree of similarity, but it has to be set on Preferences as 99. Even then, it does not work perfectly at least for some kinds of images, like line-art. It unfortunately does not provide an automatic selection mechanism with rational criteria, such as resolution, date or whatever, the automatic selection seems to just randomly just pick the first image found as the reference to preserve. Deleting many images can be extremely slow, as it tries to update the result count at every delete.

    All three of these tools find visual duplicates, not just files that are identical byte for byte.

    Источник

    Оцените статью
    Adblock
    detector