Part of my code includes the following script, which both shows a progress
bar (for as long as 'categorize_reports()' is executed) and prints the
fileid and the output of the 'document' function; the latter is the one
increasing the calculation time (please see my comment). Any ideas on how to
use all the cores of my CPU here?
...
def categorize_reports():
if __name__ == '__main__':
root2 = Tkinter.Tk(className=' Processing Progress')
m = Meter(root2, relief='ridge', bd=3)
m.pack(fill='x')
i=0.0
for fileid in fileids():
m.set(i, 'Processing will take a few minutes...')
i=i+1.000/len(fileids())
m.after(1000, lambda: _demo(m, i))
print str(fileid), document(fileid) #this slows down the process
root2.withdraw()
...
Thanks
Tax
_______________________________________________
Tutor maillist - [email protected]
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor