{
  "analysis_logger": {
    "buffer_len": 0,
    "cap_bytes": 0,
    "dropped_count": 0,
    "dropped_record_count": 0,
    "enabled": false,
    "file_cap_bytes": 0,
    "file_path": "",
    "file_size_bytes": null,
    "flush_count": 0,
    "flush_interval_seconds": 0.0,
    "flush_state": {
      "count": 0,
      "last_at": "",
      "last_error": "",
      "last_record_count": 0,
      "status": "idle"
    },
    "flush_status": "idle",
    "last_flush_at": "",
    "last_flush_error": "",
    "last_flush_record_count": 0,
    "max_buffer_records": 0,
    "mode": "off",
    "policy_source": "base_live_policy",
    "record_counts": {
      "scenario_debug": 0,
      "scenario_event": 0,
      "session_start": 0,
      "session_stop": 0,
      "tracking_summary": 0
    },
    "started": false,
    "suppressed_count": 0,
    "suppressed_counts": {
      "scenario_debug": 0,
      "scenario_event": 0,
      "tracking_summary": 0
    },
    "suspend_reason": "",
    "suspended": false,
    "write_suspended": false,
    "written_count": 0,
    "written_record_count": 0
  },
  "buffers": {
    "frame_buffer_len": 50,
    "frame_buffer_maxlen": 50,
    "frame_queue_maxsize": 10,
    "frame_queue_size": 0
  },
  "cctv_id": "31",
  "cgroup_memory": {
    "current_mb": 4998.328,
    "limit_mb": null
  },
  "ffmpeg": {
    "error_count": 0,
    "h264_decode_error_count": 0,
    "h264_decode_error_count_per_hour": 0,
    "input_options": [],
    "last_error_at": "",
    "last_error_summary": "",
    "last_exit_at": "",
    "last_returncode": null,
    "last_stable_duration_sec": 205.848,
    "last_started_at": "2026-07-15T17:46:39+09:00",
    "pid": 2386,
    "process": {
      "exists": false,
      "pid": 2386
    },
    "restart_count": 0,
    "restart_count_per_hour": 0,
    "rtsp_timeout_count": 0,
    "rtsp_timeout_count_per_hour": 0,
    "rtsp_tolerant_mode": false,
    "running": false,
    "start_count": 1
  },
  "frame_flow": {
    "analysis": {
      "adaptive_enabled": false,
      "analysis_cap_enabled": false,
      "effective_analysis_fps": 10.0,
      "enabled": false,
      "last_decision": "initial",
      "processing_p95_ms": 100.812,
      "sample_count": 2033,
      "scenario_effective_fps_enabled": false,
      "target_fps": 10.0,
      "warmup_remaining_s": 94.062
    },
    "queue_clear_age_s": 3.0,
    "queue_max_age_s": 2.0,
    "queue_maxsize": 10,
    "reader_queue_enabled": false,
    "stats": {
      "analysis_frames": 2033,
      "analysis_skipped": 0,
      "frames_dequeued": 0,
      "frames_queued": 0,
      "last_analysis_at": "2026-07-15T17:50:04+09:00",
      "last_queue_age_ms": null,
      "last_skip_at": "",
      "max_queue_age_ms": 0.0,
      "queue_cleared": 0,
      "queue_dropped": 0
    }
  },
  "health": {
    "criticals": [
      "ffmpeg_not_running"
    ],
    "level": "critical",
    "thresholds": {
      "ffmpeg_restart_count_per_hour": {
        "critical": 6,
        "warning": 3
      },
      "h264_decode_error_count_per_hour": {
        "critical": 50,
        "warning": 10
      },
      "last_frame_pushed_age_sec": {
        "critical": 30,
        "warning": 10
      },
      "last_frame_read_age_sec": {
        "critical": 30,
        "warning": 10
      },
      "last_stable_duration_sec": {
        "critical_below": 180,
        "warning_below": 600
      },
      "mjpeg_age_sec": {
        "critical": 30,
        "warning": 10
      },
      "rtsp_timeout_count_per_hour": {
        "critical": 30,
        "warning": 10
      }
    },
    "warnings": []
  },
  "instance_id": "6ebe06bd",
  "last_frame_pushed_age_sec": 0.773,
  "last_frame_pushed_at": "2026-07-15T17:50:04+09:00",
  "last_frame_read_age_sec": 0.874,
  "last_frame_read_at": "2026-07-15T17:50:04+09:00",
  "memory_observability": {
    "active_channels": [
      "20",
      "21"
    ],
    "capped": false,
    "configured_mode": "monitoring",
    "current_rows": 10,
    "debug_expires_at": null,
    "deduplicated_count": 3,
    "effective_mode": "monitoring",
    "error_count": 0,
    "last_sample_age_sec": 0.797,
    "last_sample_duration_ms": 679.086,
    "last_trigger": "pre_stop",
    "next_snapshot_in_sec": 599.203,
    "reason": "channel_unregistered_recovery_pending",
    "rotation_count": 5,
    "runtime_state": "active",
    "sample_count": 10,
    "storage_bytes": 184251
  },
  "mjpeg": {
    "age_sec": 0.764,
    "exists": true,
    "mtime": "2026-07-15T17:50:04.741993+09:00",
    "mtime_epoch": 1784105404.7419927,
    "path": "/data/playlist/streaming/31/mjpeg.jpg",
    "size_bytes": 263259
  },
  "monitor_url": "http://sapi.ssims.ai:80/mjpeg/31",
  "observed_at": "2026-07-15T17:50:05+09:00",
  "process": {
    "exists": true,
    "fd_count": 106,
    "hwm_mb": 840.664,
    "name": "celery",
    "pid": 217,
    "rss_mb": 830.445,
    "state": "R (running)",
    "threads": 69
  },
  "reason_codes": [
    "ffmpeg_not_running"
  ],
  "recommended_action": "channel_restart_recommended",
  "recorder": {
    "active_count": 0,
    "cooldown_sec": 100,
    "last_event_key_count": 0,
    "oldest_recorder_age_sec": null,
    "recorders": [],
    "running_ffmpeg_count": 0,
    "running_pids": [],
    "stopping_count": 0
  },
  "recovery_eligible": true,
  "scenario_state_metrics": {
    "danger_area_loitering": {
      "enabled": false
    },
    "enabled": true,
    "falldown_detected": {
      "enabled": false
    },
    "marine_vessel_monitoring": {
      "enabled": false
    },
    "ppe_check": {
      "active_violation_key_count": 1,
      "enabled": true,
      "last_event_key_count": 9,
      "off_candidate_key_count": 0,
      "state_prune": {
        "cap_eviction_total": 0,
        "enabled": true,
        "error_count": 0,
        "interval_s": 5.0,
        "key_cap_per_scenario": 512,
        "last_event_pruned_total": 6,
        "last_event_ttl_s": 120.0,
        "last_prune_age_s": 2.026,
        "off_candidate_pruned_total": 20
      },
      "top_level_key_count": 4
    },
    "scene_scale": {
      "decision": "mixed",
      "decision_basis": "strong_samples",
      "decision_frame": 60,
      "decision_locked": true,
      "enabled": true,
      "last_metrics": {
        "decision_basis": "strong_samples",
        "decision_locked": true,
        "sample_cap": 40,
        "sample_count": 40,
        "worker_height_ratio_median": 0.165849,
        "worker_small_worker_ratio": 0.0
      },
      "raw_area_sample_count": 0,
      "raw_height_sample_count": 0,
      "sample_count": 40
    }
  },
  "source_url": "file:///data/playlist/uploads/260414_아이티원업로드용_시험성적서샘플영상/input/작업자_위험구역_진입경고_테스트영상들/위험구역_접근경고_테스트영상_010.mp4",
  "stage_metrics": {
    "aggregate_counts": {
      "model_result_counts": {
        "model_count": 2,
        "models": {
          "yolo11_640_coco_Large_pretrained_by_Ultralytics_11": {
            "avg": 2.048,
            "max": 5.0,
            "p95": 2.0,
            "sample_count": 293
          },
          "yolo11m_640_worker_ppe_equipment_ops260616_28class": {
            "avg": 2.874,
            "max": 9.0,
            "p95": 6.0,
            "sample_count": 293
          }
        },
        "truncated_count": 0
      },
      "object_counts": {
        "by_category.안전그네 미착용": {
          "avg": 1.0,
          "max": 1.0,
          "p95": 1.0,
          "sample_count": 52
        },
        "by_category.안전그네 착용": {
          "avg": 1.0,
          "max": 1.0,
          "p95": 1.0,
          "sample_count": 2
        },
        "by_category.안전모 미착용": {
          "avg": 1.0,
          "max": 1.0,
          "p95": 1.0,
          "sample_count": 14
        },
        "by_category.안전모 착용": {
          "avg": 1.0,
          "max": 1.0,
          "p95": 1.0,
          "sample_count": 28
        },
        "by_category.작업자": {
          "avg": 1.0,
          "max": 1.0,
          "p95": 1.0,
          "sample_count": 293
        },
        "total": {
          "avg": 1.328,
          "max": 3.0,
          "p95": 3.0,
          "sample_count": 293
        }
      },
      "tracking_counts": {
        "active": {
          "avg": 1.143,
          "max": 2.0,
          "p95": 2.0,
          "sample_count": 293
        },
        "lost": {
          "avg": 0.0,
          "max": 0.0,
          "p95": 0.0,
          "sample_count": 293
        },
        "removed": {
          "avg": 0.041,
          "max": 1.0,
          "p95": 0.0,
          "sample_count": 293
        },
        "tracked": {
          "avg": 1.143,
          "max": 2.0,
          "p95": 2.0,
          "sample_count": 293
        },
        "unconfirmed": {
          "avg": 0.0,
          "max": 0.0,
          "p95": 0.0,
          "sample_count": 293
        }
      }
    },
    "counts": {
      "inference_timeouts": 0,
      "invalid_reads": 0,
      "processed_frames": 293,
      "pushed_frames": 293,
      "read_frames": 292,
      "select_timeouts": 0,
      "triton_result_errors": 0
    },
    "enabled": true,
    "fps": {
      "processed": 9.771,
      "pushed": 9.771,
      "read": 9.738
    },
    "hints": [
      "frame_processing_p95_over_budget",
      "triton_wait_p95_dominant"
    ],
    "inference_client": {
      "effective_mode": "monitoring",
      "enabled": true,
      "inflight": {
        "current": 0,
        "max": 2,
        "source": "client_direct"
      },
      "model_key_cap": 30,
      "models": {
        "yolo11_640_coco_Large_pretrained_by_Ultralytics_11": {
          "attempt_count": 292,
          "client_acquire_ms": {
            "avg_ms": 0.008,
            "count": 292,
            "max_ms": 0.029,
            "p95_ms": 0.014,
            "reason": null,
            "sample_age_ms": 813.584,
            "source": "client_direct"
          },
          "error_count": 0,
          "executor_queue_ms": {
            "avg_ms": 5.438,
            "count": 292,
            "max_ms": 11.238,
            "p95_ms": 8.11,
            "reason": null,
            "sample_age_ms": 878.192,
            "source": "client_direct"
          },
          "instrumentation_overhead_ms": {
            "avg_ms": 0.024,
            "count": 292,
            "max_ms": 0.161,
            "p95_ms": 0.044,
            "reason": null,
            "sample_age_ms": 885.98,
            "source": "client_direct"
          },
          "parse_ms": {
            "avg_ms": 0.21,
            "count": 292,
            "max_ms": 0.588,
            "p95_ms": 0.421,
            "reason": null,
            "sample_age_ms": 813.603,
            "source": "client_direct"
          },
          "prepare_ms": {
            "avg_ms": 2.205,
            "count": 292,
            "max_ms": 8.686,
            "p95_ms": 3.661,
            "reason": null,
            "sample_age_ms": 876.251,
            "source": "client_direct"
          },
          "request_count": 292,
          "request_tensor_bytes": {
            "avg": 2764808.0,
            "count": 292,
            "max": 2764808.0,
            "p95": 2764808.0,
            "reason": null,
            "sample_age_ms": 876.222,
            "source": "client_direct"
          },
          "response_tensor_bytes": {
            "avg": 8.0,
            "count": 292,
            "max": 8.0,
            "p95": 8.0,
            "reason": null,
            "sample_age_ms": 814.153,
            "source": "client_direct"
          },
          "retry_count": 0,
          "roundtrip_total_ms": {
            "avg_ms": 47.888,
            "count": 292,
            "max_ms": 86.688,
            "p95_ms": 73.303,
            "reason": null,
            "sample_age_ms": 813.576,
            "source": "client_direct"
          },
          "sample_age_ms": 813.568,
          "source": "client_direct",
          "task_total_ms": {
            "avg_ms": 50.497,
            "count": 292,
            "max_ms": 90.596,
            "p95_ms": 75.843,
            "reason": null,
            "sample_age_ms": 813.568,
            "source": "client_direct"
          },
          "timeout_count": 0
        },
        "yolo11m_640_worker_ppe_equipment_ops260616_28class": {
          "attempt_count": 292,
          "client_acquire_ms": {
            "avg_ms": 0.007,
            "count": 292,
            "max_ms": 0.043,
            "p95_ms": 0.014,
            "reason": null,
            "sample_age_ms": 825.267,
            "source": "client_direct"
          },
          "error_count": 0,
          "executor_queue_ms": {
            "avg_ms": 0.566,
            "count": 292,
            "max_ms": 3.301,
            "p95_ms": 1.677,
            "reason": null,
            "sample_age_ms": 885.78,
            "source": "client_direct"
          },
          "instrumentation_overhead_ms": {
            "avg_ms": 0.214,
            "count": 292,
            "max_ms": 2.782,
            "p95_ms": 1.158,
            "reason": null,
            "sample_age_ms": 886.1,
            "source": "client_direct"
          },
          "parse_ms": {
            "avg_ms": 0.254,
            "count": 292,
            "max_ms": 3.232,
            "p95_ms": 0.516,
            "reason": null,
            "sample_age_ms": 825.274,
            "source": "client_direct"
          },
          "prepare_ms": {
            "avg_ms": 1.773,
            "count": 292,
            "max_ms": 4.075,
            "p95_ms": 3.047,
            "reason": null,
            "sample_age_ms": 883.499,
            "source": "client_direct"
          },
          "request_count": 292,
          "request_tensor_bytes": {
            "avg": 2764808.0,
            "count": 292,
            "max": 2764808.0,
            "p95": 2764808.0,
            "reason": null,
            "sample_age_ms": 883.471,
            "source": "client_direct"
          },
          "response_tensor_bytes": {
            "avg": 8.0,
            "count": 292,
            "max": 8.0,
            "p95": 8.0,
            "reason": null,
            "sample_age_ms": 825.519,
            "source": "client_direct"
          },
          "retry_count": 0,
          "roundtrip_total_ms": {
            "avg_ms": 50.914,
            "count": 292,
            "max_ms": 85.369,
            "p95_ms": 71.016,
            "reason": null,
            "sample_age_ms": 825.264,
            "source": "client_direct"
          },
          "sample_age_ms": 825.26,
          "source": "client_direct",
          "task_total_ms": {
            "avg_ms": 53.106,
            "count": 292,
            "max_ms": 88.984,
            "p95_ms": 73.96,
            "reason": null,
            "sample_age_ms": 825.26,
            "source": "client_direct"
          },
          "timeout_count": 0
        }
      },
      "process_executor": {
        "inflight_current": 0,
        "inflight_max": 2,
        "max_workers": 40,
        "pid": 217,
        "protocols": {
          "grpc": {
            "max_workers": 40,
            "queued_current": 0,
            "source": "thread_pool_executor_private_scalar"
          }
        },
        "queued_current": 0,
        "source": "client_direct_and_executor_scalar"
      },
      "protocol": "grpc",
      "reason": "active",
      "sample_cap": 512,
      "schema_version": "ssims.live_inference_client_summary.v1",
      "snapshot_overhead_ms": 6.176,
      "truncated_model_count": 0,
      "window_s": 30.0
    },
    "latency_ms": {
      "analyze": {
        "avg_ms": 5.741,
        "count": 293,
        "max_ms": 12.372,
        "p95_ms": 9.149
      },
      "analyze_detail": {
        "data_bus_build_ms": {
          "avg_ms": 2.273,
          "count": 293,
          "max_ms": 7.454,
          "p95_ms": 3.442
        },
        "detection_prepare_ms": {
          "avg_ms": 1.489,
          "count": 293,
          "max_ms": 6.051,
          "p95_ms": 2.764
        },
        "event_filter_ms": {
          "avg_ms": 0.004,
          "count": 293,
          "max_ms": 0.019,
          "p95_ms": 0.01
        },
        "id_reconcile_ms": {
          "avg_ms": 0.143,
          "count": 293,
          "max_ms": 1.393,
          "p95_ms": 0.309
        },
        "mcmt_ms": {
          "avg_ms": 0.004,
          "count": 293,
          "max_ms": 0.032,
          "p95_ms": 0.008
        },
        "scenario_analyze_ms": {
          "avg_ms": 0.266,
          "count": 293,
          "max_ms": 3.214,
          "p95_ms": 0.501
        },
        "setup_ms": {
          "avg_ms": 0.053,
          "count": 293,
          "max_ms": 0.354,
          "p95_ms": 0.105
        },
        "total_inside_ms": {
          "avg_ms": 5.67,
          "count": 293,
          "max_ms": 12.152,
          "p95_ms": 9.055
        },
        "track_match_ms": {
          "avg_ms": 0.113,
          "count": 293,
          "max_ms": 0.349,
          "p95_ms": 0.206
        },
        "tracker_update_ms": {
          "avg_ms": 1.323,
          "count": 293,
          "max_ms": 5.503,
          "p95_ms": 2.161
        }
      },
      "gstreamer_push": {
        "avg_ms": 3.383,
        "count": 293,
        "max_ms": 12.324,
        "p95_ms": 5.935
      },
      "io_detail": {
        "channel_analysis_record_ms": {
          "avg_ms": 0.008,
          "count": 293,
          "max_ms": 0.046,
          "p95_ms": 0.017
        }
      },
      "model_completion": {
        "model_count": 2,
        "models": {
          "yolo11_640_coco_Large_pretrained_by_Ultralytics_11": {
            "avg_ms": 56.692,
            "count": 293,
            "max_ms": 98.984,
            "p95_ms": 83.906
          },
          "yolo11m_640_worker_ppe_equipment_ops260616_28class": {
            "avg_ms": 54.068,
            "count": 293,
            "max_ms": 89.759,
            "p95_ms": 74.806
          }
        },
        "truncated_count": 0
      },
      "processing_total": {
        "avg_ms": 75.254,
        "count": 293,
        "max_ms": 119.46,
        "p95_ms": 100.592
      },
      "read_interval": {
        "avg_ms": 100.01,
        "count": 292,
        "max_ms": 453.902,
        "p95_ms": 132.2
      },
      "scenario_detail": {
        "dispatch_overhead_ms": {
          "avg_ms": 0.017,
          "count": 293,
          "max_ms": 0.061,
          "p95_ms": 0.032
        },
        "execute_total_ms": {
          "avg_ms": 0.194,
          "count": 293,
          "max_ms": 0.831,
          "p95_ms": 0.406
        },
        "resolve_scenarios_ms": {
          "avg_ms": 0.02,
          "count": 293,
          "max_ms": 0.113,
          "p95_ms": 0.039
        },
        "scenario.no_hardhat_persistent_ms": {
          "avg_ms": 0.056,
          "count": 293,
          "max_ms": 0.316,
          "p95_ms": 0.141
        },
        "scenario.ppe_status_check_ms": {
          "avg_ms": 0.121,
          "count": 293,
          "max_ms": 0.654,
          "p95_ms": 0.24
        },
        "worker_merge_ms": {
          "avg_ms": 0.008,
          "count": 293,
          "max_ms": 0.041,
          "p95_ms": 0.015
        }
      },
      "triton_wait": {
        "avg_ms": 57.853,
        "count": 293,
        "max_ms": 98.991,
        "p95_ms": 84.755
      },
      "visualize": {
        "avg_ms": 9.675,
        "count": 293,
        "max_ms": 35.994,
        "p95_ms": 23.233
      },
      "visualize_detail": {
        "visualize_draw_all_ms": {
          "avg_ms": 8.041,
          "count": 293,
          "max_ms": 33.564,
          "p95_ms": 20.784
        },
        "visualize_input_copy_ms": {
          "avg_ms": 1.617,
          "count": 293,
          "max_ms": 4.574,
          "p95_ms": 2.828
        },
        "visualize_roi_overlay_ms": {
          "avg_ms": 0.0,
          "count": 293,
          "max_ms": 0.0,
          "p95_ms": 0.0
        },
        "visualizer_overlay_draw_ms": {
          "avg_ms": 7.889,
          "count": 293,
          "max_ms": 33.369,
          "p95_ms": 20.558
        },
        "visualizer_prepare_ms": {
          "avg_ms": 0.089,
          "count": 293,
          "max_ms": 1.005,
          "p95_ms": 0.171
        }
      }
    },
    "scenario_detail_counts": {
      "error_count": {
        "avg": 0.0,
        "max": 0.0,
        "p95": 0.0,
        "sample_count": 293
      },
      "resolved_scenario_count": {
        "avg": 2.0,
        "max": 2.0,
        "p95": 2.0,
        "sample_count": 293
      },
      "returned_event_count": {
        "avg": 0.007,
        "max": 1.0,
        "p95": 0.0,
        "sample_count": 293
      }
    },
    "target_fps": 10.0,
    "target_frame_budget_ms": 100.0,
    "window_elapsed_s": 29.986,
    "window_s": 30.0
  },
  "started_at": "2026-07-15T17:46:39+09:00",
  "state": "stopped",
  "task_id": "9228d141-ca00-4e19-80a9-598424ace428",
  "trigger": "start",
  "triton_protocol": "grpc"
}