VeraGrid 5.6.2__tar.gz → 5.6.3__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (311) hide show
  1. {veragrid-5.6.2 → veragrid-5.6.3}/PKG-INFO +1 -1
  2. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/diagram_bus_selection_dialogue.py +5 -6
  3. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/schematic_widget.py +1 -1
  4. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/GridReduce/grid_reduce.py +48 -23
  5. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/GridReduce/grid_reduce_gui.py +7 -0
  6. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/SubClasses/Model/data_base.py +14 -4
  7. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/SubClasses/Model/diagrams.py +4 -2
  8. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/SubClasses/simulations.py +168 -114
  9. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/__version__.py +1 -1
  10. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ExecuteVeraGrid.py +0 -0
  11. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/AboutDialogue/__init__.py +0 -0
  12. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/AboutDialogue/about_dialogue.py +0 -0
  13. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/AboutDialogue/gui.py +0 -0
  14. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/AboutDialogue/icons_rc.py +0 -0
  15. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/AboutDialogue/update_gui_file.py +0 -0
  16. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Analysis/AnalysisDialogue.py +0 -0
  17. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Analysis/__init__.py +0 -0
  18. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Analysis/gui.py +0 -0
  19. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Analysis/icons_rc.py +0 -0
  20. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Analysis/object_plot_analysis.py +0 -0
  21. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Analysis/update_gui_file.py +0 -0
  22. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/ContingencyPlanner/__init__.py +0 -0
  23. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/ContingencyPlanner/contingency_planner_dialogue.py +0 -0
  24. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/ContingencyPlanner/gui.py +0 -0
  25. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/ContingencyPlanner/icons_rc.py +0 -0
  26. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/ContingencyPlanner/update_gui_file.py +0 -0
  27. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/CoordinatesInput/__init__.py +0 -0
  28. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/CoordinatesInput/coordinates_dialogue.py +0 -0
  29. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/CoordinatesInput/gui.py +0 -0
  30. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/CoordinatesInput/icons_rc.py +0 -0
  31. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/CoordinatesInput/update_gui_file.py +0 -0
  32. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/Editors/__init__.py +0 -0
  33. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/Editors/controllable_shunt_editor.py +0 -0
  34. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/Editors/generator_editor.py +0 -0
  35. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/Editors/line_editor.py +0 -0
  36. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/Editors/new_line_dialogue.py +0 -0
  37. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/Editors/transformer3w_editor.py +0 -0
  38. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/Editors/transformer_editor.py +0 -0
  39. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/Editors/transformer_taps_editor.py +0 -0
  40. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Branches/__init__.py +0 -0
  41. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Branches/line_location_graphic_item.py +0 -0
  42. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Branches/map_ac_line.py +0 -0
  43. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Branches/map_dc_line.py +0 -0
  44. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Branches/map_fluid_path.py +0 -0
  45. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Branches/map_hvdc_line.py +0 -0
  46. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Branches/map_line_container.py +0 -0
  47. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Branches/map_line_segment.py +0 -0
  48. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Injections/__init__.py +0 -0
  49. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Injections/map_battery_graphics.py +0 -0
  50. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Injections/map_external_grid_graphics.py +0 -0
  51. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Injections/map_generator_graphics.py +0 -0
  52. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Injections/map_injections_template_graphics.py +0 -0
  53. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Injections/map_load_graphics.py +0 -0
  54. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Injections/map_static_generator_graphics.py +0 -0
  55. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Substation/__init__.py +0 -0
  56. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Substation/node_template.py +0 -0
  57. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Substation/substation_graphic_item.py +0 -0
  58. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Substation/voltage_level_graphic_item.py +0 -0
  59. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Tiles/TileProviders/__init__.py +0 -0
  60. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Tiles/TileProviders/blue_marble.py +0 -0
  61. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Tiles/TileProviders/cartodb.py +0 -0
  62. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Tiles/__init__.py +0 -0
  63. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Tiles/base_tiles.py +0 -0
  64. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Tiles/default_tile_data.py +0 -0
  65. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Tiles/pycacheback.py +0 -0
  66. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Tiles/tile_worker.py +0 -0
  67. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Tiles/tiles.py +0 -0
  68. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/Tiles/tiles_cache.py +0 -0
  69. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/__init__.py +0 -0
  70. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/grid_map_widget.py +0 -0
  71. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/MapWidget/map_widget.py +0 -0
  72. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Branches/__init__.py +0 -0
  73. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Branches/dc_line_graphics.py +0 -0
  74. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Branches/hvdc_graphics.py +0 -0
  75. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Branches/line_graphics.py +0 -0
  76. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Branches/line_graphics_template.py +0 -0
  77. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Branches/series_reactance_graphics.py +0 -0
  78. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Branches/switch_graphics.py +0 -0
  79. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Branches/transformer2w_graphics.py +0 -0
  80. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Branches/transformer3w_graphics.py +0 -0
  81. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Branches/upfc_graphics.py +0 -0
  82. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Branches/vsc_graphics.py +0 -0
  83. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Branches/vsc_graphics_3term.py +0 -0
  84. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Branches/winding_graphics.py +0 -0
  85. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Fluid/__init__.py +0 -0
  86. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Fluid/fluid_node_graphics.py +0 -0
  87. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Fluid/fluid_p2x_graphics.py +0 -0
  88. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Fluid/fluid_path_graphics.py +0 -0
  89. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Fluid/fluid_pump_graphics.py +0 -0
  90. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Fluid/fluid_turbine_graphics.py +0 -0
  91. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Injections/__init__.py +0 -0
  92. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Injections/battery_graphics.py +0 -0
  93. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Injections/controllable_shunt_graphics.py +0 -0
  94. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Injections/current_injection_graphics.py +0 -0
  95. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Injections/external_grid_graphics.py +0 -0
  96. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Injections/generator_graphics.py +0 -0
  97. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Injections/injections_template_graphics.py +0 -0
  98. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Injections/load_graphics.py +0 -0
  99. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Injections/shunt_graphics.py +0 -0
  100. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Injections/static_generator_graphics.py +0 -0
  101. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Substation/__init__.py +0 -0
  102. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/Substation/bus_graphics.py +0 -0
  103. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/__init__.py +0 -0
  104. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/matplotlibwidget.py +0 -0
  105. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/SchematicWidget/terminal_item.py +0 -0
  106. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/__init__.py +0 -0
  107. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/base_diagram_widget.py +0 -0
  108. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/diagrams_model.py +0 -0
  109. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/generic_graphics.py +0 -0
  110. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Diagrams/graphics_manager.py +0 -0
  111. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/GridGenerator/__init__.py +0 -0
  112. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/GridGenerator/grid_generator_dialogue.py +0 -0
  113. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/GridGenerator/gui.py +0 -0
  114. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/GridGenerator/icons_rc.py +0 -0
  115. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/GridGenerator/update_gui_file.py +0 -0
  116. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/GridMerge/__init__.py +0 -0
  117. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/GridMerge/build_diff_tree.py +0 -0
  118. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/GridMerge/grid_diff.py +0 -0
  119. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/GridMerge/grid_diff_gui.py +0 -0
  120. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/GridMerge/grid_merge.py +0 -0
  121. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/GridMerge/grid_merge_gui.py +0 -0
  122. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/GridMerge/update_gui_file.py +0 -0
  123. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/GridReduce/__init__.py +0 -0
  124. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/GridReduce/update_gui_file.py +0 -0
  125. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/LoadCatalogue/SelectComponents.py +0 -0
  126. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/LoadCatalogue/__init__.py +0 -0
  127. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/LoadCatalogue/catalogue_dialogue.py +0 -0
  128. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/LoadCatalogue/icons_rc.py +0 -0
  129. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/LoadCatalogue/update_gui_file.py +0 -0
  130. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/LoadDesigner/__init__.py +0 -0
  131. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/LoadDesigner/icons_rc.py +0 -0
  132. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/LoadDesigner/load_designer.py +0 -0
  133. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/LoadDesigner/load_designer_ui.py +0 -0
  134. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/LoadDesigner/update_gui_file.py +0 -0
  135. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/ConsoleLog.py +0 -0
  136. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/ConsoleLogController.py +0 -0
  137. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/MainWindow.py +0 -0
  138. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/SubClasses/Model/__init__.py +0 -0
  139. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/SubClasses/Model/compiled_arrays.py +0 -0
  140. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/SubClasses/Model/compiled_arrays_model.py +0 -0
  141. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/SubClasses/Model/time_events.py +0 -0
  142. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/SubClasses/README.txt +0 -0
  143. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/SubClasses/Results/__init__.py +0 -0
  144. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/SubClasses/Results/results.py +0 -0
  145. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/SubClasses/Scripting/__init__.py +0 -0
  146. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/SubClasses/Scripting/scripting.py +0 -0
  147. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/SubClasses/Server/__init__.py +0 -0
  148. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/SubClasses/Server/server.py +0 -0
  149. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/SubClasses/Settings/__init__.py +0 -0
  150. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/SubClasses/Settings/configuration.py +0 -0
  151. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/SubClasses/__init__.py +0 -0
  152. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/SubClasses/base_gui.py +0 -0
  153. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/SubClasses/io.py +0 -0
  154. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/VeraGridMain.py +0 -0
  155. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/__init__.py +0 -0
  156. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/icons_rc.py +0 -0
  157. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/object_select_window.py +0 -0
  158. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Main/update_gui_file.py +0 -0
  159. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/ProfilesInput/__init__.py +0 -0
  160. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/ProfilesInput/excel_dialog.py +0 -0
  161. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/ProfilesInput/excel_sheet_selection.py +0 -0
  162. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/ProfilesInput/icons_rc.py +0 -0
  163. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/ProfilesInput/models_dialogue.py +0 -0
  164. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/ProfilesInput/profile_dialogue.py +0 -0
  165. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/ProfilesInput/profiles_from_data_gui.py +0 -0
  166. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/ProfilesInput/profiles_from_models_gui.py +0 -0
  167. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/ProfilesInput/update_gui_file.py +0 -0
  168. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/RmsModelEditor/__init__.py +0 -0
  169. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/RmsModelEditor/block_data_dialogue.py +0 -0
  170. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/RmsModelEditor/icons_rc.py +0 -0
  171. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/RmsModelEditor/rms_model_editor.py +0 -0
  172. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/RmsModelEditor/rms_model_editor_engine.py +0 -0
  173. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/RmsModelEditor/update_gui_file.py +0 -0
  174. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/RosetaExplorer/MainWindow.py +0 -0
  175. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/RosetaExplorer/RosetaExplorer.py +0 -0
  176. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/RosetaExplorer/__init__.py +0 -0
  177. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/RosetaExplorer/icons_rc.py +0 -0
  178. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/RosetaExplorer/roseta_objects_model.py +0 -0
  179. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/RosetaExplorer/update_gui_file.py +0 -0
  180. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SigmaAnalysis/__init__.py +0 -0
  181. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SigmaAnalysis/gui.py +0 -0
  182. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SigmaAnalysis/icons_rc.py +0 -0
  183. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SigmaAnalysis/sigma_analysis_dialogue.py +0 -0
  184. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SigmaAnalysis/update_gui_file.py +0 -0
  185. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SolarPowerWizard/__init__.py +0 -0
  186. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SolarPowerWizard/gui.py +0 -0
  187. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SolarPowerWizard/icons_rc.py +0 -0
  188. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SolarPowerWizard/solar_power_wizzard.py +0 -0
  189. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SolarPowerWizard/update_gui_file.py +0 -0
  190. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SubstationDesigner/__init__.py +0 -0
  191. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SubstationDesigner/substation_designer.py +0 -0
  192. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SubstationDesigner/substation_designer_gui.py +0 -0
  193. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SubstationDesigner/update_gui_file.py +0 -0
  194. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SubstationDesigner/voltage_level_conversion.py +0 -0
  195. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SyncDialogue/__init__.py +0 -0
  196. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SyncDialogue/gui.py +0 -0
  197. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SyncDialogue/icons_rc.py +0 -0
  198. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SyncDialogue/sync_dialogue.py +0 -0
  199. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SyncDialogue/update_gui_file.py +0 -0
  200. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SystemScaler/__init__.py +0 -0
  201. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SystemScaler/icons_rc.py +0 -0
  202. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SystemScaler/system_scaler.py +0 -0
  203. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SystemScaler/system_scaler_ui.py +0 -0
  204. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/SystemScaler/update_gui_file.py +0 -0
  205. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/TowerBuilder/LineBuilderDialogue.py +0 -0
  206. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/TowerBuilder/__init__.py +0 -0
  207. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/TowerBuilder/icons_rc.py +0 -0
  208. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/TowerBuilder/table_models.py +0 -0
  209. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/TowerBuilder/tower_builder.py +0 -0
  210. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/TowerBuilder/update_gui_file.py +0 -0
  211. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/TreeModelViewer/MainWindow.py +0 -0
  212. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/TreeModelViewer/TreeModelViewer.py +0 -0
  213. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/TreeModelViewer/__init__.py +0 -0
  214. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/TreeModelViewer/icons_rc.py +0 -0
  215. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/TreeModelViewer/update_gui_file.py +0 -0
  216. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Visualization/__init__.py +0 -0
  217. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Visualization/visualization.py +0 -0
  218. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Widgets/__init__.py +0 -0
  219. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Widgets/custom_qrangeslider.py +0 -0
  220. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/Widgets/matplotlibwidget.py +0 -0
  221. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/WindPowerWizard/__init__.py +0 -0
  222. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/WindPowerWizard/gui.py +0 -0
  223. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/WindPowerWizard/icons_rc.py +0 -0
  224. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/WindPowerWizard/update_gui_file.py +0 -0
  225. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/WindPowerWizard/wind_power_wizzard.py +0 -0
  226. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/__init__.py +0 -0
  227. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/associations_model.py +0 -0
  228. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/correct_icons.py +0 -0
  229. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/general_dialogues.py +0 -0
  230. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/gui_functions.py +0 -0
  231. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/messages.py +0 -0
  232. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/object_model.py +0 -0
  233. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/object_proxy_model.py +0 -0
  234. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/pandas_model.py +0 -0
  235. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/plot_config.py +0 -0
  236. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/profiles_model.py +0 -0
  237. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/python_console.py +0 -0
  238. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/python_highlighter.py +0 -0
  239. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/results_model.py +0 -0
  240. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/rms_events_editor_dialog.py +0 -0
  241. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/rms_plot_variables_dialog.py +0 -0
  242. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/table_view_header_wrap.py +0 -0
  243. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/themes.py +0 -0
  244. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/toast_widget.py +0 -0
  245. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/update_gui_all.py +0 -0
  246. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/update_gui_common.py +0 -0
  247. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Gui/wrappable_table_model.py +0 -0
  248. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/LICENSE.txt +0 -0
  249. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Session/__init__.py +0 -0
  250. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Session/export_results_driver.py +0 -0
  251. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Session/file_handler.py +0 -0
  252. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Session/server_driver.py +0 -0
  253. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Session/session.py +0 -0
  254. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/Session/synchronization_driver.py +0 -0
  255. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/__init__.py +0 -0
  256. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/darkdetect/__init__.py +0 -0
  257. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/darkdetect/_dummy.py +0 -0
  258. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/darkdetect/_linux_detect.py +0 -0
  259. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/darkdetect/_mac_detect.py +0 -0
  260. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/darkdetect/_windows_detect.py +0 -0
  261. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/__init__.py +0 -0
  262. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/_color.py +0 -0
  263. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/_icon/__init__.py +0 -0
  264. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/_icon/icon_engine.py +0 -0
  265. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/_icon/svg.py +0 -0
  266. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/_main.py +0 -0
  267. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/_os_appearance/__init__.py +0 -0
  268. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/_os_appearance/_accent/__init__.py +0 -0
  269. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/_os_appearance/_accent/_mac_detect.py +0 -0
  270. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/_os_appearance/listener.py +0 -0
  271. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/_proxy_style.py +0 -0
  272. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/_resources/__init__.py +0 -0
  273. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/_resources/colors.py +0 -0
  274. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/_resources/palette.py +0 -0
  275. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/_resources/standard_icons.py +0 -0
  276. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/_resources/stylesheets.py +0 -0
  277. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/_resources/svg.py +0 -0
  278. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/_style_loader.py +0 -0
  279. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/_template/__init__.py +0 -0
  280. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/_template/engine.py +0 -0
  281. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/_template/filter.py +0 -0
  282. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/_util.py +0 -0
  283. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/qtpy/QtCore/__init__.py +0 -0
  284. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/qtpy/QtGui/__init__.py +0 -0
  285. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/qtpy/QtSvg/__init__.py +0 -0
  286. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/qtpy/QtWidgets/__init__.py +0 -0
  287. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/qtpy/__init__.py +0 -0
  288. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/qtpy/qt_compat.py +0 -0
  289. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/qtpy/qt_version.py +0 -0
  290. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/widget_gallery/__init__.py +0 -0
  291. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/widget_gallery/__main__.py +0 -0
  292. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/widget_gallery/_ui/__init__.py +0 -0
  293. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/widget_gallery/_ui/dock_ui.py +0 -0
  294. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/widget_gallery/_ui/frame_ui.py +0 -0
  295. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/widget_gallery/_ui/icons_ui.py +0 -0
  296. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/widget_gallery/_ui/mdi_ui.py +0 -0
  297. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/widget_gallery/_ui/widgets_ui.py +0 -0
  298. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/ThirdParty/qdarktheme/widget_gallery/main_window.py +0 -0
  299. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/__init__.py +0 -0
  300. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/data/VeraGrid.ico +0 -0
  301. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/data/VeraGrid.svg +0 -0
  302. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/data/__init__.py +0 -0
  303. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/data/cables.csv +0 -0
  304. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/data/sequence_lines.csv +0 -0
  305. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/data/transformers.csv +0 -0
  306. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/data/wires.csv +0 -0
  307. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/plugins.py +0 -0
  308. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/templates.py +0 -0
  309. {veragrid-5.6.2 → veragrid-5.6.3}/VeraGrid/update.py +0 -0
  310. {veragrid-5.6.2 → veragrid-5.6.3}/setup.cfg +0 -0
  311. {veragrid-5.6.2 → veragrid-5.6.3}/setup.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: VeraGrid
