Skip to content

Commit

Permalink
Use timer in example
Browse files Browse the repository at this point in the history
  • Loading branch information
mannbach committed Aug 28, 2024
1 parent 94fc94e commit 4123d75
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion examples/undirected/pah.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
from netin.models import PAHModel

from netin.utils import SimulationTimer

def run():
n = 4000
Expand All @@ -9,7 +9,9 @@ def run():
h_mm = 0.5
seed = 1234
m = PAHModel(N=n, m=k, f_m=f_m, h_m=h_mm, h_M=h_MM, seed=seed)
timer = SimulationTimer(m)
m.simulate()
print(f"Simulated model {m} in {timer.time:.2f} seconds.")

if __name__ == '__main__':
run()

0 comments on commit 4123d75

Please sign in to comment.