Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 30 for then_branch (0.15 sec)

  1. tensorflow/compiler/mlir/tfrt/tests/tf_to_corert/control_flow.mlir

      // CHECK: [[cond_res:%.*]]:2 = tfrt.cond [[cond]]
      // CHECK-SAME: @cond_true @cond_false(%arg0, %arg2) : (!tfrt.chain, !tfrt_fallback.tf_tensor)
      %2 = "tf.If"(%arg0, %arg1) {else_branch = @cond_false, then_branch = @cond_true, is_stateless = true} : (tensor<i1>, tensor<i32>) -> tensor<i32>
      // CHECK: [[out_ch:%.*]] = tfrt.merge.chains [[cond_res]]#0, %arg0 : !tfrt.chain, !tfrt.chain
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue May 14 00:40:32 UTC 2024
    - 17.5K bytes
    - Viewed (0)
  2. tensorflow/compiler/jit/rearrange_function_argument_pass_test.cc

    #include "tensorflow/core/public/version.h"
    
    namespace tensorflow {
    
    TEST(RearrangeFunctionArgumentForFunctionTest, Basic) {
      FunctionDefLibrary fdl;
      {
        // Function for StatefulPartitionedCall's "f", If's
        // "then_branch"/"else_branch".
        // "arg0" (T=DT_RESOURCE), "arg1" (T=DT_BOOL)
        // "ret0" = "arg1"
        // "ret1" = "arg0"
        tensorflow::Scope s = tensorflow::Scope::NewRootScope();
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri Feb 09 11:36:41 UTC 2024
    - 10.5K bytes
    - Viewed (0)
  3. tensorflow/compiler/jit/compilability_check_util.cc

      if (!s.ok()) {
        *uncompilable_reason = s.message();
        return false;
      }
      return true;
    }
    
    // Tests whether 'if_node' is compilable. Every operator in the then_branch and
    // else_branch functions must be compilable for 'if_node' to be compilable.
    bool RecursiveCompilabilityChecker::IsCompilableIf(
        const Node& if_node, FunctionLibraryRuntime* lib_runtime,
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Mar 12 06:33:33 UTC 2024
    - 30.3K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/tensorflow/transforms/resource_op_lifting.cc

        } else if (auto if_op = llvm::dyn_cast<TF::IfOp>(&op)) {
          auto then_branch = if_op.then_function();
          auto else_branch = if_op.else_function();
          // Recursively handle the nested control flow.
          (void)HoistForControlFlow(&then_branch.front(), module, vars_initialized,
                                    lifted_partitioned_call_callees);
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 55.1K bytes
    - Viewed (0)
  5. tensorflow/compiler/mlir/tf2xla/internal/passes/extract_outside_compilation.cc

          /*is_stateless=*/false, if_region.get_thenFuncNameAttr(),
          if_region.get_elseFuncNameAttr());
    
      // Create empty then branch region.
      auto& then_branch = host_side_if.getThenBranch();
      then_branch.push_back(new Block);
      builder.setInsertionPointToEnd(&then_branch.front());
      builder.create<mlir::TF::YieldOp>(if_region.getLoc(),
                                        /*operands=*/ArrayRef<Value>{});
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Apr 30 21:25:12 UTC 2024
    - 68.3K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/tfrt/tests/hoist_invariant_ops.mlir

      // CHECK-NOT: tf.Const
      // CHECK:  "tf._TfrtGetResource"()
      %cond = "tf.Const"() {device = "/CPU:0", value = dense<true> : tensor<i1>} : () -> tensor<i1>
      // CHECK: tf.If
      %x = "tf.If"(%cond, %handle) {then_branch = @some_func, else_branch = @some_func, is_stateless = false} : (tensor<i1>, tensor<!tf_type.resource<tensor<i32>>>) -> tensor<i32>
      %r = "tf.AddV2"(%arg, %x) {device = "/CPU:0"} : (tensor<i32>, tensor<i32>) -> tensor<i32>
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Mon Apr 01 23:54:14 UTC 2024
    - 18.3K bytes
    - Viewed (0)
  7. tensorflow/compiler/mlir/quantization/stablehlo/tests/passes/insert_calibration_statistics_saver.mlir

        %1 = "tf.Greater"(%0, %cst_0) {device = ""} : (tensor<f32>, tensor<f32>) -> tensor<i1>
        %2:2 = "tf.If"(%1, %arg0) <{else_branch = @cond_false_80, is_stateless = true, then_branch = @cond_true_70}> {Tcond = i1, Tin = [f32], Tout = [i1, f32], _lower_using_switch_merge = true, _read_only_resource_inputs = [], device = ""} : (tensor<i1>, tensor<1x4xf32>) -> (tensor<i1>, tensor<1x3xf32>)
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 01:09:50 UTC 2024
    - 24.3K bytes
    - Viewed (0)
  8. tensorflow/compiler/mlir/tfrt/tests/mlrt/tf_to_mlrt.mlir

    // CHECK: [[z:%.*]] = mlrt.cond [[cond]] @then @else([[x]], [[y]])
    // CHECK: return [[z]]
    func.func @main(%cond: tensor<i1>, %x: tensor<i32>, %y: tensor<i32>) -> tensor<i32> {
      %z = "tf.If"(%cond, %x, %y) {then_branch = @then, else_branch = @else, is_stateless = true} : (tensor<i1>, tensor<i32>, tensor<i32>) -> tensor<i32>
      return %z: tensor<i32>
    }
    
    // -----
    
    // Test lowering AsyncOpKernel
    
    // CHECK-LABEL: func @main
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri May 31 20:44:15 UTC 2024
    - 24.7K bytes
    - Viewed (0)
  9. tensorflow/compiler/mlir/quantization/tensorflow/tests/insert_custom_aggregation_ops.mlir

        %1 = "tf.Greater"(%0, %cst_0) {device = ""} : (tensor<f32>, tensor<f32>) -> tensor<i1>
        %2:2 = "tf.If"(%1, %arg0) <{else_branch = @cond_false_80, is_stateless = true, then_branch = @cond_true_70}> {Tcond = i1, Tin = [f32], Tout = [i1, f32], _lower_using_switch_merge = true, _read_only_resource_inputs = [], device = ""} : (tensor<i1>, tensor<1x4xf32>) -> (tensor<i1>, tensor<1x3xf32>)
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri May 10 04:07:09 UTC 2024
    - 32.1K bytes
    - Viewed (0)
  10. tensorflow/compiler/mlir/lite/transforms/lower_static_tensor_list.cc

        auto original_point = rewriter.saveInsertionPoint();
        rewriter.setInsertionPointAfter(op->getParentOfType<func::FuncOp>());
        SymbolTable manager(op->getParentOfType<ModuleOp>());
    
        // Constructs `then_branch`, which is executed when `if_cond` evaluates to
        // true.
        auto then_branch_op =
            rewriter.create<func::FuncOp>(loc, "cond_true", func_type);
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Jun 11 20:00:43 UTC 2024
    - 70.7K bytes
    - Viewed (0)
Back to top