Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 3 of 3 for StablehloVhloTypeConverter (0.17 sec)

  1. tensorflow/compiler/mlir/lite/flatbuffer_operator.h

    // https://github.com/openxla/stablehlo/blob/e5ad51715a11721c78b6748ab5de7945df24b1b8/stablehlo/transforms/StablehloLegalizeToVhlo.cpp#L756
    // so we can create correct vhlo types
    class StablehloVhloTypeConverter : public mlir::vhlo::VhloTypeConverter {
     public:
      StablehloVhloTypeConverter() : mlir::vhlo::VhloTypeConverter() {
        addConversion([](mlir::Type type) -> mlir::Type {
          if (type.getDialect().getNamespace() ==
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu May 16 21:00:09 UTC 2024
    - 11.2K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/lite/flatbuffer_operator.cc

      return mlir::vhlo::BooleanV1Attr::get(builder.getContext(), value);
    }
    
    static mlir::Attribute BuildVhloIntV1Attr(int64_t value,
                                              mlir::Builder builder) {
      mlir::StablehloVhloTypeConverter type_converter;
      auto vhlo_type =
          type_converter.convertType(builder.getI64IntegerAttr(value).getType());
      return mlir::vhlo::IntegerV1Attr::get(builder.getContext(), vhlo_type,
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue May 21 18:21:50 UTC 2024
    - 38K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/lite/flatbuffer_import.cc

        value = mlir::TF::TensorProtoAttr::get(shaped_type, mangled);
      } else {
        return errors::Unimplemented("Constant of unsupported type");
      }
    
      if (use_stablehlo_constant) {
        mlir::StablehloVhloTypeConverter vhlo_type_converter;
        llvm::ArrayRef<char> val_ref(reinterpret_cast<const char*>(buffer.data()),
                                     buffer.size());
        auto vhlo_val = mlir::vhlo::TensorV1Attr::get(
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue May 21 18:21:50 UTC 2024
    - 66.8K bytes
    - Viewed (0)
Back to top