Circuit#
- class popo.network.Circuit(dss=None)#
Bases:
objectThe circuit currently compiled in OpenDSS.
Examples
>>> circuit = Circuit.load("feeder/Master.dss") >>> circuit.converged True >>> pd.DataFrame(circuit.lines).head() >>> circuit.bus_voltages().query("bus != @circuit.source_bus")["vmag_pu"].min()
- classmethod load(master, solve=True, dss=None)#
Clear the engine, compile
masterand optionally solve it.
- command(text)#
Run an OpenDSS command and return its text result.
The result is what a
?query or anexportreports, e.g. the path written.opendssdirectleaves it inText.Result()rather than returning it, so it is read back here.- Return type:
- property transformers: Iterator[Transformer]#
Every transformer, as the record
popo.network.read_transformers()produces.The secondary is the second winding: its bus is where customers connect and its voltage is what separates a distribution transformer from one further upstream.
- property storage_units: Iterator[StorageUnit]#
Every storage unit, in circuit order.
opendssdirectexposes only a storage unit’s name, state and state of charge, so the ratings are read with a?property query.
- bus_voltages()#
Per-phase bus voltages. See
popo.powerflow.results.bus_voltages().- Return type:
- line_currents()#
Per-phase line currents. See
popo.powerflow.results.line_currents().- Return type:
- element_powers(element_type)#
Per-phase powers of one element type. See
popo.powerflow.results.element_powers().- Return type:
- summary()#
A one-line health check. See
popo.powerflow.results.circuit_summary().
- solve_time_series(horizon, transformers=None, **kwargs)#
Step the circuit over time. See
popo.powerflow.solve_time_series().- Parameters:
- Return type:
- Returns:
The
popo.powerflow.SolveReportof the run.