code: def generate_RF_bins(data, dim = 40, num_bins = 10):
    
    intervals = []
    for i in range(dim):
      current_dim_data = [data[x][i] for x in range(len(data))]
      current_dim_data = numpy.sort(current_dim_data)
      intervals.append([current_dim_data[int(len(current_dim_data)*x/num_bins)]
          for x in range(1, num_bins)])
    return intervals
docs: Generates bins for the encoder.  Bins are designed to have equal frequency,
    per Poirazi & Mel (2001), which requires reading the data once.
    Bins are represented as the intervals dividing them.