Page 1 of 1

PDF processing in Photoshop (feedback please)

Posted: Wed Jun 21, 2017 8:35 pm
by Silere
Hello,

A few days ago I got eye fatigue from studying the Rachmaninoff's Piano Trio No. 1. I used the only available edition on IMSLP at the time. To rest, I decided to edit the score with the software I already got on my computer.

Since I could not find a method that I liked, I created my own and recorded a tutorial for YouTube:
Tutorial - Fix a scanned music score with Photoshop

I would like to share my method and have feedback from this community to make it better. I would like an algorithm to completely remove the noise in a scanned music score and do not require any human intervention.

First a comparison:
Original
Image
After noise reduction
Image

The problem with the original score is the high amount of noise on the scan.

The algorithm I used to greatly remove the noise is:
Image
  1. Convert the image to grayscale mode
  2. Duplicate layer
  3. Apply Dust & Scrtches filter
  4. Set the filtered layer to lighten
  5. Convert the image to bitmap mode
  6. Save as a PDF Grayscale with no compression
For me, the advantage over the method documented in IMSLP that uses Photoline software, is that I didn't have to install any extra software in my computer. Also, once I had the algorithm, I could just use Batch processing to filter the whole score in seconds (as shown at the end of the tutorial).

The original score is 2.13 MB in size. The resulting one ended in 1.66 MB. I think the reduced size, with no apparent loss in quality, is also really valuable.

Please feel free to download and critique the processed version I uploaded on the Piano Trio page

(Also, I would be glad if someone corrected my grammar in "Misc. Notes". I could not find how to edit the page)

Thank you.

Re: PDF processing in Photoshop (feedback please)

Posted: Sat Jul 29, 2017 6:38 am
by coulonnus
I just found the time to research this. Judging by the proportion {thickness of the staff lines}/{distance between staff lines} this score has been scanned to dark. I begun starting with converting the pages to jpg, resizing them by 200% and converting them back to tif with a low threshold so only the darkest pixels remain, making all lines look thinner. The smallest stains already disappear at this stage.

Then I created my own method to remove all groups of dark pixels smaller than a given radius. This radius must be carefully chosen so you don't remove augmentation dots, dots on the i of con anima etc.

If I resize the pages back to their original size I obtain a pdf of 1.9 MB. I have also manually removed markings, fingerings, stains bigger than a useful dot etc. But like you, if you watch the crescendo indications p.5 some letters were slightly degraded.

Note that I had to unlock the original file with Gsview before I could split it with pdftk.