View source: R/batch_processing.R
process_batch_list | R Documentation |
Process a list of handwriting samples saved as PNG images: (1) Load the image
and convert it to black and white with readPNGBinary()
(2) Thin the
handwriting to one pixel in width with thinImage()
(3) Run
processHandwriting()
to split the handwriting into parts called edges
and place nodes at the ends of edges. Then combine edges into component
shapes called graphs. (4) Save the processed document in an RDS file. (5)
Optional. Return a list of the processed documents.
process_batch_list(images, output_dir, skip_docs_on_retry = TRUE)
images |
A vector of image file paths |
output_dir |
A directory to save the processed images |
skip_docs_on_retry |
Logical whether to skip documents in the images arguement that
caused errors on a previous run. The errors and document names are stored
in output_dir > problems.txt. If this is the first run,
|
No return value, called for side effects
## Not run:
images <- c('path/to/image1.png', 'path/to/image2.png', 'path/to/image3.png')
process_batch_list(images, "path/to/output_dir", FALSE)
process_batch_list(images, "path/to/output_dir", TRUE)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.