Search Options

Results per page
Sort
Preferred Languages
Advance

Results 21 - 30 of 42 for BlockArgument (0.19 sec)

  1. tensorflow/compiler/mlir/tensorflow/transforms/resource_device_inference.cc

              continue;
            }
            // Transfer the annotation to both region arguments
            for (Region* region : while_region.getRegions()) {
              BlockArgument arg = region->getArgument(output_index);
              LLVM_DEBUG(llvm::dbgs()
                         << "  Propagating device = '" << *device << "' to arg #"
                         << output_index << " of region #"
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri Mar 03 03:47:00 UTC 2023
    - 13.3K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/tensorflow/transforms/sparsecore/embedding_sequencing.cc

      // args. This will basically be our set increment fn.
      for (Operation* op : non_tpu_ops)
        for (Value input : op->getOperands())
          if (BlockArgument arg = llvm::dyn_cast<BlockArgument>(input))
            // TODO(bfontain): Check that this is actually an argument to the loop
            // body.
            non_tpu_args.insert(arg.getArgNumber());
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 39.4K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/tensorflow/transforms/cluster_tf_ops_pass.cc

          std::string value_device = "";
    
          // If the value is defined as an argument of the func_op, adds it to
          // the argument list of the function that uses this op.
          if (BlockArgument block_arg = mlir::dyn_cast<BlockArgument>(value)) {
            if (StringAttr attr = func_op.getArgAttrOfType<StringAttr>(
                    block_arg.getArgNumber(), kTFDeviceAttr)) {
              value_device = attr.getValue().str();
            }
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 13.4K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/quantization/tensorflow/passes/prepare_quantize.cc

        return (arg.hasOneUse() &&
                llvm::isa<quantfork::QuantizeCastOp>(*arg.user_begin()));
      };
    
      bool need_to_set_input_nodes_quantization_params = false;
      for (const BlockArgument arg : func.getArguments()) {
        auto shaped = mlir::dyn_cast<ShapedType>(arg.getType());
        if (shaped && mlir::isa<FloatType>(shaped.getElementType()) &&
            !has_quantize_op(arg)) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 17.2K bytes
    - Viewed (0)
  5. tensorflow/compiler/mlir/tensorflow/transforms/tensor_array_ops_decomposition.cc

      llvm::SmallDenseMap<int64_t, llvm::StringSet<>> result_sets;
      auto insert = [&](Value v, const string& source, const Block& func_block) {
        auto arg = v.dyn_cast<BlockArgument>();
        if (!arg || arg.getOwner() != &func_block) return;
        auto insert_res = result_sets[arg.getArgNumber()].insert(source);
        if (!insert_res.second) return;
        result[arg.getArgNumber()].push_back(source);
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Mar 02 20:41:19 UTC 2023
    - 40.2K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/lite/transforms/prepare_quantize.cc

        return (arg.hasOneUse() &&
                llvm::isa<quantfork::QuantizeCastOp>(*arg.user_begin()));
      };
    
      bool need_to_set_input_nodes_quantization_params = false;
      for (const BlockArgument arg : func.getArguments()) {
        auto shaped = mlir::dyn_cast<ShapedType>(arg.getType());
        if (shaped && mlir::isa<FloatType>(shaped.getElementType()) &&
            !has_quantize_op(arg)) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 17.6K bytes
    - Viewed (0)
  7. tensorflow/compiler/mlir/tensorflow/transforms/tpu_resource_partitioning.cc

      if (auto* resource_op = resource.getDefiningOp()) {
        return resource_op->getAttr(kDeviceAttr);
      } else {
        const auto resource_arg = resource.dyn_cast_or_null<BlockArgument>();
        if (resource_arg && (resource_arg.getOwner() == &(func.front()))) {
          return func.getArgAttrOfType<mlir::StringAttr>(
              resource_arg.getArgNumber(), kFuncDeviceAttr);
        } else {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Sep 06 19:12:29 UTC 2023
    - 11.8K bytes
    - Viewed (0)
  8. tensorflow/compiler/mlir/tensorflow/transforms/host_runtime/tpu_variable_runtime_reformatting.cc

        if (!arg.hasOneUse() ||
            !mlir::isa<TF::ResourceType>(getElementTypeOrSelf(arg.getType()))) {
          continue;
        }
        auto block_arg = mlir::dyn_cast<BlockArgument>(arg);
        if (!block_arg || block_arg.getOwner() != &replicate.GetBody()) continue;
        assert(replicate_arg_to_execute_arg.count(block_arg.getArgNumber()) == 0 &&
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 21.9K bytes
    - Viewed (0)
  9. tensorflow/compiler/mlir/quantization/tensorflow/passes/quantize_weights.cc

        }
        return success();
      }
    
     private:
      // Check if op's user or op's user after an identity op is connected to a
      // terminator.
      bool checkIfAnyUserIsConnectedToTermiantor(BlockArgument op) const {
        for (const auto& user : op.getUsers()) {
          if (user->template hasTrait<OpTrait::IsTerminator>()) return true;
          if (auto next_user = dyn_cast_or_null<TF::IdentityOp>(user)) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Mar 05 07:39:40 UTC 2024
    - 11.3K bytes
    - Viewed (0)
  10. tensorflow/compiler/mlir/quantization/stablehlo/passes/quantization_patterns.h

          return failure();
        }
    
        Operation* operand_op = operand.getDefiningOp();
        if (operand_op == nullptr) {
          // When `QuantizeOpT`'s operand does not have a defining op, it means it
          // is a `BlockArgument`. The pattern does not match if there is no op to
          // quantize.
          return failure();
        }
    
        if (operand_op->hasTrait<OpTrait::ConstantLike>()) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 10.9K bytes
    - Viewed (0)
Back to top