| image_to_markdown | R Documentation |
Submits an image for OCR, polls for completion, and saves Markdown output.
image_to_markdown(
image_path,
output_dir,
page_index,
token = "",
job_url = "",
model = "",
use_doc_orientation_classify = FALSE,
use_doc_unwarping = FALSE,
use_chart_recognition = FALSE,
poll_interval = 5,
max_wait_seconds = 1800,
timeout = 600
)
image_path |
Path to the image file. |
output_dir |
Directory for OCR output. |
page_index |
Page index for naming output files (1-indexed). |
token |
PaddleOCR API token. |
job_url |
PaddleOCR API endpoint. |
model |
Model name. |
use_doc_orientation_classify |
Logical; enable orientation classification. |
use_doc_unwarping |
Logical; enable document unwarping. |
use_chart_recognition |
Logical; enable chart recognition. |
poll_interval |
Polling interval in seconds. |
max_wait_seconds |
Maximum wait time. |
timeout |
HTTP timeout. |
A list with markdown_paths, markdown_texts, and
job_id.
## Not run:
result <- image_to_markdown("page_1.png", output_dir = "output", page_index = 1)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.