3
- Version: 5.6.2
3
+ Version: 5.6.3
4
4
  Summary: VeraGrid is a Power Systems simulation program intended for professional use and research
5
5
  Home-page: https://github.com/SanPen/VeraGrid
6
6
  Author: Santiago Peñate Vera et. Al.
@@ -3,14 +3,13 @@
3
3
  # file, You can obtain one at https://mozilla.org/MPL/2.0/.
4
4
  # SPDX-License-Identifier: MPL-2.0
5
5
  from __future__ import annotations
6
- from typing import List, Union, Any, TYPE_CHECKING
7
- from PySide6 import QtCore, QtGui, QtWidgets
8
- from PySide6.QtWidgets import (QApplication, QDialog, QTableView, QVBoxLayout, QPushButton, QHBoxLayout,
9
- QLabel, QComboBox, QSpacerItem, QSizePolicy)
6
+ from typing import List, TYPE_CHECKING
7
+ from PySide6 import QtWidgets
8
+ from PySide6.QtWidgets import (QVBoxLayout, QPushButton)
10
9
 
11
10
  from VeraGrid.Gui.Diagrams.SchematicWidget.schematic_widget import (SchematicWidget, make_diagram_from_buses,
12
11
  SchematicDiagram)
13
- from VeraGridEngine.Devices.Substation.substation import Substation
12
+ from VeraGridEngine.Devices.Substation.substation import Substation, DeviceType
14
13
  from VeraGridEngine.Devices.Substation.bus import Bus
