Event Progress
- Namespace
- LMKit.Extraction
- Assembly
- LM-Kit.NET.dll
Occurs when the extraction operation makes progress, including phase transitions and pass completions.
public event EventHandler<ExtractionProgressEventArgs> Progress
Returns
- EventHandler<ExtractionProgressEventArgs>
- Occurs when the extraction operation makes progress, including phase transitions and pass completions.
Examples
var extractor = new TextExtraction(model);
extractor.Progress += (sender, e) =>
{
switch (e.Phase)
{
case ExtractionPhase.OcrProcessing:
Console.WriteLine($"OCR: page {e.PageIndex + 1}/{e.TotalPages}");
break;
case ExtractionPhase.Extracting:
Console.WriteLine($"Extracting: pass {e.PassIndex + 1}/{e.TotalPasses}");
break;
case ExtractionPhase.PostProcessing:
Console.WriteLine("Post-processing results...");
break;
case ExtractionPhase.Completed:
Console.WriteLine("Extraction complete.");
break;
}
};
var result = extractor.Parse();