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

#include "translate_ranker_model.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/internal_visibility.h"
#include "google/protobuf/extension_set.h"
#include "google/protobuf/generated_message_util.h"
#include "google/protobuf/wire_format_lite.h"
#include "google/protobuf/io/zero_copy_stream_impl_lite.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 assist_ranker {
class TranslateRankerModel_TranslateLogisticRegressionModel::_Internal {
 public:
  using HasBits = decltype(::std::declval<TranslateRankerModel_TranslateLogisticRegressionModel>()._impl_._has_bits_);
  static constexpr ::int32_t kHasBitsOffset =
      8 * PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_._has_bits_);
};

constexpr TranslateRankerModel_TranslateLogisticRegressionModel::ParseTableT_ TranslateRankerModel_TranslateLogisticRegressionModel::InternalGenerateParseTable_(const ::_pbi::ClassData* class_data) {
  return ParseTableT_{
    {
      PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_._has_bits_),
      0, // no _extensions_
      12, 120,  // max_field_number, fast_idx_mask
      offsetof(ParseTableT_, field_lookup_table),
      4294963200,  // skipmap
      offsetof(ParseTableT_, field_entries),
      12,  // num_field_entries
      4,  // num_aux_entries
      offsetof(ParseTableT_, aux_entries),
      class_data,
      nullptr,  // post_loop_handler
      ::_pbi::TcParser::GenericFallbackLite,  // fallback
      #ifdef PROTOBUF_PREFETCH_PARSE_TABLE
      ::_pbi::TcParser::GetTable<::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel>(),  // to_prefetch
      #endif  // PROTOBUF_PREFETCH_PARSE_TABLE
    }, {{
      {::_pbi::TcParser::MiniParse, {}},
      // optional float bias = 1;
      {::_pbi::TcParser::FastF32S1,
       {13, 0, 0,
        PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.bias_)}},
      // optional float accept_ratio_weight = 2;
      {::_pbi::TcParser::FastF32S1,
       {21, 1, 0,
        PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.accept_ratio_weight_)}},
      // optional float decline_ratio_weight = 3;
      {::_pbi::TcParser::FastF32S1,
       {29, 2, 0,
        PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.decline_ratio_weight_)}},
      // optional float ignore_ratio_weight = 4;
      {::_pbi::TcParser::FastF32S1,
       {37, 3, 0,
        PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.ignore_ratio_weight_)}},
      {::_pbi::TcParser::MiniParse, {}},
      {::_pbi::TcParser::MiniParse, {}},
      {::_pbi::TcParser::MiniParse, {}},
      {::_pbi::TcParser::MiniParse, {}},
      // optional float accept_count_weight = 9;
      {::_pbi::TcParser::FastF32S1,
       {77, 4, 0,
        PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.accept_count_weight_)}},
      // optional float decline_count_weight = 10;
      {::_pbi::TcParser::FastF32S1,
       {85, 5, 0,
        PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.decline_count_weight_)}},
      // optional float ignore_count_weight = 11;
      {::_pbi::TcParser::FastF32S1,
       {93, 6, 0,
        PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.ignore_count_weight_)}},
      // optional float threshold = 12;
      {::_pbi::TcParser::FastF32S1,
       {101, 7, 0,
        PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.threshold_)}},
      {::_pbi::TcParser::MiniParse, {}},
      {::_pbi::TcParser::MiniParse, {}},
      {::_pbi::TcParser::MiniParse, {}},
    }}, {{
      65535, 65535
    }}, {{
      // optional float bias = 1;
      {PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.bias_), _Internal::kHasBitsOffset + 0, 0, (0 | ::_fl::kFcOptional | ::_fl::kFloat)},
      // optional float accept_ratio_weight = 2;
      {PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.accept_ratio_weight_), _Internal::kHasBitsOffset + 1, 0, (0 | ::_fl::kFcOptional | ::_fl::kFloat)},
      // optional float decline_ratio_weight = 3;
      {PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.decline_ratio_weight_), _Internal::kHasBitsOffset + 2, 0, (0 | ::_fl::kFcOptional | ::_fl::kFloat)},
      // optional float ignore_ratio_weight = 4;
      {PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.ignore_ratio_weight_), _Internal::kHasBitsOffset + 3, 0, (0 | ::_fl::kFcOptional | ::_fl::kFloat)},
      // map<string, float> source_language_weight = 5;
      {PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.source_language_weight_), _Internal::kHasBitsOffset + 8, 0, (0 | ::_fl::kFcRepeated | ::_fl::kMap)},
      // map<string, float> target_language_weight = 6;
      {PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.target_language_weight_), _Internal::kHasBitsOffset + 9, 1, (0 | ::_fl::kFcRepeated | ::_fl::kMap)},
      // map<string, float> country_weight = 7;
      {PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.country_weight_), _Internal::kHasBitsOffset + 10, 2, (0 | ::_fl::kFcRepeated | ::_fl::kMap)},
      // map<string, float> locale_weight = 8;
      {PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.locale_weight_), _Internal::kHasBitsOffset + 11, 3, (0 | ::_fl::kFcRepeated | ::_fl::kMap)},
      // optional float accept_count_weight = 9;
      {PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.accept_count_weight_), _Internal::kHasBitsOffset + 4, 0, (0 | ::_fl::kFcOptional | ::_fl::kFloat)},
      // optional float decline_count_weight = 10;
      {PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.decline_count_weight_), _Internal::kHasBitsOffset + 5, 0, (0 | ::_fl::kFcOptional | ::_fl::kFloat)},
      // optional float ignore_count_weight = 11;
      {PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.ignore_count_weight_), _Internal::kHasBitsOffset + 6, 0, (0 | ::_fl::kFcOptional | ::_fl::kFloat)},
      // optional float threshold = 12;
      {PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.threshold_), _Internal::kHasBitsOffset + 7, 0, (0 | ::_fl::kFcOptional | ::_fl::kFloat)},
    }},
    {{
        {::_pbi::TcParser::GetMapAuxInfo(
            0, 0, 9, 2, 1)},
        {::_pbi::TcParser::GetMapAuxInfo(
            0, 0, 9, 2, 1)},
        {::_pbi::TcParser::GetMapAuxInfo(
            0, 0, 9, 2, 1)},
        {::_pbi::TcParser::GetMapAuxInfo(
            0, 0, 9, 2, 1)},
    }},
    {{
    }},
  };
}


inline constexpr TranslateRankerModel_TranslateLogisticRegressionModel::Impl_::Impl_(
    [[maybe_unused]] ::google::protobuf::internal::InternalVisibility visibility,
    ::_pbi::ConstantInitialized) noexcept
      : _cached_size_{0},
        bias_{0},
        accept_ratio_weight_{0},
        decline_ratio_weight_{0},
        ignore_ratio_weight_{0},
        accept_count_weight_{0},
        decline_count_weight_{0},
        ignore_count_weight_{0},
        threshold_{0},
        source_language_weight_ { visibility, ::_pbi::InternalMetadataOffset::Build<
            ::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel,
            PROTOBUF_FIELD_OFFSET(::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.source_language_weight_)>()
         }
        ,
        target_language_weight_ { visibility, ::_pbi::InternalMetadataOffset::Build<
            ::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel,
            PROTOBUF_FIELD_OFFSET(::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.target_language_weight_)>()
         }
        ,
        country_weight_ { visibility, ::_pbi::InternalMetadataOffset::Build<
            ::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel,
            PROTOBUF_FIELD_OFFSET(::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.country_weight_)>()
         }
        ,
        locale_weight_ { visibility, ::_pbi::InternalMetadataOffset::Build<
            ::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel,
            PROTOBUF_FIELD_OFFSET(::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.locale_weight_)>()
         }
     {}

