experiments.experiment_utils.make_batch_epoch_dict_fixedniter

make_batch_epoch_dict_fixedniter(niter, data_fracs, N_max, batch_size)

Convenience function for figuring out the number of epochs necessary to ensure that at each data fraction, the total number of iterations (and batch size) will stay fixed.

Parameters:
  • niter (int) – The total number of iterations you want run at every data_frac

  • data_fracs (np.ndarray) – 1-D array of data fractions

  • N_max (int) – The maximum number of data points in the optimization process

  • batch_size (int) – The fixed batch size

Return batch_epoch_dict:

A dictionary where keys are data fractions and values are [batch_size,num_epochs]