Closed yasirroni closed 4 months ago
from matpower import start_instance from matpowercaseframes import CaseFrames m = start_instance() mpc = m.loadcase('case9', verbose=False) m.push("_mpc", mpc, verbose=False) m.eval("_r1 = runpf(_mpc);", verbose=True) fieldnames_r1 = m.eval("fieldnames(_r1);", verbose=False) for i in fieldnames_r1.ravel(): try: val = m.eval(f"_r1.{i};", verbose=False) # print(type(val)) # print(val) except Exception as e: print(i) print(e) pass
Cell(['version', 'baseMVA', 'bus', 'gen', 'branch', 'gencost', 'order', 'task', 'et', 'success', 'iterations', 'om'])
task Octave evaluation error: error: save: error while writing '' to MAT file om Octave evaluation error: error: save: error while writing '' to MAT file
Solved in https://github.com/yasirroni/matpower-pip/pull/15.