commit | author | age
|
e555c0
|
1 |
from Ocr import Paper |
02e0f7
|
2 |
from sklearn.externals import joblib |
e555c0
|
3 |
|
762a5e
|
4 |
|
5cb7c1
|
5 |
settings = {"sid_mask": "61xx0xxx", "answer_treshold": 0.25} |
0436f6
|
6 |
classifier = joblib.load("filename.joblib") |
e555c0
|
7 |
|
0436f6
|
8 |
#p = Paper(filename="testpage300dpi_scan1.png") |
ac766e
|
9 |
#p=Paper(filename='sizif111.tif', sid_classifier=classifier, settings=settings) |
SP |
10 |
p=Paper(filename='processed_scans/20141016095134535_0006.tif', sid_classifier=classifier, settings=settings) |
02e0f7
|
11 |
|
0436f6
|
12 |
# print(p.QRData) |
SP |
13 |
# print(p.errors) |
e555c0
|
14 |
|
0436f6
|
15 |
# print(p.getSkewAngle()) |
SP |
16 |
# print(p.locateUpMarkers()) |
|
17 |
# print(p.locateRightMarkers()) |
|
18 |
# print(p.answerMatrix) |
|
19 |
# p.get_enhanced_sid() |
|
20 |
|
|
21 |
|
|
22 |
print(p.get_paper_ocr_data()) |