15
14
  from VeraGridEngine.Devices.multi_circuit import MultiCircuit
16
15
 
@@ -38,7 +37,7 @@ class DiagramBusSelectorDialogue(QtWidgets.QDialog):
38
37
 
39
38
  self.layout = QVBoxLayout(self)
40
39
 
41
- selected_buses = grid.get_buses_from_objects(elements=[substation])
40
+ selected_buses = grid.get_buses_from_objects(elements=[substation], dtype=DeviceType.SubstationDevice)
42
41
 
43
42
  if len(selected_buses):
44
43
  diagram = make_diagram_from_buses(circuit=grid,
@@ -4735,7 +4735,7 @@ class SchematicWidget(BaseDiagramWidget):
4735
4735
  vl_wizard.setModal(True)
4736
4736
  vl_wizard.exec() # waits until closed
4737
4737
 
4738
- if vl_wizard.closed_ok is not None:
4738
+ if vl_wizard.closed_ok:
4739
4739
  (new_buses,
4740
4740
  conn_buses,
4741
4741
  associated_branches,
@@ -10,15 +10,16 @@ import numpy as np
10
10
  from VeraGrid.Gui.GridReduce.grid_reduce_gui import Ui_ReduceDialog
11
11
  from VeraGrid.Gui.general_dialogues import LogsDialogue
12
12
  from VeraGrid.Gui.messages import yes_no_question, warning_msg
13
- from VeraGrid.Gui.gui_functions import get_list_model
13
+ from VeraGrid.Gui.gui_functions import get_list_model, enums_to_model
14
14
  from VeraGrid.Session.session import SimulationSession
15
15
  from VeraGridEngine.Devices.Substation.bus import Bus
16
16
  from VeraGridEngine.Devices.multi_circuit import MultiCircuit
17
17
  from VeraGridEngine.Topology.GridReduction.di_shi_grid_reduction import di_shi_reduction
18
- from VeraGridEngine.Topology.GridReduction.ptdf_grid_reduction import ptdf_reduction, ptdf_reduction_projected, ptdf_reduction_ree_bad, ptdf_reduction_ree_less_bad
18
+ from VeraGridEngine.Topology.GridReduction.ptdf_grid_reduction import ptdf_reduction, ptdf_reduction_projected, \
19
+ ptdf_reduction_ree_bad, ptdf_reduction_ree_less_bad
19
20
  from VeraGridEngine.Topology.GridReduction.ward_equivalents import ward_standard_reduction
20
21
  from VeraGridEngine.basic_structures import Logger
21
- from VeraGridEngine.enumerations import GridReductionMethod
22
+ from VeraGridEngine.enumerations import GridReductionMethod, BusReductionMethod
22
23
 
23
24
 
24
25
  class GridReduceDialogue(QtWidgets.QDialog):
@@ -44,12 +45,18 @@ class GridReduceDialogue(QtWidgets.QDialog):
44
45
 
45
46
  self.ui.listView.setModel(get_list_model(list(selected_buses_set)))
46
47
 
47
- methods = [GridReductionMethod.PTDF,
48
- GridReductionMethod.PTDFProjected,
49
- GridReductionMethod.DiShi,
50
- GridReductionMethod.Ward]
51
- self.methods_dict = {m.value: m for m in methods}
52
- self.ui.methodComboBox.setModel(get_list_model([m.value for m in methods]))
48
+ self.methods_dict, methods_mdl = enums_to_model(
49
+ [GridReductionMethod.PTDF,
50
+ GridReductionMethod.PTDFProjected,
51
+ GridReductionMethod.DiShi,
52
+ GridReductionMethod.Ward]
53
+ )
54
+ self.ui.methodComboBox.setModel(methods_mdl)
55
+
56
+ self.bus_methods_dict, bus_methods_mdl = enums_to_model(
57
+ [BusReductionMethod.Reduce, BusReductionMethod.Keep]
58
+ )
59
+ self.ui.busModeComboBox.setModel(bus_methods_mdl)
53
60
 
54
61
  self._grid: MultiCircuit = grid
55
62
  self._session: SimulationSession = session
@@ -59,7 +66,7 @@ class GridReduceDialogue(QtWidgets.QDialog):
59
66
 
60
67
  self.ui.reduceButton.clicked.connect(self.reduce_grid)
61
68
 
62
- def reduce_grid(self):
69
+ def reduce_grid(self) -> None:
63
70
  """
64
71
  The elements of the grid will be added with new idtags.
65
72
  This is useful in the case you want to compose a new grid from grids that are the same.
@@ -67,21 +74,39 @@ class GridReduceDialogue(QtWidgets.QDialog):
67
74
  """
68
75
  if len(self._selected_buses_set):
69
76
 
70
- method: GridReductionMethod = self.methods_dict[self.ui.methodComboBox.currentText()]
77
+ reduction_method: GridReductionMethod = self.methods_dict[self.ui.methodComboBox.currentText()]
78
+ bus_mode: BusReductionMethod = self.bus_methods_dict[self.ui.busModeComboBox.currentText()]
79
+
80
+ if bus_mode == BusReductionMethod.Reduce:
81
+ text = f"This will delete the selected buses and reintroduce their influence."
82
+ else:
83
+ text = "This will keep the selected buses and delete all others, reintroducing their influence."
84
+
85
+ text += f"using the {reduction_method.value} equivalent. "
86
+ "This cannot be undone and it is dangerous if you don't know"
87
+ "what you are doing \nAre you sure?"
71
88
 
72
89
  ok = yes_no_question(
73
- text="This will delete the selected buses and reintroduce their influence"
74
- "using the Ward equivalent. This cannot be undone and it is dangerous if you don't know"
75
- "what you are doing \nAre you sure?",
90
+ text=text,
76
91
  title="Grid reduction?")
77
92
 
78
93
  if ok:
79
94
 
80
- # convert the set of buses to bus indices
81
- reduction_bus_indices = np.array([self._grid.buses.index(b) for b in self._selected_buses_set],
82
- dtype=int)
95
+ if bus_mode == BusReductionMethod.Reduce:
96
+ # convert the set of buses to bus indices
97
+ reduction_bus_indices = np.array([self._grid.buses.index(b)
98
+ for b in self._selected_buses_set],
99
+ dtype=int)
100
+
101
+ elif bus_mode == BusReductionMethod.Keep:
102
+ # the the other buses that are not in the set
103
+ reduction_bus_indices = np.array([i for i in range(self._grid.get_bus_number())
104
+ if self._grid.buses[i] not in self._selected_buses_set],
105
+ dtype=int)
106
+ else:
107
+ raise NotImplementedError(f"BusReductionMethod not implemented: {bus_mode.value}")
83
108
 
84
- if method == GridReductionMethod.DiShi:
109
+ if reduction_method == GridReductionMethod.DiShi:
85
110
 
86
111
  # get the previous power flow
87
112
  _, pf_res = self._session.power_flow
@@ -97,7 +122,7 @@ class GridReduceDialogue(QtWidgets.QDialog):
97
122
  V0=pf_res.voltage
98
123
  )
99
124
 
100
- elif method == GridReductionMethod.Ward:
125
+ elif reduction_method == GridReductionMethod.Ward:
101
126
 
102
127
  # get the previous power flow
103
128
  _, pf_res = self._session.power_flow
@@ -113,7 +138,7 @@ class GridReduceDialogue(QtWidgets.QDialog):
113
138
  V0=pf_res.voltage,
114
139
  )
