import numpy as np
import pandas as pd
from typing import Any, List, Optional, Tuple
class BusHandle:
@property
def id(self) -> int: ...
@property
def vn_kv(self) -> float: ...
@property
def vm_pu(self) -> float:
...
@property
def va_degree(self) -> float: ...
@property
def p_mw(self) -> float:
...
@property
def q_mvar(self) -> float: ...
def set_load(self, p_mw: float, q_mvar: float) -> None:
...
def set_gen(self, p_mw: float, vm_pu: float) -> None:
...
class LoadHandle:
@property
def bus(self) -> int: ...
p_mw: float
q_mvar: float
in_service: bool
class GenHandle:
@property
def bus(self) -> int: ...
p_mw: float
vm_pu: float
in_service: bool
class LineHandle:
@property
def from_bus(self) -> int: ...
@property
def to_bus(self) -> int: ...
in_service: bool
@property
def p_from_mw(self) -> float: ...
@property
def q_from_mvar(self) -> float: ...
@property
def i_ka(self) -> float: ...
class TrafoHandle: ...
class ExtGridHandle: ...
class ShuntHandle: ...
class SGenHandle: ...
class SwitchHandle: ...
class SolveReport:
@property
def converged(self) -> bool: ...
@property
def iterations(self) -> int: ...
@property
def runtime_ms(self) -> float: ...
@property
def rebuild(self) -> str:
...
def __bool__(self) -> bool: ...
class GridEditor:
def __enter__(self) -> "GridEditor": ...
def __exit__(self, exc_type: Any, exc_value: Any, traceback: Any) -> None: ...
def add_bus(self, vn_kv: float, name: Optional[str] = None,
vm_min: float = 0.9, vm_max: float = 1.1,
zone: int = 0) -> Tuple[int, BusHandle]: ...
def add_line(self, from_bus: int, to_bus: int, length_km: float,
std_type: Optional[str] = None, r_ohm_per_km: float = 0.1,
x_ohm_per_km: float = 0.1, c_nf_per_km: float = 0.0,
g_us_per_km: float = 0.0, parallel: int = 1,
max_i_ka: float = 0.0, name: Optional[str] = None) -> LineHandle: ...
def add_load(self, bus: int, p_mw: float, q_mvar: float,
name: Optional[str] = None) -> LoadHandle:
...
def add_gen(self, bus: int, p_mw: float, vm_pu: float = 1.0,
p_min: float = -1000.0, p_max: float = 1000.0,
q_min: float = -1000.0, q_max: float = 1000.0,
name: Optional[str] = None) -> GenHandle: ...
def add_ext_grid(self, bus: int, vm_pu: float = 1.0, va_degree: float = 0.0,
name: Optional[str] = None) -> ExtGridHandle: ...
def add_trafo(self, hv_bus: int, lv_bus: int, sn_mva: float = 1.0,
vn_hv_kv: float = 110.0, vn_lv_kv: float = 10.0,
vk_percent: float = 10.0, vkr_percent: float = 0.1,
pfe_kw: float = 0.0, i0_percent: float = 0.0,
shift_degree: float = 0.0, tap_pos: float = 0.0,
tap_neutral: float = 0.0, tap_step_percent: float = 1.25,
name: Optional[str] = None) -> TrafoHandle: ...
def add_shunt(self, bus: int, q_mvar: float, p_mw: float = 0.0,
vn_kv: float = 110.0, step: int = 1,
name: Optional[str] = None) -> ShuntHandle: ...
def remove(self, element: Any) -> None:
...
def commit(self) -> None: ...
def abort(self) -> None: ...
class PowerGrid:
def __init__(self, case_path: Optional[str] = None, _qlim: bool = False,
**kwargs: Any): ...
@classmethod
def from_pandapower(cls, net: Any) -> "PowerGrid":
...
def load_network(self, net: "Network") -> None:
...
def bus(self, id: int) -> Optional[BusHandle]: ...
def load(self, bus: Optional[int] = None,
name: Optional[str] = None) -> Optional[LoadHandle]: ...
def loads(self, bus: Optional[int] = None) -> List[LoadHandle]: ...
def gen(self, bus: Optional[int] = None,
name: Optional[str] = None) -> Optional[GenHandle]: ...
def line(self, from_bus: int, to_bus: int) -> Optional[LineHandle]: ...
def edit(self) -> GridEditor: ...
def set_base(self, f_hz: float = 50.0, sn_mva: float = 100.0) -> None: ...
def solve(self) -> SolveReport:
...
@property
def res_bus(self) -> pd.DataFrame: ...
@property
def res_line(self) -> pd.DataFrame: ...
@property
def v(self) -> np.ndarray:
...
@property
def converged(self) -> bool: ...
@property
def iterations(self) -> int: ...
@property
def n_bus(self) -> int: ...
@property
def n_line(self) -> int: ...
def describe(self) -> pd.DataFrame: ...
def display_case_buses(self) -> pd.DataFrame: ...
def display_case_loads(self) -> pd.DataFrame: ...
class Network: ...
def load_csv_zip(path: str) -> Network: ...
def version() -> str: ...
def features() -> List[str]: ...