Change modular_partitioning so that series tasks are grouped based on their file name