mirror of https://gitlab.com/pamhyr/pamhyr2
tools: Minor change.
parent
1b2791edb5
commit
c59c924f58
|
|
@ -16,7 +16,6 @@ from View.MainWindow import ApplicationWindow
|
||||||
from Model.Study import Study
|
from Model.Study import Study
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
reset_timers()
|
|
||||||
conf = Config.load()
|
conf = Config.load()
|
||||||
app = QApplication(sys.argv)
|
app = QApplication(sys.argv)
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -61,15 +61,14 @@ def timer(func):
|
||||||
end_time = time.perf_counter()
|
end_time = time.perf_counter()
|
||||||
run_time = end_time - start_time
|
run_time = end_time - start_time
|
||||||
|
|
||||||
if func not in _timers:
|
|
||||||
_timers[func] = 0
|
|
||||||
_calls[func] = 0
|
|
||||||
|
|
||||||
_timers[func] += run_time
|
_timers[func] += run_time
|
||||||
_calls[func] += 1
|
_calls[func] += 1
|
||||||
|
|
||||||
return value
|
return value
|
||||||
|
|
||||||
|
_timers[func] = 0
|
||||||
|
_calls[func] = 0
|
||||||
|
|
||||||
return wrapper
|
return wrapper
|
||||||
|
|
||||||
#########
|
#########
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue