ABMParams#

class ABMParams(**data)[source]#

Bases: BaseModelParams

Parameters for the agent-based measles model (daily timesteps).

All fields are inherited from BaseModelParams. Key fields:

num_ticks#

Number of daily simulation steps (e.g., 365 = 1 year).

Type:

int

seed#

Random seed for reproducibility. Default: 20250314.

Type:

int

start_time#

Simulation start in "YYYY-MM" format. Default: "2000-01".

Type:

str

verbose#

Print detailed logging. Default: False.

Type:

bool

Example:

params = ABMParams(num_ticks=365, seed=42)
params = ABMParams(num_ticks=730, seed=0, start_time="2010-06")

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

Attributes

model_computed_fields

model_config

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

model_extra

Get extra fields set during validation.

model_fields

model_fields_set

Returns the set of fields that have been explicitly set on this model instance.

states

List of model states.

time_step_days

Time step in days.

seed

start_time

num_ticks

verbose

show_progress

use_numba

Methods

property time_step_days: int#

Time step in days. Must be implemented by subclasses.

property states: list[str]#

List of model states. Must be implemented by subclasses.

model_config: ClassVar[ConfigDict] = {'extra': 'forbid'}#

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].