115
140
 
116
- elif method == GridReductionMethod.PTDF:
141
+ elif reduction_method == GridReductionMethod.PTDF:
117
142
 
118
143
  # NOTE: self._grid gets reduced in-place
119
144
  grid_reduced, logger = ptdf_reduction(
@@ -121,16 +146,16 @@ class GridReduceDialogue(QtWidgets.QDialog):
121
146
  reduction_bus_indices=reduction_bus_indices,
122
147
  )
123
148
 
124
- elif method == GridReductionMethod.PTDFProjected:
149
+ elif reduction_method == GridReductionMethod.PTDFProjected:
125
150
 
126
151
  # NOTE: self._grid gets reduced in-place
127
-
152
+
128
153
  # get the options from the linear analysis driver
129
154
  lin_drv, _ = self._session.linear_power_flow
130
155
  distribute_slack = True
131
156
  if lin_drv is not None:
132
157
  distribute_slack = lin_drv.options.distribute_slack
133
-
158
+
134
159
  grid_reduced, logger = ptdf_reduction_projected(
135
160
  grid=self._grid,
136
161
  reduction_bus_indices=reduction_bus_indices,
@@ -48,6 +48,11 @@ class Ui_ReduceDialog(object):
48
48
  self.horizontalLayout = QHBoxLayout(self.frame)
49
49
  self.horizontalLayout.setObjectName(u"horizontalLayout")
50
50
  self.horizontalLayout.setContentsMargins(0, 0, 0, 0)
51
+ self.busModeComboBox = QComboBox(self.frame)
52
+ self.busModeComboBox.setObjectName(u"busModeComboBox")
53
+
54
+ self.horizontalLayout.addWidget(self.busModeComboBox)
55
+
51
56
  self.methodComboBox = QComboBox(self.frame)
52
57
  self.methodComboBox.setObjectName(u"methodComboBox")
53
58
 
@@ -73,6 +78,8 @@ class Ui_ReduceDialog(object):
73
78
 
74
79
  def retranslateUi(self, ReduceDialog):
75
80
  ReduceDialog.setWindowTitle(QCoreApplication.translate("ReduceDialog", u"Grid Merge", None))
81
+ self.busModeComboBox.setPlaceholderText(QCoreApplication.translate("ReduceDialog", u"Buses", None))
82
+ self.methodComboBox.setPlaceholderText(QCoreApplication.translate("ReduceDialog", u"Method", None))
76
83
  #if QT_CONFIG(tooltip)
77
84
  self.reduceButton.setToolTip(QCoreApplication.translate("ReduceDialog", u"Aply the selected changes", None))
78
85
  #endif // QT_CONFIG(tooltip)
@@ -407,7 +407,7 @@ class DataBaseTableMain(DiagramsMain):
407
407
  source_model = proxy_model.sourceModel()
408
408
 
409
409
  sel_idx = self.ui.dataStructureTableView.selectedIndexes()
410
- objects = source_model.objects if hasattr(source_model, 'objects') else []
410
+ objects: List[ALL_DEV_TYPES] = source_model.objects if hasattr(source_model, 'objects') else []
411
411
 
412
412
  if len(objects) > 0:
413
413
 
@@ -419,7 +419,8 @@ class DataBaseTableMain(DiagramsMain):
419
419
  sel_obj: ALL_DEV_TYPES = source_model.objects[idx]
420
420
  selected_objects.append(sel_obj)
421
421
 
422
- buses = self.circuit.get_buses_from_objects(elements=selected_objects)
422
+ buses = self.circuit.get_buses_from_objects(elements=selected_objects,
423
+ dtype=objects[0].device_type)
423
424
 
424
425
  return buses, selected_objects
425
426
 
@@ -699,8 +700,19 @@ class DataBaseTableMain(DiagramsMain):
699
700
  self.grid_reduction_dialogue.exec()
700
701
 
701
702
  if self.grid_reduction_dialogue.did_reduce:
703
+
704
+ # delete from the diagrams
702
705
  self.delete_from_all_diagrams(elements=list(selected_buses))
703
706
 
707
+ # update the view
708
+ self.view_objects_data()
709
+ self.update_from_to_list_views()
710
+ self.update_date_dependent_combos()
711
+ else:
712
+ self.show_warning_toast("No reduction done")
713
+ else:
714
+ self.show_warning_toast("Select some elements first")
715
+
704
716
  def grid_reduction_from_schematic_selection(self):
705
717
  """
706
718
  Call the grid reduction dialogue on the schematic selection
@@ -1011,8 +1023,6 @@ class DataBaseTableMain(DiagramsMain):
1011
1023
  # # update event
1012
1024
  # self.circuit.rms_events[idx] = self.rms_events_Editor_window.get_updated_event()
1013
1025
 
1014
-
1015
-
1016
1026
  else:
1017
1027
 
1018
1028
  warning_msg('No editor available.\n'
@@ -1964,7 +1964,8 @@ class DiagramsMain(CompiledArraysMain):
1964
1964
  title="Substations schematic")
1965
1965
  return
1966
1966
 
1967
- selected_buses = self.circuit.get_buses_from_objects(elements=substations)
1967
+ selected_buses = self.circuit.get_buses_from_objects(elements=substations,
1968
+ dtype=DeviceType.SubstationDevice)
1968
1969
 
1969
1970
  if len(selected_buses):
1970
1971
  diagram = make_diagram_from_buses(circuit=self.circuit,
@@ -2005,7 +2006,8 @@ class DiagramsMain(CompiledArraysMain):
2005
2006
  self.show_error_toast("The current diagram is not a schematic :(")
2006
2007
  return
2007
2008
 
2008
- selected_buses = self.circuit.get_buses_from_objects(elements=substations)
2009
+ selected_buses = self.circuit.get_buses_from_objects(elements=substations,
2010
+ dtype=DeviceType.SubstationDevice)
2009
2011
 
2010
2012
  if len(selected_buses):
2011
2013
  diagram_widget.add_buses(selected_buses)
@@ -60,39 +60,45 @@ class SimulationsMain(TimeEventsMain):
60
60
  self._remote_jobs: Dict[str, RemoteJobDriver] = dict()
61
61
 
62
62
  # Power Flow Methods
63
- self.se_solvers_dict, se_solvers_mdl = gf.enums_to_model([SolverType.NR,
64
- SolverType.LM,
65
- SolverType.GN])
63
+ self.se_solvers_dict, se_solvers_mdl = gf.enums_to_model(
64
+ [SolverType.NR,
65
+ SolverType.LM,
66
+ SolverType.GN]
67
+ )
66
68
  self.ui.se_solver_comboBox.setModel(se_solvers_mdl)
67
69
  self.ui.se_solver_comboBox.setCurrentIndex(0)
68
70
 
69
71
  # SE Methods
70
- self.solvers_dict, solvers_mdl = gf.enums_to_model([SolverType.NR,
71
- SolverType.IWAMOTO,
72
- SolverType.LM,
73
- SolverType.PowellDogLeg,
74
- SolverType.FASTDECOUPLED,
75
- SolverType.HELM,
76
- SolverType.GAUSS,
77
- SolverType.LACPF,
78
- SolverType.Linear])
72
+ self.solvers_dict, solvers_mdl = gf.enums_to_model(
73
+ [SolverType.NR,
74
+ SolverType.IWAMOTO,
75
+ SolverType.LM,
76
+ SolverType.PowellDogLeg,
77
+ SolverType.FASTDECOUPLED,
78
+ SolverType.HELM,
79
+ SolverType.GAUSS,
80
+ SolverType.LACPF,
81
+ SolverType.Linear]
82
+ )
79
83
  self.ui.solver_comboBox.setModel(solvers_mdl)
80
84
  self.ui.solver_comboBox.setCurrentIndex(0)
81
85
 
82
86
  # transfer modes
83
- self.transfer_modes_dict = OrderedDict()
84
- self.transfer_modes_dict['Area generation'] = AvailableTransferMode.Generation
85
- self.transfer_modes_dict['Area installed power'] = AvailableTransferMode.InstalledPower
86
- self.transfer_modes_dict['Area load'] = AvailableTransferMode.Load
87
- self.transfer_modes_dict['Area nodes'] = AvailableTransferMode.GenerationAndLoad
88
- lst = list(self.transfer_modes_dict.keys())
89
- self.ui.transferMethodComboBox.setModel(gf.get_list_model(lst))
87
+ self.transfer_modes_dict, transfer_modes_mdl = gf.enums_to_model(
88
+ [AvailableTransferMode.Generation,
89
+ AvailableTransferMode.InstalledPower,
90
+ AvailableTransferMode.Load,
91
+ AvailableTransferMode.GenerationAndLoad]
92
+ )
93
+ self.ui.transferMethodComboBox.setModel(transfer_modes_mdl)
90
94
  self.ui.transferMethodComboBox.setCurrentIndex(1)
91
95
 
92
96
  # opf solvers dictionary
93
- self.lp_solvers_dict, lp_solvers_mdl = gf.enums_to_model([SolverType.LINEAR_OPF,
94
- SolverType.NONLINEAR_OPF,
95
- SolverType.GREEDY_DISPATCH_OPF])
97
+ self.lp_solvers_dict, lp_solvers_mdl = gf.enums_to_model(
98
+ [SolverType.LINEAR_OPF,
99
+ SolverType.NONLINEAR_OPF,
100
+ SolverType.GREEDY_DISPATCH_OPF]
101
+ )
96
102
  self.ui.lpf_solver_comboBox.setModel(lp_solvers_mdl)
97
103
 
98
104
  # opf dispatch methods
@@ -104,43 +110,47 @@ class SimulationsMain(TimeEventsMain):
104
110
  )
105
111
  self.ui.opfDispatchModeComboBox.setModel(opf_dispatch_mode_mdl)
106
112
 
113
+ # MIP frameworks
107
114
  self.opf_mip_framework_dict, opf_mip_framework_mdl = gf.enums_to_model(
108
115
  get_available_mip_frameworks()
109
116
  )
110
117
  self.ui.mip_framework_comboBox.setModel(opf_mip_framework_mdl)
111
118
 
112
119
  # reliability modes
113
- self.reliability_mode_dict = OrderedDict()
114
- self.reliability_mode_dict[ReliabilityMode.GenerationAdequacy.value] = ReliabilityMode.GenerationAdequacy
115
- self.reliability_mode_dict[ReliabilityMode.GridMetrics.value] = ReliabilityMode.GridMetrics
116
- self.ui.reliability_method_comboBox.setModel(gf.get_list_model(list(self.reliability_mode_dict.keys())))
120
+ (self.reliability_mode_dict,
121
+ reliability_mode_dict_mdl) = gf.enums_to_model(
122
+ [ReliabilityMode.GenerationAdequacy,
123
+ ReliabilityMode.GridMetrics]
124
+ )
125
+ self.ui.reliability_method_comboBox.setModel(reliability_mode_dict_mdl)
117
126
 
118
127
  # ips solvers dictionary
119
- self.ips_solvers_dict = OrderedDict()
120
- self.ips_solvers_dict[SolverType.NR.value] = SolverType.NR
121
- self.ui.ips_method_comboBox.setModel(gf.get_list_model(list(self.ips_solvers_dict.keys())))
128
+ (self.ips_solvers_dict,
129
+ ips_solvers_dict_mdl) = gf.enums_to_model(
130
+ [SolverType.NR]
131
+ )
132
+ self.ui.ips_method_comboBox.setModel(ips_solvers_dict_mdl)
122
133
 
123
134
  # the MIP combobox models assigning is done in modify_ui_options_according_to_the_engine
124
- self.mip_solvers_dict = OrderedDict()
125
- self.mip_solvers_dict[MIPSolvers.HIGHS.value] = MIPSolvers.HIGHS
126
- self.mip_solvers_dict[MIPSolvers.SCIP.value] = MIPSolvers.SCIP
127
- self.mip_solvers_dict[MIPSolvers.CPLEX.value] = MIPSolvers.CPLEX
128
- self.mip_solvers_dict[MIPSolvers.GUROBI.value] = MIPSolvers.GUROBI
129
- self.mip_solvers_dict[MIPSolvers.XPRESS.value] = MIPSolvers.XPRESS
130
- self.mip_solvers_dict[MIPSolvers.CBC.value] = MIPSolvers.CBC
131
- self.mip_solvers_dict[MIPSolvers.PDLP.value] = MIPSolvers.PDLP
135
+ (self.mip_solvers_dict,
136
+ mip_solvers_dict_mdl) = gf.enums_to_model(
137
+ [MIPSolvers.HIGHS,
138
+ MIPSolvers.SCIP,
139
+ MIPSolvers.CPLEX,
140
+ MIPSolvers.GUROBI,
141
+ MIPSolvers.XPRESS,
142
+ MIPSolvers.CBC,
143
+ MIPSolvers.PDLP]
144
+ )
132
145
 
133
146
  # opf solvers dictionary
134
- self.nodal_capacity_methods_dict = OrderedDict()
135
-
136
- for val in [NodalCapacityMethod.LinearOptimization,
137
- NodalCapacityMethod.NonlinearOptimization,
138
- NodalCapacityMethod.CPF]:
139
- self.nodal_capacity_methods_dict[val.value] = val
140
-
141
- self.ui.nodal_capacity_method_comboBox.setModel(
142
- gf.get_list_model(list(self.nodal_capacity_methods_dict.keys()))
147
+ (self.nodal_capacity_methods_dict,
148
+ nodal_capacity_methods_mdl) = gf.enums_to_model(
149
+ [NodalCapacityMethod.LinearOptimization,
150
+ NodalCapacityMethod.NonlinearOptimization,
151
+ NodalCapacityMethod.CPF]
143
152
  )
153
+ self.ui.nodal_capacity_method_comboBox.setModel(nodal_capacity_methods_mdl)
144
154
 
145
155
  # branch types for reduction
146
156
  mdl = gf.get_list_model([DeviceType.LineDevice.value,
@@ -148,19 +158,23 @@ class SimulationsMain(TimeEventsMain):
148
158
  self.ui.removeByTypeListView.setModel(mdl)
149
159
 
150
160
  # OPF grouping modes
151
- self.opf_time_groups = OrderedDict()
152
- self.opf_time_groups[TimeGrouping.NoGrouping.value] = TimeGrouping.NoGrouping
153
- self.opf_time_groups[TimeGrouping.Monthly.value] = TimeGrouping.Monthly
154
- self.opf_time_groups[TimeGrouping.Weekly.value] = TimeGrouping.Weekly
155
- self.opf_time_groups[TimeGrouping.Daily.value] = TimeGrouping.Daily
156
- self.opf_time_groups[TimeGrouping.Hourly.value] = TimeGrouping.Hourly
157
- self.ui.opf_time_grouping_comboBox.setModel(gf.get_list_model(list(self.opf_time_groups.keys())))
158
-
159
- self.opf_zonal_groups = OrderedDict()
160
- self.opf_zonal_groups[ZonalGrouping.NoGrouping.value] = ZonalGrouping.NoGrouping
161
- # self.opf_zonal_groups[ZonalGrouping.Area.value] = ZonalGrouping.Area
162
- self.opf_zonal_groups[ZonalGrouping.All.value] = ZonalGrouping.All
163
- self.ui.opfZonalGroupByComboBox.setModel(gf.get_list_model(list(self.opf_zonal_groups.keys())))
161
+ (self.opf_time_groups,
162
+ opf_time_groups_mdl) = gf.enums_to_model(
163
+ [TimeGrouping.NoGrouping,
164
+ TimeGrouping.Monthly,
165
+ TimeGrouping.Weekly,
166
+ TimeGrouping.Daily,
167
+ TimeGrouping.Hourly]
168
+ )
169
+ self.ui.opf_time_grouping_comboBox.setModel(opf_time_groups_mdl)
170
+
171
+ # zonal opf grouping
172
+ (self.opf_zonal_groups,
173
+ opf_zonal_groups_mdl) = gf.enums_to_model(
174
+ [ZonalGrouping.NoGrouping,
175
+ ZonalGrouping.All]
176
+ )
177
+ self.ui.opfZonalGroupByComboBox.setModel(opf_zonal_groups_mdl)
164
178
 
165
179
  # voltage collapse mode (full, nose)
166
180
  self.ui.vc_stop_at_comboBox.setModel(gf.get_list_model([sim.CpfStopAt.Nose.value,
@@ -168,63 +182,56 @@ class SimulationsMain(TimeEventsMain):
168
182
  self.ui.vc_stop_at_comboBox.setCurrentIndex(0)
169
183
 
170
184
  # reactive power controls
171
- self.contingency_engines_dict = OrderedDict()
172
- self.contingency_engines_dict[ContingencyMethod.PowerFlow.value] = ContingencyMethod.PowerFlow
173
- # self.contingency_engines_dict[ContingencyMethod.OptimalPowerFlow.value] = ContingencyMethod.OptimalPowerFlow
174
- self.contingency_engines_dict[ContingencyMethod.Linear.value] = ContingencyMethod.Linear
175
- self.contingency_engines_dict[ContingencyMethod.PTDF_scan.value] = ContingencyMethod.PTDF_scan
176
- self.contingency_engines_dict[ContingencyMethod.HELM.value] = ContingencyMethod.HELM
177
- self.ui.contingencyEngineComboBox.setModel(gf.get_list_model(list(self.contingency_engines_dict.keys())))
185
+ (self.contingency_engines_dict,
186
+ contingency_engines_mdl) = gf.enums_to_model(
187
+ [ContingencyMethod.PowerFlow,
188
+ ContingencyMethod.Linear,
189
+ ContingencyMethod.PTDF_scan,
190
+ ContingencyMethod.HELM]
191
+ )
192
+ self.ui.contingencyEngineComboBox.setModel(contingency_engines_mdl)
178
193
 
179
194
  # list of stochastic power flow methods
180
- self.stochastic_pf_methods_dict = OrderedDict()
181
- self.stochastic_pf_methods_dict[
182
- sim.StochasticPowerFlowType.LatinHypercube.value] = sim.StochasticPowerFlowType.LatinHypercube
183
- self.stochastic_pf_methods_dict[
184
- sim.StochasticPowerFlowType.MonteCarlo.value] = sim.StochasticPowerFlowType.MonteCarlo
185
- mdl = gf.get_list_model(list(self.stochastic_pf_methods_dict.keys()))
186
- self.ui.stochastic_pf_method_comboBox.setModel(mdl)
195
+ (self.stochastic_pf_methods_dict,
196
+ stochastic_pf_methods_mdl) = gf.enums_to_model(
197
+ [sim.StochasticPowerFlowType.LatinHypercube,
198
+ sim.StochasticPowerFlowType.MonteCarlo]
199
+ )
200
+ self.ui.stochastic_pf_method_comboBox.setModel(stochastic_pf_methods_mdl)
187
201
 
188
202
  # investment evaluation methods
189
- investment_methods = [
190
- InvestmentEvaluationMethod.Independent,
191
- InvestmentEvaluationMethod.NSGA3,
192
- InvestmentEvaluationMethod.MVRSM,
193
- InvestmentEvaluationMethod.MixedVariableGA,
194
- ]
195
- self.investment_evaluation_method_dict = OrderedDict()
196
- self.plugins_investment_evaluation_method_dict = OrderedDict()
197
- lst = list()
198
- for method in investment_methods:
199
- self.investment_evaluation_method_dict[method.value] = method
200
- lst.append(method.value)
201
- self.ui.investment_evaluation_method_ComboBox.setModel(gf.get_list_model(lst))
203
+ (self.investment_evaluation_method_dict,
204
+ investment_evaluation_method_mdl) = gf.enums_to_model(
205
+ [InvestmentEvaluationMethod.Independent,
206
+ InvestmentEvaluationMethod.NSGA3,
207
+ InvestmentEvaluationMethod.MVRSM,
208
+ InvestmentEvaluationMethod.MixedVariableGA, ]
209
+ )
210
+ self.ui.investment_evaluation_method_ComboBox.setModel(investment_evaluation_method_mdl)
202
211
 
203
212
  # contingency filtering modes
204
- con_filters = [ContingencyFilteringMethods.AllActive,
205
- ContingencyFilteringMethods.Country,
206
- ContingencyFilteringMethods.Area,
207
- ContingencyFilteringMethods.Zone,
208
- ContingencyFilteringMethods.SensitiveToMonitored]
209
- self.contingency_filter_modes_dict = OrderedDict()
210
- con_filter_vals = list()
211
- for con_filter in con_filters:
212
- self.contingency_filter_modes_dict[con_filter.value] = con_filter
213
- con_filter_vals.append(con_filter.value)
214
- self.ui.contingency_filter_by_comboBox.setModel(gf.get_list_model(con_filter_vals))
215
-
216
- # ptdf grouping modes
217
- self.ptdf_group_modes = OrderedDict()
218
-
219
- self.investment_evaluation_objfunc_dict = OrderedDict()
220
- lst = list()
221
- for method in [InvestmentsEvaluationObjectives.PowerFlow,
222
- InvestmentsEvaluationObjectives.TimeSeriesPowerFlow,
223
- InvestmentsEvaluationObjectives.GenerationAdequacy,
224
- InvestmentsEvaluationObjectives.SimpleDispatch]:
225
- self.investment_evaluation_objfunc_dict[method.value] = method
226
- lst.append(method.value)
227
- self.ui.investment_evaluation_objfunc_ComboBox.setModel(gf.get_list_model(lst))
213
+ (self.contingency_filter_modes_dict,
214
+ contingency_filter_modes_mdl) = gf.enums_to_model(
215
+ [ContingencyFilteringMethods.AllActive,
216
+ ContingencyFilteringMethods.Country,
217
+ ContingencyFilteringMethods.Community,
218
+ ContingencyFilteringMethods.Region,
219
+ ContingencyFilteringMethods.Municipality,
220
+ ContingencyFilteringMethods.Area,
221
+ ContingencyFilteringMethods.Zone,
222
+ ContingencyFilteringMethods.SensitiveToMonitored]
223
+ )
224
+ self.ui.contingency_filter_by_comboBox.setModel(contingency_filter_modes_mdl)
225
+
226
+ # investment modes
227
+ (self.investment_evaluation_objfunc_dict,
228
+ investment_evaluation_objfunc_mdl) = gf.enums_to_model(
229
+ [InvestmentsEvaluationObjectives.PowerFlow,
230
+ InvestmentsEvaluationObjectives.TimeSeriesPowerFlow,
231
+ InvestmentsEvaluationObjectives.GenerationAdequacy,
232
+ InvestmentsEvaluationObjectives.SimpleDispatch]
233
+ )
234
+ self.ui.investment_evaluation_objfunc_ComboBox.setModel(investment_evaluation_objfunc_mdl)
228
235
 
229
236
  # dictionaries for available results
230
237
  self.available_results_dict: Union[Dict[str, Dict[str, ResultTypes]], None] = dict()
@@ -457,6 +464,21 @@ class SimulationsMain(TimeEventsMain):
457
464
  checks=True,
458
465
  check_value=True)
459
466
 
467
+ elif filter_mode == ContingencyFilteringMethods.Community:
468
+ mdl = gf.get_list_model(lst=[elm.name for elm in self.circuit.get_communities()],
469
+ checks=True,
470
+ check_value=True)
471
+
472
+ elif filter_mode == ContingencyFilteringMethods.Region:
473
+ mdl = gf.get_list_model(lst=[elm.name for elm in self.circuit.get_regions()],
474
+ checks=True,
475
+ check_value=True)
476
+
477
+ elif filter_mode == ContingencyFilteringMethods.Municipality:
478
+ mdl = gf.get_list_model(lst=[elm.name for elm in self.circuit.get_municipalities()],
479
+ checks=True,
480
+ check_value=True)
481
+
460
482
  elif filter_mode == ContingencyFilteringMethods.Area:
461
483
  mdl = gf.get_list_model(lst=[elm.name for elm in self.circuit.get_areas()],
462
484
  checks=True,
@@ -506,7 +528,40 @@ class SimulationsMain(TimeEventsMain):
506
528
  return self.circuit.get_contingency_groups_in(grouping_elements=[elements[i] for i in idx])
507
529
  else:
508
530
  # default to returning all groups, since it's safer
509
- return self.circuit.get_contingency_groups()
531
+ return self.circuit.get_contingency_groups_active()
532
+
533
+ elif filter_mode == ContingencyFilteringMethods.Community:
534
+
535
+ if self.circuit.get_communities_number() > 0:
536
+ # get the selection indices
537
+ idx = gf.get_checked_indices(self.ui.contingency_group_filter_listView.model())
538
+ elements = self.circuit.get_communities()
539
+ return self.circuit.get_contingency_groups_in(grouping_elements=[elements[i] for i in idx])
540
+ else:
541
+ # default to returning all groups, since it's safer
542
+ return self.circuit.get_contingency_groups_active()
543
+
544
+ elif filter_mode == ContingencyFilteringMethods.Region:
545
+
546
+ if self.circuit.get_regions_number() > 0:
547
+ # get the selection indices
548
+ idx = gf.get_checked_indices(self.ui.contingency_group_filter_listView.model())
549
+ elements = self.circuit.get_regions()
550
+ return self.circuit.get_contingency_groups_in(grouping_elements=[elements[i] for i in idx])
551
+ else:
552
+ # default to returning all groups, since it's safer
553
+ return self.circuit.get_contingency_groups_active()
554
+
555
+ elif filter_mode == ContingencyFilteringMethods.Municipality:
556
+
557
+ if self.circuit.get_municipalities_number() > 0:
558
+ # get the selection indices
559
+ idx = gf.get_checked_indices(self.ui.contingency_group_filter_listView.model())
560
+ elements = self.circuit.get_municipalities()
561
+ return self.circuit.get_contingency_groups_in(grouping_elements=[elements[i] for i in idx])
562
+ else:
563
+ # default to returning all groups, since it's safer
564
+ return self.circuit.get_contingency_groups_active()
510
565
 
511
566
  elif filter_mode == ContingencyFilteringMethods.Area:
512
567
  if self.circuit.get_area_number() > 0:
@@ -516,7 +571,7 @@ class SimulationsMain(TimeEventsMain):
516
571
  return self.circuit.get_contingency_groups_in(grouping_elements=[elements[i] for i in idx])
517
572
  else:
518
573
  # default to returning all groups, since it's safer
519
- return self.circuit.get_contingency_groups()
574
+ return self.circuit.get_contingency_groups_active()
520
575
 
521
576
  elif filter_mode == ContingencyFilteringMethods.Zone:
522
577
  if self.circuit.get_zone_number() > 0:
@@ -526,7 +581,7 @@ class SimulationsMain(TimeEventsMain):
526
581
  return self.circuit.get_contingency_groups_in(grouping_elements=[elements[i] for i in idx])
527
582
  else:
528
583
  # default to returning all groups, since it's safer
529
- return self.circuit.get_contingency_groups()
584
+ return self.circuit.get_contingency_groups_active()
530
585
 
531
586
  elif filter_mode == ContingencyFilteringMethods.SensitiveToMonitored:
532
587
  idx = gf.get_checked_indices(self.ui.contingency_group_filter_listView.model())
@@ -1139,7 +1194,6 @@ class SimulationsMain(TimeEventsMain):
1139
1194
  if not self.session.is_anything_running():
1140
1195
  self.UNLOCK()
1141
1196
 
1142
-
1143
1197
  def run_power_flow3ph(self):
1144
1198
  """
1145
1199
  Run a power flow simulation