Commit
·
b3e1590
1
Parent(s):
af7559c
Update app.py
Browse files
app.py
CHANGED
@@ -8,7 +8,7 @@ def calculate_distance(org_text, ocr_str):
|
|
8 |
ocr_chars = list(ocr_str)
|
9 |
org_chars = list(org_str)
|
10 |
cer = Levenshtein.distance(org_chars, ocr_chars) / len(org_chars)
|
11 |
-
return
|
12 |
|
13 |
iface = gradio.Interface(
|
14 |
fn=calculate_distance,
|
|
|
8 |
ocr_chars = list(ocr_str)
|
9 |
org_chars = list(org_str)
|
10 |
cer = Levenshtein.distance(org_chars, ocr_chars) / len(org_chars)
|
11 |
+
return f"The Character Error Rate (CER): {cer}"
|
12 |
|
13 |
iface = gradio.Interface(
|
14 |
fn=calculate_distance,
|