# `Monty.Frameworks.Models.SensorModules.SnapshotTelemetry`
[🔗](https://github.com/d-led/ex.tbp.monty/blob/v0.1.0/packages/ex_tbp_monty_core/lib/monty/frameworks/models/sensor_modules/snapshot_telemetry.ex#L1)

Keeps the raw observations a sensor saw, and where it was when it saw them.

Mirrors `tbp/monty/frameworks/models/sensor_modules.py::SnapshotTelemetry`.
Only a sensor configured with `save_raw_obs: true` fills it. What it is for is
looking back at the very pixels a percept was computed from — a graph of
features is not enough to tell a bad estimate from a bad view — so the
observation is kept as it arrived rather than as it was summarised.

The observations are held newest first, which is how a list is cheapest to
grow in; `state_dict/1` hands them back in the order they were taken, one pose
per observation, as Monty's does.

# `pose`

```elixir
@type pose() :: %{sm_rotation: [float()], sm_location: [float()]}
```

The sensor's pose when it took one observation: `wxyz`, then metres.

# `t`

```elixir
@type t() :: %Monty.Frameworks.Models.SensorModules.SnapshotTelemetry{
  poses: [pose()],
  raw_observations: [map()]
}
```

# `new`

```elixir
@spec new() :: t()
```

# `raw_observation`

```elixir
@spec raw_observation(t(), map(), Monty.Geometry.Rotation.t(), [float()]) :: t()
```

Records one raw observation and the sensor's pose when it took it.

Both lists grow together, which is the invariant `state_dict/1` relies on.

# `reset`

```elixir
@spec reset(t()) :: t()
```

Forgets everything, for a new episode.

# `state_dict`

```elixir
@spec state_dict(t()) :: %{raw_observations: [map()], sm_properties: [pose()]}
```

What was recorded, oldest first, as Monty's `state_dict` reports it.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
