when I try to run this code, a warning appears in opendss, would you know what is missing import py_dss_interface dss = py_dss_interface.DSSDLL(r"C:\Program Files\OpenDSS") dss_file = r"C:\Program Files\OpenDSS\IEEETestCases\123Bus\IEEE123Master.dss" dss.text("compile [{}]".format(dss_file)) load_mult = 0.3 circuit_pu = 1.04 penetration_list= [penetration* 100 for penetration in range(0,101)] def process(penetration): dss.text('New Energymeter.m1 Line.L115') #Thevenin Equivalent dss.text(f"edit vsource.source...
Thank you for your help
import py_dss_interface dss = py_dss_interface.DSSDLL(r"C:\Program Files\OpenDSS") dss_file = r"C:\Program Files\OpenDSS\IEEETestCases\123Bus\IEEE123Master.dss" dss.text("compile [{}]".format(dss_file)) dss.text("solve") dss.text("show losses") losses_text = dss.text("show losses") total_losses = None for line in losses_text.split("\n"): if line.startswith("Total Losses"): total_losses = float(line.split(":")[1].strip().split()[0]) break if total_losses is not None: print("Perdas Totais: {:.2f} kW".format(total_losses))...
how do i get the total losses of an IEEE 123 bus network? and how do you calculate the losses across the network
I would like to know how the result of this function works, because I applied it to an IEEE 123 bus network, and it gave me the values of the magnitude and its angle, however, from what I could see it also included the same magnitude but with a lag in the angle. So in this case I would also like what these values represent
but this code is not returning correct values
'm using pycharm to interface with openDSS, currently in python, here's the code I'm doing import py_dss_interface dss = py_dss_interface.DSSDLL(r"C:\Program Files\OpenDSS") dss_file = r"C:\Program Files\OpenDSS\IEEETestCases\123Bus\IEEE123Master.dss" dss.text("compile [{}]".format(dss_file)) dss.solution_solve() Obtém todos os nomes dos elementos de linha do circuito line_names = dss.circuit_all_element_names() Dicionário para armazenar o carregamento percentual por trecho e por fase load_percentages...
I need to make a percentage load report, but I'm having trouble knowing the functions needed for this, could you help me?