Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 13 for NativeCodeCall (0.2 sec)

  1. tensorflow/compiler/mlir/tf2xla/transforms/legalize_tf_patterns.td

    class SliceDenseIntElementsAttrColumn2D<string column> : NativeCodeCall<
      "SliceDenseIntElementsAttrColumn2D($0.cast<ElementsAttr>(), " # column # " )">;
    
    class SliceDenseIntElementsAttr<string index, string axis> : NativeCodeCall<
      "SliceDenseIntElementsAttr($0.cast<ElementsAttr>(), " # index # ", " # axis # ")">;
    
    // Interior padding attribute based on the TF padding.
    def GetInteriorPadding : NativeCodeCall <
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Mon May 06 18:46:23 UTC 2024
    - 34.8K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/lite/utils/utils.td

    include "mlir/IR/OpBase.td"
    include "mlir/Dialect/Func/IR/FuncOps.td"
    include "mlir/IR/PatternBase.td"
    
    def CreateNoneValue : NativeCodeCall<
      "$_builder.create<TFL::NoValueOp>($0.getLoc(), $_builder.getUnitAttr())">;
    
    // Returns shape of a ranked tensor.
    // if called without a ranked tensor it will fail.
    def GetShape: NativeCodeCall<"GetShape($0)">;
    
    // Constraint that values in list attribute are all ones.
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Apr 30 00:40:15 UTC 2024
    - 4.8K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/tensorflow/transforms/lower_tf.td

      NativeCodeCall<"GetI64ElementsAttr({" # value # "}, &$_builder)">;
    
    class GetF32Scalar<int value> :
      NativeCodeCall<"GetF32Scalar(&$_builder, " # value # ")">;
    
    def TrueBoolAttr : AttrConstraint<CPred<"$_self.cast<::mlir::BoolAttr>().getValue()">>;
    
    def CreateTFShapeOp : NativeCodeCall<
        "$_builder.create<TF::ShapeOp>($0.getLoc(), $1, $2)">;
    
    def IsI32 : NativeCodeCall<
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Jun 04 13:30:42 UTC 2024
    - 24.7K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/lite/stablehlo/transforms/composite_avg_pool_patterns.td

    // See the function doc in the header file.
    def GetPadOpAttr: NativeCodeCall<"GetPadOpAttr($_builder, (*$0.begin()).getDefiningOp<mhlo::CompositeOp>())">;
    
    // See the function doc in the header file.
    def GetPaddingArrayCeilMode: NativeCodeCall<"GetPaddingArrayCeilMode($_builder, (*$0.begin()).getDefiningOp<mhlo::CompositeOp>())">;
    
    class CreateStringAttr<string values> : NativeCodeCall<
      "$_builder.getStringAttr("# values #")">;
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue May 28 23:16:05 UTC 2024
    - 7.8K bytes
    - Viewed (0)
  5. tensorflow/compiler/mlir/lite/stablehlo/transforms/composite_utils.td

    include "mlir/IR/PatternBase.td"
    
    // See the function doc in the header file.
    def GetNhwcReturnTypeFromNchw: NativeCodeCall<
      "GetNhwcReturnTypeFromNchw((*$0.begin()).getDefiningOp())">;
    
    // When given a DenseIntElementsAttr containing I64 elements, this extracts
    // one I32IntegerAttr from the given index.
    class GetI32At<int index>: NativeCodeCall<
      "$_builder.getI32IntegerAttr(static_cast<int32_t>(*($0.getValues<int64_t>().begin() + " # index #")))">;
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed May 08 19:05:30 UTC 2024
    - 2.7K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/lite/transforms/legalize_patterns.td

    def convertIntAttrTo32Bit : NativeCodeCall<
        "$_builder.getI32IntegerAttr($0.cast<IntegerAttr>().getInt())">;
    
    // Builds a constant bool attribute.
    class GetBoolAttr<int value> :
        NativeCodeCall<"$_builder.getBoolAttr(" # value #")">;
    
    // Converts an integer attribute $0 to 64-bit with builder.
    def convertIntAttrTo64Bit : NativeCodeCall<
        "$_builder.getI64IntegerAttr($0.cast<IntegerAttr>().getInt())">;
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Jun 04 13:30:42 UTC 2024
    - 28.5K bytes
    - Viewed (0)
  7. tensorflow/compiler/mlir/tensorflow/transforms/decompose_resource_ops.td

    def CheckHasResourceSubtype : Constraint<CPred<"HasResourceSubtype($0)">>;
    
    def CreateConstBoolAttrFalse : NativeCodeCall<"$_builder.getBoolAttr(false)">;
    
    def CreateTFReadVariableOpFromResourceHandle : NativeCodeCall<
        "$_builder.create<TF::ReadVariableOp>("
        "$0.getLoc(), GetResourceSubtype($1), $1)">;
    
    def CreateTFSelectOp: NativeCodeCall<
        "$_builder.create<TF::SelectOp>("
        "$0.getLoc(), $3.getType(), $1, $2, $3)">;
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed May 22 19:47:48 UTC 2024
    - 20.7K bytes
    - Viewed (0)
  8. tensorflow/compiler/mlir/lite/transforms/prepare_patterns.td

    def DenseElementsAttr : ElementsAttrBase<
      CPred<"$_self.isa<DenseElementsAttr>()">,
      "non-opaque constant tensor">;
    
    def CreateGatherNdOp : NativeCodeCall<
        "$_builder.create<TF::GatherNdOp>($0.getLoc(), $0.getType(), $1, $2)">;
    
    def CreateTFCastOpI32 : NativeCodeCall<
        "CreateTFCastOpI32(&$_builder, $_loc, $0, $1)">;
    
    // Convert to std constant for statically shaped, non-opaque constants.
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Apr 30 00:40:15 UTC 2024
    - 10.5K bytes
    - Viewed (0)
  9. tensorflow/compiler/mlir/lite/stablehlo/odml_converter/transforms/shlo_simplify.td

    include "mlir/IR/OpBase.td"
    include "mlir/IR/BuiltinAttributes.td"
    include "mlir/IR/CommonAttrConstraints.td"
    include "mlir/IR/CommonTypeConstraints.td"
    
    def CloneF32ElementsAttrWithOnes
      : NativeCodeCall<"DenseElementsAttr::get($0.getType().cast<ShapedType>(), (float)1.0)">;
    
    def NotConstant : Constraint<
        CPred<"$0.isa<BlockArgument>() || !llvm::isa<stablehlo::ConstantOp>($0.getDefiningOp())">,
        "Is not a constant.">;
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri May 10 03:05:20 UTC 2024
    - 1.4K bytes
    - Viewed (0)
  10. tensorflow/compiler/mlir/quantization/tensorflow/passes/convert_tpu_model_to_cpu.td

    include "mlir/IR/PatternBase.td"
    include "tensorflow/compiler/mlir/quantization/common/attrs_and_constraints.td"
    
    // Combines the two variadic arguments ($in_tensors and $captured_tensors).
    def GetBatchFunctionOpArgOperands:
        NativeCodeCall<"cast<TF::BatchFunctionOp>($0[0].getDefiningOp()).getArgOperands()">;
    
    // Replaces `TF_BatchFunctionOp` into `TF_PartitionedCallOp` that calls the
    // same $f. This may be required, for example, when inlining is desired,
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Apr 02 18:58:35 UTC 2024
    - 1.6K bytes
    - Viewed (0)
Back to top