Call srand in children of ParRun() so that each child is not running
from the same random seed. This is quite possible the cause of stitching failures. From the File::Temp man page: "If you are forking many processes in parallel that are all creating temporary files, you may need to reset the random number seed using srand(EXPR) in each child else all the children will attempt to walk through the same set of random file names and may well cause themselves to give up if they exceed the number of retry attempts."
Showing with 3 additions and 0 deletions