- png_folder
Directory containing PNG images organized into
subfolders named after classes. Each PNG file represents a single ROI
extracted from an IFCB sample and must follow the standard IFCB naming
convention (for example, "D20220712T210855_IFCB134_00042.png"), which
is used to map the image to the corresponding ROI index in the ADC file.
- adc_folder
Directory containing ADC files for the samples.
- class2use_file
Path to a class2use MAT file. This file should
contain the vector of classes used for matching PNG annotations to class IDs.
- output_folder
Directory where the resulting MAT files will be written.
If the folder does not exist, it will be created automatically.
- sample_names
Optional character vector of IFCB sample names
(e.g., "D20220712T210855_IFCB134"). If NULL (default), all samples
detected from the PNG filenames in png_folder will be processed.
Each sample must have a corresponding ADC file in adc_folder.
- unclassified_id
An integer specifying the class ID to use for unclassified
regions of interest (ROIs) when creating new manual .mat files. Default is 1.
- remove_trailing_numbers
Logical. If TRUE (default), trailing numeric
suffixes are removed from PNG subfolder names before matching them to
entries in class2use (for example, "Skeletonema_036" becomes
"Skeletonema"). This is useful when class folders include numeric
identifiers that are not part of the class names in class2use.
- do_compression
A logical value indicating whether to compress the .mat file. Default is TRUE.