Skip to content

flex_rf.web.BatchData

Type: class Base(s): Tidy3dBaseModel, Mapping

Holds a collection of SimulationData returned by Batch.

When the batch is completed, the output is not a SimulationData but rather a BatchData. The data within this BatchData object can either be indexed directly batch_results[task_name] or can be looped through batch_results.items() to get the SimulationData for each task. Converting with dict(batch_results.items()) eagerly touches all tasks and can load all results.

task_paths [dict[TaskName, str]]

Mapping of task_name to path to corresponding data for each task in batch.

task_ids [dict[TaskName, str]]

Mapping of task_name to task_id for each task in batch.

verbose [bool] = True

Whether to print info messages and progressbars.

cached_tasks [dict[TaskName, bool] | None] = None

Whether the data of a task came from the cache.

lazy [bool] = False

Whether to load the actual data (lazy=False) or return a proxy that loads the data when accessed (lazy=True).

is_downloaded [bool | None] = False

Whether the simulation data was downloaded before.

load(path_dir: PathLike = DEFAULT_DATA_DIR, replace_existing: bool = False)

Load Batch from file, download results, and load them.

load_sim_data(task_name: str)

Load a simulation data object from file by task name.