def parallel_concat_lcdir(lcbasedir,<EOL>objectidlist,<EOL>aperture='<STR_LIT>',<EOL>postfix='<STR_LIT>',<EOL>sortby='<STR_LIT>',<EOL>normalize=True,<EOL>outdir=None,<EOL>recursive=True,<EOL>nworkers=<NUM_LIT:32>,<EOL>maxworkertasks=<NUM_LIT:1000>):
if not outdir:<EOL><INDENT>outdir = '<STR_LIT>'<EOL><DEDENT>if not os.path.exists(outdir):<EOL><INDENT>os.mkdir(outdir)<EOL><DEDENT>tasks = [(lcbasedir, x, {'<STR_LIT>':aperture,<EOL>'<STR_LIT>':postfix,<EOL>'<STR_LIT>':sortby,<EOL>'<STR_LIT>':normalize,<EOL>'<STR_LIT>':outdir,<EOL>'<STR_LIT>':recursive}) for x in objectidlist]<EOL>pool = mp.Pool(nworkers, maxtasksperchild=maxworkertasks)<EOL>results = pool.map(parallel_concat_worker, tasks)<EOL>pool.close()<EOL>pool.join()<EOL>return {x:y for (x,y) in zip(objectidlist, results)}<EOL>
This concatenates all text LCs for the given objectidlist.