Products | Support | Email a link to this topic. | Send comments on this topic. | Back to Introduction - All Topics | Help Version 19.0.5.10
|
Leadtools.Forms.Recognition Namespace > FormRecognitionResult Class : Confidence Property |
public int Confidence {get; set;}
'Declaration Public Property Confidence As Integer
'Usage Dim instance As FormRecognitionResult Dim value As Integer instance.Confidence = value value = instance.Confidence
For a complete example on using the forms recognition and processing, refer to the FormRecognitionEngine example.
This example finds the maximum confidence of the comparison with Master Forms.
Imports Leadtools.Forms Imports Leadtools.Forms.Recognition '''This method identifies the type of the form based on the comparison results. Public Function IdentefyForm(results As FormRecognitionResult()) As Integer Dim maxIndex As Integer = 0 maxIndex = 0 For i As Integer = 1 To results.Length - 1 If results(maxIndex).Confidence < results(i).Confidence Then maxIndex = i End If Next If results(maxIndex).Confidence < 30 Then maxIndex = -1 End If 'no match Return maxIndex End Function
using Leadtools.Forms; using Leadtools.Forms.Recognition; ///This method identifies the type of the form based on the comparison results. public int IdentefyForm(FormRecognitionResult[] results) { int maxIndex = 0; maxIndex = 0; for (int i = 1; i < results.Length; i++) { if (results[maxIndex].Confidence < results[i].Confidence) maxIndex = i; } if (results[maxIndex].Confidence < 30) maxIndex = -1;//no match return maxIndex; }