First time here? Check out the Help page!
1 | initial version |
Here's the Python I'm using in any case:
import re
def get_execution_time(eplusend):
"""Get the execution time in seconds.
Parameters
----------
eplusend : str
Path to the .end file.
Returns
-------
float
"""
with open(eplusend, 'r') as f:
text = f.read()
time = text.split(';')[-1]
h, m, s, ms = [int(n) for n in re.findall('\d+', time)]
secs = (h * 60 * 60 +
m * 60 +
s +
ms / 100.0)
return secs