라벨링 툴 pnu 정보 list string으로 수정

This commit is contained in:
2026-01-29 16:23:13 +09:00
parent 480b016f33
commit 23a096a600
5 changed files with 22 additions and 35 deletions

View File

@@ -6,6 +6,7 @@ import static com.kamco.cd.kamcoback.postgres.entity.QMapInkx5kEntity.mapInkx5kE
import static com.kamco.cd.kamcoback.postgres.entity.QMapSheetAnalDataInferenceGeomEntity.mapSheetAnalDataInferenceGeomEntity;
import static com.kamco.cd.kamcoback.postgres.entity.QMapSheetAnalInferenceEntity.mapSheetAnalInferenceEntity;
import static com.kamco.cd.kamcoback.postgres.entity.QMapSheetLearnDataGeomEntity.mapSheetLearnDataGeomEntity;
import static com.kamco.cd.kamcoback.postgres.entity.QPnuEntity.pnuEntity;
import com.fasterxml.jackson.databind.JsonNode;
import com.fasterxml.jackson.databind.ObjectMapper;
@@ -466,6 +467,14 @@ public class TrainingDataLabelRepositoryImpl extends QuerydslRepositorySupport
}
// 5. DTO 생성
// pnu list 조회
List<String> pnuList =
queryFactory
.select(pnuEntity.pnu)
.from(pnuEntity)
.where(pnuEntity.geo.geoUid.eq(mapSheetAnalDataInferenceGeomEntityEntity.getGeoUid()))
.fetch();
var changeDetectionInfo =
ChangeDetectionInfo.builder()
.mapSheetInfo(mapSheetEntity != null ? mapSheetEntity.getMapidNm() : "")
@@ -507,10 +516,7 @@ public class TrainingDataLabelRepositoryImpl extends QuerydslRepositorySupport
mapSheetAnalDataInferenceGeomEntityEntity.getCdProb() != null
? mapSheetAnalDataInferenceGeomEntityEntity.getCdProb()
: 0.0)
.pnu(
mapSheetAnalDataInferenceGeomEntityEntity.getPnu() != null
? mapSheetAnalDataInferenceGeomEntityEntity.getPnu()
: 0L)
.pnu(pnuList)
.mapSheetNum(
mapSheetAnalDataInferenceGeomEntityEntity.getMapSheetNum() != null
? mapSheetAnalDataInferenceGeomEntityEntity.getMapSheetNum()

View File

@@ -7,6 +7,7 @@ import static com.kamco.cd.kamcoback.postgres.entity.QMapSheetAnalDataInferenceG
import static com.kamco.cd.kamcoback.postgres.entity.QMapSheetAnalInferenceEntity.mapSheetAnalInferenceEntity;
import static com.kamco.cd.kamcoback.postgres.entity.QMapSheetLearnDataGeomEntity.mapSheetLearnDataGeomEntity;
import static com.kamco.cd.kamcoback.postgres.entity.QMemberEntity.memberEntity;
import static com.kamco.cd.kamcoback.postgres.entity.QPnuEntity.pnuEntity;
import com.fasterxml.jackson.databind.JsonNode;
import com.fasterxml.jackson.databind.ObjectMapper;
@@ -494,6 +495,14 @@ public class TrainingDataReviewRepositoryImpl extends QuerydslRepositorySupport
}
// 5. DTO 생성
// pnu list 조회
List<String> pnuList =
queryFactory
.select(pnuEntity.pnu)
.from(pnuEntity)
.where(pnuEntity.geo.geoUid.eq(mapSheetAnalDataInferenceGeomEntityEntity.getGeoUid()))
.fetch();
var changeDetectionInfo =
ChangeDetectionInfo.builder()
.mapSheetInfo(mapSheetEntity != null ? mapSheetEntity.getMapidNm() : "")
@@ -535,10 +544,7 @@ public class TrainingDataReviewRepositoryImpl extends QuerydslRepositorySupport
mapSheetAnalDataInferenceGeomEntityEntity.getCdProb() != null
? mapSheetAnalDataInferenceGeomEntityEntity.getCdProb()
: 0.0)
.pnu(
mapSheetAnalDataInferenceGeomEntityEntity.getPnu() != null
? mapSheetAnalDataInferenceGeomEntityEntity.getPnu()
: 0L)
.pnu(pnuList)
.mapSheetNum(
mapSheetAnalDataInferenceGeomEntityEntity.getMapSheetNum() != null
? mapSheetAnalDataInferenceGeomEntityEntity.getMapSheetNum()

View File

@@ -125,31 +125,6 @@ public class TrainingDataReviewJobService {
return result;
}
// 라벨러 완료,SKIP 시 호출 -> 미사용
@Transactional
public void assignRealtime(String assignmentUid) {
Tasks task = trainingDataReviewJobCoreService.findAssignmentTask(assignmentUid);
Long analUid = task.getAnalUid();
// pending 계산
List<InspectorPendingDto> pendings =
trainingDataReviewJobCoreService.findInspectorPendingByRound(analUid);
if (pendings.isEmpty()) {
return;
}
List<String> order = pendings.stream().map(InspectorPendingDto::getInspectorUid).toList();
trainingDataReviewJobCoreService.lockInspectors(analUid, order);
trainingDataReviewJobCoreService.assignReviewer(task.getAssignmentUid(), order.getFirst());
List<Long> geomUids = new ArrayList<>();
geomUids.add(task.getInferenceUid());
trainingDataReviewJobCoreService.updateGeomUidTestState(geomUids);
}
@Transactional
@Scheduled(cron = "0 0 2 * * *")
public void exportGeojsonLabelingGeom() {

View File

@@ -358,7 +358,7 @@ public class TrainingDataLabelDto {
private Double detectionAccuracy;
@Schema(description = "PNU (필지고유번호)", example = "36221202306020")
private Long pnu;
private List<String> pnu;
@Schema(description = "도엽번호 (map_sheet_num)", example = "34602057")
private Long mapSheetNum;

View File

@@ -351,7 +351,7 @@ public class TrainingDataReviewDto {
private Double detectionAccuracy;
@Schema(description = "PNU (필지고유번호)", example = "36221202306020")
private Long pnu;
private List<String> pnu;
@Schema(description = "도엽번호 (map_sheet_num)", example = "34602057")
private Long mapSheetNum;