Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 83 for getDefiningOp (0.48 sec)

  1. tensorflow/compiler/mlir/quantization/tensorflow/passes/replace_cast_hacks_with_tf_xla_ops.cc

      Operation *op_input = args[0].getDefiningOp();
      Operation *op_weight = args[1].getDefiningOp();
      if (isa<TF::SubOp>(op_input)) {
        op_input = op_input->getOperand(0).getDefiningOp();
      }
      if (isa<TF::SubOp>(op_weight)) {
        op_weight = op_weight->getOperand(0).getDefiningOp();
      }
      if (isa<TF::CastOp>(op_input)) {
        op_input = op_input->getOperand(0).getDefiningOp();
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 47.1K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/tensorflow/transforms/breakup-islands.cc

        if (!fetch.getDefiningOp()) {
          // Skip, because there is no op to add control to (eg: function args).
          continue;
        } else if (fetch.getDefiningOp()->getParentOp() == island_op) {
          // Skip, because it is the same island.
          continue;
        } else if (auto other_island_op = llvm::dyn_cast<tf_executor::IslandOp>(
                       fetch.getDefiningOp())) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri Aug 11 20:52:36 UTC 2023
    - 16.7K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/tensorflow/transforms/tpu_resource_partitioning.cc

        auto read_var = llvm::dyn_cast_or_null<TF::ReadVariableOp>(
            operand.get().getDefiningOp());
        if (!read_var) continue;
        auto partitioned_input =
            llvm::dyn_cast_or_null<TF::TPUPartitionedInputV2Op>(
                read_var.getResource().getDefiningOp());
        if (!partitioned_input || !AllResourceTypesHaveSubtypes(
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Sep 06 19:12:29 UTC 2023
    - 11.8K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/quantization/stablehlo/passes/bridge/convert_tf_quant_types.cc

    bool IsQintValueDefinedByIntToQintCast(Value v) {
      if (!IsIllegalType(v.getType())) {
        return true;
      }
      if (!v.getDefiningOp() || !llvm::isa<TF::CastOp>(v.getDefiningOp())) {
        return false;
      }
      return IsIntToQintCast(v.getDefiningOp());
    }
    
    bool IsTFUniformQuantizedOpLegal(Operation *op) {
      // UniformQuantized Ops are considered legal if its qint operands and
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 12.6K bytes
    - Viewed (0)
  5. tensorflow/compiler/mlir/tensorflow/transforms/sparsecore/embedding_sequencing.cc

          if (IsTPUOp(input_value.get().getDefiningOp()) &&
              !backward_pass_ops.contains(input_value.get().getDefiningOp()))
            values_to_add_nodes.insert(input_value.get());
      }
    
      for (Value value : values_to_add_nodes) {
        builder.setInsertionPointAfter(value.getDefiningOp());
        std::vector<Type> types(num_replicas, value.getType());
        Location loc = value.getDefiningOp()->getLoc();
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 39.4K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/tensorflow/transforms/tpu_dynamic_layout_pass.cc

          resource_alias_analysis.GetResourceAliases(resource_iterator);
    
      auto is_generator = [](Value val) {
        if (mlir::isa<BlockArgument>(val)) return true;
        Operation* definition = val.getDefiningOp();
        return definition->getNumOperands() == 0 &&
               definition->getNumResults() == 1;
      };
    
      // Check all generator aliases (ops or function argument) are on CPU.
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 12.7K bytes
    - Viewed (0)
  7. tensorflow/compiler/mlir/lite/transforms/post_quantize.cc

      output_types.reserve(num_return_operands);
      for (int i = 0; i != num_return_operands; ++i) {
        auto returned_value = terminator->getOperand(i);
        Operation* returned_op = returned_value.getDefiningOp();
        if (returned_op && returned_op->hasOneUse() &&
            llvm::isa<DequantizeOp>(returned_op)) {
          auto dequantize_op = llvm::cast<DequantizeOp>(returned_op);
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 17.1K bytes
    - Viewed (0)
  8. tensorflow/compiler/mlir/quantization/tensorflow/passes/prepare_lifting.cc

                                 Value multiplier) {
      auto dq_op = value.getDefiningOp<quantfork::DequantizeCastOp>();
      if (!dq_op) {
        auto mul_op = builder.create<TF::MulOp>(loc, value, multiplier);
        return mul_op.getResult();
      }
      auto q_op = dq_op.getArg().getDefiningOp<quantfork::QuantizeCastOp>();
      if (!q_op) return {};
    
      Value float_value = q_op.getArg();
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri May 17 17:58:54 UTC 2024
    - 13.3K bytes
    - Viewed (0)
  9. tensorflow/compiler/mlir/tensorflow/transforms/layout_optimization.cc

        // Operand must be defined by a transpose op.
        TransposeOp transpose =
            dyn_cast_or_null<TransposeOp>(operand.get().getDefiningOp());
        if (!transpose) return;
    
        // With permutation defined by constant operation.
        ConstOp perm =
            dyn_cast_or_null<ConstOp>(transpose.getOperand(1).getDefiningOp());
        if (!perm) return;
    
        // With the same permutation indices.
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 19.3K bytes
    - Viewed (0)
  10. tensorflow/compiler/mlir/quantization/tensorflow/passes/quantize.cc

        for (const auto& operand : same_scale_op->getOperands()) {
          auto dq_op = dyn_cast_or_null<quantfork::DequantizeCastOp>(
              operand.getDefiningOp());
          if (!dq_op) continue;
    
          Operation* preceding_op = dq_op.getArg().getDefiningOp();
          if (!preceding_op) continue;
    
          // Check whether the preceding op is a quantized composite function.
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri Mar 22 05:52:39 UTC 2024
    - 23.6K bytes
    - Viewed (0)
Back to top