marmot.formatters.formatsiip.ProcessSIIP#

class ProcessSIIP(input_folder: pathlib.Path, output_file_path: pathlib.Path, *args, region_mapping: pandas.core.frame.DataFrame = Empty DataFrame Columns: [] Index: [], **kwargs)[source]#

Bases: marmot.formatters.formatbase.Process

Process SIIP specific data from a SIIP result set.

Parameters
  • input_folder (Path) – Folder containing csv files.

  • output_file_path (Path) – Path to formatted h5 output file.

  • region_mapping (pd.DataFrame, optional) – DataFrame to map custom regions/zones to create custom aggregations. Defaults to pd.DataFrame().

  • **kwargs – These parameters will be passed to the Process class.

Methods

df_process_generator(df)

Format SIIP Generator class data

df_process_line(df)

Format SIIP Line data

df_process_region(df)

Format SIIP Region data

df_process_reserves_generators(df)

Format SIIP Reserves Generator data

get_processed_data(prop_class, prop, ...)

Handles the pulling of data from the SIIP input folder and then passes the data to one of the formating functions

output_metadata(*_)

Add SIIP specific metadata to formatted h5 file .

Attributes

PROPERTY_MAPPING

Maps simulation model property names to Marmot property names

UNITS_CONVERSION

Dictionary to convert units to standard values used by Marmot

data_collection

Dictionary model names to full filename path

get_input_data_paths

For SIIP returns paths to input folders

input_folder

Path to input folder

PROPERTY_MAPPING: dict = {'generator_generation_actual': 'generator_Generation', 'generator_generation_availability': 'generator_Available_Capacity', 'generator_installed_capacity': 'generator_Installed_Capacity', 'line_power_flow_actual': 'line_Flow', 'region_regional_load': 'region_Demand', 'reserves_generators_reserve_contribution': 'reserves_generators_Provision'}#

Maps simulation model property names to Marmot property names

EXTRA_PROPERTIES_CLASS#

alias of marmot.formatters.formatextra.ExtraSIIProperties

property get_input_data_paths: list#

For SIIP returns paths to input folders

SIIP places individual input files in a single folder, It does not combine all results into a single file like PLEXOS or ReEDS. If models have been split into partitions, returns list of partition folders, else returns scenario folder.

output_metadata(*_) None[source]#

Add SIIP specific metadata to formatted h5 file .

get_processed_data(prop_class: str, prop: str, timescale: str, model_name: str) pandas.core.frame.DataFrame[source]#

Handles the pulling of data from the SIIP input folder and then passes the data to one of the formating functions

Parameters
  • prop_class (str) – Property class e.g Region, Generator, Zone etc

  • prop (str) – Property e.g generation_actual, regional_load etc.

  • timescale (str) – Data timescale, e.g interval, month, year, etc.

  • model_name (str) – name of model to process.

Returns

Formatted results dataframe.

Return type

pd.DataFrame

df_process_generator(df: pandas.core.frame.DataFrame) pandas.core.frame.DataFrame[source]#

Format SIIP Generator class data

Parameters

df (pd.DataFrame) – Data Frame to process

Returns

dataframe formatted to generator class spec

Return type

pd.DataFrame

df_process_region(df: pandas.core.frame.DataFrame) pandas.core.frame.DataFrame[source]#

Format SIIP Region data

Parameters

df (pd.DataFrame) – Data Frame to process

Returns

dataframe formatted to region class spec

Return type

pd.DataFrame

df_process_reserves_generators(df: pandas.core.frame.DataFrame) pandas.core.frame.DataFrame[source]#

Format SIIP Reserves Generator data

Parameters

df (pd.DataFrame) – Data Frame to process

Returns

dataframe formatted to reserves generator class spec

Return type

pd.DataFrame

df_process_line(df: pandas.core.frame.DataFrame) pandas.core.frame.DataFrame[source]#

Format SIIP Line data

Parameters

df (pd.DataFrame) – Data Frame to process

Returns

dataframe formatted to region class spec

Return type

pd.DataFrame