Anchorage detection is a behaviour-inference problem

3 minute read

In brief

  • Anchorage is a latent behaviour; AIS is an imperfect observation of it.
  • A useful model combines physics-aware features, temporal context and probabilistic state inference.
  • Evaluate events, calibration and cross-port transfer—not ping-level accuracy alone.

Anchorage is not directly observed from AIS. A vessel may remain inside an anchorage polygon without being anchored, while low-speed motion outside a polygon may still correspond to anchorage or waiting. I therefore formulate anchorage as latent-state inference:

**P(state_t = anchorage AIS history, vessel context, local traffic context).**

This framing connects a practical maritime problem to a broader research question in world models: infer a compact hidden state that explains observations and supports prediction.

What is observed—and what is not

AIS provides irregular samples of position, SOG, COG, heading, navigation status and vessel metadata. It does not directly provide intent, ocean current, wind forcing, engine state, manoeuvring policy or whether a low-speed vessel is anchored, drifting or queueing.

This distinction is important because trajectory-prediction studies repeatedly identify data quality, long-horizon uncertainty and cross-environment generalisation as central limitations. The methodological question is therefore not only which architecture to use, but which latent variables and observation assumptions are required to represent vessel dynamics reliably.

A model hierarchy

I propose to build the system in layers:

  1. Physics / rule baseline — speed, displacement radius, dwell time, turn variance and distance to charted anchorage.
  2. Temporal state model — HMM/state-space model, neural process or recurrent/Transformer encoder over irregular observations.
  3. Context model — vessel type/dimensions, port/anchorage geometry, local traffic density and historical behaviour.
  4. World-model layer — predict plausible future latent states/trajectories and use prediction error to expose ambiguous transitions.

World models are attractive because they force the representation to support prediction, not just classification. Ha & Schmidhuber’s original formulation and later systems such as Dreamer show the broader idea: learn compact dynamics, then reason or act in the learned latent space. In maritime settings, the equivalent goal is not game control; it is a calibrated model of vessel-state evolution that can support forecasting and anomaly detection.

What loitering literature teaches us about anchorage

The loitering literature is a useful adversarial test for anchorage models. Miller et al.’s global transshipment work treats prolonged low-speed offshore motion as loitering and explicitly identifies ordinary waiting between jobs as a false-positive mechanism. Zhang et al.’s trajectory-shape approach uses repeated turning, which can also be produced by anchor swing. Wijaya and Nakamura explicitly remove anchored vessels before loitering scoring, showing that the distinction has to be designed into the pipeline rather than expected to emerge automatically.

This is why I propose to not train anchorage, waiting and loitering as unrelated binary classifiers. They should share a latent-state model and compete as alternative explanations for the same observed motion.

Causal lens: separate drivers from evidence

Low speed is an observation, not a cause. Wind, current, vessel dimensions, propulsion state, port congestion and operational intent can all influence the observed motion. A causal view asks which of these variables change the latent behaviour and which only change how that behaviour is observed.

The practical payoff is counterfactual reasoning: would this track still look like anchorage if the same vessel experienced a different current, traffic state or port queue? If the answer changes for the wrong reason, the model has learned context shortcuts rather than behaviour.

Event-level evaluation

A classifier can score 99% of pings correctly and still produce unusable anchorage events by flickering between states. I propose to therefore evaluate:

  • event precision/recall;
  • start/end boundary error;
  • dwell-duration error;
  • calibration / Brier score;
  • port-held-out and vessel-held-out performance;
  • robustness to sparse ping schedules.

The cross-port test is important. A model that learns one harbour’s geometry is not yet a behaviour model.

Operational impact

Reliable anchorage events support congestion measurement, port-call reconstruction, waiting-time estimation, emissions analysis and commodity-flow intelligence. But the output should carry evidence: recent track, state probability, supporting rule features and uncertainty.

The central distinction is observation ≠ state: AIS provides evidence about vessel behaviour, while the behavioural state remains latent and must be inferred under explicit assumptions.

References