pypowsybl.network.Network.get_ratio_tap_changers#

Network.get_ratio_tap_changers(all_attributes=False, attributes=None, **kwargs)[source]#

Create a ratio tap changers:class:~pandas.DataFrame.

Parameters:
  • all_attributes (bool) – flag for including all attributes in the dataframe, default is false

  • attributes (Optional[List[str]]) – attributes to include in the dataframe. The 2 parameters are mutually exclusive. If no parameter is specified, the dataframe will include the default attributes.

  • kwargs (Union[_SupportsArray[dtype[Any]], _NestedSequence[_SupportsArray[dtype[Any]]], bool, int, float, complex, str, bytes, _NestedSequence[Union[bool, int, float, complex, str, bytes]]]) – the data to be selected, as named arguments.

Returns:

the ratio tap changers dataframe

Return type:

DataFrame

Notes

The resulting dataframe, depending on the parameters, will include the following columns:

  • tap: the current tap position

  • low_tap: the low tap position (usually 0, but could be different depending on the data origin)

  • high_tap: the high tap position

  • step_count: the count of taps, should be equal to (high_tap - low_tap)

  • on_load: true if the tap changer has on-load regulation capability

  • regulating: true if the tap changer is in regulation

  • target_v: the target voltage in kV, if the tap changer is in regulation

  • target_deadband: the regulation deadband around the target voltage, in kV

  • regulating_bus_id: the bus where the tap changer regulates voltage

  • regulated_side (optional): the side where the tap changer regulates voltage (redundant with regulating_bus_id)

  • fictitious (optional): True if the tap changer is part of the model and not of the actual network

This dataframe is indexed by the id of the transformer

Examples

net = pp.network.create_eurostag_tutorial_example1_network()
net.get_ratio_tap_changers()

will output something like:

tap

low_tap

high_tap

step_count

on_load

regulating

target_v

target_deadband

regulating_bus_id

id

NHV2_NLOAD

1

0

2

3

True

True

158.0

0.0

VLLOAD_0

net = pp.network.create_eurostag_tutorial_example1_network()
net.get_ratio_tap_changers(all_attributes=True)

will output something like:

tap

low_tap

high_tap

step_count

on_load

regulating

target_v

target_deadband

regulating_bus_id

id

NHV2_NLOAD

1

0

2

3

True

True

158.0

0.0

VLLOAD_0

net = pp.network.create_eurostag_tutorial_example1_network()
net.get_ratio_tap_changers(attributes=['tap','low_tap','high_tap','step_count','target_v','regulating_bus_id'])

will output something like:

tap

low_tap

high_tap

step_count

target_v

regulating_bus_id

id

NHV2_NLOAD

1

0

2

3

158.0

VLLOAD_0