> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.nvidia.com/aerial/aodt/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.nvidia.com/aerial/aodt/_mcp/server.

# Batched Mode

Batched Mode is the simplest way to run a complete simulation through the AODT
client. After the scenario is loaded, `run_full_simulation()` asks the worker to
execute all batches and all time steps at once. Results are written to the
database as Parquet files in S3 and can be queried from the catalog, according
to the scenario configuration. This mode is best when your application wants the
complete output dataset instead of step-by-step control.

For selective CIR requests, per-slot inspection, or direct NumPy access during a
run, use [Interactive Mode](/dynamic-mode) instead.

## Batched EM and Batched RAN

Batched Mode supports two simulation modes:

* **Batched EM** runs the EM Solver and exports channel results,
  ray paths, and related setup data.
* **Batched RAN** runs the EM Solver and RAN components, including the L1/L2
  stack and channel emulation. It exports the channel results plus RAN telemetry
  and RAN configuration tables.

Use the `SimConfig` builder API to select the mode. EM scenarios can use either
a duration/interval timeline or a slot-based timeline. RAN scenarios use the
slot-based timeline so the simulation follows the 5G slot structure.

```python
from aodt_config import SimConfig, SimMode

# Batched EM, duration/interval timeline
config = SimConfig(scene, SimMode.EM, asset_config)
config.set_timeline(duration=1.0, interval=0.1)

# Batched RAN, slot timeline
config = SimConfig(scene, SimMode.RAN, asset_config)
config.set_timeline(slots_per_batch=100, realizations_per_slot=1)
```

When the builder exports YAML, it writes the corresponding scenario fields,
including `sim_is_full`, `sim_simulation_mode`, and the selected timeline
parameters.

## Workflow

The typical Batched Mode workflow is:

1. Create a `dt_client.DigitalTwinClient`.
2. Load a scenario YAML string with `client.start(...)`.
3. Inspect the loaded scenario with `client.get_status()`.
4. Call `client.run_full_simulation()`.
5. Read the exported results produced by the run.

`run_full_simulation()` is a blocking call. Progress updates appear in the
client logs while it runs, and the Python method returns a summary with
`time_steps_completed` and `total_time_seconds` when the run finishes.

For EM runs, Batched Mode works with either timeline style described in
[Interactive Mode](/dynamic-mode): slot-based timelines or duration/interval
timelines. RAN runs use slot-based timelines.

## Example

Run the full simulation example:

```bash
python client/examples/example_full_sim.py \
  --server_address localhost:50051 \
  --s3_endpoint http://minio:9000
```

Use `--import_option file --yaml_file <path>` to run a specific scenario YAML,
or let the example generate a YAML configuration programmatically.

The core pattern is:

```python
import dt_client

client = dt_client.DigitalTwinClient("localhost:50051")
client.start(yaml_content)

status = client.get_status()
if not status["scenario_loaded"]:
    raise RuntimeError("Scenario failed to load")

result = client.run_full_simulation()
print(result["time_steps_completed"])
print(result["total_time_seconds"])
```

After completion, the configured outputs are available from the database or
exported result files. See the [Results Schemas](/results-schemas) page for the
tables and columns produced by the simulation. See
`client/examples/example_query_tables.py` for an example of inspecting and
querying exported result tables.

To clean up a result database after a test run, remove both the catalog metadata
and the S3 Parquet data. See `client/examples/example_drop_database.py` for an
example script that can preview the deletion plan and execute the cleanup.

## Advanced RAN Parameters

RAN protocol and scheduler parameters are configured in `worker/config_ran.json`.
The worker container mounts this file at
`/opt/nvidia/aodt_sim/src_be/components/common/config_ran.json`.