template <typename>
constexpr TranslateRankerModel_TranslateLogisticRegressionModel::TranslateRankerModel_TranslateLogisticRegressionModel(::_pbi::ConstantInitialized,
                       const ::_pbi::ClassData* PROTOBUF_NONNULL class_data)
    : ::google::protobuf::MessageLite(
#if defined(PROTOBUF_CUSTOM_VTABLE)
          class_data
#endif  // PROTOBUF_CUSTOM_VTABLE
          ),
      _impl_(internal_visibility(), ::_pbi::ConstantInitialized()) {
}
inline void* PROTOBUF_NONNULL TranslateRankerModel_TranslateLogisticRegressionModel::PlacementNew_(
    const void* PROTOBUF_NONNULL, void* PROTOBUF_NONNULL mem,
    ::google::protobuf::Arena* PROTOBUF_NULLABLE arena) {
  return ::new (mem) TranslateRankerModel_TranslateLogisticRegressionModel(arena);
}
constexpr auto TranslateRankerModel_TranslateLogisticRegressionModel::InternalNewImpl_() {
  return ::google::protobuf::internal::MessageCreator::CopyInit(sizeof(TranslateRankerModel_TranslateLogisticRegressionModel), alignof(TranslateRankerModel_TranslateLogisticRegressionModel));
}
constexpr auto TranslateRankerModel_TranslateLogisticRegressionModel::InternalGenerateClassData_(
    const MessageLite& prototype,
    const ::google::protobuf::internal::TcParseTableBase* tc_table) {
  return ::google::protobuf::internal::ClassDataLite{
      {
          &prototype,
#ifndef PROTOBUF_MESSAGE_GLOBALS
          &_table_.header,
#else
          tc_table,
#endif
          nullptr,  // IsInitialized
          &TranslateRankerModel_TranslateLogisticRegressionModel::MergeImpl,
          ::google::protobuf::MessageLite::GetNewImpl<TranslateRankerModel_TranslateLogisticRegressionModel>(),
#if defined(PROTOBUF_CUSTOM_VTABLE)
          &TranslateRankerModel_TranslateLogisticRegressionModel::SharedDtor,
          ::google::protobuf::MessageLite::GetClearImpl<TranslateRankerModel_TranslateLogisticRegressionModel>(), &TranslateRankerModel_TranslateLogisticRegressionModel::ByteSizeLong,
              &TranslateRankerModel_TranslateLogisticRegressionModel::_InternalSerialize,
#endif  // PROTOBUF_CUSTOM_VTABLE
          PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_._cached_size_),
          true,
      },
      "assist_ranker.TranslateRankerModel.TranslateLogisticRegressionModel",
  };
}
struct TranslateRankerModel_TranslateLogisticRegressionModelGlobalsTypeInternal : ::_pbi::MessageGlobalsBase {
  constexpr TranslateRankerModel_TranslateLogisticRegressionModelGlobalsTypeInternal()
      :
#ifndef PROTOBUF_MESSAGE_GLOBALS
        _default(::_pbi::ConstantInitialized{},
                 TranslateRankerModel_TranslateLogisticRegressionModel_class_data_.base())
#else   // !PROTOBUF_MESSAGE_GLOBALS
        MessageGlobalsBase(TranslateRankerModel_TranslateLogisticRegressionModel::InternalGenerateClassData_(
            _default, &TranslateRankerModel_TranslateLogisticRegressionModel_globals_._table.header)),
        _default(::_pbi::ConstantInitialized{}, GetClassData()),
        _table(::_pbi::PrivateAccess::GenerateParseTable<TranslateRankerModel_TranslateLogisticRegressionModel>(
            GetClassData()))
#endif  // PROTOBUF_MESSAGE_GLOBALS
  {
  }
  ~TranslateRankerModel_TranslateLogisticRegressionModelGlobalsTypeInternal() {}
  union {
    alignas(::_pbi::kMaxMessageAlignment) TranslateRankerModel_TranslateLogisticRegressionModel _default;
  };
#ifdef PROTOBUF_MESSAGE_GLOBALS
  decltype(::_pbi::PrivateAccess::GenerateParseTable<TranslateRankerModel_TranslateLogisticRegressionModel>(
      ::std::declval<const ::_pbi::ClassData*>())) _table;
#endif
};
#ifdef PROTOBUF_MESSAGE_GLOBALS
static_assert(PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModelGlobalsTypeInternal, _default) ==
              ::_pbi::MessageGlobalsBase::OffsetToDefault());
#endif  // PROTOBUF_MESSAGE_GLOBALS

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 PROTOBUF_MESSAGE_GLOBALS_CONST TranslateRankerModel_TranslateLogisticRegressionModelGlobalsTypeInternal TranslateRankerModel_TranslateLogisticRegressionModel_globals_
        PROTOBUF_MESSAGE_GLOBALS_SECTION(.data.rel.ro);
#if defined(PROTOBUF_CUSTOM_VTABLE)
namespace {
const ::_pbi::ClassData* TranslateRankerModel_TranslateLogisticRegressionModel_get_class_data() {
#ifdef PROTOBUF_MESSAGE_GLOBALS
  return TranslateRankerModel_TranslateLogisticRegressionModel_globals_.GetClassData();
#else
  return TranslateRankerModel_TranslateLogisticRegressionModel_class_data_.base();
#endif  // PROTOBUF_MESSAGE_GLOBALS
}
}  // namespace
#endif  // PROTOBUF_CUSTOM_VTABLE
class TranslateRankerModel::_Internal {
 public:
  using HasBits = decltype(::std::declval<TranslateRankerModel>()._impl_._has_bits_);
  static constexpr ::int32_t kHasBitsOffset =
      8 * PROTOBUF_FIELD_OFFSET(TranslateRankerModel, _impl_._has_bits_);
  static constexpr ::int32_t kOneofCaseOffset =
      PROTOBUF_FIELD_OFFSET(::assist_ranker::TranslateRankerModel, _impl_._oneof_case_);
};

