You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
raiseNotImplementedError(f"Time format for {timestamp} not implemented.")
loops=None
iflen(sections) >=4andsections[-1].startswith("Number of loops : "):
# The header contains a loops section.
loops_lines=sections[-1].split("\n")
n_loops=int(loops_lines[0].split(":")[-1])
indexes= []
forninrange(n_loops):
index=loops_lines[n+1].split("to")[0].split()[-1]
indexes.append(int(index))
loops= {"n_loops": n_loops, "indexes": indexes}
settings= {
"posix_timestamp": uts,
"technique": technique,
"raw": "\n".join(lines),
}
returnsettings, params, loops
has seen better days and is very quickly becoming hard to maintain.
The big issue here is that the params section (i.e. everything after Cycle Definition until a blank line) can have a variable number of lines even for the same technique. This is particularly frustrating as it can happen when mpt files are generated from the same mpr file, depending on the EC-Lab version used to export the file. Note that only the EC-Lab version used to create the file is recorded in the mpt file, not the export version.
Fixing this would pave way towards resolving #149 and is a good opportunity to close #12.
The text was updated successfully, but these errors were encountered:
The
eclab.mpt
header parser in:yadg/src/yadg/extractors/eclab/mpt.py
Lines 70 to 144 in c6379f7
has seen better days and is very quickly becoming hard to maintain.
The big issue here is that the
params
section (i.e. everything afterCycle Definition
until a blank line) can have a variable number of lines even for the sametechnique
. This is particularly frustrating as it can happen whenmpt
files are generated from the samempr
file, depending on the EC-Lab version used to export the file. Note that only the EC-Lab version used to create the file is recorded in thempt
file, not the export version.Fixing this would pave way towards resolving #149 and is a good opportunity to close #12.
The text was updated successfully, but these errors were encountered: