powsybl-diagram icon indicating copy to clipboard operation
powsybl-diagram copied to clipboard

Improve the computation of invisible nodes used in NetworkGraphBuilder

Open So-Fras opened this issue 2 years ago • 0 comments

  • Do you want to request a feature or report a bug? Improvement on current code without changing its behavior.

  • What is the current behavior? The function getNextDepthVoltageLevels in VoltageLevelFilter is used to find the invisible neighboring nodes of the graph visible nodes. This function is not optimal, especially if a very large list of voltageLevels is passed as an input parameter.

  • What is the expected behavior? The behavior of the NetworkGraphBuilder should not change but the invisible nodes should be collected in a less resource-guzzling way, by reusing a slightly modified traverseVoltageLevels function.

  • What is the motivation / use case for changing the behavior? Improve performance / clean code

  • Please tell us about your environment:

    • PowSyBl Version: 5.1.1

So-Fras avatar Feb 03 '23 14:02 So-Fras