constexpr TranslateRankerModel::ParseTableT_ TranslateRankerModel::InternalGenerateParseTable_(const ::_pbi::ClassData* class_data) {
  return ParseTableT_{
    {
      PROTOBUF_FIELD_OFFSET(TranslateRankerModel, _impl_._has_bits_),
      0, // no _extensions_
      2, 0,  // max_field_number, fast_idx_mask
      offsetof(ParseTableT_, field_lookup_table),
      4294967292,  // skipmap
      offsetof(ParseTableT_, field_entries),
      2,  // num_field_entries
      1,  // num_aux_entries
      offsetof(ParseTableT_, aux_entries),
      class_data,
      nullptr,  // post_loop_handler
      ::_pbi::TcParser::GenericFallbackLite,  // fallback
      #ifdef PROTOBUF_PREFETCH_PARSE_TABLE
      ::_pbi::TcParser::GetTable<::assist_ranker::TranslateRankerModel>(),  // to_prefetch
      #endif  // PROTOBUF_PREFETCH_PARSE_TABLE
    }, {{
      // optional uint32 version = 1;
      {::_pbi::TcParser::FastV32S1,
       {8, 0, 0,
        PROTOBUF_FIELD_OFFSET(TranslateRankerModel, _impl_.version_)}},
    }}, {{
      65535, 65535
    }}, {{
      // optional uint32 version = 1;
      {PROTOBUF_FIELD_OFFSET(TranslateRankerModel, _impl_.version_), _Internal::kHasBitsOffset + 0, 0, (0 | ::_fl::kFcOptional | ::_fl::kUInt32)},
      // .assist_ranker.TranslateRankerModel.TranslateLogisticRegressionModel translate_logistic_regression_model = 2;
      {PROTOBUF_FIELD_OFFSET(TranslateRankerModel, _impl_.model_revision_.translate_logistic_regression_model_), _Internal::kOneofCaseOffset + 0, 0, (0 | ::_fl::kFcOneof | ::_fl::kMessage | ::_fl::kTvTable)},
    }},
    {{
        #ifndef PROTOBUF_MESSAGE_GLOBALS
        {::_pbi::TcParser::GetTable<::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel>()},
        #else
        {::_pbi::FieldAuxMessageGlobals(), &::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel_globals_},
        #endif
    }},
    {{
    }},
  };
}


inline constexpr TranslateRankerModel::Impl_::Impl_(
    [[maybe_unused]] ::google::protobuf::internal::InternalVisibility visibility,
    ::_pbi::ConstantInitialized) noexcept
      : _cached_size_{0},
        version_{0u},
        model_revision_{},
        _oneof_case_{} {}

template <typename>
constexpr TranslateRankerModel::TranslateRankerModel(::_pbi::ConstantInitialized,
                       const ::_pbi::ClassData* PROTOBUF_NONNULL class_data)
    : ::google::protobuf::MessageLite(
#if defined(PROTOBUF_CUSTOM_VTABLE)
          class_data
#endif  // PROTOBUF_CUSTOM_VTABLE
          ),
      _impl_(internal_visibility(), ::_pbi::ConstantInitialized()) {
}
inline void* PROTOBUF_NONNULL TranslateRankerModel::PlacementNew_(
    const void* PROTOBUF_NONNULL, void* PROTOBUF_NONNULL mem,
    ::google::protobuf::Arena* PROTOBUF_NULLABLE arena) {
  return ::new (mem) TranslateRankerModel(arena);
}
constexpr auto TranslateRankerModel::InternalNewImpl_() {
  return ::google::protobuf::internal::MessageCreator::ZeroInit(sizeof(TranslateRankerModel), alignof(TranslateRankerModel));
}
constexpr auto TranslateRankerModel::InternalGenerateClassData_(
    const MessageLite& prototype,
    const ::google::protobuf::internal::TcParseTableBase* tc_table) {
  return ::google::protobuf::internal::ClassDataLite{
      {
          &prototype,
#ifndef PROTOBUF_MESSAGE_GLOBALS
          &_table_.header,
#else
          tc_table,
#endif
          nullptr,  // IsInitialized
          &TranslateRankerModel::MergeImpl,
          ::google::protobuf::MessageLite::GetNewImpl<TranslateRankerModel>(),
#if defined(PROTOBUF_CUSTOM_VTABLE)
          &TranslateRankerModel::SharedDtor,
          ::google::protobuf::MessageLite::GetClearImpl<TranslateRankerModel>(), &TranslateRankerModel::ByteSizeLong,
              &TranslateRankerModel::_InternalSerialize,
#endif  // PROTOBUF_CUSTOM_VTABLE
          PROTOBUF_FIELD_OFFSET(TranslateRankerModel, _impl_._cached_size_),
          true,
      },
      "assist_ranker.TranslateRankerModel",
  };
}
struct TranslateRankerModelGlobalsTypeInternal : ::_pbi::MessageGlobalsBase {
  constexpr TranslateRankerModelGlobalsTypeInternal()
      :
#ifndef PROTOBUF_MESSAGE_GLOBALS
        _default(::_pbi::ConstantInitialized{},
                 TranslateRankerModel_class_data_.base())
#else   // !PROTOBUF_MESSAGE_GLOBALS
        MessageGlobalsBase(TranslateRankerModel::InternalGenerateClassData_(
            _default, &TranslateRankerModel_globals_._table.header)),
        _default(::_pbi::ConstantInitialized{}, GetClassData()),
        _table(::_pbi::PrivateAccess::GenerateParseTable<TranslateRankerModel>(
            GetClassData()))
#endif  // PROTOBUF_MESSAGE_GLOBALS
  {
  }
  ~TranslateRankerModelGlobalsTypeInternal() {}
  union {
    alignas(::_pbi::kMaxMessageAlignment) TranslateRankerModel _default;
  };
#ifdef PROTOBUF_MESSAGE_GLOBALS
  decltype(::_pbi::PrivateAccess::GenerateParseTable<TranslateRankerModel>(
      ::std::declval<const ::_pbi::ClassData*>())) _table;
#endif
};
#ifdef PROTOBUF_MESSAGE_GLOBALS
static_assert(PROTOBUF_FIELD_OFFSET(TranslateRankerModelGlobalsTypeInternal, _default) ==
              ::_pbi::MessageGlobalsBase::OffsetToDefault());
#endif  // PROTOBUF_MESSAGE_GLOBALS

PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT
    PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 PROTOBUF_MESSAGE_GLOBALS_CONST TranslateRankerModelGlobalsTypeInternal TranslateRankerModel_globals_
        PROTOBUF_MESSAGE_GLOBALS_SECTION(.data.rel.ro);
