Class LicensePlateDetectionRecognitionOptions
- Assembly
- CapCognition.Net.LicensePlateDetection.dll
public class LicensePlateDetectionRecognitionOptions : RecognitionOptions, IDisposable
- Inheritance
-
LicensePlateDetectionRecognitionOptions
- Implements
- Inherited Members
Properties
DeliverPlatePictureInResult
Gets or sets a value indicating whether the result should contain the plate picture.
public bool DeliverPlatePictureInResult { get; set; }
Property Value
DoAutomaticDetectionOptimization
Set the true to do optimization of the processing methods when the models are loaded the first time. Only enable when using the models for multiple detections.
public bool DoAutomaticDetectionOptimization { get; set; }
Property Value
PlateModelConfidence
public float PlateModelConfidence { get; set; }
Property Value
PlateModelMulConfidence
public float PlateModelMulConfidence { get; set; }
Property Value
PlateModelQuality
Set the quality of the license plate model.
public LicensePlateDetectionRecognitionOptions.QualityPlateModel PlateModelQuality { get; set; }
Property Value
RecognitionMode
Gets or sets the mode of recognition used by the system.
public LicensePlateDetectionRecognitionOptions.RecognitionModeType RecognitionMode { get; set; }
Property Value
TextModelConfidence
public float TextModelConfidence { get; set; }
Property Value
TextModelMulConfidence
public float TextModelMulConfidence { get; set; }
Property Value
TextModelQuality
Set the quality of the text model.
public LicensePlateDetectionRecognitionOptions.QualityTextModel TextModelQuality { get; set; }
Property Value
TextModelWideConfidence
public float TextModelWideConfidence { get; set; }
Property Value
TextModelWideMulConfidence
public float TextModelWideMulConfidence { get; set; }
Property Value
TextWideModelQuality
Set the quality of the text wide model.
public LicensePlateDetectionRecognitionOptions.QualityTextWideModel TextWideModelQuality { get; set; }
Property Value
UseCroppedImageForRecognition
If true: Use cropped image for recognition. The image will be cropped (stretched) to fill the recognition area. Depending on the image aspect ratio, the image might be stretched horizontally or vertically so only the center part is taken for the recognition.
-------------------
| |
|................|
| |
| Recognized |
| |
| |
|................|
| |
| |
-------------------
If false: Use a fit image for recognition. The image will be resized to fit the recognition area.
-------------------
| b. . b|
| l. . l|
| a. Recognized . a|
| c. . c|
| k. . k|
| . . |
-------------------
public bool UseCroppedImageForRecognition { get; set; }
Property Value
UseCudaProvider
Set the true to use the CUDA provider for the recognition. Note: Only enable when cuda toolkit (https://developer.nvidia.com/cuda-downloads) and CUDNN (https://developer.nvidia.com/cudnn) are installed. Only available for Windows and Linux. Under ARM64 or ARM32, the CUDA provider is not available.
public bool UseCudaProvider { get; set; }
Property Value
VehicleModelConfidence
public float VehicleModelConfidence { get; set; }
Property Value
VehicleModelMulConfidence
public float VehicleModelMulConfidence { get; set; }
Property Value
VehicleModelQuality
Set the quality of the vehicle model.
public LicensePlateDetectionRecognitionOptions.QualityVehicleModel VehicleModelQuality { get; set; }
Property Value
Methods
CheckIfModelsNeedsPreparation()
checks if at least one model needs to be prepared before it can be used.
public bool CheckIfModelsNeedsPreparation()
Returns
- bool
True if one of the models is not prepared
ClearModelCacheFolder()
Clears the model cache folder.
public void ClearModelCacheFolder()
ClearOldModelsFromCacheFolder()
Removes all model files from the cache folder except for the currently required models.
public void ClearOldModelsFromCacheFolder()
Remarks
This method helps manage disk space by deleting outdated or unused model files from the cache. Only the models referenced by the current application version are retained; all other files in the model cache folder are deleted. This operation is not reversible.
CreateAndPrepareModels()
Creates and prepares the models asynchronously.
public bool CreateAndPrepareModels()
Returns
- bool
True if the models were created and prepared successfully.
CreateAndPrepareModelsAsync()
Creates and prepares the models asynchronously.
public Task<bool> CreateAndPrepareModelsAsync()
Returns
Dispose()
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
public override void Dispose()
Events
ModelsDownloadStartedEvt
This event is raised to notify the start of downloading the models. Note: The event can be called from a different thread than the main thread.
public event LicensePlateDetectionRecognitionOptions.ModelsDownloadStartedDelegate? ModelsDownloadStartedEvt
Event Type
ModelsDownloadedEvt
This event is raised to notify the end of downloading all the models. Note: The event can be called from a different thread than the main thread.
public event LicensePlateDetectionRecognitionOptions.ModelsDownloadedDelegate? ModelsDownloadedEvt
Event Type
PreparationProgressEvt
This event is raised to notify the progress of the model loading. Note: The event can be called from a different thread than the main thread.
public event LicensePlateDetectionRecognitionOptions.ProgressDelegate? PreparationProgressEvt