Thanks a lot for the help so far. After adding torch.multiprocessing.set_start_method("spawn"), there arise new problems:
TypeError: can't pickle File objects
Somehow, file objects or group nodes (pytables reader) cannot be pickled. Is there a way around this?