// Generated by the protocol buffer compiler.  DO NOT EDIT!
// NO CHECKED-IN PROTOBUF GENCODE
// source: graph.proto
// Protobuf C++ Version: 6.32.1

#include "graph.pb.h"

#include <algorithm>
#include <type_traits>
#include "google/protobuf/io/coded_stream.h"
#include "google/protobuf/generated_message_tctable_impl.h"
#include "google/protobuf/extension_set.h"
#include "google/protobuf/generated_message_util.h"
#include "google/protobuf/wire_format_lite.h"
#include "google/protobuf/descriptor.h"
#include "google/protobuf/generated_message_reflection.h"
#include "google/protobuf/reflection_ops.h"
#include "google/protobuf/wire_format.h"
// @@protoc_insertion_point(includes)

// Must be included last.
#include "google/protobuf/port_def.inc"
PROTOBUF_PRAGMA_INIT_SEG
namespace _pb = ::google::protobuf;
namespace _pbi = ::google::protobuf::internal;
namespace _fl = ::google::protobuf::internal::field_layout;
namespace opencv_tensorflow {
template <typename>
PROTOBUF_CONSTEXPR NodeDef_AttrEntry_DoNotUse::NodeDef_AttrEntry_DoNotUse(::_pbi::ConstantInitialized)
#if defined(PROTOBUF_CUSTOM_VTABLE)
    : NodeDef_AttrEntry_DoNotUse::MapEntry(NodeDef_AttrEntry_DoNotUse_class_data_.base()){}
#else   // PROTOBUF_CUSTOM_VTABLE
    : NodeDef_AttrEntry_DoNotUse::MapEntry() {
}
#endif  // PROTOBUF_CUSTOM_VTABLE
struct NodeDef_AttrEntry_DoNotUseDefaultTypeInternal {
  PROTOBUF_CONSTEXPR NodeDef_AttrEntry_DoNotUseDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~NodeDef_AttrEntry_DoNotUseDefaultTypeInternal() {}
  union {
    NodeDef_AttrEntry_DoNotUse _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 NodeDef_AttrEntry_DoNotUseDefaultTypeInternal _NodeDef_AttrEntry_DoNotUse_default_instance_;

inline constexpr NodeDef::Impl_::Impl_(
    ::_pbi::ConstantInitialized) noexcept
      : _cached_size_{0},
        input_{},
        attr_{},
        name_(
            &::google::protobuf::internal::fixed_address_empty_string,
            ::_pbi::ConstantInitialized()),
        op_(
            &::google::protobuf::internal::fixed_address_empty_string,
            ::_pbi::ConstantInitialized()),
        device_(
            &::google::protobuf::internal::fixed_address_empty_string,
            ::_pbi::ConstantInitialized()) {}

template <typename>
PROTOBUF_CONSTEXPR NodeDef::NodeDef(::_pbi::ConstantInitialized)
#if defined(PROTOBUF_CUSTOM_VTABLE)
    : ::google::protobuf::Message(NodeDef_class_data_.base()),
#else   // PROTOBUF_CUSTOM_VTABLE
    : ::google::protobuf::Message(),
#endif  // PROTOBUF_CUSTOM_VTABLE
      _impl_(::_pbi::ConstantInitialized()) {
}
struct NodeDefDefaultTypeInternal {
  PROTOBUF_CONSTEXPR NodeDefDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~NodeDefDefaultTypeInternal() {}
  union {
    NodeDef _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 NodeDefDefaultTypeInternal _NodeDef_default_instance_;

inline constexpr GraphDef::Impl_::Impl_(
    ::_pbi::ConstantInitialized) noexcept
      : _cached_size_{0},
        node_{},
        library_{nullptr},
        versions_{nullptr},
        version_{0} {}

template <typename>
PROTOBUF_CONSTEXPR GraphDef::GraphDef(::_pbi::ConstantInitialized)
#if defined(PROTOBUF_CUSTOM_VTABLE)
    : ::google::protobuf::Message(GraphDef_class_data_.base()),
#else   // PROTOBUF_CUSTOM_VTABLE
    : ::google::protobuf::Message(),
#endif  // PROTOBUF_CUSTOM_VTABLE
      _impl_(::_pbi::ConstantInitialized()) {
}
struct GraphDefDefaultTypeInternal {
  PROTOBUF_CONSTEXPR GraphDefDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {}
  ~GraphDefDefaultTypeInternal() {}
  union {
    GraphDef _instance;
  };
};

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 GraphDefDefaultTypeInternal _GraphDef_default_instance_;
}  // namespace opencv_tensorflow
static constexpr const ::_pb::EnumDescriptor *PROTOBUF_NONNULL *PROTOBUF_NULLABLE
    file_level_enum_descriptors_graph_2eproto = nullptr;
static constexpr const ::_pb::ServiceDescriptor *PROTOBUF_NONNULL *PROTOBUF_NULLABLE
    file_level_service_descriptors_graph_2eproto = nullptr;
const ::uint32_t
    TableStruct_graph_2eproto::offsets[] ABSL_ATTRIBUTE_SECTION_VARIABLE(
        protodesc_cold) = {
        0x081, // bitmap
        PROTOBUF_FIELD_OFFSET(::opencv_tensorflow::GraphDef, _impl_._has_bits_),
        7, // hasbit index offset
        PROTOBUF_FIELD_OFFSET(::opencv_tensorflow::GraphDef, _impl_.node_),
        PROTOBUF_FIELD_OFFSET(::opencv_tensorflow::GraphDef, _impl_.versions_),
        PROTOBUF_FIELD_OFFSET(::opencv_tensorflow::GraphDef, _impl_.version_),
        PROTOBUF_FIELD_OFFSET(::opencv_tensorflow::GraphDef, _impl_.library_),
        ~0u,
        1,
        2,
        0,
        0x081, // bitmap
        PROTOBUF_FIELD_OFFSET(::opencv_tensorflow::NodeDef_AttrEntry_DoNotUse, _impl_._has_bits_),
        5, // hasbit index offset
        PROTOBUF_FIELD_OFFSET(::opencv_tensorflow::NodeDef_AttrEntry_DoNotUse, _impl_.key_),
        PROTOBUF_FIELD_OFFSET(::opencv_tensorflow::NodeDef_AttrEntry_DoNotUse, _impl_.value_),
        0,
        1,
        0x081, // bitmap
        PROTOBUF_FIELD_OFFSET(::opencv_tensorflow::NodeDef, _impl_._has_bits_),
        8, // hasbit index offset
        PROTOBUF_FIELD_OFFSET(::opencv_tensorflow::NodeDef, _impl_.name_),
        PROTOBUF_FIELD_OFFSET(::opencv_tensorflow::NodeDef, _impl_.op_),
        PROTOBUF_FIELD_OFFSET(::opencv_tensorflow::NodeDef, _impl_.input_),
        PROTOBUF_FIELD_OFFSET(::opencv_tensorflow::NodeDef, _impl_.device_),
        PROTOBUF_FIELD_OFFSET(::opencv_tensorflow::NodeDef, _impl_.attr_),
        0,
        1,
        ~0u,
        2,
        ~0u,
};

static const ::_pbi::MigrationSchema
    schemas[] ABSL_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = {
        {0, sizeof(::opencv_tensorflow::GraphDef)},
        {11, sizeof(::opencv_tensorflow::NodeDef_AttrEntry_DoNotUse)},
        {18, sizeof(::opencv_tensorflow::NodeDef)},
};
static const ::_pb::Message* PROTOBUF_NONNULL const file_default_instances[] = {
    &::opencv_tensorflow::_GraphDef_default_instance_._instance,
    &::opencv_tensorflow::_NodeDef_AttrEntry_DoNotUse_default_instance_._instance,
    &::opencv_tensorflow::_NodeDef_default_instance_._instance,
};
const char descriptor_table_protodef_graph_2eproto[] ABSL_ATTRIBUTE_SECTION_VARIABLE(
    protodesc_cold) = {
    "\n\013graph.proto\022\021opencv_tensorflow\032\020attr_v"
    "alue.proto\032\016function.proto\032\016versions.pro"
    "to\"\262\001\n\010GraphDef\022(\n\004node\030\001 \003(\0132\032.opencv_t"
    "ensorflow.NodeDef\022/\n\010versions\030\004 \001(\0132\035.op"
    "encv_tensorflow.VersionDef\022\023\n\007version\030\003 "
    "\001(\005B\002\030\001\0226\n\007library\030\002 \001(\0132%.opencv_tensor"
    "flow.FunctionDefLibrary\"\301\001\n\007NodeDef\022\014\n\004n"
    "ame\030\001 \001(\t\022\n\n\002op\030\002 \001(\t\022\r\n\005input\030\003 \003(\t\022\016\n\006"
    "device\030\004 \001(\t\0222\n\004attr\030\005 \003(\0132$.opencv_tens"
    "orflow.NodeDef.AttrEntry\032I\n\tAttrEntry\022\013\n"
    "\003key\030\001 \001(\t\022+\n\005value\030\002 \001(\0132\034.opencv_tenso"
    "rflow.AttrValue:\0028\001B,\n\030org.tensorflow.fr"
    "ameworkB\013GraphProtosP\001\370\001\001b\006proto3"
};
static const ::_pbi::DescriptorTable* PROTOBUF_NONNULL const
    descriptor_table_graph_2eproto_deps[3] = {
        &::descriptor_table_attr_5fvalue_2eproto,
        &::descriptor_table_function_2eproto,
        &::descriptor_table_versions_2eproto,
};
static ::absl::once_flag descriptor_table_graph_2eproto_once;
PROTOBUF_CONSTINIT const ::_pbi::DescriptorTable descriptor_table_graph_2eproto = {
    false,
    false,
    513,
    descriptor_table_protodef_graph_2eproto,
    "graph.proto",
    &descriptor_table_graph_2eproto_once,
    descriptor_table_graph_2eproto_deps,
    3,
    3,
    schemas,
    file_default_instances,
    TableStruct_graph_2eproto::offsets,
    file_level_enum_descriptors_graph_2eproto,
    file_level_service_descriptors_graph_2eproto,
};
namespace opencv_tensorflow {
// ===================================================================

class GraphDef::_Internal {
 public:
  using HasBits =
      decltype(::std::declval<GraphDef>()._impl_._has_bits_);
  static constexpr ::int32_t kHasBitsOffset =
      8 * PROTOBUF_FIELD_OFFSET(GraphDef, _impl_._has_bits_);
};

void GraphDef::clear_versions() {
  ::google::protobuf::internal::TSanWrite(&_impl_);
  if (_impl_.versions_ != nullptr) _impl_.versions_->Clear();
  _impl_._has_bits_[0] &= ~0x00000002U;
}
void GraphDef::clear_library() {
  ::google::protobuf::internal::TSanWrite(&_impl_);
  if (_impl_.library_ != nullptr) _impl_.library_->Clear();
  _impl_._has_bits_[0] &= ~0x00000001U;
}
GraphDef::GraphDef(::google::protobuf::Arena* PROTOBUF_NULLABLE arena)
#if defined(PROTOBUF_CUSTOM_VTABLE)
    : ::google::protobuf::Message(arena, GraphDef_class_data_.base()) {
#else   // PROTOBUF_CUSTOM_VTABLE
    : ::google::protobuf::Message(arena) {
#endif  // PROTOBUF_CUSTOM_VTABLE
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:opencv_tensorflow.GraphDef)
}
PROTOBUF_NDEBUG_INLINE GraphDef::Impl_::Impl_(
    [[maybe_unused]] ::google::protobuf::internal::InternalVisibility visibility,
    [[maybe_unused]] ::google::protobuf::Arena* PROTOBUF_NULLABLE arena, const Impl_& from,
    [[maybe_unused]] const ::opencv_tensorflow::GraphDef& from_msg)
      : _has_bits_{from._has_bits_},
        _cached_size_{0},
        node_{visibility, arena, from.node_} {}

GraphDef::GraphDef(
    ::google::protobuf::Arena* PROTOBUF_NULLABLE arena,
    const GraphDef& from)
#if defined(PROTOBUF_CUSTOM_VTABLE)
    : ::google::protobuf::Message(arena, GraphDef_class_data_.base()) {
#else   // PROTOBUF_CUSTOM_VTABLE
    : ::google::protobuf::Message(arena) {
#endif  // PROTOBUF_CUSTOM_VTABLE
  GraphDef* const _this = this;
  (void)_this;
  _internal_metadata_.MergeFrom<::google::protobuf::UnknownFieldSet>(
      from._internal_metadata_);
  new (&_impl_) Impl_(internal_visibility(), arena, from._impl_, from);
  ::uint32_t cached_has_bits = _impl_._has_bits_[0];
  _impl_.library_ = ((cached_has_bits & 0x00000001U) != 0)
                ? ::google::protobuf::Message::CopyConstruct(arena, *from._impl_.library_)
                : nullptr;
  _impl_.versions_ = ((cached_has_bits & 0x00000002U) != 0)
                ? ::google::protobuf::Message::CopyConstruct(arena, *from._impl_.versions_)
                : nullptr;
  _impl_.version_ = from._impl_.version_;

  // @@protoc_insertion_point(copy_constructor:opencv_tensorflow.GraphDef)
}
PROTOBUF_NDEBUG_INLINE GraphDef::Impl_::Impl_(
    [[maybe_unused]] ::google::protobuf::internal::InternalVisibility visibility,
    [[maybe_unused]] ::google::protobuf::Arena* PROTOBUF_NULLABLE arena)
      : _cached_size_{0},
        node_{visibility, arena} {}

inline void GraphDef::SharedCtor(::_pb::Arena* PROTOBUF_NULLABLE arena) {
  new (&_impl_) Impl_(internal_visibility(), arena);
  ::memset(reinterpret_cast<char *>(&_impl_) +
               offsetof(Impl_, library_),
           0,
           offsetof(Impl_, version_) -
               offsetof(Impl_, library_) +
               sizeof(Impl_::version_));
}
GraphDef::~GraphDef() {
  // @@protoc_insertion_point(destructor:opencv_tensorflow.GraphDef)
  SharedDtor(*this);
}
inline void GraphDef::SharedDtor(MessageLite& self) {
  GraphDef& this_ = static_cast<GraphDef&>(self);
  if constexpr (::_pbi::DebugHardenVerifyHasBitConsistency()) {
    this_.VerifyHasBitConsistency();
  }
  this_._internal_metadata_.Delete<::google::protobuf::UnknownFieldSet>();
  ABSL_DCHECK(this_.GetArena() == nullptr);
  delete this_._impl_.library_;
  delete this_._impl_.versions_;
  this_._impl_.~Impl_();
}

inline void* PROTOBUF_NONNULL GraphDef::PlacementNew_(
    const void* PROTOBUF_NONNULL, void* PROTOBUF_NONNULL mem,
    ::google::protobuf::Arena* PROTOBUF_NULLABLE arena) {
  return ::new (mem) GraphDef(arena);
}
constexpr auto GraphDef::InternalNewImpl_() {
  constexpr auto arena_bits = ::google::protobuf::internal::EncodePlacementArenaOffsets({
      PROTOBUF_FIELD_OFFSET(GraphDef, _impl_.node_) +
          decltype(GraphDef::_impl_.node_)::
              InternalGetArenaOffset(
                  ::google::protobuf::Message::internal_visibility()),
  });
  if (arena_bits.has_value()) {
    return ::google::protobuf::internal::MessageCreator::ZeroInit(
        sizeof(GraphDef), alignof(GraphDef), *arena_bits);
  } else {
    return ::google::protobuf::internal::MessageCreator(&GraphDef::PlacementNew_,
                                 sizeof(GraphDef),
                                 alignof(GraphDef));
  }
}
constexpr auto GraphDef::InternalGenerateClassData_() {
  return ::google::protobuf::internal::ClassDataFull{
      ::google::protobuf::internal::ClassData{
          &_GraphDef_default_instance_._instance,
          &_table_.header,
          nullptr,  // OnDemandRegisterArenaDtor
          nullptr,  // IsInitialized
          &GraphDef::MergeImpl,
          ::google::protobuf::Message::GetNewImpl<GraphDef>(),
#if defined(PROTOBUF_CUSTOM_VTABLE)
          &GraphDef::SharedDtor,
          ::google::protobuf::Message::GetClearImpl<GraphDef>(), &GraphDef::ByteSizeLong,
              &GraphDef::_InternalSerialize,
#endif  // PROTOBUF_CUSTOM_VTABLE
          PROTOBUF_FIELD_OFFSET(GraphDef, _impl_._cached_size_),
          false,
      },
      &GraphDef::kDescriptorMethods,
      &descriptor_table_graph_2eproto,
      nullptr,  // tracker
  };
}

PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 const
    ::google::protobuf::internal::ClassDataFull GraphDef_class_data_ =
        GraphDef::InternalGenerateClassData_();

PROTOBUF_ATTRIBUTE_WEAK const ::google::protobuf::internal::ClassData* PROTOBUF_NONNULL
GraphDef::GetClassData() const {
  ::google::protobuf::internal::PrefetchToLocalCache(&GraphDef_class_data_);
  ::google::protobuf::internal::PrefetchToLocalCache(GraphDef_class_data_.tc_table);
  return GraphDef_class_data_.base();
}
PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1
const ::_pbi::TcParseTable<2, 4, 3, 0, 2>
GraphDef::_table_ = {
  {
    PROTOBUF_FIELD_OFFSET(GraphDef, _impl_._has_bits_),
    0, // no _extensions_
    4, 24,  // max_field_number, fast_idx_mask
    offsetof(decltype(_table_), field_lookup_table),
    4294967280,  // skipmap
    offsetof(decltype(_table_), field_entries),
    4,  // num_field_entries
    3,  // num_aux_entries
    offsetof(decltype(_table_), aux_entries),
    GraphDef_class_data_.base(),
    nullptr,  // post_loop_handler
    ::_pbi::TcParser::GenericFallback,  // fallback
    #ifdef PROTOBUF_PREFETCH_PARSE_TABLE
    ::_pbi::TcParser::GetTable<::opencv_tensorflow::GraphDef>(),  // to_prefetch
    #endif  // PROTOBUF_PREFETCH_PARSE_TABLE
  }, {{
    // .opencv_tensorflow.VersionDef versions = 4;
    {::_pbi::TcParser::FastMtS1,
     {34, 1, 2, PROTOBUF_FIELD_OFFSET(GraphDef, _impl_.versions_)}},
    // repeated .opencv_tensorflow.NodeDef node = 1;
    {::_pbi::TcParser::FastMtR1,
     {10, 63, 0, PROTOBUF_FIELD_OFFSET(GraphDef, _impl_.node_)}},
    // .opencv_tensorflow.FunctionDefLibrary library = 2;
    {::_pbi::TcParser::FastMtS1,
     {18, 0, 1, PROTOBUF_FIELD_OFFSET(GraphDef, _impl_.library_)}},
    // int32 version = 3 [deprecated = true];
    {::_pbi::TcParser::SingularVarintNoZag1<::uint32_t, offsetof(GraphDef, _impl_.version_), 2>(),
     {24, 2, 0, PROTOBUF_FIELD_OFFSET(GraphDef, _impl_.version_)}},
  }}, {{
    65535, 65535
  }}, {{
    // repeated .opencv_tensorflow.NodeDef node = 1;
    {PROTOBUF_FIELD_OFFSET(GraphDef, _impl_.node_), -1, 0, (0 | ::_fl::kFcRepeated | ::_fl::kMessage | ::_fl::kTvTable)},
    // .opencv_tensorflow.FunctionDefLibrary library = 2;
    {PROTOBUF_FIELD_OFFSET(GraphDef, _impl_.library_), _Internal::kHasBitsOffset + 0, 1, (0 | ::_fl::kFcOptional | ::_fl::kMessage | ::_fl::kTvTable)},
    // int32 version = 3 [deprecated = true];
    {PROTOBUF_FIELD_OFFSET(GraphDef, _impl_.version_), _Internal::kHasBitsOffset + 2, 0, (0 | ::_fl::kFcOptional | ::_fl::kInt32)},
    // .opencv_tensorflow.VersionDef versions = 4;
    {PROTOBUF_FIELD_OFFSET(GraphDef, _impl_.versions_), _Internal::kHasBitsOffset + 1, 2, (0 | ::_fl::kFcOptional | ::_fl::kMessage | ::_fl::kTvTable)},
  }},
  {{
      {::_pbi::TcParser::GetTable<::opencv_tensorflow::NodeDef>()},
      {::_pbi::TcParser::GetTable<::opencv_tensorflow::FunctionDefLibrary>()},
      {::_pbi::TcParser::GetTable<::opencv_tensorflow::VersionDef>()},
  }},
  {{
  }},
};
PROTOBUF_NOINLINE void GraphDef::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_tensorflow.GraphDef)
  ::google::protobuf::internal::TSanWrite(&_impl_);
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  _impl_.node_.Clear();
  cached_has_bits = _impl_._has_bits_[0];
  if ((cached_has_bits & 0x00000003U) != 0) {
    if ((cached_has_bits & 0x00000001U) != 0) {
      ABSL_DCHECK(_impl_.library_ != nullptr);
      _impl_.library_->Clear();
    }
    if ((cached_has_bits & 0x00000002U) != 0) {
      ABSL_DCHECK(_impl_.versions_ != nullptr);
      _impl_.versions_->Clear();
    }
  }
  _impl_.version_ = 0;
  _impl_._has_bits_.Clear();
  _internal_metadata_.Clear<::google::protobuf::UnknownFieldSet>();
}

#if defined(PROTOBUF_CUSTOM_VTABLE)
::uint8_t* PROTOBUF_NONNULL GraphDef::_InternalSerialize(
    const ::google::protobuf::MessageLite& base, ::uint8_t* PROTOBUF_NONNULL target,
    ::google::protobuf::io::EpsCopyOutputStream* PROTOBUF_NONNULL stream) {
  const GraphDef& this_ = static_cast<const GraphDef&>(base);
#else   // PROTOBUF_CUSTOM_VTABLE
::uint8_t* PROTOBUF_NONNULL GraphDef::_InternalSerialize(
    ::uint8_t* PROTOBUF_NONNULL target,
    ::google::protobuf::io::EpsCopyOutputStream* PROTOBUF_NONNULL stream) const {
  const GraphDef& this_ = *this;
#endif  // PROTOBUF_CUSTOM_VTABLE
  if constexpr (::_pbi::DebugHardenVerifyHasBitConsistency()) {
    this_.VerifyHasBitConsistency();
  }
  // @@protoc_insertion_point(serialize_to_array_start:opencv_tensorflow.GraphDef)
  ::uint32_t cached_has_bits = 0;
  (void)cached_has_bits;

  // repeated .opencv_tensorflow.NodeDef node = 1;
  for (unsigned i = 0, n = static_cast<unsigned>(
                           this_._internal_node_size());
       i < n; i++) {
    const auto& repfield = this_._internal_node().Get(i);
    target =
        ::google::protobuf::internal::WireFormatLite::InternalWriteMessage(
            1, repfield, repfield.GetCachedSize(),
            target, stream);
  }

  cached_has_bits = this_._impl_._has_bits_[0];
  // .opencv_tensorflow.FunctionDefLibrary library = 2;
  if ((cached_has_bits & 0x00000001U) != 0) {
    target = ::google::protobuf::internal::WireFormatLite::InternalWriteMessage(
        2, *this_._impl_.library_, this_._impl_.library_->GetCachedSize(), target,
        stream);
  }

  // int32 version = 3 [deprecated = true];
  if ((cached_has_bits & 0x00000004U) != 0) {
    if (this_._internal_version() != 0) {
      target =
          ::google::protobuf::internal::WireFormatLite::WriteInt32ToArrayWithField<3>(
              stream, this_._internal_version(), target);
    }
  }

  // .opencv_tensorflow.VersionDef versions = 4;
  if ((cached_has_bits & 0x00000002U) != 0) {
    target = ::google::protobuf::internal::WireFormatLite::InternalWriteMessage(
        4, *this_._impl_.versions_, this_._impl_.versions_->GetCachedSize(), target,
        stream);
  }

  if (ABSL_PREDICT_FALSE(this_._internal_metadata_.have_unknown_fields())) {
    target =
        ::_pbi::WireFormat::InternalSerializeUnknownFieldsToArray(
            this_._internal_metadata_.unknown_fields<::google::protobuf::UnknownFieldSet>(::google::protobuf::UnknownFieldSet::default_instance), target, stream);
  }
  // @@protoc_insertion_point(serialize_to_array_end:opencv_tensorflow.GraphDef)
  return target;
}

#if defined(PROTOBUF_CUSTOM_VTABLE)
::size_t GraphDef::ByteSizeLong(const MessageLite& base) {
  const GraphDef& this_ = static_cast<const GraphDef&>(base);
#else   // PROTOBUF_CUSTOM_VTABLE
::size_t GraphDef::ByteSizeLong() const {
  const GraphDef& this_ = *this;
#endif  // PROTOBUF_CUSTOM_VTABLE
  // @@protoc_insertion_point(message_byte_size_start:opencv_tensorflow.GraphDef)
  ::size_t total_size = 0;

  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void)cached_has_bits;

  ::_pbi::Prefetch5LinesFrom7Lines(&this_);
   {
    // repeated .opencv_tensorflow.NodeDef node = 1;
    {
      total_size += 1UL * this_._internal_node_size();
      for (const auto& msg : this_._internal_node()) {
        total_size += ::google::protobuf::internal::WireFormatLite::MessageSize(msg);
      }
    }
  }
  cached_has_bits = this_._impl_._has_bits_[0];
  if ((cached_has_bits & 0x00000007U) != 0) {
    // .opencv_tensorflow.FunctionDefLibrary library = 2;
    if ((cached_has_bits & 0x00000001U) != 0) {
      total_size += 1 +
                    ::google::protobuf::internal::WireFormatLite::MessageSize(*this_._impl_.library_);
    }
    // .opencv_tensorflow.VersionDef versions = 4;
    if ((cached_has_bits & 0x00000002U) != 0) {
      total_size += 1 +
                    ::google::protobuf::internal::WireFormatLite::MessageSize(*this_._impl_.versions_);
    }
    // int32 version = 3 [deprecated = true];
    if ((cached_has_bits & 0x00000004U) != 0) {
      if (this_._internal_version() != 0) {
        total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(
            this_._internal_version());
      }
    }
  }
  return this_.MaybeComputeUnknownFieldsSize(total_size,
                                             &this_._impl_._cached_size_);
}

void GraphDef::MergeImpl(::google::protobuf::MessageLite& to_msg, const ::google::protobuf::MessageLite& from_msg) {
  auto* const _this = static_cast<GraphDef*>(&to_msg);
  auto& from = static_cast<const GraphDef&>(from_msg);
  if constexpr (::_pbi::DebugHardenVerifyHasBitConsistency()) {
    from.VerifyHasBitConsistency();
  }
  ::google::protobuf::Arena* arena = _this->GetArena();
  // @@protoc_insertion_point(class_specific_merge_from_start:opencv_tensorflow.GraphDef)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  _this->_internal_mutable_node()->MergeFrom(
      from._internal_node());
  cached_has_bits = from._impl_._has_bits_[0];
  if ((cached_has_bits & 0x00000007U) != 0) {
    if ((cached_has_bits & 0x00000001U) != 0) {
      ABSL_DCHECK(from._impl_.library_ != nullptr);
      if (_this->_impl_.library_ == nullptr) {
        _this->_impl_.library_ = ::google::protobuf::Message::CopyConstruct(arena, *from._impl_.library_);
      } else {
        _this->_impl_.library_->MergeFrom(*from._impl_.library_);
      }
    }
    if ((cached_has_bits & 0x00000002U) != 0) {
      ABSL_DCHECK(from._impl_.versions_ != nullptr);
      if (_this->_impl_.versions_ == nullptr) {
        _this->_impl_.versions_ = ::google::protobuf::Message::CopyConstruct(arena, *from._impl_.versions_);
      } else {
        _this->_impl_.versions_->MergeFrom(*from._impl_.versions_);
      }
    }
    if ((cached_has_bits & 0x00000004U) != 0) {
      if (from._internal_version() != 0) {
        _this->_impl_.version_ = from._impl_.version_;
      }
    }
  }
  _this->_impl_._has_bits_[0] |= cached_has_bits;
  _this->_internal_metadata_.MergeFrom<::google::protobuf::UnknownFieldSet>(from._internal_metadata_);
}

void GraphDef::CopyFrom(const GraphDef& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_tensorflow.GraphDef)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}


void GraphDef::InternalSwap(GraphDef* PROTOBUF_RESTRICT PROTOBUF_NONNULL other) {
  using ::std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
  _impl_.node_.InternalSwap(&other->_impl_.node_);
  ::google::protobuf::internal::memswap<
      PROTOBUF_FIELD_OFFSET(GraphDef, _impl_.version_)
      + sizeof(GraphDef::_impl_.version_)
      - PROTOBUF_FIELD_OFFSET(GraphDef, _impl_.library_)>(
          reinterpret_cast<char*>(&_impl_.library_),
          reinterpret_cast<char*>(&other->_impl_.library_));
}

::google::protobuf::Metadata GraphDef::GetMetadata() const {
  return ::google::protobuf::Message::GetMetadataImpl(GetClassData()->full());
}
// ===================================================================

#if defined(PROTOBUF_CUSTOM_VTABLE)
NodeDef_AttrEntry_DoNotUse::NodeDef_AttrEntry_DoNotUse()
    : SuperType(NodeDef_AttrEntry_DoNotUse_class_data_.base()) {}
NodeDef_AttrEntry_DoNotUse::NodeDef_AttrEntry_DoNotUse(::google::protobuf::Arena* PROTOBUF_NULLABLE arena)
    : SuperType(arena, NodeDef_AttrEntry_DoNotUse_class_data_.base()) {}
#else   // PROTOBUF_CUSTOM_VTABLE
NodeDef_AttrEntry_DoNotUse::NodeDef_AttrEntry_DoNotUse() : SuperType() {}
NodeDef_AttrEntry_DoNotUse::NodeDef_AttrEntry_DoNotUse(::google::protobuf::Arena* PROTOBUF_NULLABLE arena) : SuperType(arena) {}
#endif  // PROTOBUF_CUSTOM_VTABLE
inline void* PROTOBUF_NONNULL NodeDef_AttrEntry_DoNotUse::PlacementNew_(
    const void* PROTOBUF_NONNULL, void* PROTOBUF_NONNULL mem,
    ::google::protobuf::Arena* PROTOBUF_NULLABLE arena) {
  return ::new (mem) NodeDef_AttrEntry_DoNotUse(arena);
}
constexpr auto NodeDef_AttrEntry_DoNotUse::InternalNewImpl_() {
  return ::google::protobuf::internal::MessageCreator::CopyInit(sizeof(NodeDef_AttrEntry_DoNotUse),
                                            alignof(NodeDef_AttrEntry_DoNotUse));
}
constexpr auto NodeDef_AttrEntry_DoNotUse::InternalGenerateClassData_() {
  return ::google::protobuf::internal::ClassDataFull{
      ::google::protobuf::internal::ClassData{
          &_NodeDef_AttrEntry_DoNotUse_default_instance_._instance,
          &_table_.header,
          nullptr,  // OnDemandRegisterArenaDtor
          nullptr,  // IsInitialized
          &NodeDef_AttrEntry_DoNotUse::MergeImpl,
          ::google::protobuf::Message::GetNewImpl<NodeDef_AttrEntry_DoNotUse>(),
#if defined(PROTOBUF_CUSTOM_VTABLE)
          &NodeDef_AttrEntry_DoNotUse::SharedDtor,
          static_cast<void (::google::protobuf::MessageLite::*)()>(&NodeDef_AttrEntry_DoNotUse::ClearImpl),
              ::google::protobuf::Message::ByteSizeLongImpl, ::google::protobuf::Message::_InternalSerializeImpl
              ,
#endif  // PROTOBUF_CUSTOM_VTABLE
          PROTOBUF_FIELD_OFFSET(NodeDef_AttrEntry_DoNotUse, _impl_._cached_size_),
          false,
      },
      &NodeDef_AttrEntry_DoNotUse::kDescriptorMethods,
      &descriptor_table_graph_2eproto,
      nullptr,  // tracker
  };
}

PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 const
    ::google::protobuf::internal::ClassDataFull NodeDef_AttrEntry_DoNotUse_class_data_ =
        NodeDef_AttrEntry_DoNotUse::InternalGenerateClassData_();

PROTOBUF_ATTRIBUTE_WEAK const ::google::protobuf::internal::ClassData* PROTOBUF_NONNULL
NodeDef_AttrEntry_DoNotUse::GetClassData() const {
  ::google::protobuf::internal::PrefetchToLocalCache(&NodeDef_AttrEntry_DoNotUse_class_data_);
  ::google::protobuf::internal::PrefetchToLocalCache(NodeDef_AttrEntry_DoNotUse_class_data_.tc_table);
  return NodeDef_AttrEntry_DoNotUse_class_data_.base();
}
PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1
const ::_pbi::TcParseTable<1, 2, 1, 47, 2>
NodeDef_AttrEntry_DoNotUse::_table_ = {
  {
    PROTOBUF_FIELD_OFFSET(NodeDef_AttrEntry_DoNotUse, _impl_._has_bits_),
    0, // no _extensions_
    2, 8,  // max_field_number, fast_idx_mask
    offsetof(decltype(_table_), field_lookup_table),
    4294967292,  // skipmap
    offsetof(decltype(_table_), field_entries),
    2,  // num_field_entries
    1,  // num_aux_entries
    offsetof(decltype(_table_), aux_entries),
    NodeDef_AttrEntry_DoNotUse_class_data_.base(),
    nullptr,  // post_loop_handler
    ::_pbi::TcParser::DiscardEverythingFallback,  // fallback
    #ifdef PROTOBUF_PREFETCH_PARSE_TABLE
    ::_pbi::TcParser::GetTable<::opencv_tensorflow::NodeDef_AttrEntry_DoNotUse>(),  // to_prefetch
    #endif  // PROTOBUF_PREFETCH_PARSE_TABLE
  }, {{
    // .opencv_tensorflow.AttrValue value = 2;
    {::_pbi::TcParser::FastMtS1,
     {18, 1, 0, PROTOBUF_FIELD_OFFSET(NodeDef_AttrEntry_DoNotUse, _impl_.value_)}},
    // string key = 1;
    {::_pbi::TcParser::FastUS1,
     {10, 0, 0, PROTOBUF_FIELD_OFFSET(NodeDef_AttrEntry_DoNotUse, _impl_.key_)}},
  }}, {{
    65535, 65535
  }}, {{
    // string key = 1;
    {PROTOBUF_FIELD_OFFSET(NodeDef_AttrEntry_DoNotUse, _impl_.key_), _Internal::kHasBitsOffset + 0, 0, (0 | ::_fl::kFcOptional | ::_fl::kUtf8String | ::_fl::kRepAString)},
    // .opencv_tensorflow.AttrValue value = 2;
    {PROTOBUF_FIELD_OFFSET(NodeDef_AttrEntry_DoNotUse, _impl_.value_), _Internal::kHasBitsOffset + 1, 0, (0 | ::_fl::kFcOptional | ::_fl::kMessage | ::_fl::kTvTable)},
  }},
  {{
      {::_pbi::TcParser::GetTable<::opencv_tensorflow::AttrValue>()},
  }},
  {{
    "\43\3\0\0\0\0\0\0"
    "opencv_tensorflow.NodeDef.AttrEntry"
    "key"
  }},
};
// ===================================================================

class NodeDef::_Internal {
 public:
  using HasBits =
      decltype(::std::declval<NodeDef>()._impl_._has_bits_);
  static constexpr ::int32_t kHasBitsOffset =
      8 * PROTOBUF_FIELD_OFFSET(NodeDef, _impl_._has_bits_);
};

void NodeDef::clear_attr() {
  ::google::protobuf::internal::TSanWrite(&_impl_);
  _impl_.attr_.Clear();
}
NodeDef::NodeDef(::google::protobuf::Arena* PROTOBUF_NULLABLE arena)
#if defined(PROTOBUF_CUSTOM_VTABLE)
    : ::google::protobuf::Message(arena, NodeDef_class_data_.base()) {
#else   // PROTOBUF_CUSTOM_VTABLE
    : ::google::protobuf::Message(arena) {
#endif  // PROTOBUF_CUSTOM_VTABLE
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:opencv_tensorflow.NodeDef)
}
PROTOBUF_NDEBUG_INLINE NodeDef::Impl_::Impl_(
    [[maybe_unused]] ::google::protobuf::internal::InternalVisibility visibility,
    [[maybe_unused]] ::google::protobuf::Arena* PROTOBUF_NULLABLE arena, const Impl_& from,
    [[maybe_unused]] const ::opencv_tensorflow::NodeDef& from_msg)
      : _has_bits_{from._has_bits_},
        _cached_size_{0},
        input_{visibility, arena, from.input_},
        attr_{visibility, arena, from.attr_},
        name_(arena, from.name_),
        op_(arena, from.op_),
        device_(arena, from.device_) {}

NodeDef::NodeDef(
    ::google::protobuf::Arena* PROTOBUF_NULLABLE arena,
    const NodeDef& from)
#if defined(PROTOBUF_CUSTOM_VTABLE)
    : ::google::protobuf::Message(arena, NodeDef_class_data_.base()) {
#else   // PROTOBUF_CUSTOM_VTABLE
    : ::google::protobuf::Message(arena) {
#endif  // PROTOBUF_CUSTOM_VTABLE
  NodeDef* const _this = this;
  (void)_this;
  _internal_metadata_.MergeFrom<::google::protobuf::UnknownFieldSet>(
      from._internal_metadata_);
  new (&_impl_) Impl_(internal_visibility(), arena, from._impl_, from);

  // @@protoc_insertion_point(copy_constructor:opencv_tensorflow.NodeDef)
}
PROTOBUF_NDEBUG_INLINE NodeDef::Impl_::Impl_(
    [[maybe_unused]] ::google::protobuf::internal::InternalVisibility visibility,
    [[maybe_unused]] ::google::protobuf::Arena* PROTOBUF_NULLABLE arena)
      : _cached_size_{0},
        input_{visibility, arena},
        attr_{visibility, arena},
        name_(arena),
        op_(arena),
        device_(arena) {}

inline void NodeDef::SharedCtor(::_pb::Arena* PROTOBUF_NULLABLE arena) {
  new (&_impl_) Impl_(internal_visibility(), arena);
}
NodeDef::~NodeDef() {
  // @@protoc_insertion_point(destructor:opencv_tensorflow.NodeDef)
  SharedDtor(*this);
}
inline void NodeDef::SharedDtor(MessageLite& self) {
  NodeDef& this_ = static_cast<NodeDef&>(self);
  if constexpr (::_pbi::DebugHardenVerifyHasBitConsistency()) {
    this_.VerifyHasBitConsistency();
  }
  this_._internal_metadata_.Delete<::google::protobuf::UnknownFieldSet>();
  ABSL_DCHECK(this_.GetArena() == nullptr);
  this_._impl_.name_.Destroy();
  this_._impl_.op_.Destroy();
  this_._impl_.device_.Destroy();
  this_._impl_.~Impl_();
}

inline void* PROTOBUF_NONNULL NodeDef::PlacementNew_(
    const void* PROTOBUF_NONNULL, void* PROTOBUF_NONNULL mem,
    ::google::protobuf::Arena* PROTOBUF_NULLABLE arena) {
  return ::new (mem) NodeDef(arena);
}
constexpr auto NodeDef::InternalNewImpl_() {
  constexpr auto arena_bits = ::google::protobuf::internal::EncodePlacementArenaOffsets({
      PROTOBUF_FIELD_OFFSET(NodeDef, _impl_.input_) +
          decltype(NodeDef::_impl_.input_)::
              InternalGetArenaOffset(
                  ::google::protobuf::Message::internal_visibility()),
      PROTOBUF_FIELD_OFFSET(NodeDef, _impl_.attr_) +
          decltype(NodeDef::_impl_.attr_)::
              InternalGetArenaOffset(
                  ::google::protobuf::Message::internal_visibility()),
      PROTOBUF_FIELD_OFFSET(NodeDef, _impl_.attr_) +
          decltype(NodeDef::_impl_.attr_)::
              InternalGetArenaOffsetAlt(
                  ::google::protobuf::Message::internal_visibility()),
  });
  if (arena_bits.has_value()) {
    return ::google::protobuf::internal::MessageCreator::CopyInit(
        sizeof(NodeDef), alignof(NodeDef), *arena_bits);
  } else {
    return ::google::protobuf::internal::MessageCreator(&NodeDef::PlacementNew_,
                                 sizeof(NodeDef),
                                 alignof(NodeDef));
  }
}
constexpr auto NodeDef::InternalGenerateClassData_() {
  return ::google::protobuf::internal::ClassDataFull{
      ::google::protobuf::internal::ClassData{
          &_NodeDef_default_instance_._instance,
          &_table_.header,
          nullptr,  // OnDemandRegisterArenaDtor
          nullptr,  // IsInitialized
          &NodeDef::MergeImpl,
          ::google::protobuf::Message::GetNewImpl<NodeDef>(),
#if defined(PROTOBUF_CUSTOM_VTABLE)
          &NodeDef::SharedDtor,
          ::google::protobuf::Message::GetClearImpl<NodeDef>(), &NodeDef::ByteSizeLong,
              &NodeDef::_InternalSerialize,
#endif  // PROTOBUF_CUSTOM_VTABLE
          PROTOBUF_FIELD_OFFSET(NodeDef, _impl_._cached_size_),
          false,
      },
      &NodeDef::kDescriptorMethods,
      &descriptor_table_graph_2eproto,
      nullptr,  // tracker
  };
}

PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 const
    ::google::protobuf::internal::ClassDataFull NodeDef_class_data_ =
        NodeDef::InternalGenerateClassData_();

PROTOBUF_ATTRIBUTE_WEAK const ::google::protobuf::internal::ClassData* PROTOBUF_NONNULL
NodeDef::GetClassData() const {
  ::google::protobuf::internal::PrefetchToLocalCache(&NodeDef_class_data_);
  ::google::protobuf::internal::PrefetchToLocalCache(NodeDef_class_data_.tc_table);
  return NodeDef_class_data_.base();
}
PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1
const ::_pbi::TcParseTable<2, 5, 2, 55, 2>
NodeDef::_table_ = {
  {
    PROTOBUF_FIELD_OFFSET(NodeDef, _impl_._has_bits_),
    0, // no _extensions_
    5, 24,  // max_field_number, fast_idx_mask
    offsetof(decltype(_table_), field_lookup_table),
    4294967264,  // skipmap
    offsetof(decltype(_table_), field_entries),
    5,  // num_field_entries
    2,  // num_aux_entries
    offsetof(decltype(_table_), aux_entries),
    NodeDef_class_data_.base(),
    nullptr,  // post_loop_handler
    ::_pbi::TcParser::GenericFallback,  // fallback
    #ifdef PROTOBUF_PREFETCH_PARSE_TABLE
    ::_pbi::TcParser::GetTable<::opencv_tensorflow::NodeDef>(),  // to_prefetch
    #endif  // PROTOBUF_PREFETCH_PARSE_TABLE
  }, {{
    // string device = 4;
    {::_pbi::TcParser::FastUS1,
     {34, 2, 0, PROTOBUF_FIELD_OFFSET(NodeDef, _impl_.device_)}},
    // string name = 1;
    {::_pbi::TcParser::FastUS1,
     {10, 0, 0, PROTOBUF_FIELD_OFFSET(NodeDef, _impl_.name_)}},
    // string op = 2;
    {::_pbi::TcParser::FastUS1,
     {18, 1, 0, PROTOBUF_FIELD_OFFSET(NodeDef, _impl_.op_)}},
    // repeated string input = 3;
    {::_pbi::TcParser::FastUR1,
     {26, 63, 0, PROTOBUF_FIELD_OFFSET(NodeDef, _impl_.input_)}},
  }}, {{
    65535, 65535
  }}, {{
    // string name = 1;
    {PROTOBUF_FIELD_OFFSET(NodeDef, _impl_.name_), _Internal::kHasBitsOffset + 0, 0, (0 | ::_fl::kFcOptional | ::_fl::kUtf8String | ::_fl::kRepAString)},
    // string op = 2;
    {PROTOBUF_FIELD_OFFSET(NodeDef, _impl_.op_), _Internal::kHasBitsOffset + 1, 0, (0 | ::_fl::kFcOptional | ::_fl::kUtf8String | ::_fl::kRepAString)},
    // repeated string input = 3;
    {PROTOBUF_FIELD_OFFSET(NodeDef, _impl_.input_), -1, 0, (0 | ::_fl::kFcRepeated | ::_fl::kUtf8String | ::_fl::kRepSString)},
    // string device = 4;
    {PROTOBUF_FIELD_OFFSET(NodeDef, _impl_.device_), _Internal::kHasBitsOffset + 2, 0, (0 | ::_fl::kFcOptional | ::_fl::kUtf8String | ::_fl::kRepAString)},
    // map<string, .opencv_tensorflow.AttrValue> attr = 5;
    {PROTOBUF_FIELD_OFFSET(NodeDef, _impl_.attr_), -1, 0, (0 | ::_fl::kFcRepeated | ::_fl::kMap)},
  }},
  {{
      {::_pbi::TcParser::GetMapAuxInfo(1, 0, 0,
                                       9, 11,
                                       0)},
      {::_pbi::TcParser::GetTable<::opencv_tensorflow::AttrValue>()},
  }},
  {{
    "\31\4\2\5\6\4\0\0"
    "opencv_tensorflow.NodeDef"
    "name"
    "op"
    "input"
    "device"
    "attr"
  }},
};
PROTOBUF_NOINLINE void NodeDef::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_tensorflow.NodeDef)
  ::google::protobuf::internal::TSanWrite(&_impl_);
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  _impl_.input_.Clear();
  _impl_.attr_.Clear();
  cached_has_bits = _impl_._has_bits_[0];
  if ((cached_has_bits & 0x00000007U) != 0) {
    if ((cached_has_bits & 0x00000001U) != 0) {
      _impl_.name_.ClearNonDefaultToEmpty();
    }
    if ((cached_has_bits & 0x00000002U) != 0) {
      _impl_.op_.ClearNonDefaultToEmpty();
    }
    if ((cached_has_bits & 0x00000004U) != 0) {
      _impl_.device_.ClearNonDefaultToEmpty();
    }
  }
  _impl_._has_bits_.Clear();
  _internal_metadata_.Clear<::google::protobuf::UnknownFieldSet>();
}

#if defined(PROTOBUF_CUSTOM_VTABLE)
::uint8_t* PROTOBUF_NONNULL NodeDef::_InternalSerialize(
    const ::google::protobuf::MessageLite& base, ::uint8_t* PROTOBUF_NONNULL target,
    ::google::protobuf::io::EpsCopyOutputStream* PROTOBUF_NONNULL stream) {
  const NodeDef& this_ = static_cast<const NodeDef&>(base);
#else   // PROTOBUF_CUSTOM_VTABLE
::uint8_t* PROTOBUF_NONNULL NodeDef::_InternalSerialize(
    ::uint8_t* PROTOBUF_NONNULL target,
    ::google::protobuf::io::EpsCopyOutputStream* PROTOBUF_NONNULL stream) const {
  const NodeDef& this_ = *this;
#endif  // PROTOBUF_CUSTOM_VTABLE
  if constexpr (::_pbi::DebugHardenVerifyHasBitConsistency()) {
    this_.VerifyHasBitConsistency();
  }
  // @@protoc_insertion_point(serialize_to_array_start:opencv_tensorflow.NodeDef)
  ::uint32_t cached_has_bits = 0;
  (void)cached_has_bits;

  // string name = 1;
  if ((this_._impl_._has_bits_[0] & 0x00000001U) != 0) {
    if (!this_._internal_name().empty()) {
      const ::std::string& _s = this_._internal_name();
      ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
          _s.data(), static_cast<int>(_s.length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "opencv_tensorflow.NodeDef.name");
      target = stream->WriteStringMaybeAliased(1, _s, target);
    }
  }

  // string op = 2;
  if ((this_._impl_._has_bits_[0] & 0x00000002U) != 0) {
    if (!this_._internal_op().empty()) {
      const ::std::string& _s = this_._internal_op();
      ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
          _s.data(), static_cast<int>(_s.length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "opencv_tensorflow.NodeDef.op");
      target = stream->WriteStringMaybeAliased(2, _s, target);
    }
  }

  // repeated string input = 3;
  for (int i = 0, n = this_._internal_input_size(); i < n; ++i) {
    const auto& s = this_._internal_input().Get(i);
    ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
        s.data(), static_cast<int>(s.length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "opencv_tensorflow.NodeDef.input");
    target = stream->WriteString(3, s, target);
  }

  // string device = 4;
  if ((this_._impl_._has_bits_[0] & 0x00000004U) != 0) {
    if (!this_._internal_device().empty()) {
      const ::std::string& _s = this_._internal_device();
      ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
          _s.data(), static_cast<int>(_s.length()), ::google::protobuf::internal::WireFormatLite::SERIALIZE, "opencv_tensorflow.NodeDef.device");
      target = stream->WriteStringMaybeAliased(4, _s, target);
    }
  }

  // map<string, .opencv_tensorflow.AttrValue> attr = 5;
  if (!this_._internal_attr().empty()) {
    using MapType = ::google::protobuf::Map<::std::string, ::opencv_tensorflow::AttrValue>;
    using WireHelper = _pbi::MapEntryFuncs<::std::string, ::opencv_tensorflow::AttrValue,
                                   _pbi::WireFormatLite::TYPE_STRING,
                                   _pbi::WireFormatLite::TYPE_MESSAGE>;
    const auto& field = this_._internal_attr();

    if (stream->IsSerializationDeterministic() && field.size() > 1) {
      for (const auto& entry : ::google::protobuf::internal::MapSorterPtr<MapType>(field)) {
        target = WireHelper::InternalSerialize(
            5, entry.first, entry.second, target, stream);
        ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
            entry.first.data(), static_cast<int>(entry.first.length()),
 ::google::protobuf::internal::WireFormatLite::SERIALIZE, "opencv_tensorflow.NodeDef.attr");
      }
    } else {
      for (const auto& entry : field) {
        target = WireHelper::InternalSerialize(
            5, entry.first, entry.second, target, stream);
        ::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
            entry.first.data(), static_cast<int>(entry.first.length()),
 ::google::protobuf::internal::WireFormatLite::SERIALIZE, "opencv_tensorflow.NodeDef.attr");
      }
    }
  }