#if defined(PROTOBUF_CUSTOM_VTABLE)
namespace {
const ::_pbi::ClassData* TranslateRankerModel_get_class_data() {
#ifdef PROTOBUF_MESSAGE_GLOBALS
  return TranslateRankerModel_globals_.GetClassData();
#else
  return TranslateRankerModel_class_data_.base();
#endif  // PROTOBUF_MESSAGE_GLOBALS
}
}  // namespace
#endif  // PROTOBUF_CUSTOM_VTABLE
}  // namespace assist_ranker
namespace assist_ranker {
// ===================================================================

// ===================================================================

// ===================================================================

// ===================================================================

// ===================================================================

TranslateRankerModel_TranslateLogisticRegressionModel::TranslateRankerModel_TranslateLogisticRegressionModel(::google::protobuf::Arena* PROTOBUF_NULLABLE arena)
#if defined(PROTOBUF_CUSTOM_VTABLE)
    : ::google::protobuf::MessageLite(arena, TranslateRankerModel_TranslateLogisticRegressionModel_get_class_data()) {
#else   // PROTOBUF_CUSTOM_VTABLE
    : ::google::protobuf::MessageLite(arena) {
#endif  // PROTOBUF_CUSTOM_VTABLE
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:assist_ranker.TranslateRankerModel.TranslateLogisticRegressionModel)
}
PROTOBUF_NDEBUG_INLINE TranslateRankerModel_TranslateLogisticRegressionModel::Impl_::Impl_(
    [[maybe_unused]] ::google::protobuf::internal::InternalVisibility visibility,
    [[maybe_unused]] ::google::protobuf::Arena* PROTOBUF_NULLABLE arena, const Impl_& from,
    [[maybe_unused]] const ::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel& from_msg)
      : _has_bits_{from._has_bits_},
        _cached_size_{0},
        source_language_weight_ {
          visibility, ::_pbi::InternalMetadataOffset::Build<
              ::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel,
              PROTOBUF_FIELD_OFFSET(::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.source_language_weight_)>()
          , from.source_language_weight_
        }
        ,
        target_language_weight_ {
          visibility, ::_pbi::InternalMetadataOffset::Build<
              ::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel,
              PROTOBUF_FIELD_OFFSET(::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.target_language_weight_)>()
          , from.target_language_weight_
        }
        ,
        country_weight_ {
          visibility, ::_pbi::InternalMetadataOffset::Build<
              ::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel,
              PROTOBUF_FIELD_OFFSET(::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.country_weight_)>()
          , from.country_weight_
        }
        ,
        locale_weight_ {
          visibility, ::_pbi::InternalMetadataOffset::Build<
              ::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel,
              PROTOBUF_FIELD_OFFSET(::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.locale_weight_)>()
          , from.locale_weight_
        }
     {}

TranslateRankerModel_TranslateLogisticRegressionModel::TranslateRankerModel_TranslateLogisticRegressionModel(
    ::google::protobuf::Arena* PROTOBUF_NULLABLE arena,
    const TranslateRankerModel_TranslateLogisticRegressionModel& from)
#if defined(PROTOBUF_CUSTOM_VTABLE)
    : ::google::protobuf::MessageLite(arena, TranslateRankerModel_TranslateLogisticRegressionModel_get_class_data()) {

#else   // PROTOBUF_CUSTOM_VTABLE
    : ::google::protobuf::MessageLite(arena) {
#endif  // PROTOBUF_CUSTOM_VTABLE
  TranslateRankerModel_TranslateLogisticRegressionModel* const _this = this;
  (void)_this;
  _internal_metadata_.MergeFrom<::std::string>(
      from._internal_metadata_);
  new (&_impl_) Impl_(internal_visibility(), arena, from._impl_, from);
  ::memcpy(reinterpret_cast<char*>(&_impl_) +
               offsetof(Impl_, bias_),
           reinterpret_cast<const char*>(&from._impl_) +
               offsetof(Impl_, bias_),
           offsetof(Impl_, threshold_) -
               offsetof(Impl_, bias_) +
               sizeof(Impl_::threshold_));

  // @@protoc_insertion_point(copy_constructor:assist_ranker.TranslateRankerModel.TranslateLogisticRegressionModel)
}
PROTOBUF_NDEBUG_INLINE TranslateRankerModel_TranslateLogisticRegressionModel::Impl_::Impl_(
    [[maybe_unused]] ::google::protobuf::internal::InternalVisibility visibility,
    [[maybe_unused]] ::google::protobuf::Arena* PROTOBUF_NULLABLE arena)
      : _cached_size_{0},
        source_language_weight_ { visibility, ::_pbi::InternalMetadataOffset::Build<
            ::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel,
            PROTOBUF_FIELD_OFFSET(::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.source_language_weight_)>()
         }
        ,
        target_language_weight_ { visibility, ::_pbi::InternalMetadataOffset::Build<
            ::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel,
            PROTOBUF_FIELD_OFFSET(::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.target_language_weight_)>()
         }
        ,
        country_weight_ { visibility, ::_pbi::InternalMetadataOffset::Build<
            ::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel,
            PROTOBUF_FIELD_OFFSET(::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.country_weight_)>()
         }
        ,
        locale_weight_ { visibility, ::_pbi::InternalMetadataOffset::Build<
            ::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel,
            PROTOBUF_FIELD_OFFSET(::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.locale_weight_)>()
         }
     {}

inline void TranslateRankerModel_TranslateLogisticRegressionModel::SharedCtor(::_pb::Arena* PROTOBUF_NULLABLE arena) {
  new (&_impl_) Impl_(internal_visibility(), arena);
  ::memset(reinterpret_cast<char*>(&_impl_) +
               offsetof(Impl_, bias_),
           0,
           offsetof(Impl_, threshold_) -
               offsetof(Impl_, bias_) +
               sizeof(Impl_::threshold_));
}
TranslateRankerModel_TranslateLogisticRegressionModel::~TranslateRankerModel_TranslateLogisticRegressionModel() {
  // @@protoc_insertion_point(destructor:assist_ranker.TranslateRankerModel.TranslateLogisticRegressionModel)
  SharedDtor(*this);
}
inline void TranslateRankerModel_TranslateLogisticRegressionModel::SharedDtor(MessageLite& self) {
  TranslateRankerModel_TranslateLogisticRegressionModel& this_ = static_cast<TranslateRankerModel_TranslateLogisticRegressionModel&>(self);
  if constexpr (::_pbi::DebugHardenCheckHasBitConsistency()) {
    this_.CheckHasBitConsistency();
  }
  this_._internal_metadata_.Delete<::std::string>();
  ABSL_DCHECK(this_.GetArena() == nullptr);
  this_._impl_.~Impl_();
}

#ifndef PROTOBUF_MESSAGE_GLOBALS
PROTOBUF_CONSTINIT
PROTOBUF_ATTRIBUTE_INIT_PRIORITY1
const ::google::protobuf::internal::ClassDataLite TranslateRankerModel_TranslateLogisticRegressionModel_class_data_ =
    TranslateRankerModel_TranslateLogisticRegressionModel::InternalGenerateClassData_(TranslateRankerModel_TranslateLogisticRegressionModel_globals_._default);

PROTOBUF_ATTRIBUTE_WEAK const ::google::protobuf::internal::ClassData* PROTOBUF_NONNULL
TranslateRankerModel_TranslateLogisticRegressionModel::GetClassData() const {
  return TranslateRankerModel_TranslateLogisticRegressionModel_class_data_.base();
}
#else
PROTOBUF_ATTRIBUTE_WEAK const ::google::protobuf::internal::ClassData* PROTOBUF_NONNULL
TranslateRankerModel_TranslateLogisticRegressionModel::GetClassData() const {
  return TranslateRankerModel_TranslateLogisticRegressionModel_globals_.GetClassData();
}
#endif  // !PROTOBUF_MESSAGE_GLOBALS
#ifndef PROTOBUF_MESSAGE_GLOBALS
PROTOBUF_CONSTINIT
PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 const TranslateRankerModel_TranslateLogisticRegressionModel::ParseTableT_
    TranslateRankerModel_TranslateLogisticRegressionModel::_table_ =
        TranslateRankerModel_TranslateLogisticRegressionModel::InternalGenerateParseTable_(TranslateRankerModel_TranslateLogisticRegressionModel_class_data_.base());
#endif  // !PROTOBUF_MESSAGE_GLOBALS
PROTOBUF_NOINLINE void TranslateRankerModel_TranslateLogisticRegressionModel::Clear() {
// @@protoc_insertion_point(message_clear_start:assist_ranker.TranslateRankerModel.TranslateLogisticRegressionModel)
  ::google::protobuf::internal::TSanWrite(&_impl_);
  ::uint32_t cached_has_bits = 0;
  // Prevent compiler warnings about cached_has_bits being unused
  (void) cached_has_bits;

  cached_has_bits = _impl_._has_bits_[0];
  if (BatchCheckHasBit(cached_has_bits, 0x000000ffU)) {
    ::memset(&_impl_.bias_, 0, static_cast<::size_t>(
        reinterpret_cast<char*>(&_impl_.threshold_) -
        reinterpret_cast<char*>(&_impl_.bias_)) + sizeof(_impl_.threshold_));
  }
  if (BatchCheckHasBit(cached_has_bits, 0x00000f00U)) {
    if (CheckHasBit(cached_has_bits, 0x00000100U)) {
      _impl_.source_language_weight_.Clear();
    }
    if (CheckHasBit(cached_has_bits, 0x00000200U)) {
      _impl_.target_language_weight_.Clear();
    }
    if (CheckHasBit(cached_has_bits, 0x00000400U)) {
      _impl_.country_weight_.Clear();
    }
    if (CheckHasBit(cached_has_bits, 0x00000800U)) {
      _impl_.locale_weight_.Clear();
    }
  }
  _impl_._has_bits_.Clear();
  _internal_metadata_.Clear<::std::string>();
}

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

  cached_has_bits = this_._impl_._has_bits_[0];
  // optional float bias = 1;
  if (CheckHasBit(cached_has_bits, 0x00000001U)) {
    target = stream->EnsureSpace(target);
    target = ::_pbi::WireFormatLite::WriteFloatToArray(
        1, this_._internal_bias(), target);
  }

  // optional float accept_ratio_weight = 2;
  if (CheckHasBit(cached_has_bits, 0x00000002U)) {
    target = stream->EnsureSpace(target);
    target = ::_pbi::WireFormatLite::WriteFloatToArray(
        2, this_._internal_accept_ratio_weight(), target);
  }

  // optional float decline_ratio_weight = 3;
  if (CheckHasBit(cached_has_bits, 0x00000004U)) {
    target = stream->EnsureSpace(target);
    target = ::_pbi::WireFormatLite::WriteFloatToArray(
        3, this_._internal_decline_ratio_weight(), target);
  }

  // optional float ignore_ratio_weight = 4;
  if (CheckHasBit(cached_has_bits, 0x00000008U)) {
    target = stream->EnsureSpace(target);
    target = ::_pbi::WireFormatLite::WriteFloatToArray(
        4, this_._internal_ignore_ratio_weight(), target);
  }

  // map<string, float> source_language_weight = 5;
  if (CheckHasBit(cached_has_bits, 0x00000100U)) {
    if (!this_._internal_source_language_weight().empty()) {
      using MapType = ::google::protobuf::Map<::std::string, float>;
      using WireHelper = _pbi::MapEntryFuncs<::std::string, float,
                                     _pbi::WireFormatLite::TYPE_STRING,
                                     _pbi::WireFormatLite::TYPE_FLOAT>;
      const auto& field = this_._internal_source_language_weight();

      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);
        }
      } else {
        for (const auto& entry : field) {
          target = WireHelper::InternalSerialize(
              5, entry.first, entry.second, target, stream);
        }
      }
    }
  }

  // map<string, float> target_language_weight = 6;
  if (CheckHasBit(cached_has_bits, 0x00000200U)) {
    if (!this_._internal_target_language_weight().empty()) {
      using MapType = ::google::protobuf::Map<::std::string, float>;
      using WireHelper = _pbi::MapEntryFuncs<::std::string, float,
                                     _pbi::WireFormatLite::TYPE_STRING,
                                     _pbi::WireFormatLite::TYPE_FLOAT>;
      const auto& field = this_._internal_target_language_weight();

      if (stream->IsSerializationDeterministic() && field.size() > 1) {
        for (const auto& entry : ::google::protobuf::internal::MapSorterPtr<MapType>(field)) {
          target = WireHelper::InternalSerialize(
              6, entry.first, entry.second, target, stream);
        }
      } else {
        for (const auto& entry : field) {
          target = WireHelper::InternalSerialize(
              6, entry.first, entry.second, target, stream);
        }
      }
    }
  }

  // map<string, float> country_weight = 7;
  if (CheckHasBit(cached_has_bits, 0x00000400U)) {
    if (!this_._internal_country_weight().empty()) {
      using MapType = ::google::protobuf::Map<::std::string, float>;
      using WireHelper = _pbi::MapEntryFuncs<::std::string, float,
                                     _pbi::WireFormatLite::TYPE_STRING,
                                     _pbi::WireFormatLite::TYPE_FLOAT>;
      const auto& field = this_._internal_country_weight();

      if (stream->IsSerializationDeterministic() && field.size() > 1) {
        for (const auto& entry : ::google::protobuf::internal::MapSorterPtr<MapType>(field)) {
          target = WireHelper::InternalSerialize(
              7, entry.first, entry.second, target, stream);
        }
      } else {
        for (const auto& entry : field) {
          target = WireHelper::InternalSerialize(
              7, entry.first, entry.second, target, stream);
        }
      }
    }
  }

  // map<string, float> locale_weight = 8;
  if (CheckHasBit(cached_has_bits, 0x00000800U)) {
    if (!this_._internal_locale_weight().empty()) {
      using MapType = ::google::protobuf::Map<::std::string, float>;
      using WireHelper = _pbi::MapEntryFuncs<::std::string, float,
                                     _pbi::WireFormatLite::TYPE_STRING,
                                     _pbi::WireFormatLite::TYPE_FLOAT>;
      const auto& field = this_._internal_locale_weight();

      if (stream->IsSerializationDeterministic() && field.size() > 1) {
        for (const auto& entry : ::google::protobuf::internal::MapSorterPtr<MapType>(field)) {
          target = WireHelper::InternalSerialize(
              8, entry.first, entry.second, target, stream);
        }
      } else {
        for (const auto& entry : field) {
          target = WireHelper::InternalSerialize(
              8, entry.first, entry.second, target, stream);
        }
      }
    }
  }

  // optional float accept_count_weight = 9;
  if (CheckHasBit(cached_has_bits, 0x00000010U)) {
    target = stream->EnsureSpace(target);
    target = ::_pbi::WireFormatLite::WriteFloatToArray(
        9, this_._internal_accept_count_weight(), target);
  }

  // optional float decline_count_weight = 10;
  if (CheckHasBit(cached_has_bits, 0x00000020U)) {
    target = stream->EnsureSpace(target);
    target = ::_pbi::WireFormatLite::WriteFloatToArray(
        10, this_._internal_decline_count_weight(), target);
  }

  // optional float ignore_count_weight = 11;
  if (CheckHasBit(cached_has_bits, 0x00000040U)) {
    target = stream->EnsureSpace(target);
    target = ::_pbi::WireFormatLite::WriteFloatToArray(
        11, this_._internal_ignore_count_weight(), target);
  }

  // optional float threshold = 12;
  if (CheckHasBit(cached_has_bits, 0x00000080U)) {
    target = stream->EnsureSpace(target);
    target = ::_pbi::WireFormatLite::WriteFloatToArray(
        12, this_._internal_threshold(), target);
  }

  if (ABSL_PREDICT_FALSE(this_._internal_metadata_.have_unknown_fields())) {
    target = stream->WriteRaw(
        this_._internal_metadata_.unknown_fields<::std::string>(::google::protobuf::internal::GetEmptyString).data(),
        static_cast<int>(this_._internal_metadata_.unknown_fields<::std::string>(::google::protobuf::internal::GetEmptyString).size()), target);
  }
  // @@protoc_insertion_point(serialize_to_array_end:assist_ranker.TranslateRankerModel.TranslateLogisticRegressionModel)
  return target;
}

