message: Throw an exception if steps_per_epoch is not specified in multi-worker training and dataset is sharded.
diff: @@ -1177,7 +1177,12 @@ class DataHandler(object):
  distribute_options.AutoShardPolicy.OFF)):
  # If the dataset would be auto-sharded, we should not infer a local
  # steps_per_epoch due to the possible inbalanced sharding between workers.
  - return None
  + raise ValueError("When dataset is sharded across workers, please "
  + "specify a reasonable `steps_per_epoch` such that all "
  + "workers will train the same number of steps and each "
  + "step can get data from dataset without EOF. This is "
  + "required for allreduce to succeed. We will handle the "
  + "last partial batch in the future.")
  size = cardinality.cardinality(dataset)
  if size == cardinality.INFINITE and steps is None:
  