  if (ABSL_PREDICT_FALSE(this_._internal_metadata_.have_unknown_fields())) {
    target =
        ::_pbi::WireFormat::InternalSerializeUnknownFieldsToArray(
            this_._internal_metadata_.unknown_fields<::google::protobuf::UnknownFieldSet>(::google::protobuf::UnknownFieldSet::default_instance), target, stream);
  }
  // @@protoc_insertion_point(serialize_to_array_end:opencv_tensorflow.NodeDef)
  return target;
}

#if defined(PROTOBUF_CUSTOM_VTABLE)
::size_t NodeDef::ByteSizeLong(const MessageLite& base) {
  const NodeDef& this_ = static_cast<const NodeDef&>(base);
#else   // PROTOBUF_CUSTOM_VTABLE
::size_t NodeDef::ByteSizeLong() const {
  const NodeDef& this_ = *this;
#endif  // PROTOBUF_CUSTOM_VTABLE
  // @@protoc_insertion_point(message_byte_size_start:opencv_tensorflow.NodeDef)
  ::size_t total_size = 0;

  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void)cached_has_bits;

  ::_pbi::Prefetch5LinesFrom7Lines(&this_);
   {
    // repeated string input = 3;
    {
      total_size +=
          1 * ::google::protobuf::internal::FromIntSize(this_._internal_input().size());
      for (int i = 0, n = this_._internal_input().size(); i < n; ++i) {
        total_size += ::google::protobuf::internal::WireFormatLite::StringSize(
            this_._internal_input().Get(i));
      }
    }
    // map<string, .opencv_tensorflow.AttrValue> attr = 5;
    {
      total_size +=
          1 * ::google::protobuf::internal::FromIntSize(this_._internal_attr_size());
      for (const auto& entry : this_._internal_attr()) {
        total_size += _pbi::MapEntryFuncs<::std::string, ::opencv_tensorflow::AttrValue,
                                       _pbi::WireFormatLite::TYPE_STRING,
                                       _pbi::WireFormatLite::TYPE_MESSAGE>::ByteSizeLong(entry.first, entry.second);
      }
    }
  }
  cached_has_bits = this_._impl_._has_bits_[0];
  if ((cached_has_bits & 0x00000007U) != 0) {
    // string name = 1;
    if ((cached_has_bits & 0x00000001U) != 0) {
      if (!this_._internal_name().empty()) {
        total_size += 1 + ::google::protobuf::internal::WireFormatLite::StringSize(
                                        this_._internal_name());
      }
    }
    // string op = 2;
    if ((cached_has_bits & 0x00000002U) != 0) {
      if (!this_._internal_op().empty()) {
        total_size += 1 + ::google::protobuf::internal::WireFormatLite::StringSize(
                                        this_._internal_op());
      }
    }
    // string device = 4;
    if ((cached_has_bits & 0x00000004U) != 0) {
      if (!this_._internal_device().empty()) {
        total_size += 1 + ::google::protobuf::internal::WireFormatLite::StringSize(
                                        this_._internal_device());
      }
    }
  }
  return this_.MaybeComputeUnknownFieldsSize(total_size,
                                             &this_._impl_._cached_size_);
}

