Text this: A Method for Borehole Image Reverse Positioning and Restoration Based on Grayscale Characteristics