콘텐츠로 이동

Anomaly Decision Rule


SaigeVAD는 아래의 decision rule을 이용하여 결함을 판단합니다.

ResultContainer

  • ResultContainer 값 중에서 Anomaly 판단에 필요한 필드는 아래 표와 같습니다.

    필드 명 Type 비고
    final_score List[int] VAD의 이상감지 점수입니다.
    final_threshold List[int] final_threshold는 VAD 프로그램에서 설정하는 “결함 임계값(critical_threshold)” 입니다.
    state_index List[int] VAD의 작동 상태입니다.
    cluster_index List[int] Anomaly clustering 결과입니다.
  • state_index 구조

    Index State 설명
    1 no_motion 공정이 정지한 상태입니다.
    2 inspect 기본 상태이며, VAD 모델을 통해 score를 계산합니다.
    3 domain_shift_detection domain shift (장면 변경)이 발생한 상태입니다.
    4 roi_calibration roi calibration이 발생한 상태입니다.
    5 no_roi_match roi template과 비교하였을 때, 허용 범위 내에 해당 template과 동일한 장면이 없는 상태입니다.
    6 error 오류가 발생한 상태입니다.
    7 slow_motion 공정이 정지한 것은 아니나, 느리게 움직이는 상태입니다.

Decision Rule

  • 아래 조건을 모두 만족하면 is_anomaly = True 입니다.
    • state_index == 2 (inspect)
    • final_score > final_threshold인 인접한 프레임이 N개 이상인 경우
      • N = 이상 감지 최소 프레임 수(min_num_anomaly_frames)
    • (Clustering 적용된 모델일 경우)
      • cluster_index == -1 or cluster_index == {유저가 설정한 결함 cluster의 index}
  • 그 외의 조건에서는 is_anomaly = False 입니다.
    • final_score > final_threshold를 만족하지만, state_index == 2가 아닌 경우 or (Clustering 적용된 모델일 경우) cluster_index == {유저가 설정한 정상 cluster의 index}
    • final_score < final_threshold인 경우