Common Scenarios¶
Domain-specific parameter examples and calibration strategies.
Scenario Index¶
- Deep-Sea Benthic Survey (>200m)
- Mid-Water Plankton/Particle Imaging
- Shallow Reef Survey (<50m)
- Fast Transect (High Vehicle Speed)
- Static Benthic Lander
- Low-Quality Optics (Blurry/Turbid)
- High-Quality Dataset (Archival)
- Quick Preview (Speed-Priority)
Deep-Sea Benthic Survey (>200m)¶
Environment Characteristics¶
- Low ambient light (dark, artificial lighting only)
- Static scenes (slow-moving or stationary organisms)
- High-detail features (organisms, geology, debris)
- Slow vehicle speed (0.2–0.8 m/s)
- Stable camera (minimal motion blur)
Typical Metric Distributions¶
brightness: min=8 p5=15 median=40 p95=120 max=180
sharpness: min=10 p5=20 median=35 p95=90 max=150
entropy: min=2.0 p5=2.8 median=3.8 p95=5.2 max=6.0
motion: min=0.5 p5=2.0 median=6.0 p95=18 max=45
Recommended Parameters¶
./sample \
--root-dir /data/benthic_survey \
--camera 1 \
--min-brightness 15 \
--max-brightness 140 \
--min-sharpness 20 \
--min-entropy 2.8 \
--max-frames 5000 \
--min-gap 2.0 \
--sample-fps 1.0 \
--n-bins 8 \
--jobs 4
Rationale¶
- Low brightness threshold (15): Accept dark frames (deep environment)
- Moderate sharpness (20): Stable platform → expect reasonable sharpness
- Moderate entropy (2.8): Organisms and geology provide texture
- Larger min-gap (2.0s): Slow speed → larger gap to avoid redundancy
- Typical grid (8 bins): Balanced diversity
Calibration Workflow¶
-
Run
calibrateon representative clip: -
Check if median brightness < 50:
- Yes → Use low threshold (15–20)
-
No → Increase threshold
-
Check sharpness distribution:
- If p25 > 20 → Use strict threshold (25–30)
-
If p25 < 20 → Use moderate threshold (18–22)
-
Check entropy:
- Benthic surveys typically have high entropy (3.0–4.5)
- Threshold at p10–p20 (e.g., 2.8–3.2)
Mid-Water Plankton/Particle Imaging¶
Environment Characteristics¶
- Moderate lighting (mix of ambient and artificial)
- Sparse features (open water with occasional plankton/particles)
- Low texture backgrounds (blue water dominates)
- Moderate vehicle speed (0.5–1.5 m/s)
- Some motion blur (particles moving, camera motion)
Typical Metric Distributions¶
brightness: min=30 p5=50 median=90 p95=180 max=220
sharpness: min=5 p5=12 median=28 p95=80 max=200
entropy: min=1.5 p5=2.0 median=2.8 p95=4.5 max=5.5
motion: min=1.0 p5=5.0 median=15 p95=35 max=70
Recommended Parameters¶
./sample \
--root-dir /data/midwater_survey \
--camera 1 \
--min-brightness 30 \
--max-brightness 200 \
--min-sharpness 15 \
--min-entropy 2.0 \
--max-frames 8000 \
--min-gap 1.0 \
--sample-fps 1.5 \
--n-bins 8 \
--jobs 4
Rationale¶
- Moderate brightness range (30–200): Accept varied lighting
- Relaxed sharpness (15): Motion blur is common, particles are small
- Low entropy threshold (2.0): Blue water is common, don't over-reject
- Larger budget (8000): Sparse features → need more frames to capture diversity
- Smaller min-gap (1.0s): Moderate speed, plankton are sparse
- Higher sample-fps (1.5): Catch brief plankton encounters
Calibration Workflow¶
-
Run
calibrateon clips with both plankton and empty water: -
Accept low entropy:
- Mid-water has inherently low texture (median entropy ~2.5–3.5)
-
Threshold at p5 or p10 (e.g., 2.0–2.2)
-
Relax sharpness if particles are small:
- Small features have low Laplacian variance
-
Threshold at p10 (e.g., 12–18)
-
Check pass rate:
- Target 50–70% (lower than benthic due to empty water rejection)
Shallow Reef Survey (<50m)¶
Environment Characteristics¶
- High ambient light (sunlight penetration)
- Rich texture (coral, algae, fish, substrate)
- Rapid scene changes (fast vehicle speed over complex terrain)
- Variable lighting (sun angle, shadows, reflections)
- Generally sharp (good visibility, fast shutter speeds)
Typical Metric Distributions¶
brightness: min=60 p5=90 median=140 p95=210 max=240
sharpness: min=20 p5=45 median=85 p95=180 max=300
entropy: min=3.0 p5=3.8 median=4.5 p95=5.8 max=6.5
motion: min=5 p5=15 median=25 p95=55 max=90
Recommended Parameters¶
./sample \
--root-dir /data/reef_survey \
--camera 1 \
--min-brightness 50 \
--max-brightness 220 \
--min-sharpness 30 \
--min-entropy 3.0 \
--max-frames 5000 \
--min-gap 1.5 \
--sample-fps 2.0 \
--n-bins 9 \
--jobs 4
Rationale¶
- Higher brightness threshold (50): Reject dark/shadowed frames
- Reject overexposure (220): Sunlight can cause blown highlights
- Stricter sharpness (30): Expect sharp images in clear water
- Moderate entropy (3.0): Abundant texture (reject uniform water columns)
- Higher sample-fps (2.0): Rapid scene changes → denser sampling
- Finer grid (9 bins): High diversity → more granular binning
Calibration Workflow¶
-
Run
calibrateon representative reef clip: -
Check for overexposure:
-
If p95 > 230 → Lower max-brightness (200–220)
-
Demand sharpness:
- Shallow water → expect good visibility
-
Threshold at p20–p30 (e.g., 30–50)
-
High entropy expected:
- Reef complexity → median entropy 4.0–5.0
-
Threshold at p10 (e.g., 3.0–3.5)
-
Check pass rate:
- Target 50–70% (high quality bias)
Fast Transect (High Vehicle Speed)¶
Environment Characteristics¶
- Rapid movement (>1.5 m/s)
- Motion blur common (unless very short shutter speed)
- Rapid scene changes (diverse conditions within short time)
- Variable lighting (rapid transitions between environments)
Typical Metric Distributions¶
brightness: variable (depends on environments traversed)
sharpness: min=3 p5=8 median=22 p95=65 max=150
entropy: variable
motion: min=10 p5=20 median=35 p95=60 max=100
Recommended Parameters¶
./sample \
--root-dir /data/fast_transect \
--camera 1 \
--min-brightness 20 \
--max-brightness 230 \
--min-sharpness 12 \
--min-entropy 2.5 \
--max-frames 10000 \
--min-gap 0.5 \
--sample-fps 2.0 \
--n-bins 10 \
--jobs 8
Rationale¶
- Relaxed sharpness (12): Motion blur is pervasive at high speed
- Small min-gap (0.5s): Fast movement → scene changes rapidly (0.75–1.5m between frames)
- Higher sample-fps (2.0): Catch brief features
- Larger budget (10000): High diversity → need more frames
- Finer grid (10 bins): High environmental variability
Calibration Workflow¶
- Accept blur:
- Motion blur is unavoidable at high speed
-
Threshold at p5 (e.g., 8–12)
-
Check motion distribution:
- If median motion > 30 → vehicle is very fast
-
Consider even smaller min-gap (0.3–0.5s)
-
Use multiple calibration clips (different segments of transect):
Static Benthic Lander¶
Environment Characteristics¶
- Stationary platform (no vehicle motion)
- Slow-changing scene (organisms enter/exit slowly)
- Low motion (only subject movement)
- Stable lighting (constant artificial light)
- Long deployment (hours to days)
Typical Metric Distributions¶
brightness: min=20 p5=30 median=55 p95=80 max=100
sharpness: min=15 p5=30 median=55 p95=110 max=180
entropy: min=2.5 p5=3.0 median=4.0 p95=5.5 max=6.2
motion: min=0.1 p5=0.5 median=2.0 p95=10 max=40
Recommended Parameters¶
./sample \
--root-dir /data/lander_deployment \
--camera 1 \
--min-brightness 25 \
--max-brightness 90 \
--min-sharpness 25 \
--min-entropy 3.0 \
--max-frames 3000 \
--min-gap 5.0 \
--sample-fps 0.5 \
--n-bins 7 \
--jobs 4
Rationale¶
- Large min-gap (5.0s): Static scene → large gap to avoid redundancy
- Low sample-fps (0.5): Sparse sampling sufficient (scene changes slowly)
- Stricter quality (sharpness 25, entropy 3.0): No excuse for poor quality (stable platform)
- Smaller budget (3000): Limited diversity in static scene
Calibration Workflow¶
-
Run
calibrateon representative hour: -
Expect low motion:
- Median motion < 5 is typical
-
Motion metric is less useful (consider removing from interest score)
-
Demand quality:
- Stable platform → no motion blur
-
Threshold sharpness at p25–p30 (e.g., 25–35)
-
Large temporal gaps:
- Start with 5–10 seconds
- Increase if output frames look very similar
Low-Quality Optics (Blurry/Turbid)¶
Environment Characteristics¶
- Poor optics (old camera, dirty lens, low-cost system)
- High turbidity (suspended sediment, particles)
- Pervasive blur (chronic defocus or motion blur)
- Low sharpness across all frames
Typical Metric Distributions¶
brightness: variable
sharpness: min=2 p5=5 median=12 p95=30 max=80
entropy: variable
motion: variable
Recommended Parameters¶
./sample \
--root-dir /data/turbid_survey \
--camera 1 \
--min-brightness 20 \
--max-brightness 230 \
--min-sharpness 6 \
--min-entropy 2.0 \
--max-frames 5000 \
--min-gap 1.0 \
--sample-fps 1.0 \
--n-bins 8 \
--jobs 4
Rationale¶
- Very relaxed sharpness (6): Accept best available (even if blurry)
- Other thresholds moderate: Don't compound issues by being too strict overall
Calibration Workflow¶
-
Run
calibrateand check sharpness distribution: -
If median sharpness < 20:
- Lower threshold to p5 or p10 (e.g., 5–10)
-
Accept that output will be blurry (best of bad data)
-
Consider upstream fixes:
- Clean lens/dome
- Adjust focus
- Reduce vehicle speed (reduce motion blur)
-
Wait for lower turbidity conditions
-
Visual validation:
- Extract sample frames manually
- Confirm they are acceptable for intended use (even if blurry)
High-Quality Dataset (Archival)¶
Goal¶
Create a pristine dataset for long-term archival or publication:
- Maximum quality
- Lossless images
- Small, curated set
- Strict quality gates
Recommended Parameters¶
./sample \
--root-dir /data/archival_survey \
--camera 1 \
--min-brightness 40 \
--max-brightness 200 \
--min-sharpness 50 \
--min-entropy 3.5 \
--max-frames 1000 \
--min-gap 3.0 \
--sample-fps 1.0 \
--n-bins 8 \
--max-per-cell 5 \
--format .png \
--jobs 4
Rationale¶
- Strict quality gates (sharpness 50, entropy 3.5): Demand excellence
- Small budget (1000): Curated, not comprehensive
- Low max-per-cell (5): Force diversity (avoid over-sampling common scenes)
- PNG format: Lossless (no compression artifacts)
- Larger min-gap (3.0s): Strong temporal separation
Workflow¶
- Run
calibrateand choose strict thresholds: - Use p50 or higher for all metrics
-
Target 10–30% pass rate (very selective)
-
Run
samplewith strict parameters -
Manual review:
- Visually inspect all 1000 frames
- Remove any marginal quality frames
- Final curated set: ~800–900 frames
Quick Preview (Speed-Priority)¶
Goal¶
Fast preview run to check data quality or test parameters:
- Minimize runtime
- Sacrifice completeness for speed
- Quick iteration
Recommended Parameters¶
./sample \
--root-dir /data/preview \
--camera 1 \
--min-brightness 20 \
--max-brightness 230 \
--min-sharpness 15 \
--min-entropy 2.5 \
--max-frames 500 \
--min-gap 2.0 \
--sample-fps 0.5 \
--n-bins 6 \
--jobs 8 \
--format .jpg
Rationale¶
- Low sample-fps (0.5): Sparse sampling (50% reduction in examined frames)
- Small budget (500): Fast extraction
- Coarse grid (6 bins): Faster diversity selection
- Many jobs (8): Maximize parallelism
- JPEG output: Faster encoding
Workflow¶
-
Run preview:
-
Inspect output frames:
- Check quality (are thresholds appropriate?)
-
Check diversity (is grid capturing variety?)
-
Adjust parameters and re-run full sampling:
Tip: Caching makes re-runs very fast (only diversity selection and extraction re-run).
Summary Table¶
| Scenario | min-bright | min-sharp | min-entropy | max-frames | min-gap | sample-fps |
|---|---|---|---|---|---|---|
| Deep benthic | 15 | 20 | 2.8 | 5000 | 2.0 | 1.0 |
| Mid-water plankton | 30 | 15 | 2.0 | 8000 | 1.0 | 1.5 |
| Shallow reef | 50 | 30 | 3.0 | 5000 | 1.5 | 2.0 |
| Fast transect | 20 | 12 | 2.5 | 10000 | 0.5 | 2.0 |
| Static lander | 25 | 25 | 3.0 | 3000 | 5.0 | 0.5 |
| Blurry/turbid | 20 | 6 | 2.0 | 5000 | 1.0 | 1.0 |
| Archival quality | 40 | 50 | 3.5 | 1000 | 3.0 | 1.0 |
| Quick preview | 20 | 15 | 2.5 | 500 | 2.0 | 0.5 |
Next Steps¶
- Calibration Workflow: How to tune for your specific data
- Parameter Reference: Complete parameter documentation
- Main Tuning Guide: Overall tuning strategy