Duplicate Thumbnail File - A mathod to indetify duplicate articles when doing a Systematic review.
A systematic review could spawn countless articles, when running your search string on different data bases.
Many times articles were exported as PDF files and submited to diferent jornals or publications. The problem is, depending on how the PDF was exported, it will produce a different file, making it hard to check for duplicates by looking at their hash.
Five articles were written and exported to PDF, each one with a small difference.
01-jpg-100.pdf - was exported as a JPG file with 100% quality.
02-lossless.pdf - was exported as a LOSSLESS file.
03-lossless-2newlines.pdf - was exported as a LOSSLESS file with two new lines after the end of the document.
04-jpg-80-2newlines.pdf - was exported as a JPG file with 80% quality and two new lines after the end of the document.
05-jpg-80.pdf - was exported as a JPG file with 100% quality.
Let's look at their hash:
According to the hash of each file, they're different from each other, when in fact, is the "same" document.
And what if instead of looking at the hash of each file, we look to their thumbnail? It might work a little better.
So a python script was written to generate the thumbnail of each file and measure how different those thumbnails ware.
Here's the result:
|File 01||File 02||Difference|
So, as we can see, there is 0.0 difference between them, so they must have the same content.
This experiment offers a diffent approach to a common problem when doing systemic review, and in this particular case, it worked better. This method could be used alongside with other methods to indentify and exclude duplicate files.
The dtf.py script could be used as base to a more robust script that compares any files that could be compared visually.
The code for the experiment is here