#if defined(PROTOBUF_CUSTOM_VTABLE)
::size_t TranslateRankerModel_TranslateLogisticRegressionModel::ByteSizeLong(const MessageLite& base) {
  const TranslateRankerModel_TranslateLogisticRegressionModel& this_ = static_cast<const TranslateRankerModel_TranslateLogisticRegressionModel&>(base);
#else   // PROTOBUF_CUSTOM_VTABLE
::size_t TranslateRankerModel_TranslateLogisticRegressionModel::ByteSizeLong() const {
  const TranslateRankerModel_TranslateLogisticRegressionModel& this_ = *this;
#endif  // PROTOBUF_CUSTOM_VTABLE
  // @@protoc_insertion_point(message_byte_size_start:assist_ranker.TranslateRankerModel.TranslateLogisticRegressionModel)
  ::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_);
  cached_has_bits = this_._impl_._has_bits_[0];
  total_size += ::absl::popcount(0x000000ffU & cached_has_bits) * 5;
  if (BatchCheckHasBit(cached_has_bits, 0x00000f00U)) {
    // map<string, float> source_language_weight = 5;
    if (CheckHasBit(cached_has_bits, 0x00000100U)) {
      total_size +=
          1 * ::google::protobuf::internal::FromIntSize(this_._internal_source_language_weight_size());
      for (const auto& entry : this_._internal_source_language_weight()) {
        total_size += _pbi::MapEntryFuncs<::std::string, float,
                                       _pbi::WireFormatLite::TYPE_STRING,
                                       _pbi::WireFormatLite::TYPE_FLOAT>::ByteSizeLong(entry.first, entry.second);
      }
    }
    // map<string, float> target_language_weight = 6;
    if (CheckHasBit(cached_has_bits, 0x00000200U)) {
      total_size +=
          1 * ::google::protobuf::internal::FromIntSize(this_._internal_target_language_weight_size());
      for (const auto& entry : this_._internal_target_language_weight()) {
        total_size += _pbi::MapEntryFuncs<::std::string, float,
                                       _pbi::WireFormatLite::TYPE_STRING,
                                       _pbi::WireFormatLite::TYPE_FLOAT>::ByteSizeLong(entry.first, entry.second);
      }
    }
    // map<string, float> country_weight = 7;
    if (CheckHasBit(cached_has_bits, 0x00000400U)) {
      total_size +=
          1 * ::google::protobuf::internal::FromIntSize(this_._internal_country_weight_size());
      for (const auto& entry : this_._internal_country_weight()) {
        total_size += _pbi::MapEntryFuncs<::std::string, float,
                                       _pbi::WireFormatLite::TYPE_STRING,
                                       _pbi::WireFormatLite::TYPE_FLOAT>::ByteSizeLong(entry.first, entry.second);
      }
    }
    // map<string, float> locale_weight = 8;
    if (CheckHasBit(cached_has_bits, 0x00000800U)) {
      total_size +=
          1 * ::google::protobuf::internal::FromIntSize(this_._internal_locale_weight_size());
      for (const auto& entry : this_._internal_locale_weight()) {
        total_size += _pbi::MapEntryFuncs<::std::string, float,
                                       _pbi::WireFormatLite::TYPE_STRING,
                                       _pbi::WireFormatLite::TYPE_FLOAT>::ByteSizeLong(entry.first, entry.second);
      }
    }
  }
  if (ABSL_PREDICT_FALSE(this_._internal_metadata_.have_unknown_fields())) {
    total_size += this_._internal_metadata_.unknown_fields<::std::string>(::google::protobuf::internal::GetEmptyString).size();
  }
  this_._impl_._cached_size_.Set(::_pbi::ToCachedSize(total_size));
  return total_size;
}

