Search Options

Results per page
Sort
Preferred Languages
Advance

Results 31 - 40 of 86 for StringAttr (0.27 sec)

  1. tensorflow/compiler/mlir/tfr/passes/raise_to_tf.cc

        if (!matchPattern(input, m_Constant(&arg_value))) {
          return failure();
        }
        auto attr_name = signature.getArgAttrOfType<StringAttr>(
            operand.index(), kAttrArgumentNameAttr);
        auto attr_type = signature.getArgAttrOfType<StringAttr>(
            operand.index(), kAttrArgumentTypeAttr);
        auto value = ProcessAttributeValue(arg_value, attr_type);
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 21.8K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/tensorflow/transforms/decompose_reduce_dataset.cc

      // propagated to the reduce function call.
      reduce_call->setAttr(kDeviceAttr,
                           reduce_dataset->getAttrOfType<StringAttr>(kDeviceAttr));
      reduce_call->setAttr(
          TF::kCompileDeviceTypeAttr,
          reduce_dataset->getAttrOfType<StringAttr>(TF::kCompileDeviceTypeAttr));
    
      SmallVector<Value, 4> if_returns;
    
      builder.create<TF::YieldOp>(loc,
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 14K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/tensorflow/transforms/host_runtime/tpu_rewrite_pass.cc

        if (clone.getName() == entry_func.getName()) {
          // We can simply change name of TPU program's main function because there
          // should be no other reference to it.
          clone.setName(StringAttr::get(clone.getContext(), "main"));
          clone.setPublic();
        } else {
          clone.setPrivate();
        }
        symbol_table.insert(clone);
      }
    
      *serialized_func_module =
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Apr 30 21:25:12 UTC 2024
    - 29.7K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/quantization/tensorflow/passes/merge_initializer_function_ops_to_main.cc

    // initializer function. Assumes that there exists such an attribute.
    std::string GetInitializerType(func::FuncOp init_func_op) {
      return init_func_op
          ->getAttrOfType<StringAttr>(kTfSavedModelInitializerTypeAttr)
          .str();
    }
    
    // An initializer function should satisfy the follwing conditions:
    // * Its GraphOp should only have control outputs.
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Sun May 12 12:54:52 UTC 2024
    - 15.3K bytes
    - Viewed (0)
  5. tensorflow/compiler/mlir/lite/python/saved_model_to_tfl_flatbuffer.cc

      auto input_attr = tf_attrs.get("inputs");
      if (!input_attr) {
        return errors::InvalidArgument("no inputs attribute found");
      }
      auto input_names = mlir::cast<mlir::StringAttr>(input_attr).getValue();
      input_names.split(function_input_names, ",", /*MaxSplit=*/-1,
                        /*KeepEmpty=*/false);
      const int function_input_names_size = function_input_names.size();
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Sun May 12 12:39:37 UTC 2024
    - 11K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/tensorflow/transforms/tpu_resource_partitioning.cc

          return func.getArgAttrOfType<mlir::StringAttr>(
              resource_arg.getArgNumber(), kFuncDeviceAttr);
        } else {
          return mlir::Attribute{};
        }
      }
    }
    
    bool IsCompositeDevice(mlir::Attribute attr) {
      const auto str_attr = attr.dyn_cast_or_null<mlir::StringAttr>();
      return str_attr &&
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Sep 06 19:12:29 UTC 2023
    - 11.8K bytes
    - Viewed (0)
  7. tensorflow/compiler/mlir/tensorflow/utils/tf_xla_mlir_translate.cc

      size_t numRead;
      mlir::Attribute attr = mlir::parseAttribute(input, context, {}, &numRead);
      if (!attr || !mlir::isa<mlir::StringAttr>(attr)) {
        LOG(ERROR) << "Input is not parsable as a MLIR StringAttr.";
        return nullptr;
      }
      auto str_attr = mlir::cast<mlir::StringAttr>(attr);
    
      mlir::DialectRegistry registry;
      RegisterMlirInputDialects(registry);
      context->appendDialectRegistry(registry);
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 18.8K bytes
    - Viewed (0)
  8. tensorflow/compiler/mlir/tensorflow/transforms/replicate_to_island.cc

               << "requires device ordinal from device " << logical_core_name
               << " to be present in 'tf.device.replicate' op";
      }
      llvm::StringRef tpu_device =
          tpu_replica.cast<ArrayAttr>()[replica_id].cast<StringAttr>().getValue();
      return tensorflow::GetDeviceOrdinalFromDeviceString(op->getLoc(), tpu_device,
                                                          &device_ordinal);
    }
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Mon Jul 24 21:01:40 UTC 2023
    - 16.9K bytes
    - Viewed (0)
  9. tensorflow/compiler/mlir/quantization/common/attrs_and_constraints.h

    // Checks whether the given op contains QuantizationTrait::FullyQuantizable.
    inline bool HasQuantizableTrait(Operation* op) {
      return op->hasAttrOfType<StringAttr>(kQuantTraitAttrName) &&
             op->getAttrOfType<StringAttr>(kQuantTraitAttrName).getValue().str() ==
                 QuantTraitValues[QuantizationTrait::FullyQuantizable];
    }
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 9.9K bytes
    - Viewed (0)
  10. tensorflow/compiler/mlir/tensorflow/transforms/executor_tpuv1_island_coarsening.cc

    // returns `std::nullopt`.
    std::optional<llvm::StringRef> GetTpuClusterName(Operation* op) {
      if (auto tpu_status = op->getAttrOfType<StringAttr>(kTpuStatusAttr)) {
        // Borrow cluster name from TPU status (for `TPUCompilationResult` op).
        return tpu_status.getValue();
      }
      auto device_type = op->getAttrOfType<StringAttr>(TF::kCompileDeviceTypeAttr);
      if (!device_type || device_type.getValue() != TF::kTpuDevice) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri May 17 17:58:54 UTC 2024
    - 27.6K bytes
    - Viewed (0)
Back to top