347d06f2 by 周伟奇

fix registeredCapital

1 parent 357ac93f
import re
from datetime import datetime
# from .rmb_lower import rmb_handler
from .rmb_upper import to_rmb_upper
from .rmb_lower import rmb_handler
# from .rmb_upper import to_rmb_upper
class Comparison:
......@@ -109,18 +109,18 @@ class Comparison:
if ocr_str == '' or ocr_str.strip() == '':
return self.RESULT_NA, None
try:
# ocr_lower = rmb_handler.to_rmb_lower()
# res = self.build_res(float(input_str) == ocr_lower)
input_rmb_upper = to_rmb_upper(float(input_str))
res = self.build_res(input_rmb_upper == ocr_str)
ocr_lower = rmb_handler.to_rmb_lower()
res = self.build_res(float(input_str) == ocr_lower)
# input_rmb_upper = to_rmb_upper(float(input_str))
# res = self.build_res(input_rmb_upper == ocr_str)
except Exception as e:
return self.RESULT_N, None
else:
if res == self.RESULT_Y:
return res, input_str
else:
# return res, ocr_lower
return res, None
return res, ocr_lower
# return res, None
def type_compare(self, input_str, ocr_str, idx, **kwargs):
if not isinstance(ocr_str, str) or not isinstance(input_str, str):
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!