Skip to content

taps.apps.configs.synthetic

WorkflowStructure

Bases: Enum

Workflow structure types.

SyntheticConfig

Bases: AppConfig

Synthetic application configuration.

Parameters:

  • name (Literal[str], default: 'synthetic' ) –

    Application name.

  • structure (WorkflowStructure) –

    Workflow structure.

  • task_count (int) –

    Number of tasks in the workflow.

  • task_data_bytes (int, default: 0 ) –

    Intermediate task data size.

  • task_sleep (float, default: 0 ) –

    minimum duration of each task.

  • bag_max_running (int | None, default: None ) –

    Max running tasks in bag workflow.

  • warmup_tasks (int, default: 0 ) –

    Number of warmup tasks before running the workflow.

get_app

get_app() -> App

Create an application instance from the config.

Source code in taps/apps/configs/synthetic.py
def get_app(self) -> App:
    """Create an application instance from the config."""
    from taps.apps.synthetic import SyntheticApp
    from taps.apps.synthetic import WorkflowStructure

    return SyntheticApp(
        structure=WorkflowStructure(self.structure),
        task_count=self.task_count,
        task_data_bytes=self.task_data_bytes,
        task_sleep=self.task_sleep,
        bag_max_running=self.bag_max_running,
        warmup_tasks=self.warmup_tasks,
    )