void NodeDef::MergeImpl(::google::protobuf::MessageLite& to_msg, const ::google::protobuf::MessageLite& from_msg) {
  auto* const _this = static_cast<NodeDef*>(&to_msg);
  auto& from = static_cast<const NodeDef&>(from_msg);
  if constexpr (::_pbi::DebugHardenVerifyHasBitConsistency()) {
    from.VerifyHasBitConsistency();
  }
  // @@protoc_insertion_point(class_specific_merge_from_start:opencv_tensorflow.NodeDef)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void) cached_has_bits;

  _this->_internal_mutable_input()->MergeFrom(from._internal_input());
  _this->_impl_.attr_.MergeFrom(from._impl_.attr_);
  cached_has_bits = from._impl_._has_bits_[0];
  if ((cached_has_bits & 0x00000007U) != 0) {
    if ((cached_has_bits & 0x00000001U) != 0) {
      if (!from._internal_name().empty()) {
        _this->_internal_set_name(from._internal_name());
      } else {
        if (_this->_impl_.name_.IsDefault()) {
          _this->_internal_set_name("");
        }
      }
    }
    if ((cached_has_bits & 0x00000002U) != 0) {
      if (!from._internal_op().empty()) {
        _this->_internal_set_op(from._internal_op());
      } else {
        if (_this->_impl_.op_.IsDefault()) {
          _this->_internal_set_op("");
        }
      }
    }
    if ((cached_has_bits & 0x00000004U) != 0) {
      if (!from._internal_device().empty()) {
        _this->_internal_set_device(from._internal_device());
      } else {
        if (_this->_impl_.device_.IsDefault()) {
          _this->_internal_set_device("");
        }
      }
    }
  }
  _this->_impl_._has_bits_[0] |= cached_has_bits;
  _this->_internal_metadata_.MergeFrom<::google::protobuf::UnknownFieldSet>(from._internal_metadata_);
}

