revrt.models.cost_layers.DryCosts#

class DryCosts(*, iso_region_tiff: Annotated[Path, PathType(path_type=file)], nlcd_tiff: Annotated[Path, PathType(path_type=file)], slope_tiff: Annotated[Path, PathType(path_type=file)], cost_configs: Annotated[Path, PathType(path_type=file)] | None = None, default_mults: IsoMultipliers | None = None, extra_tiffs: list[Annotated[Path, PathType(path_type=file)]] | None = None)[source]#

Bases: BaseModel

Config items required to generate dry costs

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.

Methods

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.

iso_region_tiff

Filename of ISO region GeoTIFF

nlcd_tiff

File name of NLCD GeoTiff

slope_tiff

File name of slope GeoTiff

cost_configs

Path to json file with transmission cost configuration values

default_mults

Multipliers to be used for default region

extra_tiffs

Optional list of extra GeoTIFFs to add to cost H5 file

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

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

property model_extra: dict[str, Any] | None#

Get extra fields set during validation.

Returns:

A dictionary of extra fields, or None if config.extra is not set to “allow”.

property model_fields_set: set[str]#

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

Returns:
A set of strings representing the fields that have been set,

i.e. that were not filled from defaults.

iso_region_tiff: Annotated[Path, PathType(path_type=file)]#

Filename of ISO region GeoTIFF

nlcd_tiff: Annotated[Path, PathType(path_type=file)]#

File name of NLCD GeoTiff

slope_tiff: Annotated[Path, PathType(path_type=file)]#

File name of slope GeoTiff

cost_configs: Annotated[Path, PathType(path_type=file)] | None#

Path to json file with transmission cost configuration values

Path to json file containing dictionary with transmission cost configuration values. Valid configuration keys are:

  • “base_line_costs”

  • “iso_lookup”

  • “iso_multipliers”

  • “land_use_classes”

  • “new_substation_costs”

  • “power_classes”

  • “power_to_voltage”

  • “transformer_costs”

  • “upgrade_substation_costs”

Each of these keys should point to a dictionary or a path to a separate json file containing a dictionary of configurations for each section.

default_mults: IsoMultipliers | None#

Multipliers to be used for default region

This input should be a dictionary with three keys:

  • “iso”: This key is ignored, but is required. Can set to “default” and move on.

  • “land_use”: A dictionary where keys are the land use types (e.g. “cropland”, “forest”, “wetland”, etc.) and values are the multipliers for those land uses.

  • “slope”: A dictionary where keys are the slope types/multipliers (e.g. “hill_mult”, “hill_slope”, “mtn_mult”, “mtn_slope”, etc.) and values are the slopes/multipliers.

extra_tiffs: list[Annotated[Path, PathType(path_type=file)]] | None#

Optional list of extra GeoTIFFs to add to cost H5 file