added a progress bar for job submission

This commit is contained in:
Stephen McQuay 2011-04-02 02:01:22 -06:00
parent 0a0e43f409
commit 20ea028db6

View File

@ -78,18 +78,23 @@ if __name__ == '__main__':
results = []
widgets = ['submit jobs: ', Percentage(), ' ', Bar(), ' ', ETA()]
pbar = ProgressBar(widgets = widgets, maxval = count)
pbar.start()
submit_start = time.time()
for i in xrange(count):
X = np.random.random((1,3))[0]
tasksq.put((i, options.order, options.extra, X))
pbar.update(i+1)
submit_end = time.time()
pbar.finish()
for i in xrange(participants):
print "sending worker %d start message" % (i+1,)
slavesq.put("start")
receive_start = time.time()
widgets = ['Progress: ', Percentage(), ' ', Bar(), ' ', ETA()]
widgets = ['interpolate: ', Percentage(), ' ', Bar(), ' ', ETA()]
pbar = ProgressBar(widgets = widgets, maxval = count)
pbar.start()
for i in xrange(count):