Python Forum
fast_map (parallel/concurrent map)
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
fast_map (parallel/concurrent map)
#1
I would like to share the "fast_map" package I wrote, and possibly ask for feedback. It uses multiple processes and threads to quickly complete IO and CPU expensive blocking tasks.
https://github.com/michalmonday/fast_map

Minimal example:
from fast_map import fast_map # pip3 install fast_map
import time

def io_and_cpu_expensive_function(x):
    time.sleep(1)
    for i in range(10 ** 6):
        pass
    return x*x

for i in fast_map(io_and_cpu_expensive_function, range(8)):
    print(i)
Reply


Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020