torchcell.trainers.int_hetero_cell.normalize_accumulation_schedule

normalize_accumulation_schedule(schedule: dict[Any, Any] | None) → dict[int, int] | None[source]

Return the schedule with integer epoch keys in ascending order.

A key is an integer epoch >= 0, given as an int or as a string of digits: wandb.config returns every mapping key as a string, so {0: 16} in a config reaches the task as {"0": 16}. Anything else is refused by name, notably "0:16", which is what YAML reads from the flow mapping {0:16} written without a space. A value is a positive integer step count.