mirror of
https://github.com/qurator-spk/dinglehopper.git
synced 2025-07-01 06:29:59 +02:00
🚧 Add OCR-D parameter for plain text encoding
This commit is contained in:
parent
5578ce83a3
commit
9db5b4caf5
2 changed files with 7 additions and 0 deletions
|
@ -25,6 +25,11 @@
|
||||||
"enum": ["region", "line"],
|
"enum": ["region", "line"],
|
||||||
"default": "region",
|
"default": "region",
|
||||||
"description": "PAGE XML hierarchy level to extract the text from"
|
"description": "PAGE XML hierarchy level to extract the text from"
|
||||||
|
},
|
||||||
|
"plain_encoding": {
|
||||||
|
"type": "string",
|
||||||
|
"default": "autodetect",
|
||||||
|
"description": "Encoding (e.g. \"utf-8\") of plain text files"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -26,6 +26,7 @@ class OcrdDinglehopperEvaluate(Processor):
|
||||||
assert self.parameter
|
assert self.parameter
|
||||||
metrics = self.parameter["metrics"]
|
metrics = self.parameter["metrics"]
|
||||||
textequiv_level = self.parameter["textequiv_level"]
|
textequiv_level = self.parameter["textequiv_level"]
|
||||||
|
plain_encoding = self.parameter["plain_encoding"]
|
||||||
|
|
||||||
# wrong number of inputs: let fail
|
# wrong number of inputs: let fail
|
||||||
gt_file, ocr_file = input_files
|
gt_file, ocr_file = input_files
|
||||||
|
@ -52,6 +53,7 @@ class OcrdDinglehopperEvaluate(Processor):
|
||||||
self.output_file_grp,
|
self.output_file_grp,
|
||||||
metrics=metrics,
|
metrics=metrics,
|
||||||
textequiv_level=textequiv_level,
|
textequiv_level=textequiv_level,
|
||||||
|
plain_encoding=plain_encoding,
|
||||||
)
|
)
|
||||||
|
|
||||||
# Add reports to the workspace
|
# Add reports to the workspace
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue