Skip to content

Commit

Permalink
pythonflow: declare class vars inside __init__
Browse files Browse the repository at this point in the history
  • Loading branch information
bennn committed Jul 21, 2023
1 parent 4f4a0a2 commit b1cb10b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 2 additions & 0 deletions Benchmark/pythonflow/shallow/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ def __init__(self: PythonFlow) -> None:
self.residual = []
self.total_flow = 0
self.file_name = "graph2.txt"
self.options = []
self.cost = []

self.load_file()
self.init_flow()
Expand Down
4 changes: 3 additions & 1 deletion Benchmark/pythonflow/untyped/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ def __init__(self):
self.total_flow = 0
# file name
self.file_name = "graph2.txt"
self.options = []
self.cost = []

""" -- testing --
n = 20
Expand Down Expand Up @@ -183,4 +185,4 @@ def print_graph(self, graph):
flow = PythonFlow()


flow.main_algorithm()
flow.main_algorithm()

0 comments on commit b1cb10b

Please sign in to comment.