anemoi.utils.settings_schema package
Submodules
anemoi.utils.settings_schema.base module
- class anemoi.utils.settings_schema.base.AnemoiBaseSettingsSchema(**extra_data: Any)
Bases:
BaseModelBase schema for Anemoi settings.
- model_config = {'alias_generator': <function AnemoiBaseSettingsSchema.<lambda>>, 'extra': 'allow', 'populate_by_name': True, 'serialize_by_alias': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
anemoi.utils.settings_schema.datasets module
- class anemoi.utils.settings_schema.datasets.DatasetsNamedConfig(**extra_data: Any)
Bases:
BaseModelNamed dataset mappings (friendly name -> full path/URL).
- model_config = {'extra': 'allow'}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class anemoi.utils.settings_schema.datasets.DatasetsConfig(*, path: list[str] = <factory>, use_search_path_not_found: bool = False, ignore_naming_conventions: bool = False, named: DatasetsNamedConfig = <factory>, **extra_data: Any)
Bases:
AnemoiBaseSettingsSchemaConfiguration for dataset discovery and validation.
Used by
anemoi-datasetsfor search paths, naming convention checks, and named dataset aliases.- use_search_path_not_found: bool
When true, if a .zarr path does not exist, strip to basename and search the paths above instead of failing immediately.
- model_config = {'alias_generator': <function AnemoiBaseSettingsSchema.<lambda>>, 'extra': 'allow', 'populate_by_name': True, 'serialize_by_alias': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- ignore_naming_conventions: bool
When true, skip all dataset naming-convention validation during creation.
- named: DatasetsNamedConfig
Map of friendly dataset names to full paths or URLs.
anemoi.utils.settings_schema.nexus module
- class anemoi.utils.settings_schema.nexus.NexusConfig(*, api_url: str | None = None, api_token: SecretStr | None = None, **extra_data: Any)
Bases:
AnemoiBaseSettingsSchemaConfiguration for access to the Anemoi Nexus.
- model_config = {'alias_generator': <function AnemoiBaseSettingsSchema.<lambda>>, 'extra': 'allow', 'populate_by_name': True, 'serialize_by_alias': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
anemoi.utils.settings_schema.object_storage module
Pydantic models for object storage configuration.
- class anemoi.utils.settings_schema.object_storage.ObjectStorageBucketConfig(*, endpoint_url: str | None = None, skip_signature: bool | None = False, access_key_id: SecretStr | None = None, secret_access_key: SecretStr | None = None, region: str | None = None, account_name: SecretStr | None = None, account_key: SecretStr | None = None, sas_token: SecretStr | None = None, **extra_data: Any)
Bases:
AnemoiBaseSettingsSchemaObject storage configuration for S3-compatible and Azure Blob services.
At the top level (
ObjectStorageConfig) these fields act as global defaults. Under a named sub-section (e.g. [object-storage.”my-bucket”]) they act as per-bucket/account overrides.- endpoint_url: str | None
Endpoint URL. S3-compatible services, Azurite or sovereign clouds for Azure.
- model_config = {'alias_generator': <function AnemoiBaseSettingsSchema.<lambda>>, 'extra': 'allow', 'populate_by_name': True, 'serialize_by_alias': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class anemoi.utils.settings_schema.object_storage.ObjectStorageConfig(*, endpoint_url: str | None = None, skip_signature: bool | None = False, access_key_id: SecretStr | None = None, secret_access_key: SecretStr | None = None, region: str | None = None, account_name: SecretStr | None = None, account_key: SecretStr | None = None, sas_token: SecretStr | None = None, type: Literal['s3', 'az'] | None = None, **extra_data: Any)
Bases:
ObjectStorageBucketConfigTop-level, global object storage configuration.
Inherits all backend fields from
ObjectStorageBucketConfigused for per-bucket/account overrides under __pydantic_extra__ (named sub-sections, e.g. [object-storage.”my-bucket”]).- model_config = {'alias_generator': <function AnemoiBaseSettingsSchema.<lambda>>, 'extra': 'allow', 'populate_by_name': True, 'serialize_by_alias': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
anemoi.utils.settings_schema.paramdb module
- class anemoi.utils.settings_schema.paramdb.ParamDBConfig(*, default_origin: str = 'ecmf', cache_length: int = 30, local_cache: Annotated[Path, PathType(path_type=file)] | None = None, **extra_data: Any)
Bases:
AnemoiBaseSettingsSchemaConfiguration for the GRIB parameter database lookups.
Used by
anemoi.utils.gribto control how GRIB parameter metadata is resolved (online API vs local cache, default origin for disambiguation, and cache lifetime).- model_config = {'alias_generator': <function AnemoiBaseSettingsSchema.<lambda>>, 'extra': 'allow', 'populate_by_name': True, 'serialize_by_alias': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
anemoi.utils.settings_schema.registry module
- class anemoi.utils.settings_schema.registry.RegistryConfig(*, api_url: str | None = None, api_token: SecretStr | None = None, allow_delete: bool = False, plots_uri_pattern: str | None = None, datasets_uri_pattern: str | None = None, weights_uri_pattern: str | None = None, weights_platform: str | None = None, **extra_data: Any)
Bases:
AnemoiBaseSettingsSchemaConfiguration for access to the Anemoi registry.
- model_config = {'alias_generator': <function AnemoiBaseSettingsSchema.<lambda>>, 'extra': 'allow', 'populate_by_name': True, 'serialize_by_alias': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
anemoi.utils.settings_schema.utils module
- class anemoi.utils.settings_schema.utils.UtilsConfig(*, grids_path: Path | None = None, cache_directory: Path = PosixPath('/home/docs/.cache/anemoi'), debug_imports_in_cli: bool = False, **extra_data: Any)
Bases:
AnemoiBaseSettingsSchemaMiscellaneous anemoi-utils settings.
Used by
anemoi.utils.gridsfor custom grid file paths.- grids_path: Path | None
Custom path to a directory containing precomputed grid files (grid-<name>.npz).
When set, grids are loaded from this directory before falling back to the built-in remote source. Supports ~ expansion.
- model_config = {'alias_generator': <function AnemoiBaseSettingsSchema.<lambda>>, 'extra': 'allow', 'populate_by_name': True, 'serialize_by_alias': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].