Skip to content

Commit

Permalink
Merge branch 'develop' into enhance/load_hashed_traces
Browse files Browse the repository at this point in the history
  • Loading branch information
hariharan-devarajan authored Oct 3, 2024
2 parents f8a3415 + 6f1e4d1 commit d886b69
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions dfanalyzer/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -208,12 +208,19 @@ def load_objects(line, fn, time_granularity, time_approximate, condition_fn, loa
d["trange"] = int(((val["ts"] + val["dur"])/2.0) / time_granularity)
d.update(io_function(val, d, time_approximate,condition_fn))
if fn:
d.update(fn(val, d, time_approximate,condition_fn, load_data))
user_d = fn(val, d, time_approximate,condition_fn, load_data)
if type(user_d) is list:
for user_dict in user_d[1:]:
yield user_dict
d.update(user_d[0])
else:
d.update(user_d)
logging.debug(f"built an dictionary for line {d}")
yield d
except ValueError as error:
logging.error(f"Processing {line} failed with {error}")
return d

return {}
def io_function(json_object, current_dict, time_approximate,condition_fn):
d = {}
d["phase"] = 0
Expand Down

0 comments on commit d886b69

Please sign in to comment.