@@ -22,7 +22,7 @@ def __init__(self):
2222 altdss .ClearAll ()
2323 altdss ('new circuit.MyCircuit' )
2424
25- def add_load_nodes (self , load_type : str = "house" , params = {}, num = 1 ):
25+ def add_load_nodes (self , load_type : str = "house" , params = {}, num : int = 1 ):
2626 """
2727 When the user wants to manually add nodes, or make nodes with varying parameters.
2828
@@ -55,7 +55,7 @@ def update_source(self, source_type: str = "turbine", params = {}):
5555 """
5656 return make_source_node (params , source_type )
5757
58- def add_PVSystem (self , load_nodes , params = {}, num_panels = 1 ):
58+ def add_PVSystem (self , load_nodes : list [ str ] , params = {}, num_panels : int = 1 ):
5959 """
6060 Specify a list of load nodes to add a PVsystem ("solar panel") to.
6161
@@ -74,7 +74,7 @@ def add_PVSystem(self, load_nodes, params = {}, num_panels = 1):
7474 self .num_pv += 1
7575 return PV_nodes
7676
77- def add_generator (self , num , gen_type : GeneratorType = GeneratorType .SMALL , params = {}):
77+ def add_generator (self , num : int = 1 , gen_type : GeneratorType = GeneratorType .SMALL , params = {}):
7878 """
7979 Specify parameters for a generator to add to the circuit
8080
@@ -92,7 +92,7 @@ def add_generator(self, num, gen_type: GeneratorType = GeneratorType.SMALL, para
9292 return generators
9393
9494
95- def add_lines (self , connections , line_type : str = "lv" , params = {}, transformer = True ):
95+ def add_lines (self , connections : list [ tuple ] , line_type : str = "lv" , params = {}, transformer : bool = True ):
9696 """
9797 Specify all lines that the user wants to add. If redundant lines, doesn't add anything
9898
@@ -104,7 +104,7 @@ def add_lines(self, connections, line_type: str = "lv", params = {}, transformer
104104 make_line (src , dst , line_type , self .num_lines , params , transformer )
105105 self .num_lines += 1
106106
107- def view_load_nodes (self , indices = []):
107+ def view_load_nodes (self , indices : list = []):
108108 """
109109 View load nodes (what their parameters are) at the given indices.
110110
@@ -151,7 +151,7 @@ def solve(self):
151151 """
152152 altdss .Solution .Solve ()
153153
154- def results (self , queries , export_path = "" ):
154+ def results (self , queries : list [ str ] , export_path = "" ):
155155 """
156156 Allow the user to query for many results at once instead of learning how to manually query
157157
0 commit comments