预处理数据的时候使用多进程可以大大减少程序运行时间。
上代码
with Pool(15)as proc:
results = list(
tqdm(
proc.imap(convert_one,files,
),
total=len(files)
预处理数据的时候使用多进程可以大大减少程序运行时间。
上代码
with Pool(15)as proc:
results = list(
tqdm(
proc.imap(convert_one,files,
),
total=len(files)