void TranslateRankerModel_TranslateLogisticRegressionModel::MergeImpl(::google::protobuf::MessageLite& to_msg,
                      const ::google::protobuf::MessageLite& from_msg) {
   auto* const _this = static_cast<TranslateRankerModel_TranslateLogisticRegressionModel*>(&to_msg);
  auto& from = static_cast<const TranslateRankerModel_TranslateLogisticRegressionModel&>(from_msg);
  if constexpr (::_pbi::DebugHardenCheckHasBitConsistency()) {
    from.CheckHasBitConsistency();
  }
  // @@protoc_insertion_point(class_specific_merge_from_start:assist_ranker.TranslateRankerModel.TranslateLogisticRegressionModel)
  ABSL_DCHECK_NE(&from, _this);
  ::uint32_t cached_has_bits = 0;
  (void)cached_has_bits;

  cached_has_bits = from._impl_._has_bits_[0];
  if (BatchCheckHasBit(cached_has_bits, 0x000000ffU)) {
    if (CheckHasBit(cached_has_bits, 0x00000001U)) {
      _this->_impl_.bias_ = from._impl_.bias_;
    }
    if (CheckHasBit(cached_has_bits, 0x00000002U)) {
      _this->_impl_.accept_ratio_weight_ = from._impl_.accept_ratio_weight_;
    }
    if (CheckHasBit(cached_has_bits, 0x00000004U)) {
      _this->_impl_.decline_ratio_weight_ = from._impl_.decline_ratio_weight_;
    }
    if (CheckHasBit(cached_has_bits, 0x00000008U)) {
      _this->_impl_.ignore_ratio_weight_ = from._impl_.ignore_ratio_weight_;
    }
    if (CheckHasBit(cached_has_bits, 0x00000010U)) {
      _this->_impl_.accept_count_weight_ = from._impl_.accept_count_weight_;
    }
    if (CheckHasBit(cached_has_bits, 0x00000020U)) {
      _this->_impl_.decline_count_weight_ = from._impl_.decline_count_weight_;
    }
    if (CheckHasBit(cached_has_bits, 0x00000040U)) {
      _this->_impl_.ignore_count_weight_ = from._impl_.ignore_count_weight_;
    }
    if (CheckHasBit(cached_has_bits, 0x00000080U)) {
      _this->_impl_.threshold_ = from._impl_.threshold_;
    }
  }
  if (BatchCheckHasBit(cached_has_bits, 0x00000f00U)) {
    if (CheckHasBit(cached_has_bits, 0x00000100U)) {
      _this->_impl_.source_language_weight_.MergeFrom(from._impl_.source_language_weight_);
    }
    if (CheckHasBit(cached_has_bits, 0x00000200U)) {
      _this->_impl_.target_language_weight_.MergeFrom(from._impl_.target_language_weight_);
    }
    if (CheckHasBit(cached_has_bits, 0x00000400U)) {
      _this->_impl_.country_weight_.MergeFrom(from._impl_.country_weight_);
    }
    if (CheckHasBit(cached_has_bits, 0x00000800U)) {
      _this->_impl_.locale_weight_.MergeFrom(from._impl_.locale_weight_);
    }
  }
  _this->_impl_._has_bits_[0] |= cached_has_bits;
  _this->_internal_metadata_.MergeFrom<::std::string>(
      from._internal_metadata_);
}

