Skip to content

Version 0.14.0

Latest

Choose a tag to compare

@benoit9126 benoit9126 released this 22 Jan 08:30
· 3 commits to develop since this release
18b1fbe

Release notes for Roseau Load Flow version 0.14.0.

This version requires Python 3.12+. It introduces several new features, improvements, bug fixes as well as the removals of deprecated functionality and support for older dependency versions.

Plotting Improvements

This release includes major improvements and adds many new features to the plotting module.

Voltage Profile Plotting

The new function rlf.plotting.voltage_profile plots the voltage profile of a network. This function returns an object with plot_matplotlib() and plot_plotly() methods to create plots using either Matplotlib or Plotly.

voltage-profile

Contributed in PR 429 and PR 424

Plotting Results on an Interactive Map

The new function rlf.plotting.plot_results_interactive_map plots a network with load flow results on an interactive map. This function works similarly to rlf.plotting.plot_interactive_map, but colors the buses according to their voltage levels and the lines and transformers according to their loading levels. It also include the results in the tooltips and popups of the network elements.

interactive-map-results

Contributed in PR 426

Improvements to Interactive Map Styles

The rlf.plotting.plot_interactive_map function has been improved with several style changes to visually distinguish different voltage levels, line types, and network elements.

  • Different voltage levels are represented with different marker sizes and line widths
    • Nominal voltages are used to determine the voltage levels automatically (HV, MV, LV). If nominal voltages are not available, they are inferred from the transformers and sources
  • Underground lines are dashed while other lines are solid including lines with unknown line type
  • Transformers are represented with a square icon with a divider in the middle and with both HV and LV buses information in the tooltip and popup
  • Sourcers are represented with a bigger square icon

Note that the markers of buses, transformers and sources now use the folium.DivIcon icon which means the style function must now return a style dictionary of the form {'html': ...} for these elements.

The function also gained the fit_bounds parameter that, when set to True (default), causes the bounds of the map to be automatically adjusted using folium.FitOverlays to fit the network elements.

Contributed in PR 418

LV Line Parameters in the Catalogue

This release adds several low voltage (LV) line parameters to the line catalogue. LV line parameters include a neutral conductor and generate 4x4 matrices by default. You can create an LV line parameter using its name from the catalogue, e.g. rlf.LineParameters.from_catalogue("U_AL_3x150+70"). All added LV lines parameters have a name in the format <Type>_<Material>_3x<PhaseSection>+<NeutralSection>. You can get all added LV lines with the following regular expression:

rlf.LineParameters.get_catalogue(r"^[UOT]_[A-Z]+_3x(\d+)\+(\d+(?:\.\d+)?)$")

Contributed in PR 434

Optional Neutral Elimination When Converting Line Parameters to Symmetrical Components

When calling the to_sym method of rlf.LineParameters, you can now pass eliminate_neutral=True to optionally eliminate the neutral conductor using Kron's reduction. This is useful when converting the line parameters to other software that do not support neutral conductors like pandapower. Converting to software that support neutral conductors like PowerFactory should not eliminate the neutral conductor.

Additionally, the new function rlf.converters.kron_reduction performs Kron reduction on any nxn matrix reducing it to an (n-1)x(n-1) matrix by eliminating the last row and column.

Contributed in PR 436

Removal of Deprecated Functionality

The following deprecated functionality has been removed.

  • The side parameter of rlf.GroundConnection, rlf.plotting.plot_voltage_phasors and rlf.plotting.plot_symmetrical_voltages is removed. Pass a branch side directly instead (e.g. rlf.GroundConnection(ground=ground, element=transformer.side_hv)).
  • The potentials attribute and constructor parameter of Bus is removed. Use initial_potentials instead.
  • The bus of a disconnected load or source no longer returns None. Use the new is_disconnected property to check if the load or source is disconnected.
  • The phase parameter of rlf.PotentialRef is removed. Use phases instead.
  • The res_voltages_hv and res_voltages_lv attributes of rlf.Transformer are removed. Use <side>.res_voltages instead.
  • Deprecated names in rlf.constants, rlf.types and rlf.sym modules are removed.
  • Deprecated modules in the rlf.utils package are removed. This package is for internal use only and should not be considered stable.

Contributed in PR 425

Dropping Support for Older Python and Dependency Versions

roseau-load-flow version 0.14.0 requires Python 3.12 or newer. Additionally, the minimum supported versions of some dependencies have been bumped as per SPEC-0.

The minimum supported versions of required dependencies are now:

  • certifi>=2023.5.7
  • geopandas>=1.0.0
  • numpy>=1.21.5
  • pandas>=1.4.0
  • numpy>=2.0.0
  • pandas>=2.1.0
  • pint>=0.21.0
  • platformdirs>=4.0.0
  • pyproj>=3.3.0
  • roseau-load-flow-engine>=0.19.0
  • shapely>=2.0.0
  • typing-extensions>=4.6.2

Contributed in PR 419 and PR 420

Miscellaneous Improvements and Bug Fixes

  • Add missing transformer tap to the edge data in the graph generated by ElectricalNetwork.to_graph. Contributed in PR 427
  • Improve initial voltage guesses in the Newton algorithm for networks involving delta connected sources. Contributed in PR 421
  • Fix filtering catalogues using compiled regular expressions with newer versions of pandas. Contributed in PR 404
  • Restore bus and layers to the layer control in the interactive map plot. This was broken in version 0.13.0. Contributed in PR 413

What's Changed

Full Changelog: v0.13.1...v0.14.0