Change output folder for examples.

Signed-off-by: Christoph Auer <cau@zurich.ibm.com>
This commit is contained in:
Christoph Auer 2024-10-15 16:34:45 +02:00
parent c1794a79e2
commit 40bb84d2de
7 changed files with 6 additions and 7 deletions

View File

@ -122,7 +122,7 @@ def main():
raises_on_error=False, # to let conversion run through all and examine results at the end
)
success_count, partial_success_count, failure_count = export_documents(
conv_results, output_dir=Path("../../examples/scratch")
conv_results, output_dir=Path("scratch")
)
end_time = time.time() - start_time

View File

@ -113,7 +113,7 @@ def main():
_log.info(f"Document converted in {end_time:.2f} seconds.")
## Export results
output_dir = Path("../../examples/scratch")
output_dir = Path("scratch")
output_dir.mkdir(parents=True, exist_ok=True)
doc_filename = conv_result.input.file.stem

View File

@ -15,7 +15,7 @@ def main():
logging.basicConfig(level=logging.INFO)
input_doc_path = Path("./tests/data/2206.01062.pdf")
output_dir = Path("../../examples/scratch")
output_dir = Path("scratch")
# Important: For operating with page images, we must keep them, otherwise the DocumentConverter
# will destroy them for cleaning up memory.

View File

@ -20,7 +20,7 @@ def main():
logging.basicConfig(level=logging.INFO)
input_doc_path = Path("./tests/data/2206.01062.pdf")
output_dir = Path("../../examples/scratch")
output_dir = Path("scratch")
# Important: For operating with page images, we must keep them, otherwise the DocumentConverter
# will destroy them for cleaning up memory.

View File

@ -13,7 +13,7 @@ def main():
logging.basicConfig(level=logging.INFO)
input_doc_path = Path("./tests/data/2206.01062.pdf")
output_dir = Path("../../examples/scratch")
output_dir = Path("scratch")
doc_converter = DocumentConverter()

View File

@ -53,7 +53,7 @@ doc_converter = (
conv_results = doc_converter.convert_all(input_paths)
for res in conv_results:
out_path = Path("../../examples/scratch")
out_path = Path("scratch")
print(
f"Document {res.input.file.name} converted."
f"\nSaved markdown output to: {str(out_path)}"

View File

@ -1 +0,0 @@
../docs/examples/custom_convert.py