# Default params per stage — overridable per-run via CLI or cron patch
stage_01_ingest:
  gap_min: 5                     # minutes gap to split segment
  ssd_root: /mnt/ssd
  output_dir: /home/cosma/cosma-pipeline

stage_02_usbl_parse:
  # USBL log/ CSVs are raw serial frames — real nav is in bag/*.mcap
  # This stage parses MCAP bag files for USBL/nav topics
  mcap_topics:
    - /usbl/position
    - /usbl/fix
    - /navigation/position
    - /bluerov/usbl
    - /waterlinked/position
  fallback_csv_serial: true      # try to decode serial bytes if no mcap topic
  output_format: parquet         # or csv

stage_03_usbl_filter:
  method: mad                    # mad | kalman_simple
  mad_sigma: 3.0
  moving_avg_window: 5

stage_04_frame_extract:
  fps: 1
  width: 518
  height: 294
  trim_hors_eau: true

stage_05_inference:
  workers:
    - host: 192.168.0.87
      user: floppyrj45
      gpu: "RTX 3060 12GB"
      vram_mib: 11913
      lingbot_path: /home/floppyrj45/ai-video/lingbot-map
      frames_dir: /home/floppyrj45/cosma-pipeline-frames
    - host: 192.168.0.84
      user: root
      gpu: "RTX 3090 24GB"
      vram_mib: 24576
      lingbot_path: /root/ai-video/lingbot-map
      frames_dir: /root/cosma-pipeline-frames
  model_path: /home/floppyrj45/ai-video/lingbot-map/checkpoints/lingbot_map.pt
  mode: streaming
  keyframe_interval: 6

stage_06_align:
  use_imu_heading: true
  use_depth: true

stage_07_stitch_per_auv:
  voxel_size: 0.05
  use_ransac: true

stage_08_stitch_cross_auv:
  voxel_size: 0.1
  final_icp: true
