code: def make_epochs_per_sample(weights, n_epochs):
      
      result = -1.0 * np.ones(weights.shape[0], dtype=np.float64)
      n_samples = n_epochs * (weights / weights.max())
      result[n_samples > 0] = float(n_epochs) / n_samples[n_samples > 0]
      return result
docs: Given a set of weights and number of epochs generate the number of
      epochs per sample for each weight.
  
      Parameters
      ----------
      weights: array of shape (n_1_simplices)
          The weights ofhow much we wish to sample each 1-simplex.
  
      n_epochs: int
          The total number of epochs we want to train for.
  
      Returns
      -------
      An array of number of epochs per sample, one for each 1-simplex.