Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 5 of 5 for getNumRegions (0.16 sec)

  1. tensorflow/compiler/mlir/tensorflow/utils/call_graph_util.cc

                 << "Cannot find function " << sym.getRootReference();
        }
        callees.push_back(callee);
      }
      return success();
    }
    
    bool HasSingleBlock(func::FuncOp func) {
      return func->getNumRegions() == 1 && func.getBody().hasOneBlock();
    }
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 2.6K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/tensorflow/transforms/remove_unused_arguments.cc

    // This is a lengthy bit of code, since it has to recreate the operation.
    // TODO(kramm): Move this under utils/ somewhere.
    void EraseResults(Operation* op, llvm::BitVector erase) {
      assert(!op->getNumRegions());
      std::vector<Type> result_types;
      for (auto result : op->getResults()) {
        if (!erase[result.getResultNumber()]) {
          result_types.push_back(result.getType());
        }
      }
      OpBuilder builder(op);
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 8.9K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/quantization/tensorflow/passes/merge_duplicate_resource_ops.cc

    // Gets the GraphOp from the function op. Returns an empty op iff it doesn't
    // exist.
    // TODO(b/284222084): Move executor dialect utilities to a new library.
    GraphOp GetGraphOpFromFuncOp(func::FuncOp func_op) {
      if (func_op->getNumRegions() == 0 || func_op.getBody().empty()) return {};
    
      auto graph_op_range = func_op.front().without_terminator();
      if (llvm::hasSingleElement(graph_op_range)) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri May 26 04:26:16 UTC 2023
    - 4.7K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/tensorflow/transforms/tpu_parallel_execute_sink_resource_write.cc

    // such AssignVariableOp are also pruned.
    void SinkResourceWritesIntoParallelExecute(
        tf_device::ParallelExecuteOp parallel_execute) {
      bool rewrite = false;
      const int num_regions = parallel_execute.getNumRegions();
      llvm::SmallVector<Value, 4> results_to_remap;
    
      // Go through each region and find AssignVariableOps that can be moved into
      // the parallel_execute region. Result indices by region index are collected,
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Dec 06 04:46:18 UTC 2022
    - 6.6K bytes
    - Viewed (0)
  5. tensorflow/compiler/mlir/tensorflow/transforms/constant_fold_utils.cc

      // could be folded should have a custom folder instead of relying on the
      // TensorFlow folding hook.
      if (inst == nullptr || inst->getNumResults() == 0 ||
          inst->hasTrait<OpTrait::TF::NoConstantFold>() ||
          inst->getNumRegions() != 0 || !isMemoryEffectFree(inst)) {
        return false;
      }
    
      // If any of the result types are variants, don't try to constant fold them.
      // This creates opaque variant constants which lose information and would
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 7.3K bytes
    - Viewed (0)
Back to top