def METHOD_NAME(
        self,
        new_hist: np.ndarray,
        origin_hist: np.ndarray,
        upsample_bins_count: int,
        downsample_bins_count: int,
        start_bin_idx: int,
        bins_count: int, ):
    upsampled_histogram = np.repeat(origin_hist, upsample_bins_count)
    expanded_hist = np.zeros(
        (bins_count * downsample_bins_count), dtype=np.float32)
    expanded_hist[start_bin_idx:bins_count * upsample_bins_count +
                  start_bin_idx] = upsampled_histogram
    cumsumed_hist = np.cumsum(
        expanded_hist,
        dtype=np.float64)[downsample_bins_count - 1::downsample_bins_count]
    shift_cumsumed_hist = np.zeros((bins_count), dtype=np.float64)
    shift_cumsumed_hist[1:] = cumsumed_hist[0:-1]
    sampled_hist = (
        cumsumed_hist - shift_cumsumed_hist) / upsample_bins_count
    new_hist = new_hist.astype(np.float32)
    new_hist += sampled_hist.astype(np.float32)
    return new_hist