reV.hybrids.hybrids.MetaHybridizer

class MetaHybridizer(data, allow_solar_only=False, allow_wind_only=False, fillna=None, limits=None, ratio_bounds=None, ratio='solar_capacity/wind_capacity')[source]

Bases: object

Framework to handle hybridization of meta data.

Parameters:
  • data (HybridsData) – Instance of HybridsData containing input data to hybridize.

  • allow_solar_only (bool, optional) – Option to allow SC points with only solar capacity (no wind). By default, False.

  • allow_wind_only (bool, optional) – Option to allow SC points with only wind capacity (no solar), By default, False.

  • fillna (dict, optional) – Dictionary containing column_name, fill_value pairs representing any fill values that should be applied after merging the wind and solar meta. Note that column names will likely have to be prefixed with solar or wind. By default, None.

  • limits (dict, optional) – Option to specify mapping (in the form of a dictionary) of {colum_name: max_value} representing the upper limit (maximum value) for the values of a column in the merged meta. For example, limits={‘solar_capacity’: 100} would limit all the values of the solar capacity in the merged meta to a maximum value of 100. This limit is applied BEFORE ratio calculations. The names of the columns should match the column names in the merged meta, so they are likely prefixed with solar or wind`. By default, ``None (no limits applied).

  • ratio_bounds (tuple, optional) – Option to set ratio bounds (in two-tuple form) on the columns of the ratio input. For example, ratio_bounds=(0.5, 1.5) would adjust the values of both of the ratio columns such that their ratio is always between half and double (e.g., no value would be more than double the other). To specify a single ratio value, use the same value as the upper and lower bound. For example, ratio_bounds=(1, 1) would adjust the values of both of the ratio columns such that their ratio is always equal. By default, None (no limit on the ratio).

  • ratio (str, optional) – Option to specify the columns used to calculate the ratio that is limited by the ratio_bounds input. This input is a string in the form “numerator_column_name/denominator_column_name”. For example, ratio=’solar_capacity/wind_capacity’ would limit the ratio of the solar to wind capacities as specified by the ratio_bounds input. If ratio_bounds is None, this input does nothing. The names of the columns should be prefixed with one of the prefixes defined as class variables. By default 'solar_capacity/wind_capacity'.

Methods

hybridize()

Combine the solar and wind metas and run hybridize methods.

validate_input()

Validate the input parameters.

Attributes

hybrid_meta

Hybridized summary for the representative profiles.

solar_profile_indices_map

Map hybrid to solar rep indices.

wind_profile_indices_map

Map hybrid to wind rep indices.

property hybrid_meta

Hybridized summary for the representative profiles.

Returns:

hybrid_meta (pd.DataFrame) – Summary for the hybridized representative profiles. At the very least, this has a column that the data was merged on.

validate_input()[source]

Validate the input parameters.

This method validates that the input limit, fill, and ratio columns are formatted correctly.

hybridize()[source]

Combine the solar and wind metas and run hybridize methods.

property solar_profile_indices_map

Map hybrid to solar rep indices.

Returns:

  • hybrid_indices (np.ndarray) – Index values corresponding to hybrid rep profiles.

  • solar_indices (np.ndarray) – Index values of the solar rep profiles corresponding to the hybrid rep profile indices.

property wind_profile_indices_map

Map hybrid to wind rep indices.

Returns:

  • hybrid_indices (np.ndarray) – Index values corresponding to hybrid rep profiles.

  • wind_indices (np.ndarray) – Index values of the wind rep profiles corresponding to the hybrid rep profile indices.