Skip to content

a easy-to-use Python multi-thread/process parallel helper

Notifications You must be signed in to change notification settings

ferventdesert/multi_yielder

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

multi_yielder

a easy-to-use Python multi-thread/process parallel helper

support:

  • multi thread, process or gevent
  • easy to use
  • easy to stop

how to use:

def xprint(x): 
    time.sleep(1)  # mock a long time task 
    yield x*x   
i=0
for item in multi_yield(xprint, process_mode,3,xrange(100)):
    i+=1
    print(item)
    if i>10:
        break
        

About

a easy-to-use Python multi-thread/process parallel helper

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages