Search Options

Results per page
Sort
Preferred Languages
Advance

Results 131 - 140 of 176 for getDefiningOp (0.38 sec)

  1. tensorflow/compiler/mlir/quantization/stablehlo/passes/bridge/convert_tf_quant_to_mhlo_int_test.cc

              "Func must have ReturnOp as last op and must return 1 value");
        }
        auto def_op = return_op.getOperand(0).getDefiningOp();
        auto fold_results = ConstantFoldOpIfPossible(def_op);
        if (fold_results.size() != 1 ||
            !llvm::isa<TF::ConstOp>(fold_results[0].getDefiningOp())) {
          return absl::InternalError("Failed to evaluate TF ops");
        }
    
        // Convert output tensor back to xla::Literal.
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Apr 03 01:03:21 UTC 2024
    - 35.8K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/lite/utils/lstm_utils_test.cc

      // we set its value as a const tensor of specified size and value 0.
      EXPECT_TRUE(
          mlir::cast<ElementsAttr>(mlir::cast<mlir::arith::ConstantOp>(
                                       it->getOpOperand(15).get().getDefiningOp())
                                       .getValue())
              .getValues<FloatAttr>()[0]
              .getValue()
              .isExactlyValue(0.0f));
    
      EXPECT_EQ(fused_lstm_func_.getFunctionType().getNumResults(), 1);
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 10K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/quantization/common/lift_as_function_call.cc

      std::stack<Operation*> op_stack;
      while (!value_queue.empty()) {
        Value current_value = value_queue.front();
        value_queue.pop();
    
        Operation* defining_node = current_value.getDefiningOp();
        if (defining_node == nullptr) continue;
        op_stack.push(defining_node);
        for (Value arg : defining_node->getOperands()) {
          if (!argument_set.contains(arg.getImpl())) {
            value_queue.push(arg);
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri May 17 17:58:54 UTC 2024
    - 21.8K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/tensorflow/transforms/host_runtime/tpu_variable_runtime_reformatting.cc

                       llvm::SmallPtrSet<Operation*, 4>* skipped = nullptr) {
      while (auto result = mlir::dyn_cast<OpResult>(v)) {
        if (!(allow_other_use || v.hasOneUse())) break;
        auto op = result.getDefiningOp();
        if (!llvm::isa<TF::IdentityOp, TF::IdentityNOp>(op)) {
          break;
        }
        v = op->getOperand(result.getResultNumber());
        if (skipped) skipped->insert(op);
      }
      return v;
    }
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 21.9K bytes
    - Viewed (0)
  5. tensorflow/compiler/mlir/quantization/stablehlo/passes/convert_func_to_bfloat16.cc

      if (!converter.isLegal(convert_op.getOperand().getType())) {
        auto other_convert_op = dyn_cast_or_null<OtherConvertOp>(
            convert_op.getOperand().getDefiningOp());
        return other_convert_op &&
               converter.isLegal(other_convert_op.getOperand().getType());
      } else if (!converter.isLegal(convert_op.getResult().getType())) {
        if (!convert_op.getResult().hasOneUse()) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 9.3K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/lite/transforms/modify_io_nodes.cc

      for (int i = 0; i != num_return_operands; ++i) {
        auto returned_value = terminator->getOperand(i);
        Type returned_type = returned_value.getType();
        Operation* returned_op = returned_value.getDefiningOp();
        if (returned_op && llvm::isa<DequantizeOp>(returned_op)) {
          auto dequantize_op = llvm::cast<DequantizeOp>(returned_op);
          auto dequantize_input = dequantize_op.getInput();
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 8.9K bytes
    - Viewed (0)
  7. tensorflow/compiler/mlir/tensorflow/transforms/shape_inference.cc

      while (
          llvm::isa_and_nonnull<IdentityOp, IdentityNOp>(value.getDefiningOp())) {
        value = value.getDefiningOp()->getOperand(
            mlir::cast<OpResult>(value).getResultNumber());
      }
    
      Operation* op = value.getDefiningOp();
      if (!llvm::isa_and_nonnull<BatchDatasetV2Op, MapDatasetOp, RepeatDatasetOp,
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Sat Jun 08 07:28:49 UTC 2024
    - 134.1K bytes
    - Viewed (0)
  8. tensorflow/compiler/mlir/tfr/passes/raise_to_tf.cc

          continue;
        }
    
        // The index is valid for the call_op.
        Value input = call_op.getOperand(operand.index());
        Operation* input_op = input.getDefiningOp();
        auto input_tfr_type =
            signature.getFunctionType().getInputs()[operand.index()];
    
        // There are three cases for the preceding input_op:
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 21.8K bytes
    - Viewed (0)
  9. tensorflow/compiler/mlir/quantization/common/lift_as_function_call_test.cc

                             FunctionCallOpType::TFXlaCallModuleOp,
                             "composite_dot_general_fn", operands, results,
                             attributes)[0]
              .getDefiningOp();
      const auto entry_function_symbol_ref =
          lifted_op->getAttrOfType<FlatSymbolRefAttr>("_entry_function");
      SymbolTable symbol_table(*module_op);
      auto entry_func = dyn_cast_or_null<func::FuncOp>(
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri May 10 04:07:09 UTC 2024
    - 26.2K bytes
    - Viewed (0)
  10. tensorflow/compiler/mlir/tensorflow/transforms/host_runtime/tpu_merge_variables_with_execute.cc

            operand.value().get().getDefiningOp());
        if (!read_op) continue;
        if (check_same_region &&
            read_op->getParentRegion() != execute_parent->getParentRegion())
          continue;
    
        auto resource = read_op.getResource();
        if (check_device) {
          // TODO(lyandy): Wrap resource ops in tf_device.launch.
          if (auto* resource_op = resource.getDefiningOp()) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Feb 29 17:52:11 UTC 2024
    - 27K bytes
    - Viewed (0)
Back to top