set .close() for multiprocessing