Search Options

Results per page
Sort
Preferred Languages
Advance

Results 31 - 40 of 463 for int64Ptr (0.65 sec)

  1. tensorflow/compiler/mlir/quantization/tensorflow/cc/const_op_size.cc

    // element is arbitrarily considered to be 4 bytes.
    constexpr int64_t kAssumedNumBytesPerElem = 4;
    
    int64_t GetSizeOfIntOrFloatConst(TF::ConstOp const_op) {
      const Type dtype = const_op.getDtype();
      const ElementsAttr const_value = const_op.getValue();
    
      const auto bytes_per_elem =
          static_cast<int64_t>(dtype.getIntOrFloatBitWidth() / CHAR_BIT);
    
      return bytes_per_elem * const_value.getNumElements();
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Dec 14 04:37:13 UTC 2022
    - 2.7K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/lite/stablehlo/transforms/legalize_hlo_conversions/scatter.cc

            scatter_op, "update_window_dims are not leading or trailing indices");
    
      SmallVector<int64_t, 4> permutation_array(updates_type.getRank());
      int64_t dim = 0;
      // Move leading indices to the back of the array.
      const auto permutation_array_size = permutation_array.size();
      for (int64_t i = update_window_dims.size(); i < permutation_array_size; ++i) {
        permutation_array[i] = dim;
        ++dim;
      }
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Sep 12 02:29:42 UTC 2023
    - 3.1K bytes
    - Viewed (0)
  3. tensorflow/c/tf_tensor.cc

    int TensorInterface::NumDims() const { return tensor_.dims(); }
    
    int64_t TensorInterface::Dim(int dim_index) const {
      return static_cast<int64_t>(tensor_.dim_size(dim_index));
    }
    
    int64_t TensorInterface::NumElements() const {
      return static_cast<int64_t>(tensor_.NumElements());
    }
    
    size_t TensorInterface::ByteSize() const {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Sun Apr 14 21:57:32 UTC 2024
    - 11.5K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/lite/stablehlo/transforms/legalize_hlo_conversions/util.h

    // with `size` number of values.
    bool IsIotaAttr(ArrayRef<int64_t> arr, int64_t size);
    
    // Returns a DenseIntElementsAttr for a permutation and the shape after
    // applying the permutation to a given shape through a transpose.
    PermutationAndShape GetPermutationAndTransposedShape(
        llvm::ArrayRef<int64_t> permutation_array, ShapedType input_type,
        ConversionPatternRewriter& rewriter);
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Nov 08 11:35:25 UTC 2023
    - 6.4K bytes
    - Viewed (0)
  5. tensorflow/compiler/mlir/tensorflow/transforms/shape_inference_pass.cc

     public:
      ShapeInference() = default;
      explicit ShapeInference(ArrayRef<ArrayRef<int64_t>> input_shapes)
          : input_shapes_(input_shapes) {}
      void runOnOperation() override {
        // Parse `input_arg_shapes_` if provided (test only)
        SmallVector<ArrayRef<int64_t>> input_shapes_vec;
        absl::StatusOr<SmallVector<SmallVector<int64_t>>> parsed_shapes;
        if (!input_arg_shapes_.empty()) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Apr 24 12:49:45 UTC 2024
    - 3K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/tensorflow/transforms/collection_ops_util.cc

    }
    
    namespace {
    
    int64_t GetFirstIfIndicesAreContiguous(Value indices) {
      auto type = mlir::dyn_cast<RankedTensorType>(indices.getType());
      if (!type) return -1;
      auto indices_op = indices.getDefiningOp();
      if (!indices_op) return -1;
      auto const_op = llvm::dyn_cast<TF::ConstOp>(indices_op);
      if (!const_op) return -1;
      int64_t last_index = -1;
      int64_t first_index = -1;
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 14.5K bytes
    - Viewed (0)
  7. tensorflow/compiler/mlir/tensorflow/ir/tf_ops_tensor_helper.h

    inline bool HasRankAtMost(Value value, int64_t rank) {
      RankedTensorType type = GetRankedTensorTypeForOperand(value);
      return !type || type.getRank() <= rank;
    }
    
    inline bool IsUnknownDimOrRank(int64_t dim_or_rank) {
      return dim_or_rank == -1;
    }
    
    // Returns dimension index for the given TensorFlow axis that supports negative
    // indexing.
    inline int64_t GetDimForAxis(int64_t axis, int64_t rank) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 3.8K bytes
    - Viewed (0)
  8. tensorflow/compiler/mlir/lite/ir/tfl_ops.cc

      int64_t x_row_dim = x_shape[x_shape.size() - 2];
      int64_t x_col_dim = x_shape[x_shape.size() - 1];
      int64_t y_row_dim = y_shape[y_shape.size() - 2];
      int64_t y_col_dim = y_shape[y_shape.size() - 1];
      int64_t out_row_dim = output_shape[output_shape.size() - 2];
      int64_t out_col_dim = output_shape[output_shape.size() - 1];
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu May 02 09:41:17 UTC 2024
    - 169.2K bytes
    - Viewed (0)
  9. tensorflow/compiler/mlir/quantization/common/ir/FakeQuantSupport.cc

    // fake quant op used in the training to use the nudged scale as well.
    static void getNudgedScaleAndZeroPoint(int64_t qmin, int64_t qmax, double rmin,
                                           double rmax, double &scale,
                                           int64_t &nudgedZeroPoint) {
      // Determine the scale.
      const double qminDouble = qmin;
      const double qmaxDouble = qmax;
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Mar 21 11:52:27 UTC 2024
    - 7.7K bytes
    - Viewed (0)
  10. tensorflow/compiler/mlir/tensorflow/transforms/optimize.cc

        // Thus, we fail to match if the consuming reshape rank is larger.
        ArrayRef<int64_t> input_shape = input_type.getShape();
        if (reshape_shape.size() > input_shape.size()) return failure();
    
        // Extend the input shape with leading 1s to match the broadcast shape.
        ArrayRef<int64_t> broadcast_shape = output_type.getShape();
        SmallVector<int64_t, 4> input_shape_extended;
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 8.1K bytes
    - Viewed (0)
Back to top