void TranslateRankerModel_TranslateLogisticRegressionModel::CopyFrom(const TranslateRankerModel_TranslateLogisticRegressionModel& from) {
  // @@protoc_insertion_point(class_specific_copy_from_start:assist_ranker.TranslateRankerModel.TranslateLogisticRegressionModel)
  if (&from == this) return;
  Clear();
  MergeFrom(from);
}


void TranslateRankerModel_TranslateLogisticRegressionModel::InternalSwap(TranslateRankerModel_TranslateLogisticRegressionModel* PROTOBUF_RESTRICT PROTOBUF_NONNULL other) {
  using ::std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
  ::google::protobuf::internal::memswap<
      PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.threshold_)
      + sizeof(TranslateRankerModel_TranslateLogisticRegressionModel::_impl_.threshold_)
      - PROTOBUF_FIELD_OFFSET(TranslateRankerModel_TranslateLogisticRegressionModel, _impl_.bias_)>(
          reinterpret_cast<char*>(&_impl_.bias_),
          reinterpret_cast<char*>(&other->_impl_.bias_));
  _impl_.source_language_weight_.InternalSwap(&other->_impl_.source_language_weight_);
  _impl_.target_language_weight_.InternalSwap(&other->_impl_.target_language_weight_);
  _impl_.country_weight_.InternalSwap(&other->_impl_.country_weight_);
  _impl_.locale_weight_.InternalSwap(&other->_impl_.locale_weight_);
}

// ===================================================================

