Skip to content

Commit

Permalink
Fix cluster percentage completion calculation
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexandra Lynn Macedo committed May 31, 2018
1 parent b2e13e9 commit 0213f20
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions bin/gwdetchar-lasso-correlation
Original file line number Diff line number Diff line change
Expand Up @@ -622,7 +622,7 @@ def generate_cluster(input_,):
if len(current_cluster) == 0:
with counter.get_lock():
counter.value += 1
pc = 100 * counter.value / nchan
pc = 100 * counter.value / len(nonzerodata)
print("Completed [%d/%d] %3d%% %-50s"
% (counter.value, len(nonzerodata), pc, '(%s)' % str(currentchan)), end='\r')
sys.stdout.flush()
Expand Down Expand Up @@ -680,7 +680,7 @@ def generate_cluster(input_,):

with counter.get_lock():
counter.value += 1
pc = 100 * counter.value / nchan
pc = 100 * counter.value / len(nonzerodata)
print("Completed [%d/%d] %3d%% %-50s"
% (counter.value, len(nonzerodata), pc, '(%s)' % str(currentchan)), end='\r')
sys.stdout.flush()
Expand Down

0 comments on commit 0213f20

Please sign in to comment.