Aspose.Barcode for Python via Java Generation and Recognition API docs
asposebarcode.Recognition.BarCodeConfidence Class Reference

Contains recognition confidence level. More...

Inherits Enum.

Static Public Attributes

string NONE = "0"
 
string MODERATE = "80"
 
string STRONG = "100"
 

Detailed Description

Contains recognition confidence level.

This sample shows how BarCodeConfidence changed, depending on barcode type

#Moderate confidence
generator = BarcodeGenerator(EncodeTypes.CODE_128, "12345")
generator.save("test.png")
reader = BarCodeReader("test.png", None, [DecodeType.CODE_39_STANDARD, DecodeType.CODE_128])
for result in reader.readBarCodes():
print("BarCode Type: " + result.getCodeTypeName())
print("BarCode CodeText: " + result.getCodeText())
print("BarCode Confidence: " + result.getConfidence())
print("BarCode ReadingQuality: " + result.getReadingQuality())
#Strong confidence
generator = BarcodeGenerator(EncodeTypes.QR, "12345")
generator.save("test.png")
reader = BarCodeReader("test.png", None, [DecodeType.CODE_39_STANDARD, DecodeType.QR])
for result in reader.readBarCodes():
print("BarCode Type: " + result.getCodeTypeName())
print("BarCode CodeText: " + result.getCodeText())
print("BarCode Confidence: " + result.getConfidence())
print("BarCode ReadingQuality: " + result.getReadingQuality())

Member Data Documentation

◆ MODERATE

string asposebarcode.Recognition.BarCodeConfidence.MODERATE = "80"
static

◆ NONE

string asposebarcode.Recognition.BarCodeConfidence.NONE = "0"
static

◆ STRONG

string asposebarcode.Recognition.BarCodeConfidence.STRONG = "100"
static