Package com.nefrock.edgeocr
Class CropDetectionFilter
java.lang.Object
com.nefrock.edgeocr.CropDetectionFilter
範囲を指定して検出のフィルターリングを設定するためのデータクラス
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionCropDetectionFilter(boolean combineHorizontal, float combineHorizontalThreshold, List<CropDetectionFilter.CropSpec> textCropSpecs, List<CropDetectionFilter.CropSpec> barcodeCropSpecs) フィルターを初期化するCropDetectionFilter(List<android.graphics.RectF> textCrops, List<android.graphics.RectF> barcodeCrops, boolean combineHorizontal, float combineHorizontalThreshold) フィルターを初期化する -
Method Summary
Modifier and TypeMethodDescriptionList<android.graphics.RectF>booleanfloatList<android.graphics.RectF>voidsetBarcodeCrops(List<android.graphics.RectF> barcodeCrops) バーコードの検出範囲を設定するvoidsetBarcodeCropSpecs(List<CropDetectionFilter.CropSpec> barcodeCropSpecs) バーコードの検出範囲とその属性を設定するvoidsetCombineHorizontal(boolean combineHorizontal) それぞれの範囲内で、水平方向に近い検出を結合するかどうかを設定するvoidsetCombineHorizontalThreshold(float combineHorizontalThreshold) 結合する際の距離の閾値(縦方向のIoU)を設定するvoidsetTextCrops(List<android.graphics.RectF> textCrops) テキストの検出範囲を設定するvoidsetTextCropSpecs(List<CropDetectionFilter.CropSpec> textCropSpecs) テキストの検出範囲とその属性を設定する
-
Constructor Details
-
CropDetectionFilter
public CropDetectionFilter(boolean combineHorizontal, float combineHorizontalThreshold, List<CropDetectionFilter.CropSpec> textCropSpecs, List<CropDetectionFilter.CropSpec> barcodeCropSpecs) フィルターを初期化する- Parameters:
combineHorizontal- それぞれの範囲内で、水平方向に近い検出を結合するかどうかcombineHorizontalThreshold- 結合する際の距離の閾値(縦方向のIoU)textCropSpecs- テキストの検出範囲とその属性barcodeCropSpecs- バーコードの検出範囲とその属性
-
CropDetectionFilter
public CropDetectionFilter(List<android.graphics.RectF> textCrops, List<android.graphics.RectF> barcodeCrops, boolean combineHorizontal, float combineHorizontalThreshold) フィルターを初期化する- Parameters:
textCrops- テキストの検出範囲barcodeCrops- バーコードの検出範囲combineHorizontal- それぞれの範囲内で、水平方向に近い検出を結合するかどうかcombineHorizontalThreshold- 結合する際の距離の閾値(縦方向のIoU)
-
-
Method Details
-
getTextCropSpecs
- Returns:
- テキストの検出範囲とその属性
-
setTextCropSpecs
テキストの検出範囲とその属性を設定する- Parameters:
textCropSpecs- テキストの検出範囲とその属性
-
getTextCrops
- Returns:
- テキストの検出範囲
-
setTextCrops
テキストの検出範囲を設定する- Parameters:
textCrops- テキストの検出範囲
-
getBarcodeCropSpecs
- Returns:
- バーコードの検出範囲とその属性
-
setBarcodeCropSpecs
バーコードの検出範囲とその属性を設定する- Parameters:
barcodeCropSpecs- バーコードの検出範囲とその属性
-
getBarcodeCrops
- Returns:
- バーコードの検出範囲
-
setBarcodeCrops
バーコードの検出範囲を設定する- Parameters:
barcodeCrops- バーコードの検出範囲
-
getCombineHorizontal
public boolean getCombineHorizontal()- Returns:
- それぞれの範囲内で、水平方向に近い検出を結合するかどうか
-
setCombineHorizontal
public void setCombineHorizontal(boolean combineHorizontal) それぞれの範囲内で、水平方向に近い検出を結合するかどうかを設定する- Parameters:
combineHorizontal- それぞれの範囲内で、水平方向に近い検出を結合するかどうか
-
getCombineHorizontalThreshold
public float getCombineHorizontalThreshold()- Returns:
- 結合する際の距離の閾値(縦方向のIoU)
-
setCombineHorizontalThreshold
public void setCombineHorizontalThreshold(float combineHorizontalThreshold) 結合する際の距離の閾値(縦方向のIoU)を設定する- Parameters:
combineHorizontalThreshold- 結合する際の距離の閾値(縦方向のIoU)
-