def fun_page(page_id,onoma):
pp= Pool(50)
mega_list = []
start = time.time()
pst = p(page_id,access_token)
n = 50
group_post = group(pst,n)
temp = 0
for j in group_post:
temp += len(j)
print(str(temp)+'/'+str(len(pst)))
re = pp.map(pros,list(j))
for jj in re:
mega_list.append(jj)
duration = (time.time()-start)/float(60)
print ("Time:"+str(duration)+'min')
with open(onoma,'w') as f:
json.dump(mega_list,f)
return mega_list
评论列表
文章目录