fix a bug in task_split.py