Skip to content

Commit

Permalink
small updates
Browse files Browse the repository at this point in the history
  • Loading branch information
jeremyholtzman committed Jun 24, 2018
1 parent 2d42633 commit 491cd29
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions ocr_clean.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# https://www.pyimagesearch.com/2017/07/10/using-tesseract-ocr-python/

# run the file with
# python2 ocr.py -i example_01.png
# or
Expand Down Expand Up @@ -29,9 +27,7 @@

# check to see if we should apply thresholding to preprocess the
# Next, depending on the pre-processing method specified by our command line argument,
# we will either threshold or blur the image. This is where you would want to add more
# advanced pre-processing methods (depending on your specific application of OCR) which are beyond the scope of this blog post.
# image
# we will either threshold or blur the image.
if args["preprocess"] == "thresh":
gray = cv2.threshold(gray, 0, 255,
cv2.THRESH_BINARY | cv2.THRESH_OTSU)[1]
Expand Down

0 comments on commit 491cd29

Please sign in to comment.