Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 83 for ArrayAttr (0.32 sec)

  1. tensorflow/compiler/mlir/lite/utils/perception_ops_utils_test.cc

    }
    
    template <int N>
    ArrayAttr createInt32Array(mlir::Builder* builder, mlir::MLIRContext* context,
                               const SmallVector<int32_t, N>& values) {
      SmallVector<Attribute, N> ret;
      for (int32_t value : values) {
        ret.push_back(builder->getI32IntegerAttr(value));
      }
      return ArrayAttr::get(context, ret);
    }
    
    template <int N>
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Sep 29 21:02:21 UTC 2022
    - 7.4K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/lite/utils/validators.cc

    // and writes X, Y as 32-bit integer attribute to `x`, `y`.
    bool TFIntListIs1XY1(Operation *op, StringRef name, IntegerAttr *x,
                         IntegerAttr *y) {
      auto attr = op->getAttrOfType<ArrayAttr>(name);
      if (!attr) return false;
    
      auto elements = attr.getValue();
      if (elements.size() != 4 ||
          std::any_of(elements.begin(), elements.end(),
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 5.2K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/quantization/tensorflow/utils/tf_to_xla_attribute_utils.h

                                         Value input, Value filter,
                                         int8_t input_zp_value, ArrayAttr strides,
                                         ArrayAttr dilations,
                                         StringAttr conv_padding,
                                         ArrayAttr explicit_paddings,
                                         Value &padding, int num_dims = 4);
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Sun Dec 10 05:52:02 UTC 2023
    - 2K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/tensorflow/ir/tf_ops_layout_helper.h

    // Shuffle elements in the `attr` according to the permutation. Optional
    // `inner_size` allows to shuffle array attributes created from rank 2 tensors
    // on outer dimension only.
    ArrayAttr ShuffleArrayAttr(ArrayAttr attr, ArrayRef<int64_t> permutation,
                               int inner_size = 1);
    
    // Shuffle ranked tensor dimensions according to the permutation.
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Jun 08 01:19:25 UTC 2023
    - 5.3K bytes
    - Viewed (0)
  5. tensorflow/compiler/mlir/tfrt/ir/tfrt_fallback_async.td

      }];
    
      let arguments = (ins
        TFRT_ChainType:$in_ch,
        I64Attr:$num_args,
        StrAttr:$device,
        ArrayAttr:$op_attrs,
        // TODO(b/173025975): consider using DictionaryAttr after we support
        // BEF conversion for this type.
        ArrayAttr:$op_func_attrs,
        I64Attr:$op_key,
        StrAttr:$op_name
      );
    
      let results = (outs
        TFRT_ChainType:$out_ch
      );
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 18 15:01:21 UTC 2024
    - 15.8K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/tfrt/ir/tfrt_fallback_common.h

    template <typename OpTy>
    mlir::LogicalResult VerifyExecuteOpCommon(OpTy op) {
      auto op_attr_array = op.getOpAttrs().getValue();
      for (auto op_attr : op_attr_array) {
        auto key_value = mlir::dyn_cast<mlir::ArrayAttr>(op_attr);
        if (!key_value || key_value.getValue().size() != 2 ||
            !mlir::isa<mlir::StringAttr>(key_value.getValue()[0]))
          return op.emitOpError() << "each op_attr should be a key-value pair, "
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 4.5K bytes
    - Viewed (0)
  7. tensorflow/compiler/mlir/tensorflow/ir/tf_ops_layout_helper.cc

        return {};
      }
    }
    
    // Shuffle elements in the `attr` according to the permutation. Optional
    // `inner_size` allows to shuffle array attributes created from rank 2 tensors
    // on outer dimension only.
    ArrayAttr ShuffleArrayAttr(ArrayAttr attr, ArrayRef<int64_t> permutation,
                               int inner_size) {
      if (attr.empty()) return attr;
    
      assert(attr.size() % inner_size == 0);
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 3.3K bytes
    - Viewed (0)
  8. tensorflow/compiler/mlir/tf2xla/transforms/utils.h

                                    OpBuilder* builder);
    
    ConstantOp GetScalarNegZeroOfType(Type ty, Location loc, OpBuilder* builder);
    
    // Converts an ArrayAttr to a 1D 64-bit dense elements attribute.
    DenseIntElementsAttr GetI64ElementsAttr(ArrayAttr attr);
    DenseIntElementsAttr GetI64ElementsAttr(llvm::ArrayRef<int64_t> values,
                                            Builder* builder);
    
    }  // namespace mhlo
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Sep 06 19:12:29 UTC 2023
    - 2.3K bytes
    - Viewed (0)
  9. tensorflow/compiler/mlir/tfrt/saved_model/saved_model.cc

    #include "tfrt/bef_converter/mlir_to_bef.h"  // from @tf_runtime
    
    namespace tensorflow {
    namespace {
    
    using ::mlir::tf_saved_model::kTfSavedModelIndexPathAttr;
    
    llvm::StringRef ProcessIndexPath(mlir::ArrayAttr index_path) {
      if (index_path.size() == 1 && mlir::isa<mlir::StringAttr>(index_path[0])) {
        // TODO(chky): Support cases where index_path is not a single string.
        return mlir::cast<mlir::StringAttr>(index_path[0]).getValue();
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 5.9K bytes
    - Viewed (0)
  10. tensorflow/compiler/mlir/quantization/tensorflow/utils/tf_to_xla_attribute_utils.cc

                                         Value input, Value filter,
                                         int8_t input_zp_value, ArrayAttr strides,
                                         ArrayAttr dilations,
                                         StringAttr conv_padding,
                                         ArrayAttr explicit_paddings,
                                         Value &padding, int num_dims) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri May 17 17:58:54 UTC 2024
    - 13.3K bytes
    - Viewed (0)
Back to top