void TranslateRankerModel::set_allocated_translate_logistic_regression_model(::assist_ranker::TranslateRankerModel_TranslateLogisticRegressionModel* PROTOBUF_NULLABLE translate_logistic_regression_model) {
  ::google::protobuf::Arena* message_arena = GetArena();
  clear_model_revision();
  if (translate_logistic_regression_model) {
    ::google::protobuf::Arena* submessage_arena = translate_logistic_regression_model->GetArena();
    if (message_arena != submessage_arena) {
      translate_logistic_regression_model = ::google::protobuf::internal::GetOwnedMessage(message_arena, translate_logistic_regression_model, submessage_arena);
    }
    set_has_translate_logistic_regression_model();
    _impl_.model_revision_.translate_logistic_regression_model_ = translate_logistic_regression_model;
  }
  // @@protoc_insertion_point(field_set_allocated:assist_ranker.TranslateRankerModel.translate_logistic_regression_model)
}
TranslateRankerModel::TranslateRankerModel(::google::protobuf::Arena* PROTOBUF_NULLABLE arena)
#if defined(PROTOBUF_CUSTOM_VTABLE)
    : ::google::protobuf::MessageLite(arena, TranslateRankerModel_get_class_data()) {
#else   // PROTOBUF_CUSTOM_VTABLE
    : ::google::protobuf::MessageLite(arena) {
#endif  // PROTOBUF_CUSTOM_VTABLE
  SharedCtor(arena);
  // @@protoc_insertion_point(arena_constructor:assist_ranker.TranslateRankerModel)
}
PROTOBUF_NDEBUG_INLINE TranslateRankerModel::Impl_::Impl_(
    [[maybe_unused]] ::google::protobuf::internal::InternalVisibility visibility,
    [[maybe_unused]] ::google::protobuf::Arena* PROTOBUF_NULLABLE arena, const Impl_& from,
    [[maybe_unused]] const ::assist_ranker::TranslateRankerModel& from_msg)
      : _has_bits_{from._has_bits_},
        _cached_size_{0},
        model_revision_{},
        _oneof_case_{from._oneof_case_[0]} {}

TranslateRankerModel::TranslateRankerModel(
    ::google::protobuf::Arena* PROTOBUF_NULLABLE arena,
    const TranslateRankerModel& from)
#if defined(PROTOBUF_CUSTOM_VTABLE)
    : ::google::protobuf::MessageLite(arena, TranslateRankerModel_get_class_data()) {

#else   // PROTOBUF_CUSTOM_VTABLE
    : ::google::protobuf::MessageLite(arena) {
#endif  // PROTOBUF_CUSTOM_VTABLE
  TranslateRankerModel* const _this = this;
  (void)_this;
  _internal_metadata_.MergeFrom<::std::string>(
      from._internal_metadata_);
  new (&_impl_) Impl_(internal_visibility(), arena, from._impl_, from);
  _impl_.version_ = from._impl_.version_;
  switch (model_revision_case()) {
    case MODEL_REVISION_NOT_SET:
      break;
      case kTranslateLogisticRegressionModel:
        _impl_.model_revision_.translate_logistic_regression_model_ = ::google::protobuf::MessageLite::CopyConstruct(arena, *from._impl_.model_revision_.translate_logistic_regression_model_);
        break;
  }

  // @@protoc_insertion_point(copy_constructor:assist_ranker.TranslateRankerModel)
}
PROTOBUF_NDEBUG_INLINE TranslateRankerModel::Impl_::Impl_(
    [[maybe_unused]] ::google::protobuf::internal::InternalVisibility visibility,
    [[maybe_unused]] ::google::protobuf::Arena* PROTOBUF_NULLABLE arena)
      : _cached_size_{0},
        model_revision_{},
        _oneof_case_{} {}

inline void TranslateRankerModel::SharedCtor(::_pb::Arena* PROTOBUF_NULLABLE arena) {
  new (&_impl_) Impl_(internal_visibility(), arena);
  _impl_.version_ = {};
}
TranslateRankerModel::~TranslateRankerModel() {
  // @@protoc_insertion_point(destructor:assist_ranker.TranslateRankerModel)
  SharedDtor(*this);
}
inline void TranslateRankerModel::SharedDtor(MessageLite& self) {
  TranslateRankerModel& this_ = static_cast<TranslateRankerModel&>(self);
  if constexpr (::_pbi::DebugHardenCheckHasBitConsistency()) {
    this_.CheckHasBitConsistency();
  }
  this_._internal_metadata_.Delete<::std::string>();
  ABSL_DCHECK(this_.GetArena() == nullptr);
  if (this_.has_model_revision()) {
    this_.clear_model_revision();
  }
  this_._impl_.~Impl_();
}

void TranslateRankerModel::clear_model_revision() {
// @@protoc_insertion_point(one_of_clear_start:assist_ranker.TranslateRankerModel)
  ::google::protobuf::internal::TSanWrite(&_impl_);
  switch (model_revision_case()) {
    case kTranslateLogisticRegressionModel: {
      if (GetArena() == nullptr) {
        delete _impl_.model_revision_.translate_logistic_regression_model_;
      } else if (::google::protobuf::internal::DebugHardenClearOneofMessageOnArena()) {
        if (_impl_.model_revision_.translate_logistic_regression_model_ != nullptr) {
          _impl_.model_revision_.translate_logistic_regression_model_->Clear();
        }
      }
      break;
    }
    case MODEL_REVISION_NOT_SET: {
      break;
    }
  }
  _impl_._oneof_case_[0] = MODEL_REVISION_NOT_SET;
}


#ifndef PROTOBUF_MESSAGE_GLOBALS
PROTOBUF_CONSTINIT
PROTOBUF_ATTRIBUTE_INIT_PRIORITY1
const ::google::protobuf::internal::ClassDataLite TranslateRankerModel_class_data_ =
    TranslateRankerModel::InternalGenerateClassData_(TranslateRankerModel_globals_._default);

PROTOBUF_ATTRIBUTE_WEAK const ::google::protobuf::internal::ClassData* PROTOBUF_NONNULL
TranslateRankerModel::GetClassData() const {
  return TranslateRankerModel_class_data_.base();
}
#else
PROTOBUF_ATTRIBUTE_WEAK const ::google::protobuf::internal::ClassData* PROTOBUF_NONNULL
TranslateRankerModel::GetClassData() const {
  return TranslateRankerModel_globals_.GetClassData();
}
#endif  // !PROTOBUF_MESSAGE_GLOBALS
#ifndef PROTOBUF_MESSAGE_GLOBALS
PROTOBUF_CONSTINIT
PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 const TranslateRankerModel::ParseTableT_
    TranslateRankerModel::_table_ =
        TranslateRankerModel::InternalGenerateParseTable_(TranslateRankerModel_class_data_.base());
#endif  // !PROTOBUF_MESSAGE_GLOBALS
PROTOBUF_NOINLINE void TranslateRankerModel::Clear() {
// @@protoc_insertion_point(message_clear_start:assist_ranker.TranslateRankerModel)
  ::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_.version_ = 0u;
  clear_model_revision();
  _impl_._has_bits_.Clear();
  _internal_metadata_.Clear<::std::string>();
}

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

  cached_has_bits = this_._impl_._has_bits_[0];
  // optional uint32 version = 1;
  if (CheckHasBit(cached_has_bits, 0x00000001U)) {
    target = stream->EnsureSpace(target);
    target = ::_pbi::WireFormatLite::WriteUInt32ToArray(
        1, this_._internal_version(), target);
  }

  // .assist_ranker.TranslateRankerModel.TranslateLogisticRegressionModel translate_logistic_regression_model = 2;
  if (this_.model_revision_case() == kTranslateLogisticRegressionModel) {
    target = ::google::protobuf::internal::WireFormatLite::InternalWriteMessage(
        2, *this_._impl_.model_revision_.translate_logistic_regression_model_, this_._impl_.model_revision_.translate_logistic_regression_model_->GetCachedSize(), target,
        stream);
  }

  if (ABSL_PREDICT_FALSE(this_._internal_metadata_.have_unknown_fields())) {
    target = stream->WriteRaw(
        this_._internal_metadata_.unknown_fields<::std::string>(::google::protobuf::internal::GetEmptyString).data(),
        static_cast<int>(this_._internal_metadata_.unknown_fields<::std::string>(::google::protobuf::internal::GetEmptyString).size()), target);
  }
  // @@protoc_insertion_point(serialize_to_array_end:assist_ranker.TranslateRankerModel)
  return target;
}

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

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

   {
    // optional uint32 version = 1;
    cached_has_bits = this_._impl_._has_bits_[0];
    if (CheckHasBit(cached_has_bits, 0x00000001U)) {
      total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(
          this_._internal_version());
    }
  }
  switch (this_.model_revision_case()) {
    // .assist_ranker.TranslateRankerModel.TranslateLogisticRegressionModel translate_logistic_regression_model = 2;
    case kTranslateLogisticRegressionModel: {
      total_size += 1 +
                    ::google::protobuf::internal::WireFormatLite::MessageSize(*this_._impl_.model_revision_.translate_logistic_regression_model_);
      break;
    }
    case MODEL_REVISION_NOT_SET: {
      break;
    }
  }
  if (ABSL_PREDICT_FALSE(this_._internal_metadata_.have_unknown_fields())) {
    total_size += this_._internal_metadata_.unknown_fields<::std::string>(::google::protobuf::internal::GetEmptyString).size();
  }
  this_._impl_._cached_size_.Set(::_pbi::ToCachedSize(total_size));
  return total_size;
}

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

  cached_has_bits = from._impl_._has_bits_[0];
  if (CheckHasBit(cached_has_bits, 0x00000001U)) {
    _this->_impl_.version_ = from._impl_.version_;
  }
  _this->_impl_._has_bits_[0] |= cached_has_bits;
  if (const uint32_t oneof_from_case =
          from._impl_._oneof_case_[0]) {
    const uint32_t oneof_to_case = _this->_impl_._oneof_case_[0];
    const bool oneof_needs_init = oneof_to_case != oneof_from_case;
    if (oneof_needs_init) {
      if (oneof_to_case != 0) {
        _this->clear_model_revision();
      }
      _this->_impl_._oneof_case_[0] = oneof_from_case;
    }

    switch (oneof_from_case) {
      case kTranslateLogisticRegressionModel: {
        if (oneof_needs_init) {
          _this->_impl_.model_revision_.translate_logistic_regression_model_ = ::google::protobuf::MessageLite::CopyConstruct(arena, *from._impl_.model_revision_.translate_logistic_regression_model_);
        } else {
          _this->_impl_.model_revision_.translate_logistic_regression_model_->MergeFrom(*from._impl_.model_revision_.translate_logistic_regression_model_);
        }
        break;
      }
      case MODEL_REVISION_NOT_SET:
        break;
    }
  }
  _this->_internal_metadata_.MergeFrom<::std::string>(
      from._internal_metadata_);
}

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


void TranslateRankerModel::InternalSwap(TranslateRankerModel* PROTOBUF_RESTRICT PROTOBUF_NONNULL other) {
  using ::std::swap;
  _internal_metadata_.InternalSwap(&other->_internal_metadata_);
  swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
  swap(_impl_.version_, other->_impl_.version_);
  swap(_impl_.model_revision_, other->_impl_.model_revision_);
  swap(_impl_._oneof_case_[0], other->_impl_._oneof_case_[0]);
}

// @@protoc_insertion_point(namespace_scope)
}  // namespace assist_ranker
namespace google {
namespace protobuf {
}  // namespace protobuf
}  // namespace google
// @@protoc_insertion_point(global_scope)
#include "google/protobuf/port_undef.inc"