| Parameter                                                 | Description                                                                              | Default                                           |
| --------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ------------------------------------------------- |
| `gNB noise figure`                                        | RU/gNB receiver noise figure.                                                            | `0.5` dB                                          |
| `UE noise figure`                                         | UE receiver noise figure.                                                                | `0.5` dB                                          |
| `DL HARQ enabled`                                         | Enables downlink HARQ.                                                                   | `1`                                               |
| `UL HARQ enabled`                                         | Enables uplink HARQ.                                                                     | `1`                                               |
| `TDD patterns`                                            | Supported TDD slot patterns.                                                             | `1: DDDSUUDDDD`, `2: DDDDDDDDDD`, `3: UUUUUUUUUU` |
| `Simulation pattern`                                      | Selects the TDD pattern used for the run.                                                | `1`                                               |
| `Max scheduled UEs per TTI - dl`                          | Maximum scheduled UEs per cell in downlink.                                              | `6`                                               |
| `Max scheduled UEs per TTI - ul`                          | Maximum scheduled UEs per cell in uplink.                                                | `6`                                               |
| `Scheduler Mode`                                          | PRB scheduling algorithm. Options include `PF` and `RR`.                                 | `PF`                                              |
| `Beamformers CSI`                                         | CSI source for beamforming. Options include `SRS` and `CFR`.                             | `CFR`                                             |
| `MAC CSI`                                                 | CSI source for MAC scheduling. Options include `SRS` and `CFR`.                          | `CFR`                                             |
| `Beamforming Grp Level`                                   | Beamforming group level: `SC`, `PRBG`, or `UEG`.                                         | `PRBG`                                            |
| `pusch channel estimation`                                | PUSCH channel estimation method.                                                         | `MMSE`                                            |
| `srs channel estimation`                                  | SRS channel estimation method. `RKHS` is supported only with 64-antenna RUs.             | `MMSE`                                            |
| `channel estimation duration`                             | Delay-spread window for MMSE channel estimation.                                         | `2`                                               |
| `MCS selection mode`                                      | MCS selection method.                                                                    | `OLLA`                                            |
| `SRS SNR threshold for MU-MIMO feasibility - dl`          | Downlink SRS SNR threshold for MU-MIMO grouping.                                         | `-3.0` dB                                         |
| `SRS SNR threshold for MU-MIMO feasibility - ul`          | Uplink SRS SNR threshold for MU-MIMO grouping.                                           | `-3.0` dB                                         |
| `Channel correlation threshold for MU-MIMO grouping - dl` | Downlink channel-correlation threshold for MU-MIMO grouping.                             | `0.7`                                             |
| `Channel correlation threshold for MU-MIMO grouping - ul` | Uplink channel-correlation threshold for MU-MIMO grouping.                               | `0.7`                                             |
| `Fixed UE layers - dl`                                    | Optional fixed downlink layer assignment.                                                | disabled                                          |
| `Fixed UE layers - ul`                                    | Optional fixed uplink layer assignment.                                                  | disabled                                          |
| `RX FT filename`                                          | H5 filename for received frequency-time waveform dumping. Empty string disables dumping. | `""`                                              |

Only a subset of RAN internals is exposed through this JSON file. See
[Waveform Dumping](/waveform-dumping) for `RX FT filename`, and see
[Results Schemas](/results-schemas) for the exported `ran_config` and
`ran_telemetry` tables.

## When To Use

Use Batched Mode when:

* The application needs a complete simulation result for an EM, RAN, or
  calibration workflow.
* You do not need to inspect or modify intermediate time steps.
* You want the worker to manage simulation execution and result persistence.
* You are running calibration. See [Calibration](/calibration).

Use Interactive Mode when the application needs to request selected slots or
time steps, retrieve CIR arrays into NumPy, or feed intermediate results into
custom application logic.

## API Reference

See the [DigitalTwinClient API](/api/client) for `start`, `get_status`,
`run_full_simulation`, `cancel_simulation`, and related client methods.

See [Results Schemas](/results-schemas) for the Parquet tables and columns
exported by a completed run.