Merge pull request 'feat/infer_dev_260107' (#246) from feat/infer_dev_260107 into develop

Reviewed-on: https://kamco.gitea.gs.dabeeo.com/dabeeo/kamco-dabeeo-backoffice/pulls/246
This commit is contained in:
2026-01-15 18:56:52 +09:00
5 changed files with 33 additions and 13 deletions

View File

@@ -176,12 +176,18 @@ public class InferenceResultService {
// 비교년도 geojson 파일 생성하여 경로 받기
String modelComparePath =
getSceneInference(
String.valueOf(req.getCompareYyyy()), mapSheetNumList, req.getMapSheetScope());
String.valueOf(req.getCompareYyyy()),
mapSheetNumList,
req.getMapSheetScope(),
req.getDetectOption());
// 기준년도 geojson 파일 생성하여 경로 받기
String modelTargetPath =
getSceneInference(
String.valueOf(req.getTargetYyyy()), mapSheetNumList, req.getMapSheetScope());
String.valueOf(req.getTargetYyyy()),
mapSheetNumList,
req.getMapSheetScope(),
req.getDetectOption());
// ai 서버에 전달할 파라미터 생성
pred_requests_areas predRequestsAreas = new pred_requests_areas();
@@ -391,8 +397,10 @@ public class InferenceResultService {
* @param mapSheetScope EXCL : 추론제외, PREV 이전 년도 도엽 사용
* @return
*/
private String getSceneInference(String yyyy, List<String> mapSheetNums, String mapSheetScope) {
return mapSheetMngCoreService.getSceneInference(yyyy, mapSheetNums, mapSheetScope);
private String getSceneInference(
String yyyy, List<String> mapSheetNums, String mapSheetScope, String detectOption) {
return mapSheetMngCoreService.getSceneInference(
yyyy, mapSheetNums, mapSheetScope, detectOption);
}
/**

View File

@@ -4,6 +4,7 @@ import com.kamco.cd.kamcoback.common.exception.CustomApiException;
import com.kamco.cd.kamcoback.common.geometry.GeoJsonFileWriter;
import com.kamco.cd.kamcoback.common.geometry.GeoJsonFileWriter.ImageFeature;
import com.kamco.cd.kamcoback.inference.dto.InferenceResultDto;
import com.kamco.cd.kamcoback.inference.dto.InferenceResultDto.DetectOption;
import com.kamco.cd.kamcoback.inference.dto.InferenceResultDto.MapSheetScope;
import com.kamco.cd.kamcoback.mapsheet.dto.MapSheetMngDto;
import com.kamco.cd.kamcoback.mapsheet.dto.MapSheetMngDto.MngListCompareDto;
@@ -219,18 +220,26 @@ public class MapSheetMngCoreService {
* @param mapSheetScope EXCL : 추론제외, PREV 이전 년도 도엽 사용
* @return
*/
public String getSceneInference(String yyyy, List<String> scenes, String mapSheetScope) {
public String getSceneInference(
String yyyy, List<String> scenes, String mapSheetScope, String detectOption) {
boolean isAll = MapSheetScope.ALL.getId().equals(mapSheetScope);
String optionSuffix = "";
if (DetectOption.EXCL.getId().equals(detectOption)) {
optionSuffix = "_EXCL";
} else if (DetectOption.PREV.getId().equals(detectOption)) {
optionSuffix = "_PREV";
}
// 1) 경로/파일명 결정
String targetDir =
"local".equals(activeEnv) ? System.getProperty("user.home") + "/geojson" : inferenceDir;
String filename =
isAll
? String.format("%s_%s_ALL.geojson", yyyy, activeEnv)
: String.format("%s_%s.geojson", yyyy, activeEnv);
? String.format("%s_%s_ALL%s.geojson", yyyy, activeEnv, optionSuffix)
: String.format("%s_%s%s.geojson", yyyy, activeEnv, optionSuffix);
Path outputPath = Paths.get(targetDir, filename);

View File

@@ -94,6 +94,7 @@ file:
#model-dir: D:/kamco-nfs/ckpt/model/
model-dir: /kamco-nfs/ckpt/model/
model-tmp-dir: ${file.model-dir}tmp/
model-file-extention: pth,json,py
inference:
url: http://10.100.0.11:8000/jobs

View File

@@ -80,6 +80,7 @@ file:
model-dir: D:/kamco-nfs/ckpt/model/
#model-dir: /kamco-nfs/ckpt/model/
model-tmp-dir: ${file.model-dir}tmp/
model-file-extention: pth,json,py
inference:
url: http://10.100.0.11:8000/jobs

View File

@@ -43,18 +43,19 @@ mapsheet:
file:
#sync-root-dir: D:/app/original-images/
sync-root-dir: /app/original-images/
#sync-root-dir: D:/kamco-nfs/images/
sync-root-dir: /kamco-nfs/images/
sync-tmp-dir: ${file.sync-root-dir}/tmp
sync-file-extention: tfw,tif
#dataset-dir: D:/app/dataset/
dataset-dir: /app/dataset/
#dataset-dir: D:/kamco-nfs/dataset/
dataset-dir: /kamco-nfs/dataset/export/
dataset-tmp-dir: ${file.dataset-dir}tmp/
#model-dir: D:/app/model/
model-dir: /app/model/
#model-dir: D:/kamco-nfs/ckpt/model/
model-dir: /kamco-nfs/ckpt/model/
model-tmp-dir: ${file.model-dir}tmp/
model-file-extention: pth,json,py
inference:
url: http://10.100.0.11:8000/jobs