线程池快速上手 from concurrent.futures import ThreadPoolExecutor from utils import * workers = 8 with ThreadPoolExecutor(max_workers=workers) as pool: # 使用线程执行map计算 results = pool.map(batch_gen, ('_{}'.format(ed) for ed in range(5000, 5000*workers+1, 5000))…