diff --git a/detection/src/main/java/com/njcn/gather/detection/service/impl/DetectionServiceImpl.java b/detection/src/main/java/com/njcn/gather/detection/service/impl/DetectionServiceImpl.java index 103f243a..3ff90ad8 100644 --- a/detection/src/main/java/com/njcn/gather/detection/service/impl/DetectionServiceImpl.java +++ b/detection/src/main/java/com/njcn/gather/detection/service/impl/DetectionServiceImpl.java @@ -42,7 +42,6 @@ import lombok.AllArgsConstructor; import lombok.Data; import lombok.RequiredArgsConstructor; import org.apache.commons.collections4.CollectionUtils; -import org.springframework.beans.factory.annotation.Value; import org.springframework.stereotype.Service; import java.lang.reflect.Field; @@ -88,8 +87,8 @@ public class DetectionServiceImpl { private static final Integer INHARMONIC_FLAG = 1; private static final Integer HARMONIC_FLAG = 2; - @Value("${error.removeCount:14}") - private Integer removeErrorValueCount; +// @Value("${error.removeCount:14}") +// private Integer removeErrorValueCount; @Data @AllArgsConstructor @@ -2583,7 +2582,7 @@ public class DetectionServiceImpl { } List idxErrorValueList = DetectionUtil.sort(errorValueList, false); - int removeCount = idxErrorValueList.size() > removeErrorValueCount ? removeErrorValueCount : idxErrorValueList.size() / 5; + int removeCount = idxErrorValueList.size() > 20 ? (idxErrorValueList.size() / 20) * 7 : (idxErrorValueList.size() / 5) * 3; List newArray = DetectionUtil.getNewArray(value, idxErrorValueList.subList(removeCount, idxErrorValueList.size())); value.clear(); value.addAll(newArray);