Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 20 for Axis (0.24 sec)

  1. tensorflow/compiler/mlir/lite/ir/tfl_ops.cc

        int64_t axis = axis_int.getSExtValue();
        if (axis < 0) {
          axis += input_type.getRank();
        }
        if (axis < 0 || (input_type.hasRank() && axis >= input_type.getRank())) {
          return op.emitOpError(
              llvm::formatv("perm[{0}] must be in [-rank, rank)", index));
        }
        if (std::count(axes.begin(), axes.end(), axis) > 0) {
          return op.emitOpError(
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu May 02 09:41:17 UTC 2024
    - 169.2K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/tensorflow/ir/tf_ops_a_m.cc

                                    << -rank << ", " << rank << ")";
          if (axis < 0) axis += rank;
        }
    
        if (batch_dims >= 0 && axis >= 0 && axis < batch_dims) {
          return op.emitOpError() << "requires axis (" << axis
                                  << ") to be greater than or equal to batch_dims ("
                                  << batch_dims << ")";
        }
      }
      return success();
    }
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 146.7K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/lite/tests/ops.mlir

      // expected-error @+1 {{op attribute 'axis' should be in range [-rank - 1, rank + 1), got rank = 1, and axis = 3}}
      %0 = "tfl.pack"(%arg0, %arg1) {axis = 3 : i32, values_count = 2 : i32} : (tensor<2xi32>, tensor<2xi32>) -> tensor<2x2xi32>
      func.return %0 : tensor<2x2xi32>
    }
    
    // -----
    
    func.func @unpack(%arg0: tensor<2x3xi32>) -> tensor<2xi32> {
      // CHECK: "tfl.unpack"(%arg0) <{axis = 1 : i32, num = 3 : i32}>
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Jun 06 19:09:08 UTC 2024
    - 189.2K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/lite/transforms/optimize.cc

      if (!axes_attr) return false;
    
      for (auto a : axes_attr.getValues<APInt>()) {
        int64_t axis = a.getSExtValue();
        if (axis < 0) {
          axis += type_shape.size();
        }
        if (axis < 0 || axis >= type_shape.size()) {
          // `axis` is not a valid axis in input.
          return false;
        }
        if (type_shape[axis] != 1) {
          return false;
        }
      }
    
      return true;
    }
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Apr 30 00:40:15 UTC 2024
    - 102.3K bytes
    - Viewed (0)
  5. tensorflow/compiler/mlir/lite/ir/tfl_ops.td

        The new axis is created at dimension `axis` (default: the new axis is
        appended at the end).
      }];
    
      let arguments = (ins
        TFL_TensorOf<[I32, I64]>:$indices,
        TFL_I32Tensor:$depth,
        TFL_TensorOf<[F32, I32, I64, I1, I8, UI8]>:$on_value,
        TFL_TensorOf<[F32, I32, I64, I1, I8, UI8]>:$off_value,
    
        I32Attr:$axis
      );
    
      let results = (outs
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Jun 06 19:09:08 UTC 2024
    - 186K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/tensorflow/ir/tf_ops_n_z.cc

      int64_t value_rank = value_type.getRank();
      int64_t axis = op.getAxis();
      if (axis < -value_rank || axis >= value_rank)
        return op.emitOpError("axis attribute must be in the range of [-")
               << value_rank << ", " << value_rank << ')';
    
      axis = GetDimForAxis(axis, value_rank);
      int64_t dim_size = value_type.getDimSize(axis);
      if (ShapedType::isDynamic(dim_size)) return success();
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu May 09 22:07:10 UTC 2024
    - 170.8K bytes
    - Viewed (0)
  7. tensorflow/compiler/mlir/tensorflow/tests/canonicalize.mlir

      func.return
    }
    
    // CHECK-LABEL: testGatherToV2
    // Ensures that axis param and batch_dims attr use their default values of 0.
    func.func @testGatherToV2(%params: tensor<4x3xf32>, %indices: tensor<1x2xi32>) -> tensor<2x3xf32> {
      // CHECK: %[[AXIS:.*]] = "tf.Const"() <{value = dense<0> : tensor<i32>}> : () -> tensor<i32>
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu May 09 22:07:10 UTC 2024
    - 132.1K bytes
    - Viewed (0)
  8. tensorflow/compiler/mlir/tensorflow/tests/tf-ops.mlir

    // Test valid tf.ConcatV2
    func.func @testConcatV2(%arg: tensor<8x16xf32>, %axis: tensor<i32>) -> tensor<?xf32> {
      %0 = "tf.ConcatV2"(%arg, %arg, %axis) : (tensor<8x16xf32>, tensor<8x16xf32>, tensor<i32>) -> tensor<?xf32>
      func.return %0 : tensor<?xf32>
    }
    
    // -----
    
    // tf.ConcatV2 with wrong 'axis' element type
    func.func @testConcatV2(%arg: tensor<8x16xf32>, %axis: tensor<f32>) -> tensor<?xf32> {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Mon Oct 23 14:40:35 UTC 2023
    - 236.4K bytes
    - Viewed (0)
  9. tensorflow/compiler/mlir/lite/tests/legalize-tf.mlir

    // CHECK: "tfl.unpack"(%arg0) <{axis = 1 : i32, num = 3 : i32}> : (tensor<2x3xi32>) -> (tensor<2xi32>, tensor<2xi32>, tensor<2xi32>)
    }
    
    func.func @unpackNegAxis(%arg0: tensor<2x3xi32>) -> tensor<2xi32> {
      %0:3 = "tf.Unpack"(%arg0) {axis = -1 : i64} : (tensor<2x3xi32>) -> (tensor<2xi32>, tensor<2xi32>, tensor<2xi32>)
      func.return %0#0 : tensor<2xi32>
    
    // CHECK-LABEL: unpackNegAxis
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Jun 05 01:54:33 UTC 2024
    - 153.4K bytes
    - Viewed (0)
  10. tensorflow/compiler/mlir/lite/stablehlo/tests/uniform-quantized-stablehlo-to-tfl.mlir

    // -----
    
    // Tests that when the weight tensor for `stablehlo.dot_general` is per-axis
    // quantized, it is converted to `tfl.fully_connected` op.
    
    // CHECK-LABEL: dot_general_upstream_srq_per_axis_quantized_filter
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue May 14 17:10:32 UTC 2024
    - 106.2K bytes
    - Viewed (0)
Back to top