Location
Parameter Location
defines the location of the TargetROI with reference objects
filter conditions and offset
parameters.
Example
{
"Location":
{
"ReferenceObjectFilter" :
{
"ReferenceTargetROIDefNameArray": ["TR_0", "TR_1"],
"AtomicResultTypeArray" : ["ART_TEXT_LINE","ART_BARCODE","ART_FRAME","ART_TABLE_CELL"],
"BarcodeFilteringCondition":
{
"BarcodeFormatIds": ["BF_CODE39"],
"BarcodeTextRegExPattern": ".*b.*b.*b.*",
"RegionState": "default",
},
"FrameFilteringCondition":
{
"ImageDimensionRange": [16384,0x7fffffff],
"AspectRatioRange": [1, 10000],
"WidthRange": [1, 0x7fffffff],
"HeightRange": [1, 0x7fffffff],
"RegionState": "default",
},
"TableCellFilteringCondition":
{
"RowNumbers": "1,3,5",
"ColNumbers": "1",
"RegionState": "default",
},
"TextLineFilteringCondition":
{
"LineNumbers": "1,3-5",
"LineStringRegExPattern": "Sodium[(\w| )]*",
"RegionState": "default",
}
},
"Offset": {
"ReferenceObjectOriginIndex": 0,
"ReferenceObjectSizeType": "default",
"MeasuredByPercentage" : 1,
"FirstPoint" : [ 0, 0 ],
"SecondPoint" : [ 100, 0 ],
"ThirdPoint" : [ 100, 100 ],
"FourthPoint" : [ 0, 100 ],
}
}
}
Parameter Summary
ReferenceObjectFilter
Parameter ReferenceObjectFilter
is a group of filter conditions for figuring out the reference objects
.
ReferenceTargetROIDefNameArray
Filter the reference object by specifying TargetROI
names.
ReferenceTargetROIDefNameArray Parameter Summary |
---|
Type String[] |
Range Each member should be a name of TargetROI that defined in TargetROIDefOptions . |
Default Value null |
AtomicResultTypeArray
Filter the reference object by specifying the type of atomic results. In the TargetROIs
algorithm task can produce atomic results that can support the localization of the other TargetROIs
.
AtomicResultTypeArray Parameter Summary |
---|
Type String[] |
Range Each member should be one of the AtomicResultType , which are ART_TEXT_LINE , ART_BARCODE , ART_FRAME , ART_TABLE_CELL , ART_GEOMETRY_LINE , ART_CORNER and ART_COLOUR_REGION |
Default Value [“ART_TEXT_LINE”,”ART_BARCODE”,”ART_FRAME”] |
BarcodeFilteringCondition
One of the filter conditions. Filter the reference objects with the decoded barcode information. The parameter BarcodeFilteringCondition
includes the following child parameters:
Child Parameter Name | Child Parameter Summary |
---|---|
BarcodeFormatIds | Description Filter the reference objects by the barcode formats. |
Type String[] |
|
Range Each member of the array should be one of the BarcodeFormatIds as a string. |
|
Default Value |
|
BarcodeTextRegExPattern | Description Filter the reference objects by the barcode text with a RegEx string. |
Type String |
|
Default Value "" |
FrameFilteringCondition
One of the filter conditions. Filter the reference objects with the frame information. The parameter FrameFilteringCondition
includes the following child parameters:
Child Parameter Name | Child Parameter Summary |
---|---|
ImageDimensionRange | Description Filter the reference objects by the dimension of their original images. |
Type int[2] |
|
Default Value [16384,0x7fffffff] |
|
AspectRatioRange | Description Filter the reference objects by the aspect ratio of their original images. Aspect Ratio = BoundingRectHeight/BoundingRectWidth * 100 [MinAspectRatio, MaxAspectRatio] |
Type int[2] |
|
Default Value [1, 10000] |
|
WidthRange | Description Filter the reference objects by the width of their original images. |
Type int[2] |
|
Default Value [1, 0x7fffffff] |
|
HeightRange | Description Filter the reference objects by the height of their original images. |
Type int[2] |
|
Default Value [1, 0x7fffffff] |
TextLineFilteringCondition
One of the filter conditions. Filter the reference objects with the text line content. The parameter TextLineFilteringCondition
includes the following child parameters:
Child Parameter Name | Child Parameter Summary |
---|---|
LineNumbers | Description Filter the reference objects by the line numbers. |
Type String |
|
Range A string of one or more of the following data, separated by commas: 1. One int value which represents a specified line index; 2. One Expression, start index and stop index connected with ""-"", which represents a specified line index range. |
|
Default Value "" |
|
Remarks (1) The value is 1-based. (2) "" represents all lines. (3) The processed of the not specified text lines will implement the default settings. (4) If the line number you specified doesn't exist, the library will ignore it. |
|
LineStringRegExPattern | Description Filter the reference objects by the content of the text line with a RegEx string. |
Type String |
|
Default Value "" |
Offset
Parameter Offset
is an object that defines how the location is offset from the reference object
or the original image.
Child Parameter Name | Child Parameter Summary |
---|---|
ReferenceObjectOriginIndex |
Description Define which point of the reference object will be set as the origin of the coordinate system. |
Type int |
|
Range [0,3] |
|
Default Value 0 |
|
ReferenceObjectSizeType |
Description Define which coordinate system to use when configuring offset parameters basd on the reference objects. |
Type String |
|
Range "default" or "wholeimage" "default": Create the offset coordinate system based on the reference object. "wholeimage": Create the offset coordinate system based on the original image. |
|
Default Value "default" |
|
MeasuredInPercentage |
Description Set whether or not to use percentage to measure the points' coordinates. |
Type int |
|
Range 0 or 1 |
|
Default Value 1 |
|
FirstPoint |
Description The top-left vertex of the ROI. |
Type int[2] |
|
Default Value null |
|
Remarks When MeasureByPercentage = 1: If your ReferenceObjectSizeType is "default", the coordinate is measured based on the size of the reference object. If your ReferenceObjectSizeType is "wholeimage", the coordinate is measured based on the size of the TargetROI of the reference object. |
|
SecondPoint |
Description The top-right vertex of the ROI. |
Type int[2] |
|
Default Value null |
|
Remarks When MeasureByPercentage = 1: If your ReferenceObjectSizeType is "default", the coordinate is measured based on the size of the reference object. If your ReferenceObjectSizeType is "wholeimage", the coordinate is measured based on the size of the TargetROI of the reference object. |
|
ThirdPoint |
Description The bottom-right vertex of the ROI. |
Type int[2] |
|
Default Value null |
|
Remarks When MeasureByPercentage = 1: If your ReferenceObjectSizeType is "default", the coordinate is measured based on the size of the reference object. If your ReferenceObjectSizeType is "wholeimage", the coordinate is measured based on the size of the TargetROI of the reference object. |
|
FourthPoint |
Description The bottom-left vertex of the ROI. |
Type int[2] |
|
Default Value null |
|
Remarks When MeasureByPercentage = 1: If your ReferenceObjectSizeType is "default", the coordinate is measured based on the size of the reference object. If your ReferenceObjectSizeType is "wholeimage", the coordinate is measured based on the size of the TargetROI of the reference object. |