📅  最后修改于: 2022-03-11 14:46:31.207000             🧑  作者: Mango
import multiprocessing as mp
pool = mp.Pool(processes=mp.cpu_count())
def func( arg ):
idx,row = arg
# Edit df
return row
new_rows = pool.map( func, [(idx,row) for idx,row in data_all.iterrows()])
data_all_new = pd.concat( new_rows )