Skip to content

Commit

Permalink
Merge pull request #182 from radical-cybertools/fix/issue_180
Browse files Browse the repository at this point in the history
fixed concurrency value
  • Loading branch information
mtitov authored Oct 27, 2023
2 parents 13b5008 + fb54e55 commit 0931de1
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions src/radical/analytics/session.py
Original file line number Diff line number Diff line change
Expand Up @@ -857,16 +857,19 @@ def concurrency(self, state=None, event=None, time=None, sampling=None):
else:
# select data points according to sampling
# get min time, and create timestamps at regular intervals
t = times[0][0]
ret = list()
t = times[0][0]
v = collapsed[0][1]
ret = list()
for time, val in collapsed:
while time >= t:
ret.append([t, val])
ret.append([t, v])
t += sampling
# value is changed after reaching the next timestamp
v = val

# append last time stamp if it is not appended, yet
if ret[-1] != [t, val]:
ret.append([t, val])
if ret[-1] != [t, v]:
ret.append([t, v])

return ret

Expand Down

0 comments on commit 0931de1

Please sign in to comment.