title: Python: Letter repair using OpenCV for text recognition
body: <p>I am trying to repair image contains letters each letter split into two halves from the middle. </p>
  
  <p>original Image <br></p>
  
  <p><a href="https://i.stack.imgur.com/jEBAQ.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/jEBAQ.jpg" alt="enter image description here"></a></p>
  
  <p>After Applying the following code:</p>
  
  <pre><code>gray = cv2.cvtColor(cropped_bot, cv2.COLOR_BGR2GRAY)
  
  new_img = ((gray &gt;= 230)*255).astype('uint8')    
  
  bottom_image =  255-new_img
  </code></pre>
  
  <p>I get this Image <br>
  <a href="https://i.stack.imgur.com/ipOPE.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/ipOPE.png" alt="enter image description here"></a></p>
  
  <p>My Problem is to fix the line that split the letters into two part.</p>
  
  <p>I have tried <code>adaptiveThreshold</code></p>
  
  <pre><code>cv2.adaptiveThreshold(gray, 255, cv2.ADAPTIVE_THRESH_MEAN_C, cv2.THRESH_BINARY, 15, 2)
  </code></pre>
  
  <p>But it doesn't help. How I can solve this </p>