Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for CalculateLowerBound (0.19 sec)

  1. tensorflow/compiler/mlir/quantization/tensorflow/calibrator/custom_aggregator_op.cc

    #include "tsl/platform/errors.h"
    
    namespace tensorflow {
    namespace {
    
    using ::stablehlo::quantization::CalculateBinIndexSafe;
    using ::stablehlo::quantization::CalculateBinWidth;
    using ::stablehlo::quantization::CalculateLowerBound;
    using ::stablehlo::quantization::CalibrationOptions;
    using CPUDevice = ::Eigen::ThreadPoolDevice;
    using CalibrationMethod =
        ::stablehlo::quantization::CalibrationOptions_CalibrationMethod;
    
    }  // namespace
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 01:09:50 UTC 2024
    - 6.2K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/quantization/tensorflow/calibrator/calibration_statistics_collector_histogram.cc

    namespace tensorflow {
    namespace calibrator {
    namespace {
    
    using ::stablehlo::quantization::CalculateBinIndex;
    using ::stablehlo::quantization::CalculateBinWidth;
    using ::stablehlo::quantization::CalculateLowerBound;
    
    // Gets the histogram frequencies for the given range.
    float GetRangeFrequencies(absl::Span<const int64_t> histogram,
                              const float bin_width, const float lower_bound,
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri Apr 05 09:09:34 UTC 2024
    - 5K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/quantization/stablehlo/cc/calibration/calibration_parameters.h

      return std::pow(2, std::ceil(std::log2(raw_bin_width)));
    }
    
    // Calculates the lower bound of the histogram. The lower bound is in form of
    // `N * bin_width`.
    inline float CalculateLowerBound(const float min_value, const float bin_width) {
      return std::floor(min_value / bin_width) * bin_width;
    }
    
    // Calculates the bin index of the current value.
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 01:09:50 UTC 2024
    - 3.3K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/quantization/stablehlo/cc/calibration/calibration_parameters_test.cc

    inline int32_t CalculateActualNumBins(const float min_value,
                                          const float max_value,
                                          const float bin_width) {
      const float lower_bound = CalculateLowerBound(min_value, bin_width);
      return std::ceil((max_value - lower_bound) / bin_width);
    }
    
    TEST(CalibrationParametersTest, CalculateBinWidthSmallerThanOne) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri Apr 05 09:09:34 UTC 2024
    - 3.8K bytes
    - Viewed (0)
Back to top