mirror of
https://gitee.com/dromara/easyAi.git
synced 2024-11-30 10:47:49 +08:00
增加选区缩小参数
This commit is contained in:
parent
cbfc4b56ea
commit
cf9dbeca7a
@ -820,10 +820,8 @@ public class Operation {//进行计算
|
||||
|
||||
public double isCover(ThreeChannelMatrix threeChannelMatrix) throws Exception {//固定背景覆盖率计算
|
||||
ThreeChannelMatrix backGround = templeConfig.getBackGround();
|
||||
double minCover = templeConfig.getMinCover();
|
||||
double maxCover = templeConfig.getMaxCover();
|
||||
double errorBack = templeConfig.getBackGroundError();
|
||||
if (backGround != null && maxCover > minCover && errorBack >= 0 && errorBack <= 255) {
|
||||
if (backGround != null && errorBack >= 0 && errorBack <= 255) {
|
||||
Matrix matrixR = threeChannelMatrix.getMatrixR();
|
||||
Matrix matrixG = threeChannelMatrix.getMatrixG();
|
||||
Matrix matrixB = threeChannelMatrix.getMatrixB();
|
||||
|
@ -69,8 +69,6 @@ public class TempleConfig {
|
||||
private int times = 10;//聚类循环次数
|
||||
private int shrink = 60;//收缩参数
|
||||
private ThreeChannelMatrix backGround;//背景面板
|
||||
private double minCover;//覆盖下限
|
||||
private double maxCover;//覆盖上限
|
||||
private double backGroundError;//背景误差偏移量,0-255
|
||||
|
||||
public double getBackGroundError() {
|
||||
@ -81,22 +79,6 @@ public class TempleConfig {
|
||||
this.backGroundError = backGroundError;
|
||||
}
|
||||
|
||||
public double getMinCover() {
|
||||
return minCover;
|
||||
}
|
||||
|
||||
public void setMinCover(double minCover) {
|
||||
this.minCover = minCover;
|
||||
}
|
||||
|
||||
public double getMaxCover() {
|
||||
return maxCover;
|
||||
}
|
||||
|
||||
public void setMaxCover(double maxCover) {
|
||||
this.maxCover = maxCover;
|
||||
}
|
||||
|
||||
public ThreeChannelMatrix getBackGround() {
|
||||
return backGround;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user