def METHOD_NAME(
    self, dataset_name: str, feature_name: str, num_of_bins: int, global_min_value: float, global_max_value: float
) -> Histogram:
    if dataset_name in self.stats:
        if feature_name in self.histograms[dataset_name]:
            histo = self.histograms[dataset_name][feature_name]
        else:
            self.log_warning(
                self.fl_ctx,
                f"Could not find a matching histogram for feature {feature_name} in dataset {dataset_name}.",
            )
            return Histogram(HistogramType.STANDARD, list())
    else:
        self.log_warning(self.fl_ctx, f"No such dataset {dataset_name}")
        return Histogram(HistogramType.STANDARD, list())
    bin_edges = histo["bin_edges"]
    counts = histo["counts"]
    num_of_bins = len(counts)
    histogram_bins: List[Bin] = []
    for j in range(num_of_bins):
        low_value = bin_edges[j]
        high_value = bin_edges[j + 1]
        bin_sample_count = counts[j]
        histogram_bins.append(Bin(low_value=low_value, high_value=high_value, sample_count=bin_sample_count))
    return Histogram(HistogramType.STANDARD, histogram_bins)