This is a solution to a problem posted in Stackoverflow where a user asked to remove paper lines while keeping the drawing in a good condition.
The decision was to handle the paper seperated from the drawing to get the best results using morphology operations and inpaint.
https://stackoverflow.com/questions/71425968/remove-horizontal-lines-with-open-cv/71475252#71475252
Original image
First Mask
First inpaint
Second Mask
Second inpaint