void NodeDef::CopyFrom(const NodeDef& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_tensorflow.NodeDef)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}


void NodeDef::InternalSwap(NodeDef* PROTOBUF_RESTRICT PROTOBUF_NONNULL other) {
  using ::std::swap;
  auto* arena = GetArena();
  ABSL_DCHECK_EQ(arena, other->GetArena());
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
  _impl_.input_.InternalSwap(&other->_impl_.input_);
  _impl_.attr_.InternalSwap(&other->_impl_.attr_);
  ::_pbi::ArenaStringPtr::InternalSwap(&_impl_.name_, &other->_impl_.name_, arena);
  ::_pbi::ArenaStringPtr::InternalSwap(&_impl_.op_, &other->_impl_.op_, arena);
  ::_pbi::ArenaStringPtr::InternalSwap(&_impl_.device_, &other->_impl_.device_, arena);
}

::google::protobuf::Metadata NodeDef::GetMetadata() const {
  return ::google::protobuf::Message::GetMetadataImpl(GetClassData()->full());
}
// @@protoc_insertion_point(namespace_scope)
}  // namespace opencv_tensorflow
namespace google {
namespace protobuf {
}  // namespace protobuf
}  // namespace google
// @@protoc_insertion_point(global_scope)
PROTOBUF_ATTRIBUTE_INIT_PRIORITY2 static ::std::false_type
    _static_init2_ [[maybe_unused]] =
        (::_pbi::AddDescriptors(&descriptor_table_graph_2eproto),
         ::std::false_type{});
#include "google/protobuf/port_undef.inc"
