Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 8 of 8 for else_branch (0.31 sec)

  1. tensorflow/compiler/mlir/tensorflow/ir/tf_ops.td

        tensors, whose types are the same as what else_branch returns.
    else_branch: A function that takes 'inputs' and returns a list of
        tensors.  whose types are the same as what then_branch returns.
      }];
    
      let arguments = (ins
        TF_Tensor:$cond,
        Variadic<TF_Tensor>:$input,
    
        FlatSymbolRefAttr:$then_branch,
        FlatSymbolRefAttr:$else_branch,
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Apr 24 04:08:35 UTC 2024
    - 90.5K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/tensorflow/tests/tensor_array_ops_decomposition.mlir

      // CHECK: "tf.If"(%[[COND]], %[[VAR]], %[[GVAR1]], %[[GVAR2]])
      %1 = "tf.If"(%cond, %ta#0) {
        then_branch = @then_branch, else_branch = @else_branch, device = "", is_stateless = false}
           : (tensor<i1>, tensor<!tf_type.resource>) -> tensor<!tf_type.resource>
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Mon Oct 30 06:52:55 UTC 2023
    - 49K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/tensorflow/tests/resource_op_lifting.mlir

        // CHECK: tf_device.return [[TRUE]] :
        tf_device.return %13 : tensor<i1>
      }) : () -> tensor<i1>
      func.return
    }
    
    // CHECK-LABEL: func @case_branch
    func.func @case_branch(%arg0: !tf_res) -> tensor<i1> {
      // CHECK: [[TRUE:%.+]] = "tf.Const"
      // CHECK-SAME: value = dense<true> : tensor<i1>
      %0 = "tf.VarIsInitializedOp"(%arg0) : (!tf_res) -> tensor<i1>
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Mon Oct 30 06:52:55 UTC 2023
    - 74K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/tensorflow/transforms/resource_op_lifting.cc

          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);
          (void)HoistForControlFlow(&else_branch.front(), module, vars_initialized,
    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

                                        /*operands=*/ArrayRef<Value>{});
    
      // Create empty else branch region.
      auto& else_branch = host_side_if.getElseBranch();
      else_branch.push_back(new Block);
      builder.setInsertionPointToEnd(&else_branch.front());
      builder.create<mlir::TF::YieldOp>(if_region.getLoc(),
                                        /*operands=*/ArrayRef<Value>{});
      return host_side_if;
    }
    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/lite/transforms/lower_static_tensor_list.cc

        CreateCondTrueBranch(op, shape_dtype, result_type, then_branch_op,
                             &rewriter);
        then_branch_op.setVisibility(func::FuncOp::Visibility::Private);
    
        // Constructs `else_branch`, which is executed when `if_cond` evaluates to
        // false.
        auto else_branch_op =
            rewriter.create<func::FuncOp>(loc, "cond_false", 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)
  7. tensorflow/compiler/mlir/lite/flatbuffer_import.cc

            mlir::SymbolRefAttr::get(builder.getContext(), func_names.at(else_idx));
    
        return llvm::SmallVector<mlir::NamedAttribute, 4>{
            builder.getNamedAttr("then_branch", then_attr),
            builder.getNamedAttr("else_branch", else_attr),
            // TODO(b/139667752): Analyze statelessness correctly
            builder.getNamedAttr("is_stateless", builder.getBoolAttr(false))};
      }
      if (auto* opts = options.AsWhileOptions()) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue May 21 18:21:50 UTC 2024
    - 66.8K bytes
    - Viewed (0)
  8. tensorflow/compiler/mlir/g3doc/_includes/tf_passes.md

    `tf.IfRegion` and `tf.While` is transformed to `tf.WhileRegion`.
    
    For example, this functional operation
    
    ```mlir
      %0 = "tf.If"(%arg0, %arg1) {
        then_branch = @then_branch_func, else_branch = @else_branch_func, is_stateless = false
      } : (tensor<i1>, tensor<*xf32>) -> tensor<*xf32>
    ```
    
    will be transformed into this region-based operation
    
    ```mlir
        %0 = "tf.IfRegion"(%arg0) ( {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Aug 02 02:26:39 UTC 2023
    - 96.4K bytes
    - Viewed (0)
Back to top