Skip to content

Types

The data shapes used by the symmetric core. Axis convention: BATCH → TIME → VEHICLE → FEATURE.

Side

orbitalgym.env.types.Side

Bases: StrEnum

Side discriminator — Python-level enum, never a traced array.

BySide

orbitalgym.env.types.BySide

One entry per side. Itself a JAX pytree.

Actions

orbitalgym.env.types.Actions

Per-side stacked actions. .sides.guard shape (N_g, action_dim); .sides.bandit shape (N_b, action_dim).

SideOutput

orbitalgym.env.types.SideOutput

Per-step output for one side. Shape rules per scope:

PER_VEHICLE: obs (N_side, obs_dim); reward (N_side,); done (N_side,) bool PER_SIDE : obs (obs_dim,); reward (); done () bool

StepOutput

orbitalgym.env.types.StepOutput

Result of env.step. outputs.guard and outputs.bandit are SideOutputs. episode_done is the scalar termination signal — per-side done fields are this scalar broadcast for shape uniformity.

info["applied_dv"] is a BySide of (n_side, 3) arrays: the Δv the step actually imparted, in the truth frame, zero-padded to width 3. It differs from the commanded Δv whenever thrust or propellant clipped the command, so anything predicting the ego motion must read it rather than the command.

SideTrajectory

orbitalgym.env.types.SideTrajectory

Time-stacked per-side history. Leading axis (T,) prepended to SideOutput-shaped fields plus action / policy_state.

Trajectory

orbitalgym.env.types.Trajectory

Time-stacked rollout. env_state has leading T on every leaf; sides.guard / sides.bandit are SideTrajectorys. episode_done is (T,) latched. controlled_side is a Python-level enum (not traced).

env_state at index k is the state entering step k, so the state leaving the last step has no slot in it. final_state carries that one state, which is what closes the last step into a real transition.

applied_dv is the truth-frame Δv each step actually imparted, which is what delta-v accounting must sum: a command clipped by thrust or an empty tank never reaches the vehicle.