opencv/modules/dnn/misc/caffe/opencv-caffe.pb.cc
2017-12-20 10:43:22 +03:00

56399 lines
1.9 MiB

// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: opencv-caffe.proto
#define INTERNAL_SUPPRESS_PROTOBUF_FIELD_DEPRECATION
#include "opencv-caffe.pb.h"
#include <algorithm>
#include <google/protobuf/stubs/common.h>
#include <google/protobuf/stubs/port.h>
#include <google/protobuf/stubs/once.h>
#include <google/protobuf/io/coded_stream.h>
#include <google/protobuf/wire_format_lite_inl.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)
namespace opencv_caffe {
namespace {
const ::google::protobuf::Descriptor* BlobShape_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
BlobShape_reflection_ = NULL;
const ::google::protobuf::Descriptor* BlobProto_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
BlobProto_reflection_ = NULL;
const ::google::protobuf::Descriptor* BlobProtoVector_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
BlobProtoVector_reflection_ = NULL;
const ::google::protobuf::Descriptor* PermuteParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
PermuteParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* NormalizeBBoxParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
NormalizeBBoxParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* PriorBoxParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
PriorBoxParameter_reflection_ = NULL;
const ::google::protobuf::EnumDescriptor* PriorBoxParameter_CodeType_descriptor_ = NULL;
const ::google::protobuf::Descriptor* DetectionOutputParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
DetectionOutputParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* Datum_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
Datum_reflection_ = NULL;
const ::google::protobuf::Descriptor* FillerParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
FillerParameter_reflection_ = NULL;
const ::google::protobuf::EnumDescriptor* FillerParameter_VarianceNorm_descriptor_ = NULL;
const ::google::protobuf::Descriptor* NetParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
NetParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* SolverParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
SolverParameter_reflection_ = NULL;
const ::google::protobuf::EnumDescriptor* SolverParameter_SnapshotFormat_descriptor_ = NULL;
const ::google::protobuf::EnumDescriptor* SolverParameter_SolverMode_descriptor_ = NULL;
const ::google::protobuf::EnumDescriptor* SolverParameter_SolverType_descriptor_ = NULL;
const ::google::protobuf::Descriptor* SolverState_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
SolverState_reflection_ = NULL;
const ::google::protobuf::Descriptor* NetState_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
NetState_reflection_ = NULL;
const ::google::protobuf::Descriptor* NetStateRule_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
NetStateRule_reflection_ = NULL;
const ::google::protobuf::Descriptor* ParamSpec_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
ParamSpec_reflection_ = NULL;
const ::google::protobuf::EnumDescriptor* ParamSpec_DimCheckMode_descriptor_ = NULL;
const ::google::protobuf::Descriptor* LayerParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
LayerParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* TransformationParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
TransformationParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* LossParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
LossParameter_reflection_ = NULL;
const ::google::protobuf::EnumDescriptor* LossParameter_NormalizationMode_descriptor_ = NULL;
const ::google::protobuf::Descriptor* AccuracyParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
AccuracyParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* ArgMaxParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
ArgMaxParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* ConcatParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
ConcatParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* BatchNormParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
BatchNormParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* BiasParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
BiasParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* ContrastiveLossParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
ContrastiveLossParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* ConvolutionParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
ConvolutionParameter_reflection_ = NULL;
const ::google::protobuf::EnumDescriptor* ConvolutionParameter_Engine_descriptor_ = NULL;
const ::google::protobuf::Descriptor* CropParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
CropParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* DataParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
DataParameter_reflection_ = NULL;
const ::google::protobuf::EnumDescriptor* DataParameter_DB_descriptor_ = NULL;
const ::google::protobuf::Descriptor* NonMaximumSuppressionParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
NonMaximumSuppressionParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* SaveOutputParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
SaveOutputParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* DropoutParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
DropoutParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* DummyDataParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
DummyDataParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* EltwiseParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
EltwiseParameter_reflection_ = NULL;
const ::google::protobuf::EnumDescriptor* EltwiseParameter_EltwiseOp_descriptor_ = NULL;
const ::google::protobuf::Descriptor* ELUParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
ELUParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* EmbedParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
EmbedParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* ExpParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
ExpParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* FlattenParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
FlattenParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* HDF5DataParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
HDF5DataParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* HDF5OutputParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
HDF5OutputParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* HingeLossParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
HingeLossParameter_reflection_ = NULL;
const ::google::protobuf::EnumDescriptor* HingeLossParameter_Norm_descriptor_ = NULL;
const ::google::protobuf::Descriptor* ImageDataParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
ImageDataParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* InfogainLossParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
InfogainLossParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* InnerProductParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
InnerProductParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* InputParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
InputParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* LogParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
LogParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* LRNParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
LRNParameter_reflection_ = NULL;
const ::google::protobuf::EnumDescriptor* LRNParameter_NormRegion_descriptor_ = NULL;
const ::google::protobuf::EnumDescriptor* LRNParameter_Engine_descriptor_ = NULL;
const ::google::protobuf::Descriptor* MemoryDataParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
MemoryDataParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* MVNParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
MVNParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* ParameterParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
ParameterParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* PoolingParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
PoolingParameter_reflection_ = NULL;
const ::google::protobuf::EnumDescriptor* PoolingParameter_PoolMethod_descriptor_ = NULL;
const ::google::protobuf::EnumDescriptor* PoolingParameter_Engine_descriptor_ = NULL;
const ::google::protobuf::Descriptor* PowerParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
PowerParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* PythonParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
PythonParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* RecurrentParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
RecurrentParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* ReductionParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
ReductionParameter_reflection_ = NULL;
const ::google::protobuf::EnumDescriptor* ReductionParameter_ReductionOp_descriptor_ = NULL;
const ::google::protobuf::Descriptor* ReLUParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
ReLUParameter_reflection_ = NULL;
const ::google::protobuf::EnumDescriptor* ReLUParameter_Engine_descriptor_ = NULL;
const ::google::protobuf::Descriptor* ReshapeParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
ReshapeParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* ScaleParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
ScaleParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* SigmoidParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
SigmoidParameter_reflection_ = NULL;
const ::google::protobuf::EnumDescriptor* SigmoidParameter_Engine_descriptor_ = NULL;
const ::google::protobuf::Descriptor* SliceParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
SliceParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* SoftmaxParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
SoftmaxParameter_reflection_ = NULL;
const ::google::protobuf::EnumDescriptor* SoftmaxParameter_Engine_descriptor_ = NULL;
const ::google::protobuf::Descriptor* TanHParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
TanHParameter_reflection_ = NULL;
const ::google::protobuf::EnumDescriptor* TanHParameter_Engine_descriptor_ = NULL;
const ::google::protobuf::Descriptor* TileParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
TileParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* ThresholdParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
ThresholdParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* WindowDataParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
WindowDataParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* SPPParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
SPPParameter_reflection_ = NULL;
const ::google::protobuf::EnumDescriptor* SPPParameter_PoolMethod_descriptor_ = NULL;
const ::google::protobuf::EnumDescriptor* SPPParameter_Engine_descriptor_ = NULL;
const ::google::protobuf::Descriptor* V1LayerParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
V1LayerParameter_reflection_ = NULL;
const ::google::protobuf::EnumDescriptor* V1LayerParameter_LayerType_descriptor_ = NULL;
const ::google::protobuf::EnumDescriptor* V1LayerParameter_DimCheckMode_descriptor_ = NULL;
const ::google::protobuf::Descriptor* V0LayerParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
V0LayerParameter_reflection_ = NULL;
const ::google::protobuf::EnumDescriptor* V0LayerParameter_PoolMethod_descriptor_ = NULL;
const ::google::protobuf::Descriptor* PReLUParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
PReLUParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* NormalizedBBox_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
NormalizedBBox_reflection_ = NULL;
const ::google::protobuf::Descriptor* ROIPoolingParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
ROIPoolingParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* ProposalParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
ProposalParameter_reflection_ = NULL;
const ::google::protobuf::Descriptor* PSROIPoolingParameter_descriptor_ = NULL;
const ::google::protobuf::internal::GeneratedMessageReflection*
PSROIPoolingParameter_reflection_ = NULL;
const ::google::protobuf::EnumDescriptor* Type_descriptor_ = NULL;
const ::google::protobuf::EnumDescriptor* Phase_descriptor_ = NULL;
} // namespace
void protobuf_AssignDesc_opencv_2dcaffe_2eproto() GOOGLE_ATTRIBUTE_COLD;
void protobuf_AssignDesc_opencv_2dcaffe_2eproto() {
protobuf_AddDesc_opencv_2dcaffe_2eproto();
const ::google::protobuf::FileDescriptor* file =
::google::protobuf::DescriptorPool::generated_pool()->FindFileByName(
"opencv-caffe.proto");
GOOGLE_CHECK(file != NULL);
BlobShape_descriptor_ = file->message_type(0);
static const int BlobShape_offsets_[1] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobShape, dim_),
};
BlobShape_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
BlobShape_descriptor_,
BlobShape::internal_default_instance(),
BlobShape_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobShape, _has_bits_),
-1,
-1,
sizeof(BlobShape),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobShape, _internal_metadata_));
BlobProto_descriptor_ = file->message_type(1);
static const int BlobProto_offsets_[11] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobProto, shape_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobProto, data_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobProto, diff_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobProto, double_data_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobProto, double_diff_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobProto, raw_data_type_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobProto, raw_data_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobProto, num_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobProto, channels_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobProto, height_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobProto, width_),
};
BlobProto_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
BlobProto_descriptor_,
BlobProto::internal_default_instance(),
BlobProto_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobProto, _has_bits_),
-1,
-1,
sizeof(BlobProto),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobProto, _internal_metadata_));
BlobProtoVector_descriptor_ = file->message_type(2);
static const int BlobProtoVector_offsets_[1] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobProtoVector, blobs_),
};
BlobProtoVector_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
BlobProtoVector_descriptor_,
BlobProtoVector::internal_default_instance(),
BlobProtoVector_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobProtoVector, _has_bits_),
-1,
-1,
sizeof(BlobProtoVector),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BlobProtoVector, _internal_metadata_));
PermuteParameter_descriptor_ = file->message_type(3);
static const int PermuteParameter_offsets_[1] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PermuteParameter, order_),
};
PermuteParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
PermuteParameter_descriptor_,
PermuteParameter::internal_default_instance(),
PermuteParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PermuteParameter, _has_bits_),
-1,
-1,
sizeof(PermuteParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PermuteParameter, _internal_metadata_));
NormalizeBBoxParameter_descriptor_ = file->message_type(4);
static const int NormalizeBBoxParameter_offsets_[4] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalizeBBoxParameter, across_spatial_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalizeBBoxParameter, scale_filler_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalizeBBoxParameter, channel_shared_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalizeBBoxParameter, eps_),
};
NormalizeBBoxParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
NormalizeBBoxParameter_descriptor_,
NormalizeBBoxParameter::internal_default_instance(),
NormalizeBBoxParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalizeBBoxParameter, _has_bits_),
-1,
-1,
sizeof(NormalizeBBoxParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalizeBBoxParameter, _internal_metadata_));
PriorBoxParameter_descriptor_ = file->message_type(5);
static const int PriorBoxParameter_offsets_[17] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PriorBoxParameter, min_size_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PriorBoxParameter, max_size_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PriorBoxParameter, aspect_ratio_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PriorBoxParameter, flip_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PriorBoxParameter, clip_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PriorBoxParameter, variance_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PriorBoxParameter, img_size_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PriorBoxParameter, img_h_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PriorBoxParameter, img_w_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PriorBoxParameter, step_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PriorBoxParameter, step_h_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PriorBoxParameter, step_w_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PriorBoxParameter, offset_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PriorBoxParameter, offset_h_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PriorBoxParameter, offset_w_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PriorBoxParameter, width_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PriorBoxParameter, height_),
};
PriorBoxParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
PriorBoxParameter_descriptor_,
PriorBoxParameter::internal_default_instance(),
PriorBoxParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PriorBoxParameter, _has_bits_),
-1,
-1,
sizeof(PriorBoxParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PriorBoxParameter, _internal_metadata_));
PriorBoxParameter_CodeType_descriptor_ = PriorBoxParameter_descriptor_->enum_type(0);
DetectionOutputParameter_descriptor_ = file->message_type(6);
static const int DetectionOutputParameter_offsets_[10] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DetectionOutputParameter, num_classes_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DetectionOutputParameter, share_location_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DetectionOutputParameter, background_label_id_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DetectionOutputParameter, nms_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DetectionOutputParameter, save_output_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DetectionOutputParameter, code_type_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DetectionOutputParameter, variance_encoded_in_target_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DetectionOutputParameter, keep_top_k_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DetectionOutputParameter, confidence_threshold_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DetectionOutputParameter, normalized_bbox_),
};
DetectionOutputParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
DetectionOutputParameter_descriptor_,
DetectionOutputParameter::internal_default_instance(),
DetectionOutputParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DetectionOutputParameter, _has_bits_),
-1,
-1,
sizeof(DetectionOutputParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DetectionOutputParameter, _internal_metadata_));
Datum_descriptor_ = file->message_type(7);
static const int Datum_offsets_[7] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Datum, channels_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Datum, height_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Datum, width_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Datum, data_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Datum, label_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Datum, float_data_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Datum, encoded_),
};
Datum_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
Datum_descriptor_,
Datum::internal_default_instance(),
Datum_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Datum, _has_bits_),
-1,
-1,
sizeof(Datum),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Datum, _internal_metadata_));
FillerParameter_descriptor_ = file->message_type(8);
static const int FillerParameter_offsets_[8] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(FillerParameter, type_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(FillerParameter, value_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(FillerParameter, min_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(FillerParameter, max_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(FillerParameter, mean_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(FillerParameter, std_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(FillerParameter, sparse_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(FillerParameter, variance_norm_),
};
FillerParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
FillerParameter_descriptor_,
FillerParameter::internal_default_instance(),
FillerParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(FillerParameter, _has_bits_),
-1,
-1,
sizeof(FillerParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(FillerParameter, _internal_metadata_));
FillerParameter_VarianceNorm_descriptor_ = FillerParameter_descriptor_->enum_type(0);
NetParameter_descriptor_ = file->message_type(9);
static const int NetParameter_offsets_[9] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NetParameter, name_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NetParameter, input_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NetParameter, input_shape_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NetParameter, input_dim_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NetParameter, force_backward_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NetParameter, state_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NetParameter, debug_info_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NetParameter, layer_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NetParameter, layers_),
};
NetParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
NetParameter_descriptor_,
NetParameter::internal_default_instance(),
NetParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NetParameter, _has_bits_),
-1,
-1,
sizeof(NetParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NetParameter, _internal_metadata_));
SolverParameter_descriptor_ = file->message_type(10);
static const int SolverParameter_offsets_[40] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, net_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, net_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, train_net_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, test_net_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, train_net_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, test_net_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, train_state_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, test_state_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, test_iter_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, test_interval_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, test_compute_loss_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, test_initialization_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, base_lr_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, display_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, average_loss_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, max_iter_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, iter_size_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, lr_policy_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, gamma_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, power_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, momentum_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, weight_decay_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, regularization_type_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, stepsize_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, stepvalue_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, clip_gradients_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, snapshot_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, snapshot_prefix_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, snapshot_diff_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, snapshot_format_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, solver_mode_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, device_id_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, random_seed_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, type_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, delta_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, momentum2_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, rms_decay_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, debug_info_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, snapshot_after_train_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, solver_type_),
};
SolverParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
SolverParameter_descriptor_,
SolverParameter::internal_default_instance(),
SolverParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, _has_bits_),
-1,
-1,
sizeof(SolverParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverParameter, _internal_metadata_));
SolverParameter_SnapshotFormat_descriptor_ = SolverParameter_descriptor_->enum_type(0);
SolverParameter_SolverMode_descriptor_ = SolverParameter_descriptor_->enum_type(1);
SolverParameter_SolverType_descriptor_ = SolverParameter_descriptor_->enum_type(2);
SolverState_descriptor_ = file->message_type(11);
static const int SolverState_offsets_[4] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverState, iter_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverState, learned_net_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverState, history_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverState, current_step_),
};
SolverState_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
SolverState_descriptor_,
SolverState::internal_default_instance(),
SolverState_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverState, _has_bits_),
-1,
-1,
sizeof(SolverState),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SolverState, _internal_metadata_));
NetState_descriptor_ = file->message_type(12);
static const int NetState_offsets_[3] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NetState, phase_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NetState, level_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NetState, stage_),
};
NetState_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
NetState_descriptor_,
NetState::internal_default_instance(),
NetState_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NetState, _has_bits_),
-1,
-1,
sizeof(NetState),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NetState, _internal_metadata_));
NetStateRule_descriptor_ = file->message_type(13);
static const int NetStateRule_offsets_[5] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NetStateRule, phase_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NetStateRule, min_level_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NetStateRule, max_level_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NetStateRule, stage_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NetStateRule, not_stage_),
};
NetStateRule_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
NetStateRule_descriptor_,
NetStateRule::internal_default_instance(),
NetStateRule_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NetStateRule, _has_bits_),
-1,
-1,
sizeof(NetStateRule),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NetStateRule, _internal_metadata_));
ParamSpec_descriptor_ = file->message_type(14);
static const int ParamSpec_offsets_[4] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ParamSpec, name_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ParamSpec, share_mode_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ParamSpec, lr_mult_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ParamSpec, decay_mult_),
};
ParamSpec_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
ParamSpec_descriptor_,
ParamSpec::internal_default_instance(),
ParamSpec_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ParamSpec, _has_bits_),
-1,
-1,
sizeof(ParamSpec),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ParamSpec, _internal_metadata_));
ParamSpec_DimCheckMode_descriptor_ = ParamSpec_descriptor_->enum_type(0);
LayerParameter_descriptor_ = file->message_type(15);
static const int LayerParameter_offsets_[65] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, name_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, type_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, bottom_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, top_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, phase_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, loss_weight_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, blobs_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, propagate_down_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, include_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, exclude_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, transform_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, loss_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, accuracy_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, argmax_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, batch_norm_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, bias_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, concat_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, contrastive_loss_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, convolution_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, crop_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, data_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, detection_output_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, dropout_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, dummy_data_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, eltwise_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, elu_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, embed_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, exp_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, flatten_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, hdf5_data_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, hdf5_output_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, hinge_loss_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, image_data_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, infogain_loss_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, inner_product_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, input_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, log_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, lrn_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, memory_data_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, mvn_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, norm_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, permute_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, parameter_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, pooling_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, power_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, prelu_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, prior_box_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, proposal_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, psroi_pooling_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, python_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, recurrent_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, reduction_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, relu_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, reshape_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, roi_pooling_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, scale_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, sigmoid_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, softmax_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, spp_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, slice_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, tanh_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, threshold_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, tile_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, window_data_param_),
};
LayerParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
LayerParameter_descriptor_,
LayerParameter::internal_default_instance(),
LayerParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, _has_bits_),
-1,
-1,
sizeof(LayerParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LayerParameter, _internal_metadata_));
TransformationParameter_descriptor_ = file->message_type(16);
static const int TransformationParameter_offsets_[7] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(TransformationParameter, scale_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(TransformationParameter, mirror_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(TransformationParameter, crop_size_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(TransformationParameter, mean_file_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(TransformationParameter, mean_value_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(TransformationParameter, force_color_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(TransformationParameter, force_gray_),
};
TransformationParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
TransformationParameter_descriptor_,
TransformationParameter::internal_default_instance(),
TransformationParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(TransformationParameter, _has_bits_),
-1,
-1,
sizeof(TransformationParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(TransformationParameter, _internal_metadata_));
LossParameter_descriptor_ = file->message_type(17);
static const int LossParameter_offsets_[3] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LossParameter, ignore_label_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LossParameter, normalization_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LossParameter, normalize_),
};
LossParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
LossParameter_descriptor_,
LossParameter::internal_default_instance(),
LossParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LossParameter, _has_bits_),
-1,
-1,
sizeof(LossParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LossParameter, _internal_metadata_));
LossParameter_NormalizationMode_descriptor_ = LossParameter_descriptor_->enum_type(0);
AccuracyParameter_descriptor_ = file->message_type(18);
static const int AccuracyParameter_offsets_[3] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(AccuracyParameter, top_k_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(AccuracyParameter, axis_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(AccuracyParameter, ignore_label_),
};
AccuracyParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
AccuracyParameter_descriptor_,
AccuracyParameter::internal_default_instance(),
AccuracyParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(AccuracyParameter, _has_bits_),
-1,
-1,
sizeof(AccuracyParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(AccuracyParameter, _internal_metadata_));
ArgMaxParameter_descriptor_ = file->message_type(19);
static const int ArgMaxParameter_offsets_[3] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ArgMaxParameter, out_max_val_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ArgMaxParameter, top_k_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ArgMaxParameter, axis_),
};
ArgMaxParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
ArgMaxParameter_descriptor_,
ArgMaxParameter::internal_default_instance(),
ArgMaxParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ArgMaxParameter, _has_bits_),
-1,
-1,
sizeof(ArgMaxParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ArgMaxParameter, _internal_metadata_));
ConcatParameter_descriptor_ = file->message_type(20);
static const int ConcatParameter_offsets_[2] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConcatParameter, axis_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConcatParameter, concat_dim_),
};
ConcatParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
ConcatParameter_descriptor_,
ConcatParameter::internal_default_instance(),
ConcatParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConcatParameter, _has_bits_),
-1,
-1,
sizeof(ConcatParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConcatParameter, _internal_metadata_));
BatchNormParameter_descriptor_ = file->message_type(21);
static const int BatchNormParameter_offsets_[3] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BatchNormParameter, use_global_stats_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BatchNormParameter, moving_average_fraction_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BatchNormParameter, eps_),
};
BatchNormParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
BatchNormParameter_descriptor_,
BatchNormParameter::internal_default_instance(),
BatchNormParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BatchNormParameter, _has_bits_),
-1,
-1,
sizeof(BatchNormParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BatchNormParameter, _internal_metadata_));
BiasParameter_descriptor_ = file->message_type(22);
static const int BiasParameter_offsets_[3] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BiasParameter, axis_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BiasParameter, num_axes_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BiasParameter, filler_),
};
BiasParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
BiasParameter_descriptor_,
BiasParameter::internal_default_instance(),
BiasParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BiasParameter, _has_bits_),
-1,
-1,
sizeof(BiasParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(BiasParameter, _internal_metadata_));
ContrastiveLossParameter_descriptor_ = file->message_type(23);
static const int ContrastiveLossParameter_offsets_[2] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ContrastiveLossParameter, margin_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ContrastiveLossParameter, legacy_version_),
};
ContrastiveLossParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
ContrastiveLossParameter_descriptor_,
ContrastiveLossParameter::internal_default_instance(),
ContrastiveLossParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ContrastiveLossParameter, _has_bits_),
-1,
-1,
sizeof(ContrastiveLossParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ContrastiveLossParameter, _internal_metadata_));
ConvolutionParameter_descriptor_ = file->message_type(24);
static const int ConvolutionParameter_offsets_[18] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConvolutionParameter, num_output_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConvolutionParameter, bias_term_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConvolutionParameter, pad_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConvolutionParameter, kernel_size_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConvolutionParameter, stride_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConvolutionParameter, dilation_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConvolutionParameter, pad_h_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConvolutionParameter, pad_w_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConvolutionParameter, kernel_h_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConvolutionParameter, kernel_w_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConvolutionParameter, stride_h_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConvolutionParameter, stride_w_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConvolutionParameter, group_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConvolutionParameter, weight_filler_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConvolutionParameter, bias_filler_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConvolutionParameter, engine_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConvolutionParameter, axis_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConvolutionParameter, force_nd_im2col_),
};
ConvolutionParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
ConvolutionParameter_descriptor_,
ConvolutionParameter::internal_default_instance(),
ConvolutionParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConvolutionParameter, _has_bits_),
-1,
-1,
sizeof(ConvolutionParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ConvolutionParameter, _internal_metadata_));
ConvolutionParameter_Engine_descriptor_ = ConvolutionParameter_descriptor_->enum_type(0);
CropParameter_descriptor_ = file->message_type(25);
static const int CropParameter_offsets_[2] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(CropParameter, axis_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(CropParameter, offset_),
};
CropParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
CropParameter_descriptor_,
CropParameter::internal_default_instance(),
CropParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(CropParameter, _has_bits_),
-1,
-1,
sizeof(CropParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(CropParameter, _internal_metadata_));
DataParameter_descriptor_ = file->message_type(26);
static const int DataParameter_offsets_[10] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DataParameter, source_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DataParameter, batch_size_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DataParameter, rand_skip_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DataParameter, backend_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DataParameter, scale_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DataParameter, mean_file_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DataParameter, crop_size_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DataParameter, mirror_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DataParameter, force_encoded_color_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DataParameter, prefetch_),
};
DataParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
DataParameter_descriptor_,
DataParameter::internal_default_instance(),
DataParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DataParameter, _has_bits_),
-1,
-1,
sizeof(DataParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DataParameter, _internal_metadata_));
DataParameter_DB_descriptor_ = DataParameter_descriptor_->enum_type(0);
NonMaximumSuppressionParameter_descriptor_ = file->message_type(27);
static const int NonMaximumSuppressionParameter_offsets_[3] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NonMaximumSuppressionParameter, nms_threshold_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NonMaximumSuppressionParameter, top_k_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NonMaximumSuppressionParameter, eta_),
};
NonMaximumSuppressionParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
NonMaximumSuppressionParameter_descriptor_,
NonMaximumSuppressionParameter::internal_default_instance(),
NonMaximumSuppressionParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NonMaximumSuppressionParameter, _has_bits_),
-1,
-1,
sizeof(NonMaximumSuppressionParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NonMaximumSuppressionParameter, _internal_metadata_));
SaveOutputParameter_descriptor_ = file->message_type(28);
static const int SaveOutputParameter_offsets_[6] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SaveOutputParameter, output_directory_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SaveOutputParameter, output_name_prefix_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SaveOutputParameter, output_format_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SaveOutputParameter, label_map_file_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SaveOutputParameter, name_size_file_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SaveOutputParameter, num_test_image_),
};
SaveOutputParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
SaveOutputParameter_descriptor_,
SaveOutputParameter::internal_default_instance(),
SaveOutputParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SaveOutputParameter, _has_bits_),
-1,
-1,
sizeof(SaveOutputParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SaveOutputParameter, _internal_metadata_));
DropoutParameter_descriptor_ = file->message_type(29);
static const int DropoutParameter_offsets_[2] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DropoutParameter, dropout_ratio_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DropoutParameter, scale_train_),
};
DropoutParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
DropoutParameter_descriptor_,
DropoutParameter::internal_default_instance(),
DropoutParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DropoutParameter, _has_bits_),
-1,
-1,
sizeof(DropoutParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DropoutParameter, _internal_metadata_));
DummyDataParameter_descriptor_ = file->message_type(30);
static const int DummyDataParameter_offsets_[6] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DummyDataParameter, data_filler_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DummyDataParameter, shape_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DummyDataParameter, num_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DummyDataParameter, channels_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DummyDataParameter, height_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DummyDataParameter, width_),
};
DummyDataParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
DummyDataParameter_descriptor_,
DummyDataParameter::internal_default_instance(),
DummyDataParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DummyDataParameter, _has_bits_),
-1,
-1,
sizeof(DummyDataParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(DummyDataParameter, _internal_metadata_));
EltwiseParameter_descriptor_ = file->message_type(31);
static const int EltwiseParameter_offsets_[3] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(EltwiseParameter, operation_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(EltwiseParameter, coeff_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(EltwiseParameter, stable_prod_grad_),
};
EltwiseParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
EltwiseParameter_descriptor_,
EltwiseParameter::internal_default_instance(),
EltwiseParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(EltwiseParameter, _has_bits_),
-1,
-1,
sizeof(EltwiseParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(EltwiseParameter, _internal_metadata_));
EltwiseParameter_EltwiseOp_descriptor_ = EltwiseParameter_descriptor_->enum_type(0);
ELUParameter_descriptor_ = file->message_type(32);
static const int ELUParameter_offsets_[1] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ELUParameter, alpha_),
};
ELUParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
ELUParameter_descriptor_,
ELUParameter::internal_default_instance(),
ELUParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ELUParameter, _has_bits_),
-1,
-1,
sizeof(ELUParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ELUParameter, _internal_metadata_));
EmbedParameter_descriptor_ = file->message_type(33);
static const int EmbedParameter_offsets_[5] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(EmbedParameter, num_output_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(EmbedParameter, input_dim_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(EmbedParameter, bias_term_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(EmbedParameter, weight_filler_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(EmbedParameter, bias_filler_),
};
EmbedParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
EmbedParameter_descriptor_,
EmbedParameter::internal_default_instance(),
EmbedParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(EmbedParameter, _has_bits_),
-1,
-1,
sizeof(EmbedParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(EmbedParameter, _internal_metadata_));
ExpParameter_descriptor_ = file->message_type(34);
static const int ExpParameter_offsets_[3] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ExpParameter, base_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ExpParameter, scale_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ExpParameter, shift_),
};
ExpParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
ExpParameter_descriptor_,
ExpParameter::internal_default_instance(),
ExpParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ExpParameter, _has_bits_),
-1,
-1,
sizeof(ExpParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ExpParameter, _internal_metadata_));
FlattenParameter_descriptor_ = file->message_type(35);
static const int FlattenParameter_offsets_[2] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(FlattenParameter, axis_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(FlattenParameter, end_axis_),
};
FlattenParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
FlattenParameter_descriptor_,
FlattenParameter::internal_default_instance(),
FlattenParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(FlattenParameter, _has_bits_),
-1,
-1,
sizeof(FlattenParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(FlattenParameter, _internal_metadata_));
HDF5DataParameter_descriptor_ = file->message_type(36);
static const int HDF5DataParameter_offsets_[3] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(HDF5DataParameter, source_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(HDF5DataParameter, batch_size_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(HDF5DataParameter, shuffle_),
};
HDF5DataParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
HDF5DataParameter_descriptor_,
HDF5DataParameter::internal_default_instance(),
HDF5DataParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(HDF5DataParameter, _has_bits_),
-1,
-1,
sizeof(HDF5DataParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(HDF5DataParameter, _internal_metadata_));
HDF5OutputParameter_descriptor_ = file->message_type(37);
static const int HDF5OutputParameter_offsets_[1] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(HDF5OutputParameter, file_name_),
};
HDF5OutputParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
HDF5OutputParameter_descriptor_,
HDF5OutputParameter::internal_default_instance(),
HDF5OutputParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(HDF5OutputParameter, _has_bits_),
-1,
-1,
sizeof(HDF5OutputParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(HDF5OutputParameter, _internal_metadata_));
HingeLossParameter_descriptor_ = file->message_type(38);
static const int HingeLossParameter_offsets_[1] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(HingeLossParameter, norm_),
};
HingeLossParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
HingeLossParameter_descriptor_,
HingeLossParameter::internal_default_instance(),
HingeLossParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(HingeLossParameter, _has_bits_),
-1,
-1,
sizeof(HingeLossParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(HingeLossParameter, _internal_metadata_));
HingeLossParameter_Norm_descriptor_ = HingeLossParameter_descriptor_->enum_type(0);
ImageDataParameter_descriptor_ = file->message_type(39);
static const int ImageDataParameter_offsets_[12] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ImageDataParameter, source_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ImageDataParameter, batch_size_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ImageDataParameter, rand_skip_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ImageDataParameter, shuffle_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ImageDataParameter, new_height_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ImageDataParameter, new_width_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ImageDataParameter, is_color_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ImageDataParameter, scale_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ImageDataParameter, mean_file_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ImageDataParameter, crop_size_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ImageDataParameter, mirror_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ImageDataParameter, root_folder_),
};
ImageDataParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
ImageDataParameter_descriptor_,
ImageDataParameter::internal_default_instance(),
ImageDataParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ImageDataParameter, _has_bits_),
-1,
-1,
sizeof(ImageDataParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ImageDataParameter, _internal_metadata_));
InfogainLossParameter_descriptor_ = file->message_type(40);
static const int InfogainLossParameter_offsets_[1] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(InfogainLossParameter, source_),
};
InfogainLossParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
InfogainLossParameter_descriptor_,
InfogainLossParameter::internal_default_instance(),
InfogainLossParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(InfogainLossParameter, _has_bits_),
-1,
-1,
sizeof(InfogainLossParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(InfogainLossParameter, _internal_metadata_));
InnerProductParameter_descriptor_ = file->message_type(41);
static const int InnerProductParameter_offsets_[6] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(InnerProductParameter, num_output_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(InnerProductParameter, bias_term_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(InnerProductParameter, weight_filler_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(InnerProductParameter, bias_filler_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(InnerProductParameter, axis_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(InnerProductParameter, transpose_),
};
InnerProductParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
InnerProductParameter_descriptor_,
InnerProductParameter::internal_default_instance(),
InnerProductParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(InnerProductParameter, _has_bits_),
-1,
-1,
sizeof(InnerProductParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(InnerProductParameter, _internal_metadata_));
InputParameter_descriptor_ = file->message_type(42);
static const int InputParameter_offsets_[1] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(InputParameter, shape_),
};
InputParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
InputParameter_descriptor_,
InputParameter::internal_default_instance(),
InputParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(InputParameter, _has_bits_),
-1,
-1,
sizeof(InputParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(InputParameter, _internal_metadata_));
LogParameter_descriptor_ = file->message_type(43);
static const int LogParameter_offsets_[3] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LogParameter, base_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LogParameter, scale_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LogParameter, shift_),
};
LogParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
LogParameter_descriptor_,
LogParameter::internal_default_instance(),
LogParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LogParameter, _has_bits_),
-1,
-1,
sizeof(LogParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LogParameter, _internal_metadata_));
LRNParameter_descriptor_ = file->message_type(44);
static const int LRNParameter_offsets_[6] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LRNParameter, local_size_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LRNParameter, alpha_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LRNParameter, beta_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LRNParameter, norm_region_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LRNParameter, k_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LRNParameter, engine_),
};
LRNParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
LRNParameter_descriptor_,
LRNParameter::internal_default_instance(),
LRNParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LRNParameter, _has_bits_),
-1,
-1,
sizeof(LRNParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(LRNParameter, _internal_metadata_));
LRNParameter_NormRegion_descriptor_ = LRNParameter_descriptor_->enum_type(0);
LRNParameter_Engine_descriptor_ = LRNParameter_descriptor_->enum_type(1);
MemoryDataParameter_descriptor_ = file->message_type(45);
static const int MemoryDataParameter_offsets_[4] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(MemoryDataParameter, batch_size_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(MemoryDataParameter, channels_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(MemoryDataParameter, height_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(MemoryDataParameter, width_),
};
MemoryDataParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
MemoryDataParameter_descriptor_,
MemoryDataParameter::internal_default_instance(),
MemoryDataParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(MemoryDataParameter, _has_bits_),
-1,
-1,
sizeof(MemoryDataParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(MemoryDataParameter, _internal_metadata_));
MVNParameter_descriptor_ = file->message_type(46);
static const int MVNParameter_offsets_[3] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(MVNParameter, normalize_variance_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(MVNParameter, across_channels_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(MVNParameter, eps_),
};
MVNParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
MVNParameter_descriptor_,
MVNParameter::internal_default_instance(),
MVNParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(MVNParameter, _has_bits_),
-1,
-1,
sizeof(MVNParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(MVNParameter, _internal_metadata_));
ParameterParameter_descriptor_ = file->message_type(47);
static const int ParameterParameter_offsets_[1] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ParameterParameter, shape_),
};
ParameterParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
ParameterParameter_descriptor_,
ParameterParameter::internal_default_instance(),
ParameterParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ParameterParameter, _has_bits_),
-1,
-1,
sizeof(ParameterParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ParameterParameter, _internal_metadata_));
PoolingParameter_descriptor_ = file->message_type(48);
static const int PoolingParameter_offsets_[13] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PoolingParameter, pool_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PoolingParameter, pad_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PoolingParameter, pad_h_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PoolingParameter, pad_w_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PoolingParameter, kernel_size_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PoolingParameter, kernel_h_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PoolingParameter, kernel_w_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PoolingParameter, stride_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PoolingParameter, stride_h_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PoolingParameter, stride_w_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PoolingParameter, engine_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PoolingParameter, global_pooling_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PoolingParameter, ceil_mode_),
};
PoolingParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
PoolingParameter_descriptor_,
PoolingParameter::internal_default_instance(),
PoolingParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PoolingParameter, _has_bits_),
-1,
-1,
sizeof(PoolingParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PoolingParameter, _internal_metadata_));
PoolingParameter_PoolMethod_descriptor_ = PoolingParameter_descriptor_->enum_type(0);
PoolingParameter_Engine_descriptor_ = PoolingParameter_descriptor_->enum_type(1);
PowerParameter_descriptor_ = file->message_type(49);
static const int PowerParameter_offsets_[3] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PowerParameter, power_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PowerParameter, scale_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PowerParameter, shift_),
};
PowerParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
PowerParameter_descriptor_,
PowerParameter::internal_default_instance(),
PowerParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PowerParameter, _has_bits_),
-1,
-1,
sizeof(PowerParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PowerParameter, _internal_metadata_));
PythonParameter_descriptor_ = file->message_type(50);
static const int PythonParameter_offsets_[4] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PythonParameter, module_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PythonParameter, layer_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PythonParameter, param_str_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PythonParameter, share_in_parallel_),
};
PythonParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
PythonParameter_descriptor_,
PythonParameter::internal_default_instance(),
PythonParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PythonParameter, _has_bits_),
-1,
-1,
sizeof(PythonParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PythonParameter, _internal_metadata_));
RecurrentParameter_descriptor_ = file->message_type(51);
static const int RecurrentParameter_offsets_[5] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(RecurrentParameter, num_output_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(RecurrentParameter, weight_filler_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(RecurrentParameter, bias_filler_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(RecurrentParameter, debug_info_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(RecurrentParameter, expose_hidden_),
};
RecurrentParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
RecurrentParameter_descriptor_,
RecurrentParameter::internal_default_instance(),
RecurrentParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(RecurrentParameter, _has_bits_),
-1,
-1,
sizeof(RecurrentParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(RecurrentParameter, _internal_metadata_));
ReductionParameter_descriptor_ = file->message_type(52);
static const int ReductionParameter_offsets_[3] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ReductionParameter, operation_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ReductionParameter, axis_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ReductionParameter, coeff_),
};
ReductionParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
ReductionParameter_descriptor_,
ReductionParameter::internal_default_instance(),
ReductionParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ReductionParameter, _has_bits_),
-1,
-1,
sizeof(ReductionParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ReductionParameter, _internal_metadata_));
ReductionParameter_ReductionOp_descriptor_ = ReductionParameter_descriptor_->enum_type(0);
ReLUParameter_descriptor_ = file->message_type(53);
static const int ReLUParameter_offsets_[2] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ReLUParameter, negative_slope_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ReLUParameter, engine_),
};
ReLUParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
ReLUParameter_descriptor_,
ReLUParameter::internal_default_instance(),
ReLUParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ReLUParameter, _has_bits_),
-1,
-1,
sizeof(ReLUParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ReLUParameter, _internal_metadata_));
ReLUParameter_Engine_descriptor_ = ReLUParameter_descriptor_->enum_type(0);
ReshapeParameter_descriptor_ = file->message_type(54);
static const int ReshapeParameter_offsets_[3] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ReshapeParameter, shape_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ReshapeParameter, axis_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ReshapeParameter, num_axes_),
};
ReshapeParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
ReshapeParameter_descriptor_,
ReshapeParameter::internal_default_instance(),
ReshapeParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ReshapeParameter, _has_bits_),
-1,
-1,
sizeof(ReshapeParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ReshapeParameter, _internal_metadata_));
ScaleParameter_descriptor_ = file->message_type(55);
static const int ScaleParameter_offsets_[5] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ScaleParameter, axis_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ScaleParameter, num_axes_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ScaleParameter, filler_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ScaleParameter, bias_term_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ScaleParameter, bias_filler_),
};
ScaleParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
ScaleParameter_descriptor_,
ScaleParameter::internal_default_instance(),
ScaleParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ScaleParameter, _has_bits_),
-1,
-1,
sizeof(ScaleParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ScaleParameter, _internal_metadata_));
SigmoidParameter_descriptor_ = file->message_type(56);
static const int SigmoidParameter_offsets_[1] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SigmoidParameter, engine_),
};
SigmoidParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
SigmoidParameter_descriptor_,
SigmoidParameter::internal_default_instance(),
SigmoidParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SigmoidParameter, _has_bits_),
-1,
-1,
sizeof(SigmoidParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SigmoidParameter, _internal_metadata_));
SigmoidParameter_Engine_descriptor_ = SigmoidParameter_descriptor_->enum_type(0);
SliceParameter_descriptor_ = file->message_type(57);
static const int SliceParameter_offsets_[3] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SliceParameter, axis_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SliceParameter, slice_point_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SliceParameter, slice_dim_),
};
SliceParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
SliceParameter_descriptor_,
SliceParameter::internal_default_instance(),
SliceParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SliceParameter, _has_bits_),
-1,
-1,
sizeof(SliceParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SliceParameter, _internal_metadata_));
SoftmaxParameter_descriptor_ = file->message_type(58);
static const int SoftmaxParameter_offsets_[2] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SoftmaxParameter, engine_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SoftmaxParameter, axis_),
};
SoftmaxParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
SoftmaxParameter_descriptor_,
SoftmaxParameter::internal_default_instance(),
SoftmaxParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SoftmaxParameter, _has_bits_),
-1,
-1,
sizeof(SoftmaxParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SoftmaxParameter, _internal_metadata_));
SoftmaxParameter_Engine_descriptor_ = SoftmaxParameter_descriptor_->enum_type(0);
TanHParameter_descriptor_ = file->message_type(59);
static const int TanHParameter_offsets_[1] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(TanHParameter, engine_),
};
TanHParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
TanHParameter_descriptor_,
TanHParameter::internal_default_instance(),
TanHParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(TanHParameter, _has_bits_),
-1,
-1,
sizeof(TanHParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(TanHParameter, _internal_metadata_));
TanHParameter_Engine_descriptor_ = TanHParameter_descriptor_->enum_type(0);
TileParameter_descriptor_ = file->message_type(60);
static const int TileParameter_offsets_[2] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(TileParameter, axis_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(TileParameter, tiles_),
};
TileParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
TileParameter_descriptor_,
TileParameter::internal_default_instance(),
TileParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(TileParameter, _has_bits_),
-1,
-1,
sizeof(TileParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(TileParameter, _internal_metadata_));
ThresholdParameter_descriptor_ = file->message_type(61);
static const int ThresholdParameter_offsets_[1] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ThresholdParameter, threshold_),
};
ThresholdParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
ThresholdParameter_descriptor_,
ThresholdParameter::internal_default_instance(),
ThresholdParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ThresholdParameter, _has_bits_),
-1,
-1,
sizeof(ThresholdParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ThresholdParameter, _internal_metadata_));
WindowDataParameter_descriptor_ = file->message_type(62);
static const int WindowDataParameter_offsets_[13] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(WindowDataParameter, source_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(WindowDataParameter, scale_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(WindowDataParameter, mean_file_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(WindowDataParameter, batch_size_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(WindowDataParameter, crop_size_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(WindowDataParameter, mirror_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(WindowDataParameter, fg_threshold_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(WindowDataParameter, bg_threshold_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(WindowDataParameter, fg_fraction_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(WindowDataParameter, context_pad_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(WindowDataParameter, crop_mode_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(WindowDataParameter, cache_images_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(WindowDataParameter, root_folder_),
};
WindowDataParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
WindowDataParameter_descriptor_,
WindowDataParameter::internal_default_instance(),
WindowDataParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(WindowDataParameter, _has_bits_),
-1,
-1,
sizeof(WindowDataParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(WindowDataParameter, _internal_metadata_));
SPPParameter_descriptor_ = file->message_type(63);
static const int SPPParameter_offsets_[3] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SPPParameter, pyramid_height_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SPPParameter, pool_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SPPParameter, engine_),
};
SPPParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
SPPParameter_descriptor_,
SPPParameter::internal_default_instance(),
SPPParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SPPParameter, _has_bits_),
-1,
-1,
sizeof(SPPParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(SPPParameter, _internal_metadata_));
SPPParameter_PoolMethod_descriptor_ = SPPParameter_descriptor_->enum_type(0);
SPPParameter_Engine_descriptor_ = SPPParameter_descriptor_->enum_type(1);
V1LayerParameter_descriptor_ = file->message_type(64);
static const int V1LayerParameter_offsets_[43] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, bottom_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, top_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, name_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, include_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, exclude_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, type_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, blobs_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, blob_share_mode_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, blobs_lr_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, weight_decay_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, loss_weight_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, accuracy_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, argmax_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, concat_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, contrastive_loss_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, convolution_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, data_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, dropout_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, dummy_data_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, eltwise_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, exp_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, hdf5_data_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, hdf5_output_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, hinge_loss_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, image_data_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, infogain_loss_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, inner_product_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, lrn_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, memory_data_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, mvn_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, pooling_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, power_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, relu_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, sigmoid_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, softmax_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, slice_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, tanh_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, threshold_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, window_data_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, transform_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, loss_param_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, layer_),
};
V1LayerParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
V1LayerParameter_descriptor_,
V1LayerParameter::internal_default_instance(),
V1LayerParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, _has_bits_),
-1,
-1,
sizeof(V1LayerParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V1LayerParameter, _internal_metadata_));
V1LayerParameter_LayerType_descriptor_ = V1LayerParameter_descriptor_->enum_type(0);
V1LayerParameter_DimCheckMode_descriptor_ = V1LayerParameter_descriptor_->enum_type(1);
V0LayerParameter_descriptor_ = file->message_type(65);
static const int V0LayerParameter_offsets_[38] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, name_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, type_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, num_output_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, biasterm_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, weight_filler_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, bias_filler_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, pad_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, kernelsize_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, group_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, stride_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, pool_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, dropout_ratio_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, local_size_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, alpha_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, beta_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, k_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, source_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, scale_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, meanfile_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, batchsize_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, cropsize_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, mirror_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, blobs_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, blobs_lr_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, weight_decay_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, rand_skip_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, det_fg_threshold_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, det_bg_threshold_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, det_fg_fraction_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, det_context_pad_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, det_crop_mode_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, new_num_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, new_channels_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, new_height_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, new_width_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, shuffle_images_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, concat_dim_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, hdf5_output_param_),
};
V0LayerParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
V0LayerParameter_descriptor_,
V0LayerParameter::internal_default_instance(),
V0LayerParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, _has_bits_),
-1,
-1,
sizeof(V0LayerParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(V0LayerParameter, _internal_metadata_));
V0LayerParameter_PoolMethod_descriptor_ = V0LayerParameter_descriptor_->enum_type(0);
PReLUParameter_descriptor_ = file->message_type(66);
static const int PReLUParameter_offsets_[2] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PReLUParameter, filler_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PReLUParameter, channel_shared_),
};
PReLUParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
PReLUParameter_descriptor_,
PReLUParameter::internal_default_instance(),
PReLUParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PReLUParameter, _has_bits_),
-1,
-1,
sizeof(PReLUParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PReLUParameter, _internal_metadata_));
NormalizedBBox_descriptor_ = file->message_type(67);
static const int NormalizedBBox_offsets_[8] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalizedBBox, xmin_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalizedBBox, ymin_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalizedBBox, xmax_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalizedBBox, ymax_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalizedBBox, label_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalizedBBox, difficult_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalizedBBox, score_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalizedBBox, size_),
};
NormalizedBBox_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
NormalizedBBox_descriptor_,
NormalizedBBox::internal_default_instance(),
NormalizedBBox_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalizedBBox, _has_bits_),
-1,
-1,
sizeof(NormalizedBBox),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(NormalizedBBox, _internal_metadata_));
ROIPoolingParameter_descriptor_ = file->message_type(68);
static const int ROIPoolingParameter_offsets_[3] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ROIPoolingParameter, pooled_h_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ROIPoolingParameter, pooled_w_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ROIPoolingParameter, spatial_scale_),
};
ROIPoolingParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
ROIPoolingParameter_descriptor_,
ROIPoolingParameter::internal_default_instance(),
ROIPoolingParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ROIPoolingParameter, _has_bits_),
-1,
-1,
sizeof(ROIPoolingParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ROIPoolingParameter, _internal_metadata_));
ProposalParameter_descriptor_ = file->message_type(69);
static const int ProposalParameter_offsets_[8] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ProposalParameter, feat_stride_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ProposalParameter, base_size_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ProposalParameter, min_size_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ProposalParameter, ratio_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ProposalParameter, scale_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ProposalParameter, pre_nms_topn_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ProposalParameter, post_nms_topn_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ProposalParameter, nms_thresh_),
};
ProposalParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
ProposalParameter_descriptor_,
ProposalParameter::internal_default_instance(),
ProposalParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ProposalParameter, _has_bits_),
-1,
-1,
sizeof(ProposalParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ProposalParameter, _internal_metadata_));
PSROIPoolingParameter_descriptor_ = file->message_type(70);
static const int PSROIPoolingParameter_offsets_[3] = {
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PSROIPoolingParameter, spatial_scale_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PSROIPoolingParameter, output_dim_),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PSROIPoolingParameter, group_size_),
};
PSROIPoolingParameter_reflection_ =
::google::protobuf::internal::GeneratedMessageReflection::NewGeneratedMessageReflection(
PSROIPoolingParameter_descriptor_,
PSROIPoolingParameter::internal_default_instance(),
PSROIPoolingParameter_offsets_,
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PSROIPoolingParameter, _has_bits_),
-1,
-1,
sizeof(PSROIPoolingParameter),
GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(PSROIPoolingParameter, _internal_metadata_));
Type_descriptor_ = file->enum_type(0);
Phase_descriptor_ = file->enum_type(1);
}
namespace {
GOOGLE_PROTOBUF_DECLARE_ONCE(protobuf_AssignDescriptors_once_);
void protobuf_AssignDescriptorsOnce() {
::google::protobuf::GoogleOnceInit(&protobuf_AssignDescriptors_once_,
&protobuf_AssignDesc_opencv_2dcaffe_2eproto);
}
void protobuf_RegisterTypes(const ::std::string&) GOOGLE_ATTRIBUTE_COLD;
void protobuf_RegisterTypes(const ::std::string&) {
protobuf_AssignDescriptorsOnce();
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
BlobShape_descriptor_, BlobShape::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
BlobProto_descriptor_, BlobProto::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
BlobProtoVector_descriptor_, BlobProtoVector::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
PermuteParameter_descriptor_, PermuteParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
NormalizeBBoxParameter_descriptor_, NormalizeBBoxParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
PriorBoxParameter_descriptor_, PriorBoxParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
DetectionOutputParameter_descriptor_, DetectionOutputParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
Datum_descriptor_, Datum::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
FillerParameter_descriptor_, FillerParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
NetParameter_descriptor_, NetParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
SolverParameter_descriptor_, SolverParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
SolverState_descriptor_, SolverState::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
NetState_descriptor_, NetState::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
NetStateRule_descriptor_, NetStateRule::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
ParamSpec_descriptor_, ParamSpec::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
LayerParameter_descriptor_, LayerParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
TransformationParameter_descriptor_, TransformationParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
LossParameter_descriptor_, LossParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
AccuracyParameter_descriptor_, AccuracyParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
ArgMaxParameter_descriptor_, ArgMaxParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
ConcatParameter_descriptor_, ConcatParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
BatchNormParameter_descriptor_, BatchNormParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
BiasParameter_descriptor_, BiasParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
ContrastiveLossParameter_descriptor_, ContrastiveLossParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
ConvolutionParameter_descriptor_, ConvolutionParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
CropParameter_descriptor_, CropParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
DataParameter_descriptor_, DataParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
NonMaximumSuppressionParameter_descriptor_, NonMaximumSuppressionParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
SaveOutputParameter_descriptor_, SaveOutputParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
DropoutParameter_descriptor_, DropoutParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
DummyDataParameter_descriptor_, DummyDataParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
EltwiseParameter_descriptor_, EltwiseParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
ELUParameter_descriptor_, ELUParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
EmbedParameter_descriptor_, EmbedParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
ExpParameter_descriptor_, ExpParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
FlattenParameter_descriptor_, FlattenParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
HDF5DataParameter_descriptor_, HDF5DataParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
HDF5OutputParameter_descriptor_, HDF5OutputParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
HingeLossParameter_descriptor_, HingeLossParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
ImageDataParameter_descriptor_, ImageDataParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
InfogainLossParameter_descriptor_, InfogainLossParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
InnerProductParameter_descriptor_, InnerProductParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
InputParameter_descriptor_, InputParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
LogParameter_descriptor_, LogParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
LRNParameter_descriptor_, LRNParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
MemoryDataParameter_descriptor_, MemoryDataParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
MVNParameter_descriptor_, MVNParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
ParameterParameter_descriptor_, ParameterParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
PoolingParameter_descriptor_, PoolingParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
PowerParameter_descriptor_, PowerParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
PythonParameter_descriptor_, PythonParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
RecurrentParameter_descriptor_, RecurrentParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
ReductionParameter_descriptor_, ReductionParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
ReLUParameter_descriptor_, ReLUParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
ReshapeParameter_descriptor_, ReshapeParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
ScaleParameter_descriptor_, ScaleParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
SigmoidParameter_descriptor_, SigmoidParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
SliceParameter_descriptor_, SliceParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
SoftmaxParameter_descriptor_, SoftmaxParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
TanHParameter_descriptor_, TanHParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
TileParameter_descriptor_, TileParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
ThresholdParameter_descriptor_, ThresholdParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
WindowDataParameter_descriptor_, WindowDataParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
SPPParameter_descriptor_, SPPParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
V1LayerParameter_descriptor_, V1LayerParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
V0LayerParameter_descriptor_, V0LayerParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
PReLUParameter_descriptor_, PReLUParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
NormalizedBBox_descriptor_, NormalizedBBox::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
ROIPoolingParameter_descriptor_, ROIPoolingParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
ProposalParameter_descriptor_, ProposalParameter::internal_default_instance());
::google::protobuf::MessageFactory::InternalRegisterGeneratedMessage(
PSROIPoolingParameter_descriptor_, PSROIPoolingParameter::internal_default_instance());
}
} // namespace
void protobuf_ShutdownFile_opencv_2dcaffe_2eproto() {
BlobShape_default_instance_.Shutdown();
delete BlobShape_reflection_;
BlobProto_default_instance_.Shutdown();
delete BlobProto_reflection_;
BlobProtoVector_default_instance_.Shutdown();
delete BlobProtoVector_reflection_;
PermuteParameter_default_instance_.Shutdown();
delete PermuteParameter_reflection_;
NormalizeBBoxParameter_default_instance_.Shutdown();
delete NormalizeBBoxParameter_reflection_;
PriorBoxParameter_default_instance_.Shutdown();
delete PriorBoxParameter_reflection_;
DetectionOutputParameter_default_instance_.Shutdown();
delete DetectionOutputParameter_reflection_;
Datum_default_instance_.Shutdown();
delete Datum_reflection_;
FillerParameter_default_instance_.Shutdown();
delete FillerParameter_reflection_;
delete FillerParameter::_default_type_;
NetParameter_default_instance_.Shutdown();
delete NetParameter_reflection_;
SolverParameter_default_instance_.Shutdown();
delete SolverParameter_reflection_;
delete SolverParameter::_default_regularization_type_;
delete SolverParameter::_default_type_;
SolverState_default_instance_.Shutdown();
delete SolverState_reflection_;
NetState_default_instance_.Shutdown();
delete NetState_reflection_;
NetStateRule_default_instance_.Shutdown();
delete NetStateRule_reflection_;
ParamSpec_default_instance_.Shutdown();
delete ParamSpec_reflection_;
LayerParameter_default_instance_.Shutdown();
delete LayerParameter_reflection_;
TransformationParameter_default_instance_.Shutdown();
delete TransformationParameter_reflection_;
LossParameter_default_instance_.Shutdown();
delete LossParameter_reflection_;
AccuracyParameter_default_instance_.Shutdown();
delete AccuracyParameter_reflection_;
ArgMaxParameter_default_instance_.Shutdown();
delete ArgMaxParameter_reflection_;
ConcatParameter_default_instance_.Shutdown();
delete ConcatParameter_reflection_;
BatchNormParameter_default_instance_.Shutdown();
delete BatchNormParameter_reflection_;
BiasParameter_default_instance_.Shutdown();
delete BiasParameter_reflection_;
ContrastiveLossParameter_default_instance_.Shutdown();
delete ContrastiveLossParameter_reflection_;
ConvolutionParameter_default_instance_.Shutdown();
delete ConvolutionParameter_reflection_;
CropParameter_default_instance_.Shutdown();
delete CropParameter_reflection_;
DataParameter_default_instance_.Shutdown();
delete DataParameter_reflection_;
NonMaximumSuppressionParameter_default_instance_.Shutdown();
delete NonMaximumSuppressionParameter_reflection_;
SaveOutputParameter_default_instance_.Shutdown();
delete SaveOutputParameter_reflection_;
DropoutParameter_default_instance_.Shutdown();
delete DropoutParameter_reflection_;
DummyDataParameter_default_instance_.Shutdown();
delete DummyDataParameter_reflection_;
EltwiseParameter_default_instance_.Shutdown();
delete EltwiseParameter_reflection_;
ELUParameter_default_instance_.Shutdown();
delete ELUParameter_reflection_;
EmbedParameter_default_instance_.Shutdown();
delete EmbedParameter_reflection_;
ExpParameter_default_instance_.Shutdown();
delete ExpParameter_reflection_;
FlattenParameter_default_instance_.Shutdown();
delete FlattenParameter_reflection_;
HDF5DataParameter_default_instance_.Shutdown();
delete HDF5DataParameter_reflection_;
HDF5OutputParameter_default_instance_.Shutdown();
delete HDF5OutputParameter_reflection_;
HingeLossParameter_default_instance_.Shutdown();
delete HingeLossParameter_reflection_;
ImageDataParameter_default_instance_.Shutdown();
delete ImageDataParameter_reflection_;
InfogainLossParameter_default_instance_.Shutdown();
delete InfogainLossParameter_reflection_;
InnerProductParameter_default_instance_.Shutdown();
delete InnerProductParameter_reflection_;
InputParameter_default_instance_.Shutdown();
delete InputParameter_reflection_;
LogParameter_default_instance_.Shutdown();
delete LogParameter_reflection_;
LRNParameter_default_instance_.Shutdown();
delete LRNParameter_reflection_;
MemoryDataParameter_default_instance_.Shutdown();
delete MemoryDataParameter_reflection_;
MVNParameter_default_instance_.Shutdown();
delete MVNParameter_reflection_;
ParameterParameter_default_instance_.Shutdown();
delete ParameterParameter_reflection_;
PoolingParameter_default_instance_.Shutdown();
delete PoolingParameter_reflection_;
PowerParameter_default_instance_.Shutdown();
delete PowerParameter_reflection_;
PythonParameter_default_instance_.Shutdown();
delete PythonParameter_reflection_;
RecurrentParameter_default_instance_.Shutdown();
delete RecurrentParameter_reflection_;
ReductionParameter_default_instance_.Shutdown();
delete ReductionParameter_reflection_;
ReLUParameter_default_instance_.Shutdown();
delete ReLUParameter_reflection_;
ReshapeParameter_default_instance_.Shutdown();
delete ReshapeParameter_reflection_;
ScaleParameter_default_instance_.Shutdown();
delete ScaleParameter_reflection_;
SigmoidParameter_default_instance_.Shutdown();
delete SigmoidParameter_reflection_;
SliceParameter_default_instance_.Shutdown();
delete SliceParameter_reflection_;
SoftmaxParameter_default_instance_.Shutdown();
delete SoftmaxParameter_reflection_;
TanHParameter_default_instance_.Shutdown();
delete TanHParameter_reflection_;
TileParameter_default_instance_.Shutdown();
delete TileParameter_reflection_;
ThresholdParameter_default_instance_.Shutdown();
delete ThresholdParameter_reflection_;
WindowDataParameter_default_instance_.Shutdown();
delete WindowDataParameter_reflection_;
delete WindowDataParameter::_default_crop_mode_;
SPPParameter_default_instance_.Shutdown();
delete SPPParameter_reflection_;
V1LayerParameter_default_instance_.Shutdown();
delete V1LayerParameter_reflection_;
V0LayerParameter_default_instance_.Shutdown();
delete V0LayerParameter_reflection_;
delete V0LayerParameter::_default_det_crop_mode_;
PReLUParameter_default_instance_.Shutdown();
delete PReLUParameter_reflection_;
NormalizedBBox_default_instance_.Shutdown();
delete NormalizedBBox_reflection_;
ROIPoolingParameter_default_instance_.Shutdown();
delete ROIPoolingParameter_reflection_;
ProposalParameter_default_instance_.Shutdown();
delete ProposalParameter_reflection_;
PSROIPoolingParameter_default_instance_.Shutdown();
delete PSROIPoolingParameter_reflection_;
}
void protobuf_InitDefaults_opencv_2dcaffe_2eproto_impl() {
GOOGLE_PROTOBUF_VERIFY_VERSION;
BlobShape_default_instance_.DefaultConstruct();
::google::protobuf::internal::GetEmptyString();
BlobProto_default_instance_.DefaultConstruct();
BlobProtoVector_default_instance_.DefaultConstruct();
PermuteParameter_default_instance_.DefaultConstruct();
NormalizeBBoxParameter_default_instance_.DefaultConstruct();
PriorBoxParameter_default_instance_.DefaultConstruct();
DetectionOutputParameter_default_instance_.DefaultConstruct();
::google::protobuf::internal::GetEmptyString();
Datum_default_instance_.DefaultConstruct();
::google::protobuf::internal::GetEmptyString();
FillerParameter::_default_type_ =
new ::std::string("constant", 8);
FillerParameter_default_instance_.DefaultConstruct();
::google::protobuf::internal::GetEmptyString();
NetParameter_default_instance_.DefaultConstruct();
::google::protobuf::internal::GetEmptyString();
SolverParameter::_default_regularization_type_ =
new ::std::string("L2", 2);
SolverParameter::_default_type_ =
new ::std::string("SGD", 3);
SolverParameter_default_instance_.DefaultConstruct();
::google::protobuf::internal::GetEmptyString();
SolverState_default_instance_.DefaultConstruct();
::google::protobuf::internal::GetEmptyString();
NetState_default_instance_.DefaultConstruct();
::google::protobuf::internal::GetEmptyString();
NetStateRule_default_instance_.DefaultConstruct();
::google::protobuf::internal::GetEmptyString();
ParamSpec_default_instance_.DefaultConstruct();
::google::protobuf::internal::GetEmptyString();
LayerParameter_default_instance_.DefaultConstruct();
::google::protobuf::internal::GetEmptyString();
TransformationParameter_default_instance_.DefaultConstruct();
LossParameter_default_instance_.DefaultConstruct();
AccuracyParameter_default_instance_.DefaultConstruct();
ArgMaxParameter_default_instance_.DefaultConstruct();
ConcatParameter_default_instance_.DefaultConstruct();
BatchNormParameter_default_instance_.DefaultConstruct();
BiasParameter_default_instance_.DefaultConstruct();
ContrastiveLossParameter_default_instance_.DefaultConstruct();
ConvolutionParameter_default_instance_.DefaultConstruct();
CropParameter_default_instance_.DefaultConstruct();
::google::protobuf::internal::GetEmptyString();
DataParameter_default_instance_.DefaultConstruct();
NonMaximumSuppressionParameter_default_instance_.DefaultConstruct();
::google::protobuf::internal::GetEmptyString();
SaveOutputParameter_default_instance_.DefaultConstruct();
DropoutParameter_default_instance_.DefaultConstruct();
DummyDataParameter_default_instance_.DefaultConstruct();
EltwiseParameter_default_instance_.DefaultConstruct();
ELUParameter_default_instance_.DefaultConstruct();
EmbedParameter_default_instance_.DefaultConstruct();
ExpParameter_default_instance_.DefaultConstruct();
FlattenParameter_default_instance_.DefaultConstruct();
::google::protobuf::internal::GetEmptyString();
HDF5DataParameter_default_instance_.DefaultConstruct();
::google::protobuf::internal::GetEmptyString();
HDF5OutputParameter_default_instance_.DefaultConstruct();
HingeLossParameter_default_instance_.DefaultConstruct();
::google::protobuf::internal::GetEmptyString();
ImageDataParameter_default_instance_.DefaultConstruct();
::google::protobuf::internal::GetEmptyString();
InfogainLossParameter_default_instance_.DefaultConstruct();
InnerProductParameter_default_instance_.DefaultConstruct();
InputParameter_default_instance_.DefaultConstruct();
LogParameter_default_instance_.DefaultConstruct();
LRNParameter_default_instance_.DefaultConstruct();
MemoryDataParameter_default_instance_.DefaultConstruct();
MVNParameter_default_instance_.DefaultConstruct();
ParameterParameter_default_instance_.DefaultConstruct();
PoolingParameter_default_instance_.DefaultConstruct();
PowerParameter_default_instance_.DefaultConstruct();
::google::protobuf::internal::GetEmptyString();
PythonParameter_default_instance_.DefaultConstruct();
RecurrentParameter_default_instance_.DefaultConstruct();
ReductionParameter_default_instance_.DefaultConstruct();
ReLUParameter_default_instance_.DefaultConstruct();
ReshapeParameter_default_instance_.DefaultConstruct();
ScaleParameter_default_instance_.DefaultConstruct();
SigmoidParameter_default_instance_.DefaultConstruct();
SliceParameter_default_instance_.DefaultConstruct();
SoftmaxParameter_default_instance_.DefaultConstruct();
TanHParameter_default_instance_.DefaultConstruct();
TileParameter_default_instance_.DefaultConstruct();
ThresholdParameter_default_instance_.DefaultConstruct();
::google::protobuf::internal::GetEmptyString();
WindowDataParameter::_default_crop_mode_ =
new ::std::string("warp", 4);
WindowDataParameter_default_instance_.DefaultConstruct();
SPPParameter_default_instance_.DefaultConstruct();
::google::protobuf::internal::GetEmptyString();
V1LayerParameter_default_instance_.DefaultConstruct();
::google::protobuf::internal::GetEmptyString();
V0LayerParameter::_default_det_crop_mode_ =
new ::std::string("warp", 4);
V0LayerParameter_default_instance_.DefaultConstruct();
PReLUParameter_default_instance_.DefaultConstruct();
NormalizedBBox_default_instance_.DefaultConstruct();
ROIPoolingParameter_default_instance_.DefaultConstruct();
ProposalParameter_default_instance_.DefaultConstruct();
PSROIPoolingParameter_default_instance_.DefaultConstruct();
BlobShape_default_instance_.get_mutable()->InitAsDefaultInstance();
BlobProto_default_instance_.get_mutable()->InitAsDefaultInstance();
BlobProtoVector_default_instance_.get_mutable()->InitAsDefaultInstance();
PermuteParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
NormalizeBBoxParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
PriorBoxParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
DetectionOutputParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
Datum_default_instance_.get_mutable()->InitAsDefaultInstance();
FillerParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
NetParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
SolverParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
SolverState_default_instance_.get_mutable()->InitAsDefaultInstance();
NetState_default_instance_.get_mutable()->InitAsDefaultInstance();
NetStateRule_default_instance_.get_mutable()->InitAsDefaultInstance();
ParamSpec_default_instance_.get_mutable()->InitAsDefaultInstance();
LayerParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
TransformationParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
LossParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
AccuracyParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
ArgMaxParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
ConcatParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
BatchNormParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
BiasParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
ContrastiveLossParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
ConvolutionParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
CropParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
DataParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
NonMaximumSuppressionParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
SaveOutputParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
DropoutParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
DummyDataParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
EltwiseParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
ELUParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
EmbedParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
ExpParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
FlattenParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
HDF5DataParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
HDF5OutputParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
HingeLossParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
ImageDataParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
InfogainLossParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
InnerProductParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
InputParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
LogParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
LRNParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
MemoryDataParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
MVNParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
ParameterParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
PoolingParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
PowerParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
PythonParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
RecurrentParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
ReductionParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
ReLUParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
ReshapeParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
ScaleParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
SigmoidParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
SliceParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
SoftmaxParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
TanHParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
TileParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
ThresholdParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
WindowDataParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
SPPParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
V1LayerParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
V0LayerParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
PReLUParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
NormalizedBBox_default_instance_.get_mutable()->InitAsDefaultInstance();
ROIPoolingParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
ProposalParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
PSROIPoolingParameter_default_instance_.get_mutable()->InitAsDefaultInstance();
}
GOOGLE_PROTOBUF_DECLARE_ONCE(protobuf_InitDefaults_opencv_2dcaffe_2eproto_once_);
void protobuf_InitDefaults_opencv_2dcaffe_2eproto() {
::google::protobuf::GoogleOnceInit(&protobuf_InitDefaults_opencv_2dcaffe_2eproto_once_,
&protobuf_InitDefaults_opencv_2dcaffe_2eproto_impl);
}
void protobuf_AddDesc_opencv_2dcaffe_2eproto_impl() {
GOOGLE_PROTOBUF_VERIFY_VERSION;
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
::google::protobuf::DescriptorPool::InternalAddGeneratedFile(
"\n\022opencv-caffe.proto\022\014opencv_caffe\"\034\n\tBl"
"obShape\022\017\n\003dim\030\001 \003(\003B\002\020\001\"\224\002\n\tBlobProto\022&"
"\n\005shape\030\007 \001(\0132\027.opencv_caffe.BlobShape\022\020"
"\n\004data\030\005 \003(\002B\002\020\001\022\020\n\004diff\030\006 \003(\002B\002\020\001\022\027\n\013do"
"uble_data\030\010 \003(\001B\002\020\001\022\027\n\013double_diff\030\t \003(\001"
"B\002\020\001\022)\n\rraw_data_type\030\n \001(\0162\022.opencv_caf"
"fe.Type\022\024\n\010raw_data\030\014 \001(\014B\002\020\000\022\016\n\003num\030\001 \001"
"(\005:\0010\022\023\n\010channels\030\002 \001(\005:\0010\022\021\n\006height\030\003 \001"
"(\005:\0010\022\020\n\005width\030\004 \001(\005:\0010\"9\n\017BlobProtoVect"
"or\022&\n\005blobs\030\001 \003(\0132\027.opencv_caffe.BlobPro"
"to\"!\n\020PermuteParameter\022\r\n\005order\030\001 \003(\r\"\235\001"
"\n\026NormalizeBBoxParameter\022\034\n\016across_spati"
"al\030\001 \001(\010:\004true\0223\n\014scale_filler\030\002 \001(\0132\035.o"
"pencv_caffe.FillerParameter\022\034\n\016channel_s"
"hared\030\003 \001(\010:\004true\022\022\n\003eps\030\004 \001(\002:\0051e-10\"\346\002"
"\n\021PriorBoxParameter\022\020\n\010min_size\030\001 \001(\002\022\020\n"
"\010max_size\030\002 \001(\002\022\024\n\014aspect_ratio\030\003 \003(\002\022\022\n"
"\004flip\030\004 \001(\010:\004true\022\022\n\004clip\030\005 \001(\010:\004true\022\020\n"
"\010variance\030\006 \003(\002\022\020\n\010img_size\030\007 \001(\r\022\r\n\005img"
"_h\030\010 \001(\r\022\r\n\005img_w\030\t \001(\r\022\014\n\004step\030\n \001(\002\022\016\n"
"\006step_h\030\013 \001(\002\022\016\n\006step_w\030\014 \001(\002\022\023\n\006offset\030"
"\r \001(\002:\0030.5\022\020\n\010offset_h\030\016 \003(\002\022\020\n\010offset_w"
"\030\017 \003(\002\022\r\n\005width\030\020 \003(\002\022\016\n\006height\030\021 \003(\002\"\'\n"
"\010CodeType\022\n\n\006CORNER\020\001\022\017\n\013CENTER_SIZE\020\002\"\261"
"\003\n\030DetectionOutputParameter\022\023\n\013num_class"
"es\030\001 \001(\r\022\034\n\016share_location\030\002 \001(\010:\004true\022\036"
"\n\023background_label_id\030\003 \001(\005:\0010\022\?\n\tnms_pa"
"ram\030\004 \001(\0132,.opencv_caffe.NonMaximumSuppr"
"essionParameter\022<\n\021save_output_param\030\005 \001"
"(\0132!.opencv_caffe.SaveOutputParameter\022C\n"
"\tcode_type\030\006 \001(\0162(.opencv_caffe.PriorBox"
"Parameter.CodeType:\006CORNER\022)\n\032variance_e"
"ncoded_in_target\030\010 \001(\010:\005false\022\026\n\nkeep_to"
"p_k\030\007 \001(\005:\002-1\022\034\n\024confidence_threshold\030\t "
"\001(\002\022\035\n\017normalized_bbox\030\n \001(\010:\004true\"\201\001\n\005D"
"atum\022\020\n\010channels\030\001 \001(\005\022\016\n\006height\030\002 \001(\005\022\r"
"\n\005width\030\003 \001(\005\022\014\n\004data\030\004 \001(\014\022\r\n\005label\030\005 \001"
"(\005\022\022\n\nfloat_data\030\006 \003(\002\022\026\n\007encoded\030\007 \001(\010:"
"\005false\"\221\002\n\017FillerParameter\022\026\n\004type\030\001 \001(\t"
":\010constant\022\020\n\005value\030\002 \001(\002:\0010\022\016\n\003min\030\003 \001("
"\002:\0010\022\016\n\003max\030\004 \001(\002:\0011\022\017\n\004mean\030\005 \001(\002:\0010\022\016\n"
"\003std\030\006 \001(\002:\0011\022\022\n\006sparse\030\007 \001(\005:\002-1\022I\n\rvar"
"iance_norm\030\010 \001(\0162*.opencv_caffe.FillerPa"
"rameter.VarianceNorm:\006FAN_IN\"4\n\014Variance"
"Norm\022\n\n\006FAN_IN\020\000\022\013\n\007FAN_OUT\020\001\022\013\n\007AVERAGE"
"\020\002\"\252\002\n\014NetParameter\022\014\n\004name\030\001 \001(\t\022\r\n\005inp"
"ut\030\003 \003(\t\022,\n\013input_shape\030\010 \003(\0132\027.opencv_c"
"affe.BlobShape\022\021\n\tinput_dim\030\004 \003(\005\022\035\n\016for"
"ce_backward\030\005 \001(\010:\005false\022%\n\005state\030\006 \001(\0132"
"\026.opencv_caffe.NetState\022\031\n\ndebug_info\030\007 "
"\001(\010:\005false\022+\n\005layer\030d \003(\0132\034.opencv_caffe"
".LayerParameter\022.\n\006layers\030\002 \003(\0132\036.opencv"
"_caffe.V1LayerParameter\"\332\n\n\017SolverParame"
"ter\022\013\n\003net\030\030 \001(\t\022-\n\tnet_param\030\031 \001(\0132\032.op"
"encv_caffe.NetParameter\022\021\n\ttrain_net\030\001 \001"
"(\t\022\020\n\010test_net\030\002 \003(\t\0223\n\017train_net_param\030"
"\025 \001(\0132\032.opencv_caffe.NetParameter\0222\n\016tes"
"t_net_param\030\026 \003(\0132\032.opencv_caffe.NetPara"
"meter\022+\n\013train_state\030\032 \001(\0132\026.opencv_caff"
"e.NetState\022*\n\ntest_state\030\033 \003(\0132\026.opencv_"
"caffe.NetState\022\021\n\ttest_iter\030\003 \003(\005\022\030\n\rtes"
"t_interval\030\004 \001(\005:\0010\022 \n\021test_compute_loss"
"\030\023 \001(\010:\005false\022!\n\023test_initialization\030 \001"
"(\010:\004true\022\017\n\007base_lr\030\005 \001(\002\022\017\n\007display\030\006 \001"
"(\005\022\027\n\014average_loss\030! \001(\005:\0011\022\020\n\010max_iter\030"
"\007 \001(\005\022\024\n\titer_size\030$ \001(\005:\0011\022\021\n\tlr_policy"
"\030\010 \001(\t\022\r\n\005gamma\030\t \001(\002\022\r\n\005power\030\n \001(\002\022\020\n\010"
"momentum\030\013 \001(\002\022\024\n\014weight_decay\030\014 \001(\002\022\037\n\023"
"regularization_type\030\035 \001(\t:\002L2\022\020\n\010stepsiz"
"e\030\r \001(\005\022\021\n\tstepvalue\030\" \003(\005\022\032\n\016clip_gradi"
"ents\030# \001(\002:\002-1\022\023\n\010snapshot\030\016 \001(\005:\0010\022\027\n\017s"
"napshot_prefix\030\017 \001(\t\022\034\n\rsnapshot_diff\030\020 "
"\001(\010:\005false\022R\n\017snapshot_format\030% \001(\0162,.op"
"encv_caffe.SolverParameter.SnapshotForma"
"t:\013BINARYPROTO\022B\n\013solver_mode\030\021 \001(\0162(.op"
"encv_caffe.SolverParameter.SolverMode:\003G"
"PU\022\024\n\tdevice_id\030\022 \001(\005:\0010\022\027\n\013random_seed\030"
"\024 \001(\003:\002-1\022\021\n\004type\030( \001(\t:\003SGD\022\024\n\005delta\030\037 "
"\001(\002:\0051e-08\022\030\n\tmomentum2\030\' \001(\002:\0050.999\022\027\n\t"
"rms_decay\030& \001(\002:\0040.99\022\031\n\ndebug_info\030\027 \001("
"\010:\005false\022\"\n\024snapshot_after_train\030\034 \001(\010:\004"
"true\022B\n\013solver_type\030\036 \001(\0162(.opencv_caffe"
".SolverParameter.SolverType:\003SGD\"+\n\016Snap"
"shotFormat\022\010\n\004HDF5\020\000\022\017\n\013BINARYPROTO\020\001\"\036\n"
"\nSolverMode\022\007\n\003CPU\020\000\022\007\n\003GPU\020\001\"U\n\nSolverT"
"ype\022\007\n\003SGD\020\000\022\014\n\010NESTEROV\020\001\022\013\n\007ADAGRAD\020\002\022"
"\013\n\007RMSPROP\020\003\022\014\n\010ADADELTA\020\004\022\010\n\004ADAM\020\005\"s\n\013"
"SolverState\022\014\n\004iter\030\001 \001(\005\022\023\n\013learned_net"
"\030\002 \001(\t\022(\n\007history\030\003 \003(\0132\027.opencv_caffe.B"
"lobProto\022\027\n\014current_step\030\004 \001(\005:\0010\"U\n\010Net"
"State\022(\n\005phase\030\001 \001(\0162\023.opencv_caffe.Phas"
"e:\004TEST\022\020\n\005level\030\002 \001(\005:\0010\022\r\n\005stage\030\003 \003(\t"
"\"z\n\014NetStateRule\022\"\n\005phase\030\001 \001(\0162\023.opencv"
"_caffe.Phase\022\021\n\tmin_level\030\002 \001(\005\022\021\n\tmax_l"
"evel\030\003 \001(\005\022\r\n\005stage\030\004 \003(\t\022\021\n\tnot_stage\030\005"
" \003(\t\"\252\001\n\tParamSpec\022\014\n\004name\030\001 \001(\t\0228\n\nshar"
"e_mode\030\002 \001(\0162$.opencv_caffe.ParamSpec.Di"
"mCheckMode\022\022\n\007lr_mult\030\003 \001(\002:\0011\022\025\n\ndecay_"
"mult\030\004 \001(\002:\0011\"*\n\014DimCheckMode\022\n\n\006STRICT\020"
"\000\022\016\n\nPERMISSIVE\020\001\"\243\032\n\016LayerParameter\022\014\n\004"
"name\030\001 \001(\t\022\014\n\004type\030\002 \001(\t\022\016\n\006bottom\030\003 \003(\t"
"\022\013\n\003top\030\004 \003(\t\022\"\n\005phase\030\n \001(\0162\023.opencv_ca"
"ffe.Phase\022\023\n\013loss_weight\030\005 \003(\002\022&\n\005param\030"
"\006 \003(\0132\027.opencv_caffe.ParamSpec\022&\n\005blobs\030"
"\007 \003(\0132\027.opencv_caffe.BlobProto\022\026\n\016propag"
"ate_down\030\013 \003(\010\022+\n\007include\030\010 \003(\0132\032.opencv"
"_caffe.NetStateRule\022+\n\007exclude\030\t \003(\0132\032.o"
"pencv_caffe.NetStateRule\022>\n\017transform_pa"
"ram\030d \001(\0132%.opencv_caffe.TransformationP"
"arameter\022/\n\nloss_param\030e \001(\0132\033.opencv_ca"
"ffe.LossParameter\0227\n\016accuracy_param\030f \001("
"\0132\037.opencv_caffe.AccuracyParameter\0223\n\014ar"
"gmax_param\030g \001(\0132\035.opencv_caffe.ArgMaxPa"
"rameter\022;\n\020batch_norm_param\030\213\001 \001(\0132 .ope"
"ncv_caffe.BatchNormParameter\0220\n\nbias_par"
"am\030\215\001 \001(\0132\033.opencv_caffe.BiasParameter\0223"
"\n\014concat_param\030h \001(\0132\035.opencv_caffe.Conc"
"atParameter\022F\n\026contrastive_loss_param\030i "
"\001(\0132&.opencv_caffe.ContrastiveLossParame"
"ter\022=\n\021convolution_param\030j \001(\0132\".opencv_"
"caffe.ConvolutionParameter\0220\n\ncrop_param"
"\030\220\001 \001(\0132\033.opencv_caffe.CropParameter\022/\n\n"
"data_param\030k \001(\0132\033.opencv_caffe.DataPara"
"meter\022G\n\026detection_output_param\030\223\001 \001(\0132&"
".opencv_caffe.DetectionOutputParameter\0225"
"\n\rdropout_param\030l \001(\0132\036.opencv_caffe.Dro"
"poutParameter\022:\n\020dummy_data_param\030m \001(\0132"
" .opencv_caffe.DummyDataParameter\0225\n\relt"
"wise_param\030n \001(\0132\036.opencv_caffe.EltwiseP"
"arameter\022.\n\telu_param\030\214\001 \001(\0132\032.opencv_ca"
"ffe.ELUParameter\0222\n\013embed_param\030\211\001 \001(\0132\034"
".opencv_caffe.EmbedParameter\022-\n\texp_para"
"m\030o \001(\0132\032.opencv_caffe.ExpParameter\0226\n\rf"
"latten_param\030\207\001 \001(\0132\036.opencv_caffe.Flatt"
"enParameter\0228\n\017hdf5_data_param\030p \001(\0132\037.o"
"pencv_caffe.HDF5DataParameter\022<\n\021hdf5_ou"
"tput_param\030q \001(\0132!.opencv_caffe.HDF5Outp"
"utParameter\022:\n\020hinge_loss_param\030r \001(\0132 ."
"opencv_caffe.HingeLossParameter\022:\n\020image"
"_data_param\030s \001(\0132 .opencv_caffe.ImageDa"
"taParameter\022@\n\023infogain_loss_param\030t \001(\013"
"2#.opencv_caffe.InfogainLossParameter\022@\n"
"\023inner_product_param\030u \001(\0132#.opencv_caff"
"e.InnerProductParameter\0222\n\013input_param\030\217"
"\001 \001(\0132\034.opencv_caffe.InputParameter\022.\n\tl"
"og_param\030\206\001 \001(\0132\032.opencv_caffe.LogParame"
"ter\022-\n\tlrn_param\030v \001(\0132\032.opencv_caffe.LR"
"NParameter\022<\n\021memory_data_param\030w \001(\0132!."
"opencv_caffe.MemoryDataParameter\022-\n\tmvn_"
"param\030x \001(\0132\032.opencv_caffe.MVNParameter\022"
"9\n\nnorm_param\030\225\001 \001(\0132$.opencv_caffe.Norm"
"alizeBBoxParameter\0226\n\rpermute_param\030\224\001 \001"
"(\0132\036.opencv_caffe.PermuteParameter\022:\n\017pa"
"rameter_param\030\221\001 \001(\0132 .opencv_caffe.Para"
"meterParameter\0225\n\rpooling_param\030y \001(\0132\036."
"opencv_caffe.PoolingParameter\0221\n\013power_p"
"aram\030z \001(\0132\034.opencv_caffe.PowerParameter"
"\0222\n\013prelu_param\030\203\001 \001(\0132\034.opencv_caffe.PR"
"eLUParameter\0229\n\017prior_box_param\030\226\001 \001(\0132\037"
".opencv_caffe.PriorBoxParameter\0228\n\016propo"
"sal_param\030\311\001 \001(\0132\037.opencv_caffe.Proposal"
"Parameter\022A\n\023psroi_pooling_param\030\221N \001(\0132"
"#.opencv_caffe.PSROIPoolingParameter\0224\n\014"
"python_param\030\202\001 \001(\0132\035.opencv_caffe.Pytho"
"nParameter\022:\n\017recurrent_param\030\222\001 \001(\0132 .o"
"pencv_caffe.RecurrentParameter\022:\n\017reduct"
"ion_param\030\210\001 \001(\0132 .opencv_caffe.Reductio"
"nParameter\022/\n\nrelu_param\030{ \001(\0132\033.opencv_"
"caffe.ReLUParameter\0226\n\rreshape_param\030\205\001 "
"\001(\0132\036.opencv_caffe.ReshapeParameter\022\?\n\021r"
"oi_pooling_param\030\327\307\370\003 \001(\0132!.opencv_caffe"
".ROIPoolingParameter\0222\n\013scale_param\030\216\001 \001"
"(\0132\034.opencv_caffe.ScaleParameter\0225\n\rsigm"
"oid_param\030| \001(\0132\036.opencv_caffe.SigmoidPa"
"rameter\0225\n\rsoftmax_param\030} \001(\0132\036.opencv_"
"caffe.SoftmaxParameter\022.\n\tspp_param\030\204\001 \001"
"(\0132\032.opencv_caffe.SPPParameter\0221\n\013slice_"
"param\030~ \001(\0132\034.opencv_caffe.SliceParamete"
"r\022/\n\ntanh_param\030\177 \001(\0132\033.opencv_caffe.Tan"
"HParameter\022:\n\017threshold_param\030\200\001 \001(\0132 .o"
"pencv_caffe.ThresholdParameter\0220\n\ntile_p"
"aram\030\212\001 \001(\0132\033.opencv_caffe.TileParameter"
"\022=\n\021window_data_param\030\201\001 \001(\0132!.opencv_ca"
"ffe.WindowDataParameter\"\266\001\n\027Transformati"
"onParameter\022\020\n\005scale\030\001 \001(\002:\0011\022\025\n\006mirror\030"
"\002 \001(\010:\005false\022\024\n\tcrop_size\030\003 \001(\r:\0010\022\021\n\tme"
"an_file\030\004 \001(\t\022\022\n\nmean_value\030\005 \003(\002\022\032\n\013for"
"ce_color\030\006 \001(\010:\005false\022\031\n\nforce_gray\030\007 \001("
"\010:\005false\"\311\001\n\rLossParameter\022\024\n\014ignore_lab"
"el\030\001 \001(\005\022K\n\rnormalization\030\003 \001(\0162-.opencv"
"_caffe.LossParameter.NormalizationMode:\005"
"VALID\022\021\n\tnormalize\030\002 \001(\010\"B\n\021Normalizatio"
"nMode\022\010\n\004FULL\020\000\022\t\n\005VALID\020\001\022\016\n\nBATCH_SIZE"
"\020\002\022\010\n\004NONE\020\003\"L\n\021AccuracyParameter\022\020\n\005top"
"_k\030\001 \001(\r:\0011\022\017\n\004axis\030\002 \001(\005:\0011\022\024\n\014ignore_l"
"abel\030\003 \001(\005\"M\n\017ArgMaxParameter\022\032\n\013out_max"
"_val\030\001 \001(\010:\005false\022\020\n\005top_k\030\002 \001(\r:\0011\022\014\n\004a"
"xis\030\003 \001(\005\"9\n\017ConcatParameter\022\017\n\004axis\030\002 \001"
"(\005:\0011\022\025\n\nconcat_dim\030\001 \001(\r:\0011\"j\n\022BatchNor"
"mParameter\022\030\n\020use_global_stats\030\001 \001(\010\022&\n\027"
"moving_average_fraction\030\002 \001(\002:\0050.999\022\022\n\003"
"eps\030\003 \001(\002:\0051e-05\"d\n\rBiasParameter\022\017\n\004axi"
"s\030\001 \001(\005:\0011\022\023\n\010num_axes\030\002 \001(\005:\0011\022-\n\006fille"
"r\030\003 \001(\0132\035.opencv_caffe.FillerParameter\"L"
"\n\030ContrastiveLossParameter\022\021\n\006margin\030\001 \001"
"(\002:\0011\022\035\n\016legacy_version\030\002 \001(\010:\005false\"\221\004\n"
"\024ConvolutionParameter\022\022\n\nnum_output\030\001 \001("
"\r\022\027\n\tbias_term\030\002 \001(\010:\004true\022\013\n\003pad\030\003 \003(\r\022"
"\023\n\013kernel_size\030\004 \003(\r\022\016\n\006stride\030\006 \003(\r\022\020\n\010"
"dilation\030\022 \003(\r\022\020\n\005pad_h\030\t \001(\r:\0010\022\020\n\005pad_"
"w\030\n \001(\r:\0010\022\020\n\010kernel_h\030\013 \001(\r\022\020\n\010kernel_w"
"\030\014 \001(\r\022\020\n\010stride_h\030\r \001(\r\022\020\n\010stride_w\030\016 \001"
"(\r\022\020\n\005group\030\005 \001(\r:\0011\0224\n\rweight_filler\030\007 "
"\001(\0132\035.opencv_caffe.FillerParameter\0222\n\013bi"
"as_filler\030\010 \001(\0132\035.opencv_caffe.FillerPar"
"ameter\022B\n\006engine\030\017 \001(\0162).opencv_caffe.Co"
"nvolutionParameter.Engine:\007DEFAULT\022\017\n\004ax"
"is\030\020 \001(\005:\0011\022\036\n\017force_nd_im2col\030\021 \001(\010:\005fa"
"lse\"+\n\006Engine\022\013\n\007DEFAULT\020\000\022\t\n\005CAFFE\020\001\022\t\n"
"\005CUDNN\020\002\"0\n\rCropParameter\022\017\n\004axis\030\001 \001(\005:"
"\0012\022\016\n\006offset\030\002 \003(\r\"\253\002\n\rDataParameter\022\016\n\006"
"source\030\001 \001(\t\022\022\n\nbatch_size\030\004 \001(\r\022\024\n\trand"
"_skip\030\007 \001(\r:\0010\0228\n\007backend\030\010 \001(\0162\036.opencv"
"_caffe.DataParameter.DB:\007LEVELDB\022\020\n\005scal"
"e\030\002 \001(\002:\0011\022\021\n\tmean_file\030\003 \001(\t\022\024\n\tcrop_si"
"ze\030\005 \001(\r:\0010\022\025\n\006mirror\030\006 \001(\010:\005false\022\"\n\023fo"
"rce_encoded_color\030\t \001(\010:\005false\022\023\n\010prefet"
"ch\030\n \001(\r:\0014\"\033\n\002DB\022\013\n\007LEVELDB\020\000\022\010\n\004LMDB\020\001"
"\"[\n\036NonMaximumSuppressionParameter\022\032\n\rnm"
"s_threshold\030\001 \001(\002:\0030.3\022\r\n\005top_k\030\002 \001(\005\022\016\n"
"\003eta\030\003 \001(\002:\0011\"\252\001\n\023SaveOutputParameter\022\030\n"
"\020output_directory\030\001 \001(\t\022\032\n\022output_name_p"
"refix\030\002 \001(\t\022\025\n\routput_format\030\003 \001(\t\022\026\n\016la"
"bel_map_file\030\004 \001(\t\022\026\n\016name_size_file\030\005 \001"
"(\t\022\026\n\016num_test_image\030\006 \001(\r\"I\n\020DropoutPar"
"ameter\022\032\n\rdropout_ratio\030\001 \001(\002:\0030.5\022\031\n\013sc"
"ale_train\030\002 \001(\010:\004true\"\256\001\n\022DummyDataParam"
"eter\0222\n\013data_filler\030\001 \003(\0132\035.opencv_caffe"
".FillerParameter\022&\n\005shape\030\006 \003(\0132\027.opencv"
"_caffe.BlobShape\022\013\n\003num\030\002 \003(\r\022\020\n\010channel"
"s\030\003 \003(\r\022\016\n\006height\030\004 \003(\r\022\r\n\005width\030\005 \003(\r\"\254"
"\001\n\020EltwiseParameter\022@\n\toperation\030\001 \001(\0162("
".opencv_caffe.EltwiseParameter.EltwiseOp"
":\003SUM\022\r\n\005coeff\030\002 \003(\002\022\036\n\020stable_prod_grad"
"\030\003 \001(\010:\004true\"\'\n\tEltwiseOp\022\010\n\004PROD\020\000\022\007\n\003S"
"UM\020\001\022\007\n\003MAX\020\002\" \n\014ELUParameter\022\020\n\005alpha\030\001"
" \001(\002:\0011\"\272\001\n\016EmbedParameter\022\022\n\nnum_output"
"\030\001 \001(\r\022\021\n\tinput_dim\030\002 \001(\r\022\027\n\tbias_term\030\003"
" \001(\010:\004true\0224\n\rweight_filler\030\004 \001(\0132\035.open"
"cv_caffe.FillerParameter\0222\n\013bias_filler\030"
"\005 \001(\0132\035.opencv_caffe.FillerParameter\"D\n\014"
"ExpParameter\022\020\n\004base\030\001 \001(\002:\002-1\022\020\n\005scale\030"
"\002 \001(\002:\0011\022\020\n\005shift\030\003 \001(\002:\0010\"9\n\020FlattenPar"
"ameter\022\017\n\004axis\030\001 \001(\005:\0011\022\024\n\010end_axis\030\002 \001("
"\005:\002-1\"O\n\021HDF5DataParameter\022\016\n\006source\030\001 \001"
"(\t\022\022\n\nbatch_size\030\002 \001(\r\022\026\n\007shuffle\030\003 \001(\010:"
"\005false\"(\n\023HDF5OutputParameter\022\021\n\tfile_na"
"me\030\001 \001(\t\"e\n\022HingeLossParameter\0227\n\004norm\030\001"
" \001(\0162%.opencv_caffe.HingeLossParameter.N"
"orm:\002L1\"\026\n\004Norm\022\006\n\002L1\020\001\022\006\n\002L2\020\002\"\227\002\n\022Imag"
"eDataParameter\022\016\n\006source\030\001 \001(\t\022\025\n\nbatch_"
"size\030\004 \001(\r:\0011\022\024\n\trand_skip\030\007 \001(\r:\0010\022\026\n\007s"
"huffle\030\010 \001(\010:\005false\022\025\n\nnew_height\030\t \001(\r:"
"\0010\022\024\n\tnew_width\030\n \001(\r:\0010\022\026\n\010is_color\030\013 \001"
"(\010:\004true\022\020\n\005scale\030\002 \001(\002:\0011\022\021\n\tmean_file\030"
"\003 \001(\t\022\024\n\tcrop_size\030\005 \001(\r:\0010\022\025\n\006mirror\030\006 "
"\001(\010:\005false\022\025\n\013root_folder\030\014 \001(\t:\000\"\'\n\025Inf"
"ogainLossParameter\022\016\n\006source\030\001 \001(\t\"\331\001\n\025I"
"nnerProductParameter\022\022\n\nnum_output\030\001 \001(\r"
"\022\027\n\tbias_term\030\002 \001(\010:\004true\0224\n\rweight_fill"
"er\030\003 \001(\0132\035.opencv_caffe.FillerParameter\022"
"2\n\013bias_filler\030\004 \001(\0132\035.opencv_caffe.Fill"
"erParameter\022\017\n\004axis\030\005 \001(\005:\0011\022\030\n\ttranspos"
"e\030\006 \001(\010:\005false\"8\n\016InputParameter\022&\n\005shap"
"e\030\001 \003(\0132\027.opencv_caffe.BlobShape\"D\n\014LogP"
"arameter\022\020\n\004base\030\001 \001(\002:\002-1\022\020\n\005scale\030\002 \001("
"\002:\0011\022\020\n\005shift\030\003 \001(\002:\0010\"\306\002\n\014LRNParameter\022"
"\025\n\nlocal_size\030\001 \001(\r:\0015\022\020\n\005alpha\030\002 \001(\002:\0011"
"\022\022\n\004beta\030\003 \001(\002:\0040.75\022K\n\013norm_region\030\004 \001("
"\0162%.opencv_caffe.LRNParameter.NormRegion"
":\017ACROSS_CHANNELS\022\014\n\001k\030\005 \001(\002:\0011\022:\n\006engin"
"e\030\006 \001(\0162!.opencv_caffe.LRNParameter.Engi"
"ne:\007DEFAULT\"5\n\nNormRegion\022\023\n\017ACROSS_CHAN"
"NELS\020\000\022\022\n\016WITHIN_CHANNEL\020\001\"+\n\006Engine\022\013\n\007"
"DEFAULT\020\000\022\t\n\005CAFFE\020\001\022\t\n\005CUDNN\020\002\"Z\n\023Memor"
"yDataParameter\022\022\n\nbatch_size\030\001 \001(\r\022\020\n\010ch"
"annels\030\002 \001(\r\022\016\n\006height\030\003 \001(\r\022\r\n\005width\030\004 "
"\001(\r\"d\n\014MVNParameter\022 \n\022normalize_varianc"
"e\030\001 \001(\010:\004true\022\036\n\017across_channels\030\002 \001(\010:\005"
"false\022\022\n\003eps\030\003 \001(\002:\0051e-09\"<\n\022ParameterPa"
"rameter\022&\n\005shape\030\001 \001(\0132\027.opencv_caffe.Bl"
"obShape\"\311\003\n\020PoolingParameter\022<\n\004pool\030\001 \001"
"(\0162).opencv_caffe.PoolingParameter.PoolM"
"ethod:\003MAX\022\016\n\003pad\030\004 \001(\r:\0010\022\020\n\005pad_h\030\t \001("
"\r:\0010\022\020\n\005pad_w\030\n \001(\r:\0010\022\023\n\013kernel_size\030\002 "
"\001(\r\022\020\n\010kernel_h\030\005 \001(\r\022\020\n\010kernel_w\030\006 \001(\r\022"
"\021\n\006stride\030\003 \001(\r:\0011\022\020\n\010stride_h\030\007 \001(\r\022\020\n\010"
"stride_w\030\010 \001(\r\022>\n\006engine\030\013 \001(\0162%.opencv_"
"caffe.PoolingParameter.Engine:\007DEFAULT\022\035"
"\n\016global_pooling\030\014 \001(\010:\005false\022\027\n\tceil_mo"
"de\030\r \001(\010:\004true\".\n\nPoolMethod\022\007\n\003MAX\020\000\022\007\n"
"\003AVE\020\001\022\016\n\nSTOCHASTIC\020\002\"+\n\006Engine\022\013\n\007DEFA"
"ULT\020\000\022\t\n\005CAFFE\020\001\022\t\n\005CUDNN\020\002\"F\n\016PowerPara"
"meter\022\020\n\005power\030\001 \001(\002:\0011\022\020\n\005scale\030\002 \001(\002:\001"
"1\022\020\n\005shift\030\003 \001(\002:\0010\"g\n\017PythonParameter\022\016"
"\n\006module\030\001 \001(\t\022\r\n\005layer\030\002 \001(\t\022\023\n\tparam_s"
"tr\030\003 \001(\t:\000\022 \n\021share_in_parallel\030\004 \001(\010:\005f"
"alse\"\316\001\n\022RecurrentParameter\022\025\n\nnum_outpu"
"t\030\001 \001(\r:\0010\0224\n\rweight_filler\030\002 \001(\0132\035.open"
"cv_caffe.FillerParameter\0222\n\013bias_filler\030"
"\003 \001(\0132\035.opencv_caffe.FillerParameter\022\031\n\n"
"debug_info\030\004 \001(\010:\005false\022\034\n\rexpose_hidden"
"\030\005 \001(\010:\005false\"\264\001\n\022ReductionParameter\022D\n\t"
"operation\030\001 \001(\0162,.opencv_caffe.Reduction"
"Parameter.ReductionOp:\003SUM\022\017\n\004axis\030\002 \001(\005"
":\0010\022\020\n\005coeff\030\003 \001(\002:\0011\"5\n\013ReductionOp\022\007\n\003"
"SUM\020\001\022\010\n\004ASUM\020\002\022\t\n\005SUMSQ\020\003\022\010\n\004MEAN\020\004\"\224\001\n"
"\rReLUParameter\022\031\n\016negative_slope\030\001 \001(\002:\001"
"0\022;\n\006engine\030\002 \001(\0162\".opencv_caffe.ReLUPar"
"ameter.Engine:\007DEFAULT\"+\n\006Engine\022\013\n\007DEFA"
"ULT\020\000\022\t\n\005CAFFE\020\001\022\t\n\005CUDNN\020\002\"a\n\020ReshapePa"
"rameter\022&\n\005shape\030\001 \001(\0132\027.opencv_caffe.Bl"
"obShape\022\017\n\004axis\030\002 \001(\005:\0010\022\024\n\010num_axes\030\003 \001"
"(\005:\002-1\"\263\001\n\016ScaleParameter\022\017\n\004axis\030\001 \001(\005:"
"\0011\022\023\n\010num_axes\030\002 \001(\005:\0011\022-\n\006filler\030\003 \001(\0132"
"\035.opencv_caffe.FillerParameter\022\030\n\tbias_t"
"erm\030\004 \001(\010:\005false\0222\n\013bias_filler\030\005 \001(\0132\035."
"opencv_caffe.FillerParameter\"\177\n\020SigmoidP"
"arameter\022>\n\006engine\030\001 \001(\0162%.opencv_caffe."
"SigmoidParameter.Engine:\007DEFAULT\"+\n\006Engi"
"ne\022\013\n\007DEFAULT\020\000\022\t\n\005CAFFE\020\001\022\t\n\005CUDNN\020\002\"L\n"
"\016SliceParameter\022\017\n\004axis\030\003 \001(\005:\0011\022\023\n\013slic"
"e_point\030\002 \003(\r\022\024\n\tslice_dim\030\001 \001(\r:\0011\"\220\001\n\020"
"SoftmaxParameter\022>\n\006engine\030\001 \001(\0162%.openc"
"v_caffe.SoftmaxParameter.Engine:\007DEFAULT"
"\022\017\n\004axis\030\002 \001(\005:\0011\"+\n\006Engine\022\013\n\007DEFAULT\020\000"
"\022\t\n\005CAFFE\020\001\022\t\n\005CUDNN\020\002\"y\n\rTanHParameter\022"
";\n\006engine\030\001 \001(\0162\".opencv_caffe.TanHParam"
"eter.Engine:\007DEFAULT\"+\n\006Engine\022\013\n\007DEFAUL"
"T\020\000\022\t\n\005CAFFE\020\001\022\t\n\005CUDNN\020\002\"/\n\rTileParamet"
"er\022\017\n\004axis\030\001 \001(\005:\0011\022\r\n\005tiles\030\002 \001(\005\"*\n\022Th"
"resholdParameter\022\024\n\tthreshold\030\001 \001(\002:\0010\"\301"
"\002\n\023WindowDataParameter\022\016\n\006source\030\001 \001(\t\022\020"
"\n\005scale\030\002 \001(\002:\0011\022\021\n\tmean_file\030\003 \001(\t\022\022\n\nb"
"atch_size\030\004 \001(\r\022\024\n\tcrop_size\030\005 \001(\r:\0010\022\025\n"
"\006mirror\030\006 \001(\010:\005false\022\031\n\014fg_threshold\030\007 \001"
"(\002:\0030.5\022\031\n\014bg_threshold\030\010 \001(\002:\0030.5\022\031\n\013fg"
"_fraction\030\t \001(\002:\0040.25\022\026\n\013context_pad\030\n \001"
"(\r:\0010\022\027\n\tcrop_mode\030\013 \001(\t:\004warp\022\033\n\014cache_"
"images\030\014 \001(\010:\005false\022\025\n\013root_folder\030\r \001(\t"
":\000\"\371\001\n\014SPPParameter\022\026\n\016pyramid_height\030\001 "
"\001(\r\0228\n\004pool\030\002 \001(\0162%.opencv_caffe.SPPPara"
"meter.PoolMethod:\003MAX\022:\n\006engine\030\006 \001(\0162!."
"opencv_caffe.SPPParameter.Engine:\007DEFAUL"
"T\".\n\nPoolMethod\022\007\n\003MAX\020\000\022\007\n\003AVE\020\001\022\016\n\nSTO"
"CHASTIC\020\002\"+\n\006Engine\022\013\n\007DEFAULT\020\000\022\t\n\005CAFF"
"E\020\001\022\t\n\005CUDNN\020\002\"\334\025\n\020V1LayerParameter\022\016\n\006b"
"ottom\030\002 \003(\t\022\013\n\003top\030\003 \003(\t\022\014\n\004name\030\004 \001(\t\022+"
"\n\007include\030 \003(\0132\032.opencv_caffe.NetStateR"
"ule\022+\n\007exclude\030! \003(\0132\032.opencv_caffe.NetS"
"tateRule\0226\n\004type\030\005 \001(\0162(.opencv_caffe.V1"
"LayerParameter.LayerType\022&\n\005blobs\030\006 \003(\0132"
"\027.opencv_caffe.BlobProto\022\016\n\005param\030\351\007 \003(\t"
"\022E\n\017blob_share_mode\030\352\007 \003(\0162+.opencv_caff"
"e.V1LayerParameter.DimCheckMode\022\020\n\010blobs"
"_lr\030\007 \003(\002\022\024\n\014weight_decay\030\010 \003(\002\022\023\n\013loss_"
"weight\030# \003(\002\0227\n\016accuracy_param\030\033 \001(\0132\037.o"
"pencv_caffe.AccuracyParameter\0223\n\014argmax_"
"param\030\027 \001(\0132\035.opencv_caffe.ArgMaxParamet"
"er\0223\n\014concat_param\030\t \001(\0132\035.opencv_caffe."
"ConcatParameter\022F\n\026contrastive_loss_para"
"m\030( \001(\0132&.opencv_caffe.ContrastiveLossPa"
"rameter\022=\n\021convolution_param\030\n \001(\0132\".ope"
"ncv_caffe.ConvolutionParameter\022/\n\ndata_p"
"aram\030\013 \001(\0132\033.opencv_caffe.DataParameter\022"
"5\n\rdropout_param\030\014 \001(\0132\036.opencv_caffe.Dr"
"opoutParameter\022:\n\020dummy_data_param\030\032 \001(\013"
"2 .opencv_caffe.DummyDataParameter\0225\n\rel"
"twise_param\030\030 \001(\0132\036.opencv_caffe.Eltwise"
"Parameter\022-\n\texp_param\030) \001(\0132\032.opencv_ca"
"ffe.ExpParameter\0228\n\017hdf5_data_param\030\r \001("
"\0132\037.opencv_caffe.HDF5DataParameter\022<\n\021hd"
"f5_output_param\030\016 \001(\0132!.opencv_caffe.HDF"
"5OutputParameter\022:\n\020hinge_loss_param\030\035 \001"
"(\0132 .opencv_caffe.HingeLossParameter\022:\n\020"
"image_data_param\030\017 \001(\0132 .opencv_caffe.Im"
"ageDataParameter\022@\n\023infogain_loss_param\030"
"\020 \001(\0132#.opencv_caffe.InfogainLossParamet"
"er\022@\n\023inner_product_param\030\021 \001(\0132#.opencv"
"_caffe.InnerProductParameter\022-\n\tlrn_para"
"m\030\022 \001(\0132\032.opencv_caffe.LRNParameter\022<\n\021m"
"emory_data_param\030\026 \001(\0132!.opencv_caffe.Me"
"moryDataParameter\022-\n\tmvn_param\030\" \001(\0132\032.o"
"pencv_caffe.MVNParameter\0225\n\rpooling_para"
"m\030\023 \001(\0132\036.opencv_caffe.PoolingParameter\022"
"1\n\013power_param\030\025 \001(\0132\034.opencv_caffe.Powe"
"rParameter\022/\n\nrelu_param\030\036 \001(\0132\033.opencv_"
"caffe.ReLUParameter\0225\n\rsigmoid_param\030& \001"
"(\0132\036.opencv_caffe.SigmoidParameter\0225\n\rso"
"ftmax_param\030\' \001(\0132\036.opencv_caffe.Softmax"
"Parameter\0221\n\013slice_param\030\037 \001(\0132\034.opencv_"
"caffe.SliceParameter\022/\n\ntanh_param\030% \001(\013"
"2\033.opencv_caffe.TanHParameter\0229\n\017thresho"
"ld_param\030\031 \001(\0132 .opencv_caffe.ThresholdP"
"arameter\022<\n\021window_data_param\030\024 \001(\0132!.op"
"encv_caffe.WindowDataParameter\022>\n\017transf"
"orm_param\030$ \001(\0132%.opencv_caffe.Transform"
"ationParameter\022/\n\nloss_param\030* \001(\0132\033.ope"
"ncv_caffe.LossParameter\022-\n\005layer\030\001 \001(\0132\036"
".opencv_caffe.V0LayerParameter\"\330\004\n\tLayer"
"Type\022\010\n\004NONE\020\000\022\n\n\006ABSVAL\020#\022\014\n\010ACCURACY\020\001"
"\022\n\n\006ARGMAX\020\036\022\010\n\004BNLL\020\002\022\n\n\006CONCAT\020\003\022\024\n\020CO"
"NTRASTIVE_LOSS\020%\022\017\n\013CONVOLUTION\020\004\022\010\n\004DAT"
"A\020\005\022\021\n\rDECONVOLUTION\020\'\022\013\n\007DROPOUT\020\006\022\016\n\nD"
"UMMY_DATA\020 \022\022\n\016EUCLIDEAN_LOSS\020\007\022\013\n\007ELTWI"
"SE\020\031\022\007\n\003EXP\020&\022\013\n\007FLATTEN\020\010\022\r\n\tHDF5_DATA\020"
"\t\022\017\n\013HDF5_OUTPUT\020\n\022\016\n\nHINGE_LOSS\020\034\022\n\n\006IM"
"2COL\020\013\022\016\n\nIMAGE_DATA\020\014\022\021\n\rINFOGAIN_LOSS\020"
"\r\022\021\n\rINNER_PRODUCT\020\016\022\007\n\003LRN\020\017\022\017\n\013MEMORY_"
"DATA\020\035\022\035\n\031MULTINOMIAL_LOGISTIC_LOSS\020\020\022\007\n"
"\003MVN\020\"\022\013\n\007POOLING\020\021\022\t\n\005POWER\020\032\022\010\n\004RELU\020\022"
"\022\013\n\007SIGMOID\020\023\022\036\n\032SIGMOID_CROSS_ENTROPY_L"
"OSS\020\033\022\013\n\007SILENCE\020$\022\013\n\007SOFTMAX\020\024\022\020\n\014SOFTM"
"AX_LOSS\020\025\022\t\n\005SPLIT\020\026\022\t\n\005SLICE\020!\022\010\n\004TANH\020"
"\027\022\017\n\013WINDOW_DATA\020\030\022\r\n\tTHRESHOLD\020\037\"*\n\014Dim"
"CheckMode\022\n\n\006STRICT\020\000\022\016\n\nPERMISSIVE\020\001\"\240\010"
"\n\020V0LayerParameter\022\014\n\004name\030\001 \001(\t\022\014\n\004type"
"\030\002 \001(\t\022\022\n\nnum_output\030\003 \001(\r\022\026\n\010biasterm\030\004"
" \001(\010:\004true\0224\n\rweight_filler\030\005 \001(\0132\035.open"
"cv_caffe.FillerParameter\0222\n\013bias_filler\030"
"\006 \001(\0132\035.opencv_caffe.FillerParameter\022\016\n\003"
"pad\030\007 \001(\r:\0010\022\022\n\nkernelsize\030\010 \001(\r\022\020\n\005grou"
"p\030\t \001(\r:\0011\022\021\n\006stride\030\n \001(\r:\0011\022<\n\004pool\030\013 "
"\001(\0162).opencv_caffe.V0LayerParameter.Pool"
"Method:\003MAX\022\032\n\rdropout_ratio\030\014 \001(\002:\0030.5\022"
"\025\n\nlocal_size\030\r \001(\r:\0015\022\020\n\005alpha\030\016 \001(\002:\0011"
"\022\022\n\004beta\030\017 \001(\002:\0040.75\022\014\n\001k\030\026 \001(\002:\0011\022\016\n\006so"
"urce\030\020 \001(\t\022\020\n\005scale\030\021 \001(\002:\0011\022\020\n\010meanfile"
"\030\022 \001(\t\022\021\n\tbatchsize\030\023 \001(\r\022\023\n\010cropsize\030\024 "
"\001(\r:\0010\022\025\n\006mirror\030\025 \001(\010:\005false\022&\n\005blobs\0302"
" \003(\0132\027.opencv_caffe.BlobProto\022\020\n\010blobs_l"
"r\0303 \003(\002\022\024\n\014weight_decay\0304 \003(\002\022\024\n\trand_sk"
"ip\0305 \001(\r:\0010\022\035\n\020det_fg_threshold\0306 \001(\002:\0030"
".5\022\035\n\020det_bg_threshold\0307 \001(\002:\0030.5\022\035\n\017det"
"_fg_fraction\0308 \001(\002:\0040.25\022\032\n\017det_context_"
"pad\030: \001(\r:\0010\022\033\n\rdet_crop_mode\030; \001(\t:\004war"
"p\022\022\n\007new_num\030< \001(\005:\0010\022\027\n\014new_channels\030= "
"\001(\005:\0010\022\025\n\nnew_height\030> \001(\005:\0010\022\024\n\tnew_wid"
"th\030\? \001(\005:\0010\022\035\n\016shuffle_images\030@ \001(\010:\005fal"
"se\022\025\n\nconcat_dim\030A \001(\r:\0011\022=\n\021hdf5_output"
"_param\030\351\007 \001(\0132!.opencv_caffe.HDF5OutputP"
"arameter\".\n\nPoolMethod\022\007\n\003MAX\020\000\022\007\n\003AVE\020\001"
"\022\016\n\nSTOCHASTIC\020\002\"^\n\016PReLUParameter\022-\n\006fi"
"ller\030\001 \001(\0132\035.opencv_caffe.FillerParamete"
"r\022\035\n\016channel_shared\030\002 \001(\010:\005false\"\207\001\n\016Nor"
"malizedBBox\022\014\n\004xmin\030\001 \001(\002\022\014\n\004ymin\030\002 \001(\002\022"
"\014\n\004xmax\030\003 \001(\002\022\014\n\004ymax\030\004 \001(\002\022\r\n\005label\030\005 \001"
"(\005\022\021\n\tdifficult\030\006 \001(\010\022\r\n\005score\030\007 \001(\002\022\014\n\004"
"size\030\010 \001(\002\"Y\n\023ROIPoolingParameter\022\023\n\010poo"
"led_h\030\001 \001(\r:\0010\022\023\n\010pooled_w\030\002 \001(\r:\0010\022\030\n\rs"
"patial_scale\030\003 \001(\002:\0011\"\310\001\n\021ProposalParame"
"ter\022\027\n\013feat_stride\030\001 \001(\r:\00216\022\025\n\tbase_siz"
"e\030\002 \001(\r:\00216\022\024\n\010min_size\030\003 \001(\r:\00216\022\r\n\005rat"
"io\030\004 \003(\002\022\r\n\005scale\030\005 \003(\002\022\032\n\014pre_nms_topn\030"
"\006 \001(\r:\0046000\022\032\n\rpost_nms_topn\030\007 \001(\r:\003300\022"
"\027\n\nnms_thresh\030\010 \001(\002:\0030.7\"V\n\025PSROIPooling"
"Parameter\022\025\n\rspatial_scale\030\001 \002(\002\022\022\n\noutp"
"ut_dim\030\002 \002(\005\022\022\n\ngroup_size\030\003 \002(\005*=\n\004Type"
"\022\n\n\006DOUBLE\020\000\022\t\n\005FLOAT\020\001\022\013\n\007FLOAT16\020\002\022\007\n\003"
"INT\020\003\022\010\n\004UINT\020\004*\034\n\005Phase\022\t\n\005TRAIN\020\000\022\010\n\004T"
"EST\020\001", 18805);
::google::protobuf::MessageFactory::InternalRegisterGeneratedFile(
"opencv-caffe.proto", &protobuf_RegisterTypes);
::google::protobuf::internal::OnShutdown(&protobuf_ShutdownFile_opencv_2dcaffe_2eproto);
}
GOOGLE_PROTOBUF_DECLARE_ONCE(protobuf_AddDesc_opencv_2dcaffe_2eproto_once_);
void protobuf_AddDesc_opencv_2dcaffe_2eproto() {
::google::protobuf::GoogleOnceInit(&protobuf_AddDesc_opencv_2dcaffe_2eproto_once_,
&protobuf_AddDesc_opencv_2dcaffe_2eproto_impl);
}
// Force AddDescriptors() to be called at static initialization time.
struct StaticDescriptorInitializer_opencv_2dcaffe_2eproto {
StaticDescriptorInitializer_opencv_2dcaffe_2eproto() {
protobuf_AddDesc_opencv_2dcaffe_2eproto();
}
} static_descriptor_initializer_opencv_2dcaffe_2eproto_;
const ::google::protobuf::EnumDescriptor* Type_descriptor() {
protobuf_AssignDescriptorsOnce();
return Type_descriptor_;
}
bool Type_IsValid(int value) {
switch (value) {
case 0:
case 1:
case 2:
case 3:
case 4:
return true;
default:
return false;
}
}
const ::google::protobuf::EnumDescriptor* Phase_descriptor() {
protobuf_AssignDescriptorsOnce();
return Phase_descriptor_;
}
bool Phase_IsValid(int value) {
switch (value) {
case 0:
case 1:
return true;
default:
return false;
}
}
namespace {
static void MergeFromFail(int line) GOOGLE_ATTRIBUTE_COLD GOOGLE_ATTRIBUTE_NORETURN;
static void MergeFromFail(int line) {
::google::protobuf::internal::MergeFromFail(__FILE__, line);
}
} // namespace
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int BlobShape::kDimFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
BlobShape::BlobShape()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.BlobShape)
}
void BlobShape::InitAsDefaultInstance() {
}
BlobShape::BlobShape(const BlobShape& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.BlobShape)
}
void BlobShape::SharedCtor() {
_cached_size_ = 0;
}
BlobShape::~BlobShape() {
// @@protoc_insertion_point(destructor:opencv_caffe.BlobShape)
SharedDtor();
}
void BlobShape::SharedDtor() {
}
void BlobShape::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* BlobShape::descriptor() {
protobuf_AssignDescriptorsOnce();
return BlobShape_descriptor_;
}
const BlobShape& BlobShape::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<BlobShape> BlobShape_default_instance_;
BlobShape* BlobShape::New(::google::protobuf::Arena* arena) const {
BlobShape* n = new BlobShape;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void BlobShape::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.BlobShape)
dim_.Clear();
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool BlobShape::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.BlobShape)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// repeated int64 dim = 1 [packed = true];
case 1: {
if (tag == 10) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitive<
::google::protobuf::int64, ::google::protobuf::internal::WireFormatLite::TYPE_INT64>(
input, this->mutable_dim())));
} else if (tag == 8) {
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitiveNoInline<
::google::protobuf::int64, ::google::protobuf::internal::WireFormatLite::TYPE_INT64>(
1, 10, input, this->mutable_dim())));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.BlobShape)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.BlobShape)
return false;
#undef DO_
}
void BlobShape::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.BlobShape)
// repeated int64 dim = 1 [packed = true];
if (this->dim_size() > 0) {
::google::protobuf::internal::WireFormatLite::WriteTag(1, ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED, output);
output->WriteVarint32(_dim_cached_byte_size_);
}
for (int i = 0; i < this->dim_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteInt64NoTag(
this->dim(i), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.BlobShape)
}
::google::protobuf::uint8* BlobShape::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.BlobShape)
// repeated int64 dim = 1 [packed = true];
if (this->dim_size() > 0) {
target = ::google::protobuf::internal::WireFormatLite::WriteTagToArray(
1,
::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED,
target);
target = ::google::protobuf::io::CodedOutputStream::WriteVarint32ToArray(
_dim_cached_byte_size_, target);
}
for (int i = 0; i < this->dim_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteInt64NoTagToArray(this->dim(i), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.BlobShape)
return target;
}
size_t BlobShape::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.BlobShape)
size_t total_size = 0;
// repeated int64 dim = 1 [packed = true];
{
size_t data_size = 0;
unsigned int count = this->dim_size();
for (unsigned int i = 0; i < count; i++) {
data_size += ::google::protobuf::internal::WireFormatLite::
Int64Size(this->dim(i));
}
if (data_size > 0) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(data_size);
}
int cached_size = ::google::protobuf::internal::ToCachedSize(data_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_dim_cached_byte_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
total_size += data_size;
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void BlobShape::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.BlobShape)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const BlobShape* source =
::google::protobuf::internal::DynamicCastToGenerated<const BlobShape>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.BlobShape)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.BlobShape)
UnsafeMergeFrom(*source);
}
}
void BlobShape::MergeFrom(const BlobShape& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.BlobShape)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void BlobShape::UnsafeMergeFrom(const BlobShape& from) {
GOOGLE_DCHECK(&from != this);
dim_.UnsafeMergeFrom(from.dim_);
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void BlobShape::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.BlobShape)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void BlobShape::CopyFrom(const BlobShape& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.BlobShape)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool BlobShape::IsInitialized() const {
return true;
}
void BlobShape::Swap(BlobShape* other) {
if (other == this) return;
InternalSwap(other);
}
void BlobShape::InternalSwap(BlobShape* other) {
dim_.UnsafeArenaSwap(&other->dim_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata BlobShape::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = BlobShape_descriptor_;
metadata.reflection = BlobShape_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// BlobShape
// repeated int64 dim = 1 [packed = true];
int BlobShape::dim_size() const {
return dim_.size();
}
void BlobShape::clear_dim() {
dim_.Clear();
}
::google::protobuf::int64 BlobShape::dim(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.BlobShape.dim)
return dim_.Get(index);
}
void BlobShape::set_dim(int index, ::google::protobuf::int64 value) {
dim_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.BlobShape.dim)
}
void BlobShape::add_dim(::google::protobuf::int64 value) {
dim_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.BlobShape.dim)
}
const ::google::protobuf::RepeatedField< ::google::protobuf::int64 >&
BlobShape::dim() const {
// @@protoc_insertion_point(field_list:opencv_caffe.BlobShape.dim)
return dim_;
}
::google::protobuf::RepeatedField< ::google::protobuf::int64 >*
BlobShape::mutable_dim() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.BlobShape.dim)
return &dim_;
}
inline const BlobShape* BlobShape::internal_default_instance() {
return &BlobShape_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int BlobProto::kShapeFieldNumber;
const int BlobProto::kDataFieldNumber;
const int BlobProto::kDiffFieldNumber;
const int BlobProto::kDoubleDataFieldNumber;
const int BlobProto::kDoubleDiffFieldNumber;
const int BlobProto::kRawDataTypeFieldNumber;
const int BlobProto::kRawDataFieldNumber;
const int BlobProto::kNumFieldNumber;
const int BlobProto::kChannelsFieldNumber;
const int BlobProto::kHeightFieldNumber;
const int BlobProto::kWidthFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
BlobProto::BlobProto()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.BlobProto)
}
void BlobProto::InitAsDefaultInstance() {
shape_ = const_cast< ::opencv_caffe::BlobShape*>(
::opencv_caffe::BlobShape::internal_default_instance());
}
BlobProto::BlobProto(const BlobProto& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.BlobProto)
}
void BlobProto::SharedCtor() {
_cached_size_ = 0;
raw_data_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
shape_ = NULL;
::memset(&raw_data_type_, 0, reinterpret_cast<char*>(&width_) -
reinterpret_cast<char*>(&raw_data_type_) + sizeof(width_));
}
BlobProto::~BlobProto() {
// @@protoc_insertion_point(destructor:opencv_caffe.BlobProto)
SharedDtor();
}
void BlobProto::SharedDtor() {
raw_data_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
if (this != &BlobProto_default_instance_.get()) {
delete shape_;
}
}
void BlobProto::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* BlobProto::descriptor() {
protobuf_AssignDescriptorsOnce();
return BlobProto_descriptor_;
}
const BlobProto& BlobProto::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<BlobProto> BlobProto_default_instance_;
BlobProto* BlobProto::New(::google::protobuf::Arena* arena) const {
BlobProto* n = new BlobProto;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void BlobProto::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.BlobProto)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(BlobProto, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<BlobProto*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
if (_has_bits_[0 / 32] & 225u) {
ZR_(raw_data_type_, num_);
if (has_shape()) {
if (shape_ != NULL) shape_->::opencv_caffe::BlobShape::Clear();
}
if (has_raw_data()) {
raw_data_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
}
ZR_(channels_, width_);
#undef ZR_HELPER_
#undef ZR_
data_.Clear();
diff_.Clear();
double_data_.Clear();
double_diff_.Clear();
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool BlobProto::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.BlobProto)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional int32 num = 1 [default = 0];
case 1: {
if (tag == 8) {
set_has_num();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &num_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_channels;
break;
}
// optional int32 channels = 2 [default = 0];
case 2: {
if (tag == 16) {
parse_channels:
set_has_channels();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &channels_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(24)) goto parse_height;
break;
}
// optional int32 height = 3 [default = 0];
case 3: {
if (tag == 24) {
parse_height:
set_has_height();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &height_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(32)) goto parse_width;
break;
}
// optional int32 width = 4 [default = 0];
case 4: {
if (tag == 32) {
parse_width:
set_has_width();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &width_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(42)) goto parse_data;
break;
}
// repeated float data = 5 [packed = true];
case 5: {
if (tag == 42) {
parse_data:
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, this->mutable_data())));
} else if (tag == 45) {
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitiveNoInline<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
1, 42, input, this->mutable_data())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(50)) goto parse_diff;
break;
}
// repeated float diff = 6 [packed = true];
case 6: {
if (tag == 50) {
parse_diff:
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, this->mutable_diff())));
} else if (tag == 53) {
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitiveNoInline<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
1, 50, input, this->mutable_diff())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(58)) goto parse_shape;
break;
}
// optional .opencv_caffe.BlobShape shape = 7;
case 7: {
if (tag == 58) {
parse_shape:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_shape()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(66)) goto parse_double_data;
break;
}
// repeated double double_data = 8 [packed = true];
case 8: {
if (tag == 66) {
parse_double_data:
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitive<
double, ::google::protobuf::internal::WireFormatLite::TYPE_DOUBLE>(
input, this->mutable_double_data())));
} else if (tag == 65) {
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitiveNoInline<
double, ::google::protobuf::internal::WireFormatLite::TYPE_DOUBLE>(
1, 66, input, this->mutable_double_data())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(74)) goto parse_double_diff;
break;
}
// repeated double double_diff = 9 [packed = true];
case 9: {
if (tag == 74) {
parse_double_diff:
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitive<
double, ::google::protobuf::internal::WireFormatLite::TYPE_DOUBLE>(
input, this->mutable_double_diff())));
} else if (tag == 73) {
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitiveNoInline<
double, ::google::protobuf::internal::WireFormatLite::TYPE_DOUBLE>(
1, 74, input, this->mutable_double_diff())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(80)) goto parse_raw_data_type;
break;
}
// optional .opencv_caffe.Type raw_data_type = 10;
case 10: {
if (tag == 80) {
parse_raw_data_type:
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::Type_IsValid(value)) {
set_raw_data_type(static_cast< ::opencv_caffe::Type >(value));
} else {
mutable_unknown_fields()->AddVarint(10, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectTag(98)) goto parse_raw_data;
break;
}
// optional bytes raw_data = 12 [packed = false];
case 12: {
if (tag == 98) {
parse_raw_data:
DO_(::google::protobuf::internal::WireFormatLite::ReadBytes(
input, this->mutable_raw_data()));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.BlobProto)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.BlobProto)
return false;
#undef DO_
}
void BlobProto::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.BlobProto)
// optional int32 num = 1 [default = 0];
if (has_num()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(1, this->num(), output);
}
// optional int32 channels = 2 [default = 0];
if (has_channels()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->channels(), output);
}
// optional int32 height = 3 [default = 0];
if (has_height()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(3, this->height(), output);
}
// optional int32 width = 4 [default = 0];
if (has_width()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(4, this->width(), output);
}
// repeated float data = 5 [packed = true];
if (this->data_size() > 0) {
::google::protobuf::internal::WireFormatLite::WriteTag(5, ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED, output);
output->WriteVarint32(_data_cached_byte_size_);
}
for (int i = 0; i < this->data_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteFloatNoTag(
this->data(i), output);
}
// repeated float diff = 6 [packed = true];
if (this->diff_size() > 0) {
::google::protobuf::internal::WireFormatLite::WriteTag(6, ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED, output);
output->WriteVarint32(_diff_cached_byte_size_);
}
for (int i = 0; i < this->diff_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteFloatNoTag(
this->diff(i), output);
}
// optional .opencv_caffe.BlobShape shape = 7;
if (has_shape()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
7, *this->shape_, output);
}
// repeated double double_data = 8 [packed = true];
if (this->double_data_size() > 0) {
::google::protobuf::internal::WireFormatLite::WriteTag(8, ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED, output);
output->WriteVarint32(_double_data_cached_byte_size_);
}
for (int i = 0; i < this->double_data_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteDoubleNoTag(
this->double_data(i), output);
}
// repeated double double_diff = 9 [packed = true];
if (this->double_diff_size() > 0) {
::google::protobuf::internal::WireFormatLite::WriteTag(9, ::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED, output);
output->WriteVarint32(_double_diff_cached_byte_size_);
}
for (int i = 0; i < this->double_diff_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteDoubleNoTag(
this->double_diff(i), output);
}
// optional .opencv_caffe.Type raw_data_type = 10;
if (has_raw_data_type()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
10, this->raw_data_type(), output);
}
// optional bytes raw_data = 12 [packed = false];
if (has_raw_data()) {
::google::protobuf::internal::WireFormatLite::WriteBytesMaybeAliased(
12, this->raw_data(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.BlobProto)
}
::google::protobuf::uint8* BlobProto::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.BlobProto)
// optional int32 num = 1 [default = 0];
if (has_num()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(1, this->num(), target);
}
// optional int32 channels = 2 [default = 0];
if (has_channels()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(2, this->channels(), target);
}
// optional int32 height = 3 [default = 0];
if (has_height()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(3, this->height(), target);
}
// optional int32 width = 4 [default = 0];
if (has_width()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(4, this->width(), target);
}
// repeated float data = 5 [packed = true];
if (this->data_size() > 0) {
target = ::google::protobuf::internal::WireFormatLite::WriteTagToArray(
5,
::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED,
target);
target = ::google::protobuf::io::CodedOutputStream::WriteVarint32ToArray(
_data_cached_byte_size_, target);
}
for (int i = 0; i < this->data_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteFloatNoTagToArray(this->data(i), target);
}
// repeated float diff = 6 [packed = true];
if (this->diff_size() > 0) {
target = ::google::protobuf::internal::WireFormatLite::WriteTagToArray(
6,
::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED,
target);
target = ::google::protobuf::io::CodedOutputStream::WriteVarint32ToArray(
_diff_cached_byte_size_, target);
}
for (int i = 0; i < this->diff_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteFloatNoTagToArray(this->diff(i), target);
}
// optional .opencv_caffe.BlobShape shape = 7;
if (has_shape()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
7, *this->shape_, false, target);
}
// repeated double double_data = 8 [packed = true];
if (this->double_data_size() > 0) {
target = ::google::protobuf::internal::WireFormatLite::WriteTagToArray(
8,
::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED,
target);
target = ::google::protobuf::io::CodedOutputStream::WriteVarint32ToArray(
_double_data_cached_byte_size_, target);
}
for (int i = 0; i < this->double_data_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteDoubleNoTagToArray(this->double_data(i), target);
}
// repeated double double_diff = 9 [packed = true];
if (this->double_diff_size() > 0) {
target = ::google::protobuf::internal::WireFormatLite::WriteTagToArray(
9,
::google::protobuf::internal::WireFormatLite::WIRETYPE_LENGTH_DELIMITED,
target);
target = ::google::protobuf::io::CodedOutputStream::WriteVarint32ToArray(
_double_diff_cached_byte_size_, target);
}
for (int i = 0; i < this->double_diff_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteDoubleNoTagToArray(this->double_diff(i), target);
}
// optional .opencv_caffe.Type raw_data_type = 10;
if (has_raw_data_type()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
10, this->raw_data_type(), target);
}
// optional bytes raw_data = 12 [packed = false];
if (has_raw_data()) {
target =
::google::protobuf::internal::WireFormatLite::WriteBytesToArray(
12, this->raw_data(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.BlobProto)
return target;
}
size_t BlobProto::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.BlobProto)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 225u) {
// optional .opencv_caffe.BlobShape shape = 7;
if (has_shape()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->shape_);
}
// optional .opencv_caffe.Type raw_data_type = 10;
if (has_raw_data_type()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->raw_data_type());
}
// optional bytes raw_data = 12 [packed = false];
if (has_raw_data()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::BytesSize(
this->raw_data());
}
// optional int32 num = 1 [default = 0];
if (has_num()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->num());
}
}
if (_has_bits_[8 / 32] & 1792u) {
// optional int32 channels = 2 [default = 0];
if (has_channels()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->channels());
}
// optional int32 height = 3 [default = 0];
if (has_height()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->height());
}
// optional int32 width = 4 [default = 0];
if (has_width()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->width());
}
}
// repeated float data = 5 [packed = true];
{
size_t data_size = 0;
unsigned int count = this->data_size();
data_size = 4UL * count;
if (data_size > 0) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(data_size);
}
int cached_size = ::google::protobuf::internal::ToCachedSize(data_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_data_cached_byte_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
total_size += data_size;
}
// repeated float diff = 6 [packed = true];
{
size_t data_size = 0;
unsigned int count = this->diff_size();
data_size = 4UL * count;
if (data_size > 0) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(data_size);
}
int cached_size = ::google::protobuf::internal::ToCachedSize(data_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_diff_cached_byte_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
total_size += data_size;
}
// repeated double double_data = 8 [packed = true];
{
size_t data_size = 0;
unsigned int count = this->double_data_size();
data_size = 8UL * count;
if (data_size > 0) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(data_size);
}
int cached_size = ::google::protobuf::internal::ToCachedSize(data_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_double_data_cached_byte_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
total_size += data_size;
}
// repeated double double_diff = 9 [packed = true];
{
size_t data_size = 0;
unsigned int count = this->double_diff_size();
data_size = 8UL * count;
if (data_size > 0) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(data_size);
}
int cached_size = ::google::protobuf::internal::ToCachedSize(data_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_double_diff_cached_byte_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
total_size += data_size;
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void BlobProto::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.BlobProto)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const BlobProto* source =
::google::protobuf::internal::DynamicCastToGenerated<const BlobProto>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.BlobProto)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.BlobProto)
UnsafeMergeFrom(*source);
}
}
void BlobProto::MergeFrom(const BlobProto& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.BlobProto)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void BlobProto::UnsafeMergeFrom(const BlobProto& from) {
GOOGLE_DCHECK(&from != this);
data_.UnsafeMergeFrom(from.data_);
diff_.UnsafeMergeFrom(from.diff_);
double_data_.UnsafeMergeFrom(from.double_data_);
double_diff_.UnsafeMergeFrom(from.double_diff_);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_shape()) {
mutable_shape()->::opencv_caffe::BlobShape::MergeFrom(from.shape());
}
if (from.has_raw_data_type()) {
set_raw_data_type(from.raw_data_type());
}
if (from.has_raw_data()) {
set_has_raw_data();
raw_data_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.raw_data_);
}
if (from.has_num()) {
set_num(from.num());
}
}
if (from._has_bits_[8 / 32] & (0xffu << (8 % 32))) {
if (from.has_channels()) {
set_channels(from.channels());
}
if (from.has_height()) {
set_height(from.height());
}
if (from.has_width()) {
set_width(from.width());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void BlobProto::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.BlobProto)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void BlobProto::CopyFrom(const BlobProto& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.BlobProto)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool BlobProto::IsInitialized() const {
return true;
}
void BlobProto::Swap(BlobProto* other) {
if (other == this) return;
InternalSwap(other);
}
void BlobProto::InternalSwap(BlobProto* other) {
std::swap(shape_, other->shape_);
data_.UnsafeArenaSwap(&other->data_);
diff_.UnsafeArenaSwap(&other->diff_);
double_data_.UnsafeArenaSwap(&other->double_data_);
double_diff_.UnsafeArenaSwap(&other->double_diff_);
std::swap(raw_data_type_, other->raw_data_type_);
raw_data_.Swap(&other->raw_data_);
std::swap(num_, other->num_);
std::swap(channels_, other->channels_);
std::swap(height_, other->height_);
std::swap(width_, other->width_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata BlobProto::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = BlobProto_descriptor_;
metadata.reflection = BlobProto_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// BlobProto
// optional .opencv_caffe.BlobShape shape = 7;
bool BlobProto::has_shape() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void BlobProto::set_has_shape() {
_has_bits_[0] |= 0x00000001u;
}
void BlobProto::clear_has_shape() {
_has_bits_[0] &= ~0x00000001u;
}
void BlobProto::clear_shape() {
if (shape_ != NULL) shape_->::opencv_caffe::BlobShape::Clear();
clear_has_shape();
}
const ::opencv_caffe::BlobShape& BlobProto::shape() const {
// @@protoc_insertion_point(field_get:opencv_caffe.BlobProto.shape)
return shape_ != NULL ? *shape_
: *::opencv_caffe::BlobShape::internal_default_instance();
}
::opencv_caffe::BlobShape* BlobProto::mutable_shape() {
set_has_shape();
if (shape_ == NULL) {
shape_ = new ::opencv_caffe::BlobShape;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.BlobProto.shape)
return shape_;
}
::opencv_caffe::BlobShape* BlobProto::release_shape() {
// @@protoc_insertion_point(field_release:opencv_caffe.BlobProto.shape)
clear_has_shape();
::opencv_caffe::BlobShape* temp = shape_;
shape_ = NULL;
return temp;
}
void BlobProto::set_allocated_shape(::opencv_caffe::BlobShape* shape) {
delete shape_;
shape_ = shape;
if (shape) {
set_has_shape();
} else {
clear_has_shape();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.BlobProto.shape)
}
// repeated float data = 5 [packed = true];
int BlobProto::data_size() const {
return data_.size();
}
void BlobProto::clear_data() {
data_.Clear();
}
float BlobProto::data(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.BlobProto.data)
return data_.Get(index);
}
void BlobProto::set_data(int index, float value) {
data_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.BlobProto.data)
}
void BlobProto::add_data(float value) {
data_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.BlobProto.data)
}
const ::google::protobuf::RepeatedField< float >&
BlobProto::data() const {
// @@protoc_insertion_point(field_list:opencv_caffe.BlobProto.data)
return data_;
}
::google::protobuf::RepeatedField< float >*
BlobProto::mutable_data() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.BlobProto.data)
return &data_;
}
// repeated float diff = 6 [packed = true];
int BlobProto::diff_size() const {
return diff_.size();
}
void BlobProto::clear_diff() {
diff_.Clear();
}
float BlobProto::diff(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.BlobProto.diff)
return diff_.Get(index);
}
void BlobProto::set_diff(int index, float value) {
diff_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.BlobProto.diff)
}
void BlobProto::add_diff(float value) {
diff_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.BlobProto.diff)
}
const ::google::protobuf::RepeatedField< float >&
BlobProto::diff() const {
// @@protoc_insertion_point(field_list:opencv_caffe.BlobProto.diff)
return diff_;
}
::google::protobuf::RepeatedField< float >*
BlobProto::mutable_diff() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.BlobProto.diff)
return &diff_;
}
// repeated double double_data = 8 [packed = true];
int BlobProto::double_data_size() const {
return double_data_.size();
}
void BlobProto::clear_double_data() {
double_data_.Clear();
}
double BlobProto::double_data(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.BlobProto.double_data)
return double_data_.Get(index);
}
void BlobProto::set_double_data(int index, double value) {
double_data_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.BlobProto.double_data)
}
void BlobProto::add_double_data(double value) {
double_data_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.BlobProto.double_data)
}
const ::google::protobuf::RepeatedField< double >&
BlobProto::double_data() const {
// @@protoc_insertion_point(field_list:opencv_caffe.BlobProto.double_data)
return double_data_;
}
::google::protobuf::RepeatedField< double >*
BlobProto::mutable_double_data() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.BlobProto.double_data)
return &double_data_;
}
// repeated double double_diff = 9 [packed = true];
int BlobProto::double_diff_size() const {
return double_diff_.size();
}
void BlobProto::clear_double_diff() {
double_diff_.Clear();
}
double BlobProto::double_diff(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.BlobProto.double_diff)
return double_diff_.Get(index);
}
void BlobProto::set_double_diff(int index, double value) {
double_diff_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.BlobProto.double_diff)
}
void BlobProto::add_double_diff(double value) {
double_diff_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.BlobProto.double_diff)
}
const ::google::protobuf::RepeatedField< double >&
BlobProto::double_diff() const {
// @@protoc_insertion_point(field_list:opencv_caffe.BlobProto.double_diff)
return double_diff_;
}
::google::protobuf::RepeatedField< double >*
BlobProto::mutable_double_diff() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.BlobProto.double_diff)
return &double_diff_;
}
// optional .opencv_caffe.Type raw_data_type = 10;
bool BlobProto::has_raw_data_type() const {
return (_has_bits_[0] & 0x00000020u) != 0;
}
void BlobProto::set_has_raw_data_type() {
_has_bits_[0] |= 0x00000020u;
}
void BlobProto::clear_has_raw_data_type() {
_has_bits_[0] &= ~0x00000020u;
}
void BlobProto::clear_raw_data_type() {
raw_data_type_ = 0;
clear_has_raw_data_type();
}
::opencv_caffe::Type BlobProto::raw_data_type() const {
// @@protoc_insertion_point(field_get:opencv_caffe.BlobProto.raw_data_type)
return static_cast< ::opencv_caffe::Type >(raw_data_type_);
}
void BlobProto::set_raw_data_type(::opencv_caffe::Type value) {
assert(::opencv_caffe::Type_IsValid(value));
set_has_raw_data_type();
raw_data_type_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.BlobProto.raw_data_type)
}
// optional bytes raw_data = 12 [packed = false];
bool BlobProto::has_raw_data() const {
return (_has_bits_[0] & 0x00000040u) != 0;
}
void BlobProto::set_has_raw_data() {
_has_bits_[0] |= 0x00000040u;
}
void BlobProto::clear_has_raw_data() {
_has_bits_[0] &= ~0x00000040u;
}
void BlobProto::clear_raw_data() {
raw_data_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_raw_data();
}
const ::std::string& BlobProto::raw_data() const {
// @@protoc_insertion_point(field_get:opencv_caffe.BlobProto.raw_data)
return raw_data_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void BlobProto::set_raw_data(const ::std::string& value) {
set_has_raw_data();
raw_data_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.BlobProto.raw_data)
}
void BlobProto::set_raw_data(const char* value) {
set_has_raw_data();
raw_data_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.BlobProto.raw_data)
}
void BlobProto::set_raw_data(const void* value, size_t size) {
set_has_raw_data();
raw_data_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.BlobProto.raw_data)
}
::std::string* BlobProto::mutable_raw_data() {
set_has_raw_data();
// @@protoc_insertion_point(field_mutable:opencv_caffe.BlobProto.raw_data)
return raw_data_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* BlobProto::release_raw_data() {
// @@protoc_insertion_point(field_release:opencv_caffe.BlobProto.raw_data)
clear_has_raw_data();
return raw_data_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void BlobProto::set_allocated_raw_data(::std::string* raw_data) {
if (raw_data != NULL) {
set_has_raw_data();
} else {
clear_has_raw_data();
}
raw_data_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), raw_data);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.BlobProto.raw_data)
}
// optional int32 num = 1 [default = 0];
bool BlobProto::has_num() const {
return (_has_bits_[0] & 0x00000080u) != 0;
}
void BlobProto::set_has_num() {
_has_bits_[0] |= 0x00000080u;
}
void BlobProto::clear_has_num() {
_has_bits_[0] &= ~0x00000080u;
}
void BlobProto::clear_num() {
num_ = 0;
clear_has_num();
}
::google::protobuf::int32 BlobProto::num() const {
// @@protoc_insertion_point(field_get:opencv_caffe.BlobProto.num)
return num_;
}
void BlobProto::set_num(::google::protobuf::int32 value) {
set_has_num();
num_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.BlobProto.num)
}
// optional int32 channels = 2 [default = 0];
bool BlobProto::has_channels() const {
return (_has_bits_[0] & 0x00000100u) != 0;
}
void BlobProto::set_has_channels() {
_has_bits_[0] |= 0x00000100u;
}
void BlobProto::clear_has_channels() {
_has_bits_[0] &= ~0x00000100u;
}
void BlobProto::clear_channels() {
channels_ = 0;
clear_has_channels();
}
::google::protobuf::int32 BlobProto::channels() const {
// @@protoc_insertion_point(field_get:opencv_caffe.BlobProto.channels)
return channels_;
}
void BlobProto::set_channels(::google::protobuf::int32 value) {
set_has_channels();
channels_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.BlobProto.channels)
}
// optional int32 height = 3 [default = 0];
bool BlobProto::has_height() const {
return (_has_bits_[0] & 0x00000200u) != 0;
}
void BlobProto::set_has_height() {
_has_bits_[0] |= 0x00000200u;
}
void BlobProto::clear_has_height() {
_has_bits_[0] &= ~0x00000200u;
}
void BlobProto::clear_height() {
height_ = 0;
clear_has_height();
}
::google::protobuf::int32 BlobProto::height() const {
// @@protoc_insertion_point(field_get:opencv_caffe.BlobProto.height)
return height_;
}
void BlobProto::set_height(::google::protobuf::int32 value) {
set_has_height();
height_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.BlobProto.height)
}
// optional int32 width = 4 [default = 0];
bool BlobProto::has_width() const {
return (_has_bits_[0] & 0x00000400u) != 0;
}
void BlobProto::set_has_width() {
_has_bits_[0] |= 0x00000400u;
}
void BlobProto::clear_has_width() {
_has_bits_[0] &= ~0x00000400u;
}
void BlobProto::clear_width() {
width_ = 0;
clear_has_width();
}
::google::protobuf::int32 BlobProto::width() const {
// @@protoc_insertion_point(field_get:opencv_caffe.BlobProto.width)
return width_;
}
void BlobProto::set_width(::google::protobuf::int32 value) {
set_has_width();
width_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.BlobProto.width)
}
inline const BlobProto* BlobProto::internal_default_instance() {
return &BlobProto_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int BlobProtoVector::kBlobsFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
BlobProtoVector::BlobProtoVector()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.BlobProtoVector)
}
void BlobProtoVector::InitAsDefaultInstance() {
}
BlobProtoVector::BlobProtoVector(const BlobProtoVector& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.BlobProtoVector)
}
void BlobProtoVector::SharedCtor() {
_cached_size_ = 0;
}
BlobProtoVector::~BlobProtoVector() {
// @@protoc_insertion_point(destructor:opencv_caffe.BlobProtoVector)
SharedDtor();
}
void BlobProtoVector::SharedDtor() {
}
void BlobProtoVector::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* BlobProtoVector::descriptor() {
protobuf_AssignDescriptorsOnce();
return BlobProtoVector_descriptor_;
}
const BlobProtoVector& BlobProtoVector::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<BlobProtoVector> BlobProtoVector_default_instance_;
BlobProtoVector* BlobProtoVector::New(::google::protobuf::Arena* arena) const {
BlobProtoVector* n = new BlobProtoVector;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void BlobProtoVector::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.BlobProtoVector)
blobs_.Clear();
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool BlobProtoVector::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.BlobProtoVector)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// repeated .opencv_caffe.BlobProto blobs = 1;
case 1: {
if (tag == 10) {
DO_(input->IncrementRecursionDepth());
parse_loop_blobs:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtualNoRecursionDepth(
input, add_blobs()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(10)) goto parse_loop_blobs;
input->UnsafeDecrementRecursionDepth();
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.BlobProtoVector)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.BlobProtoVector)
return false;
#undef DO_
}
void BlobProtoVector::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.BlobProtoVector)
// repeated .opencv_caffe.BlobProto blobs = 1;
for (unsigned int i = 0, n = this->blobs_size(); i < n; i++) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
1, this->blobs(i), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.BlobProtoVector)
}
::google::protobuf::uint8* BlobProtoVector::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.BlobProtoVector)
// repeated .opencv_caffe.BlobProto blobs = 1;
for (unsigned int i = 0, n = this->blobs_size(); i < n; i++) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
1, this->blobs(i), false, target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.BlobProtoVector)
return target;
}
size_t BlobProtoVector::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.BlobProtoVector)
size_t total_size = 0;
// repeated .opencv_caffe.BlobProto blobs = 1;
{
unsigned int count = this->blobs_size();
total_size += 1UL * count;
for (unsigned int i = 0; i < count; i++) {
total_size +=
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
this->blobs(i));
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void BlobProtoVector::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.BlobProtoVector)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const BlobProtoVector* source =
::google::protobuf::internal::DynamicCastToGenerated<const BlobProtoVector>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.BlobProtoVector)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.BlobProtoVector)
UnsafeMergeFrom(*source);
}
}
void BlobProtoVector::MergeFrom(const BlobProtoVector& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.BlobProtoVector)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void BlobProtoVector::UnsafeMergeFrom(const BlobProtoVector& from) {
GOOGLE_DCHECK(&from != this);
blobs_.MergeFrom(from.blobs_);
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void BlobProtoVector::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.BlobProtoVector)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void BlobProtoVector::CopyFrom(const BlobProtoVector& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.BlobProtoVector)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool BlobProtoVector::IsInitialized() const {
return true;
}
void BlobProtoVector::Swap(BlobProtoVector* other) {
if (other == this) return;
InternalSwap(other);
}
void BlobProtoVector::InternalSwap(BlobProtoVector* other) {
blobs_.UnsafeArenaSwap(&other->blobs_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata BlobProtoVector::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = BlobProtoVector_descriptor_;
metadata.reflection = BlobProtoVector_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// BlobProtoVector
// repeated .opencv_caffe.BlobProto blobs = 1;
int BlobProtoVector::blobs_size() const {
return blobs_.size();
}
void BlobProtoVector::clear_blobs() {
blobs_.Clear();
}
const ::opencv_caffe::BlobProto& BlobProtoVector::blobs(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.BlobProtoVector.blobs)
return blobs_.Get(index);
}
::opencv_caffe::BlobProto* BlobProtoVector::mutable_blobs(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.BlobProtoVector.blobs)
return blobs_.Mutable(index);
}
::opencv_caffe::BlobProto* BlobProtoVector::add_blobs() {
// @@protoc_insertion_point(field_add:opencv_caffe.BlobProtoVector.blobs)
return blobs_.Add();
}
::google::protobuf::RepeatedPtrField< ::opencv_caffe::BlobProto >*
BlobProtoVector::mutable_blobs() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.BlobProtoVector.blobs)
return &blobs_;
}
const ::google::protobuf::RepeatedPtrField< ::opencv_caffe::BlobProto >&
BlobProtoVector::blobs() const {
// @@protoc_insertion_point(field_list:opencv_caffe.BlobProtoVector.blobs)
return blobs_;
}
inline const BlobProtoVector* BlobProtoVector::internal_default_instance() {
return &BlobProtoVector_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int PermuteParameter::kOrderFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
PermuteParameter::PermuteParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.PermuteParameter)
}
void PermuteParameter::InitAsDefaultInstance() {
}
PermuteParameter::PermuteParameter(const PermuteParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.PermuteParameter)
}
void PermuteParameter::SharedCtor() {
_cached_size_ = 0;
}
PermuteParameter::~PermuteParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.PermuteParameter)
SharedDtor();
}
void PermuteParameter::SharedDtor() {
}
void PermuteParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* PermuteParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return PermuteParameter_descriptor_;
}
const PermuteParameter& PermuteParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<PermuteParameter> PermuteParameter_default_instance_;
PermuteParameter* PermuteParameter::New(::google::protobuf::Arena* arena) const {
PermuteParameter* n = new PermuteParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void PermuteParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.PermuteParameter)
order_.Clear();
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool PermuteParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.PermuteParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// repeated uint32 order = 1;
case 1: {
if (tag == 8) {
parse_order:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
1, 8, input, this->mutable_order())));
} else if (tag == 10) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, this->mutable_order())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(8)) goto parse_order;
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.PermuteParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.PermuteParameter)
return false;
#undef DO_
}
void PermuteParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.PermuteParameter)
// repeated uint32 order = 1;
for (int i = 0; i < this->order_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(
1, this->order(i), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.PermuteParameter)
}
::google::protobuf::uint8* PermuteParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.PermuteParameter)
// repeated uint32 order = 1;
for (int i = 0; i < this->order_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteUInt32ToArray(1, this->order(i), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.PermuteParameter)
return target;
}
size_t PermuteParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.PermuteParameter)
size_t total_size = 0;
// repeated uint32 order = 1;
{
size_t data_size = 0;
unsigned int count = this->order_size();
for (unsigned int i = 0; i < count; i++) {
data_size += ::google::protobuf::internal::WireFormatLite::
UInt32Size(this->order(i));
}
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->order_size());
total_size += data_size;
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void PermuteParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.PermuteParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const PermuteParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const PermuteParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.PermuteParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.PermuteParameter)
UnsafeMergeFrom(*source);
}
}
void PermuteParameter::MergeFrom(const PermuteParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.PermuteParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void PermuteParameter::UnsafeMergeFrom(const PermuteParameter& from) {
GOOGLE_DCHECK(&from != this);
order_.UnsafeMergeFrom(from.order_);
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void PermuteParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.PermuteParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void PermuteParameter::CopyFrom(const PermuteParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.PermuteParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool PermuteParameter::IsInitialized() const {
return true;
}
void PermuteParameter::Swap(PermuteParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void PermuteParameter::InternalSwap(PermuteParameter* other) {
order_.UnsafeArenaSwap(&other->order_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata PermuteParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = PermuteParameter_descriptor_;
metadata.reflection = PermuteParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// PermuteParameter
// repeated uint32 order = 1;
int PermuteParameter::order_size() const {
return order_.size();
}
void PermuteParameter::clear_order() {
order_.Clear();
}
::google::protobuf::uint32 PermuteParameter::order(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.PermuteParameter.order)
return order_.Get(index);
}
void PermuteParameter::set_order(int index, ::google::protobuf::uint32 value) {
order_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.PermuteParameter.order)
}
void PermuteParameter::add_order(::google::protobuf::uint32 value) {
order_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.PermuteParameter.order)
}
const ::google::protobuf::RepeatedField< ::google::protobuf::uint32 >&
PermuteParameter::order() const {
// @@protoc_insertion_point(field_list:opencv_caffe.PermuteParameter.order)
return order_;
}
::google::protobuf::RepeatedField< ::google::protobuf::uint32 >*
PermuteParameter::mutable_order() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.PermuteParameter.order)
return &order_;
}
inline const PermuteParameter* PermuteParameter::internal_default_instance() {
return &PermuteParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int NormalizeBBoxParameter::kAcrossSpatialFieldNumber;
const int NormalizeBBoxParameter::kScaleFillerFieldNumber;
const int NormalizeBBoxParameter::kChannelSharedFieldNumber;
const int NormalizeBBoxParameter::kEpsFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
NormalizeBBoxParameter::NormalizeBBoxParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.NormalizeBBoxParameter)
}
void NormalizeBBoxParameter::InitAsDefaultInstance() {
scale_filler_ = const_cast< ::opencv_caffe::FillerParameter*>(
::opencv_caffe::FillerParameter::internal_default_instance());
}
NormalizeBBoxParameter::NormalizeBBoxParameter(const NormalizeBBoxParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.NormalizeBBoxParameter)
}
void NormalizeBBoxParameter::SharedCtor() {
_cached_size_ = 0;
scale_filler_ = NULL;
across_spatial_ = true;
channel_shared_ = true;
eps_ = 1e-10f;
}
NormalizeBBoxParameter::~NormalizeBBoxParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.NormalizeBBoxParameter)
SharedDtor();
}
void NormalizeBBoxParameter::SharedDtor() {
if (this != &NormalizeBBoxParameter_default_instance_.get()) {
delete scale_filler_;
}
}
void NormalizeBBoxParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* NormalizeBBoxParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return NormalizeBBoxParameter_descriptor_;
}
const NormalizeBBoxParameter& NormalizeBBoxParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<NormalizeBBoxParameter> NormalizeBBoxParameter_default_instance_;
NormalizeBBoxParameter* NormalizeBBoxParameter::New(::google::protobuf::Arena* arena) const {
NormalizeBBoxParameter* n = new NormalizeBBoxParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void NormalizeBBoxParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.NormalizeBBoxParameter)
if (_has_bits_[0 / 32] & 15u) {
across_spatial_ = true;
if (has_scale_filler()) {
if (scale_filler_ != NULL) scale_filler_->::opencv_caffe::FillerParameter::Clear();
}
channel_shared_ = true;
eps_ = 1e-10f;
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool NormalizeBBoxParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.NormalizeBBoxParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional bool across_spatial = 1 [default = true];
case 1: {
if (tag == 8) {
set_has_across_spatial();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &across_spatial_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(18)) goto parse_scale_filler;
break;
}
// optional .opencv_caffe.FillerParameter scale_filler = 2;
case 2: {
if (tag == 18) {
parse_scale_filler:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_scale_filler()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(24)) goto parse_channel_shared;
break;
}
// optional bool channel_shared = 3 [default = true];
case 3: {
if (tag == 24) {
parse_channel_shared:
set_has_channel_shared();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &channel_shared_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(37)) goto parse_eps;
break;
}
// optional float eps = 4 [default = 1e-10];
case 4: {
if (tag == 37) {
parse_eps:
set_has_eps();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &eps_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.NormalizeBBoxParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.NormalizeBBoxParameter)
return false;
#undef DO_
}
void NormalizeBBoxParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.NormalizeBBoxParameter)
// optional bool across_spatial = 1 [default = true];
if (has_across_spatial()) {
::google::protobuf::internal::WireFormatLite::WriteBool(1, this->across_spatial(), output);
}
// optional .opencv_caffe.FillerParameter scale_filler = 2;
if (has_scale_filler()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
2, *this->scale_filler_, output);
}
// optional bool channel_shared = 3 [default = true];
if (has_channel_shared()) {
::google::protobuf::internal::WireFormatLite::WriteBool(3, this->channel_shared(), output);
}
// optional float eps = 4 [default = 1e-10];
if (has_eps()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(4, this->eps(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.NormalizeBBoxParameter)
}
::google::protobuf::uint8* NormalizeBBoxParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.NormalizeBBoxParameter)
// optional bool across_spatial = 1 [default = true];
if (has_across_spatial()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(1, this->across_spatial(), target);
}
// optional .opencv_caffe.FillerParameter scale_filler = 2;
if (has_scale_filler()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
2, *this->scale_filler_, false, target);
}
// optional bool channel_shared = 3 [default = true];
if (has_channel_shared()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(3, this->channel_shared(), target);
}
// optional float eps = 4 [default = 1e-10];
if (has_eps()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(4, this->eps(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.NormalizeBBoxParameter)
return target;
}
size_t NormalizeBBoxParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.NormalizeBBoxParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 15u) {
// optional bool across_spatial = 1 [default = true];
if (has_across_spatial()) {
total_size += 1 + 1;
}
// optional .opencv_caffe.FillerParameter scale_filler = 2;
if (has_scale_filler()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->scale_filler_);
}
// optional bool channel_shared = 3 [default = true];
if (has_channel_shared()) {
total_size += 1 + 1;
}
// optional float eps = 4 [default = 1e-10];
if (has_eps()) {
total_size += 1 + 4;
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void NormalizeBBoxParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.NormalizeBBoxParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const NormalizeBBoxParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const NormalizeBBoxParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.NormalizeBBoxParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.NormalizeBBoxParameter)
UnsafeMergeFrom(*source);
}
}
void NormalizeBBoxParameter::MergeFrom(const NormalizeBBoxParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.NormalizeBBoxParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void NormalizeBBoxParameter::UnsafeMergeFrom(const NormalizeBBoxParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_across_spatial()) {
set_across_spatial(from.across_spatial());
}
if (from.has_scale_filler()) {
mutable_scale_filler()->::opencv_caffe::FillerParameter::MergeFrom(from.scale_filler());
}
if (from.has_channel_shared()) {
set_channel_shared(from.channel_shared());
}
if (from.has_eps()) {
set_eps(from.eps());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void NormalizeBBoxParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.NormalizeBBoxParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void NormalizeBBoxParameter::CopyFrom(const NormalizeBBoxParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.NormalizeBBoxParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool NormalizeBBoxParameter::IsInitialized() const {
return true;
}
void NormalizeBBoxParameter::Swap(NormalizeBBoxParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void NormalizeBBoxParameter::InternalSwap(NormalizeBBoxParameter* other) {
std::swap(across_spatial_, other->across_spatial_);
std::swap(scale_filler_, other->scale_filler_);
std::swap(channel_shared_, other->channel_shared_);
std::swap(eps_, other->eps_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata NormalizeBBoxParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = NormalizeBBoxParameter_descriptor_;
metadata.reflection = NormalizeBBoxParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// NormalizeBBoxParameter
// optional bool across_spatial = 1 [default = true];
bool NormalizeBBoxParameter::has_across_spatial() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void NormalizeBBoxParameter::set_has_across_spatial() {
_has_bits_[0] |= 0x00000001u;
}
void NormalizeBBoxParameter::clear_has_across_spatial() {
_has_bits_[0] &= ~0x00000001u;
}
void NormalizeBBoxParameter::clear_across_spatial() {
across_spatial_ = true;
clear_has_across_spatial();
}
bool NormalizeBBoxParameter::across_spatial() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NormalizeBBoxParameter.across_spatial)
return across_spatial_;
}
void NormalizeBBoxParameter::set_across_spatial(bool value) {
set_has_across_spatial();
across_spatial_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.NormalizeBBoxParameter.across_spatial)
}
// optional .opencv_caffe.FillerParameter scale_filler = 2;
bool NormalizeBBoxParameter::has_scale_filler() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void NormalizeBBoxParameter::set_has_scale_filler() {
_has_bits_[0] |= 0x00000002u;
}
void NormalizeBBoxParameter::clear_has_scale_filler() {
_has_bits_[0] &= ~0x00000002u;
}
void NormalizeBBoxParameter::clear_scale_filler() {
if (scale_filler_ != NULL) scale_filler_->::opencv_caffe::FillerParameter::Clear();
clear_has_scale_filler();
}
const ::opencv_caffe::FillerParameter& NormalizeBBoxParameter::scale_filler() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NormalizeBBoxParameter.scale_filler)
return scale_filler_ != NULL ? *scale_filler_
: *::opencv_caffe::FillerParameter::internal_default_instance();
}
::opencv_caffe::FillerParameter* NormalizeBBoxParameter::mutable_scale_filler() {
set_has_scale_filler();
if (scale_filler_ == NULL) {
scale_filler_ = new ::opencv_caffe::FillerParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.NormalizeBBoxParameter.scale_filler)
return scale_filler_;
}
::opencv_caffe::FillerParameter* NormalizeBBoxParameter::release_scale_filler() {
// @@protoc_insertion_point(field_release:opencv_caffe.NormalizeBBoxParameter.scale_filler)
clear_has_scale_filler();
::opencv_caffe::FillerParameter* temp = scale_filler_;
scale_filler_ = NULL;
return temp;
}
void NormalizeBBoxParameter::set_allocated_scale_filler(::opencv_caffe::FillerParameter* scale_filler) {
delete scale_filler_;
scale_filler_ = scale_filler;
if (scale_filler) {
set_has_scale_filler();
} else {
clear_has_scale_filler();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.NormalizeBBoxParameter.scale_filler)
}
// optional bool channel_shared = 3 [default = true];
bool NormalizeBBoxParameter::has_channel_shared() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void NormalizeBBoxParameter::set_has_channel_shared() {
_has_bits_[0] |= 0x00000004u;
}
void NormalizeBBoxParameter::clear_has_channel_shared() {
_has_bits_[0] &= ~0x00000004u;
}
void NormalizeBBoxParameter::clear_channel_shared() {
channel_shared_ = true;
clear_has_channel_shared();
}
bool NormalizeBBoxParameter::channel_shared() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NormalizeBBoxParameter.channel_shared)
return channel_shared_;
}
void NormalizeBBoxParameter::set_channel_shared(bool value) {
set_has_channel_shared();
channel_shared_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.NormalizeBBoxParameter.channel_shared)
}
// optional float eps = 4 [default = 1e-10];
bool NormalizeBBoxParameter::has_eps() const {
return (_has_bits_[0] & 0x00000008u) != 0;
}
void NormalizeBBoxParameter::set_has_eps() {
_has_bits_[0] |= 0x00000008u;
}
void NormalizeBBoxParameter::clear_has_eps() {
_has_bits_[0] &= ~0x00000008u;
}
void NormalizeBBoxParameter::clear_eps() {
eps_ = 1e-10f;
clear_has_eps();
}
float NormalizeBBoxParameter::eps() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NormalizeBBoxParameter.eps)
return eps_;
}
void NormalizeBBoxParameter::set_eps(float value) {
set_has_eps();
eps_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.NormalizeBBoxParameter.eps)
}
inline const NormalizeBBoxParameter* NormalizeBBoxParameter::internal_default_instance() {
return &NormalizeBBoxParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
const ::google::protobuf::EnumDescriptor* PriorBoxParameter_CodeType_descriptor() {
protobuf_AssignDescriptorsOnce();
return PriorBoxParameter_CodeType_descriptor_;
}
bool PriorBoxParameter_CodeType_IsValid(int value) {
switch (value) {
case 1:
case 2:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const PriorBoxParameter_CodeType PriorBoxParameter::CORNER;
const PriorBoxParameter_CodeType PriorBoxParameter::CENTER_SIZE;
const PriorBoxParameter_CodeType PriorBoxParameter::CodeType_MIN;
const PriorBoxParameter_CodeType PriorBoxParameter::CodeType_MAX;
const int PriorBoxParameter::CodeType_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int PriorBoxParameter::kMinSizeFieldNumber;
const int PriorBoxParameter::kMaxSizeFieldNumber;
const int PriorBoxParameter::kAspectRatioFieldNumber;
const int PriorBoxParameter::kFlipFieldNumber;
const int PriorBoxParameter::kClipFieldNumber;
const int PriorBoxParameter::kVarianceFieldNumber;
const int PriorBoxParameter::kImgSizeFieldNumber;
const int PriorBoxParameter::kImgHFieldNumber;
const int PriorBoxParameter::kImgWFieldNumber;
const int PriorBoxParameter::kStepFieldNumber;
const int PriorBoxParameter::kStepHFieldNumber;
const int PriorBoxParameter::kStepWFieldNumber;
const int PriorBoxParameter::kOffsetFieldNumber;
const int PriorBoxParameter::kOffsetHFieldNumber;
const int PriorBoxParameter::kOffsetWFieldNumber;
const int PriorBoxParameter::kWidthFieldNumber;
const int PriorBoxParameter::kHeightFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
PriorBoxParameter::PriorBoxParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.PriorBoxParameter)
}
void PriorBoxParameter::InitAsDefaultInstance() {
}
PriorBoxParameter::PriorBoxParameter(const PriorBoxParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.PriorBoxParameter)
}
void PriorBoxParameter::SharedCtor() {
_cached_size_ = 0;
::memset(&min_size_, 0, reinterpret_cast<char*>(&step_w_) -
reinterpret_cast<char*>(&min_size_) + sizeof(step_w_));
flip_ = true;
clip_ = true;
offset_ = 0.5f;
}
PriorBoxParameter::~PriorBoxParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.PriorBoxParameter)
SharedDtor();
}
void PriorBoxParameter::SharedDtor() {
}
void PriorBoxParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* PriorBoxParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return PriorBoxParameter_descriptor_;
}
const PriorBoxParameter& PriorBoxParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<PriorBoxParameter> PriorBoxParameter_default_instance_;
PriorBoxParameter* PriorBoxParameter::New(::google::protobuf::Arena* arena) const {
PriorBoxParameter* n = new PriorBoxParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void PriorBoxParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.PriorBoxParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(PriorBoxParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<PriorBoxParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
if (_has_bits_[0 / 32] & 219u) {
ZR_(min_size_, img_h_);
flip_ = true;
clip_ = true;
}
if (_has_bits_[8 / 32] & 7936u) {
ZR_(img_w_, step_w_);
offset_ = 0.5f;
}
#undef ZR_HELPER_
#undef ZR_
aspect_ratio_.Clear();
variance_.Clear();
offset_h_.Clear();
offset_w_.Clear();
width_.Clear();
height_.Clear();
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool PriorBoxParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.PriorBoxParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(16383);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional float min_size = 1;
case 1: {
if (tag == 13) {
set_has_min_size();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &min_size_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(21)) goto parse_max_size;
break;
}
// optional float max_size = 2;
case 2: {
if (tag == 21) {
parse_max_size:
set_has_max_size();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &max_size_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(29)) goto parse_aspect_ratio;
break;
}
// repeated float aspect_ratio = 3;
case 3: {
if (tag == 29) {
parse_aspect_ratio:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
1, 29, input, this->mutable_aspect_ratio())));
} else if (tag == 26) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, this->mutable_aspect_ratio())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(29)) goto parse_aspect_ratio;
if (input->ExpectTag(32)) goto parse_flip;
break;
}
// optional bool flip = 4 [default = true];
case 4: {
if (tag == 32) {
parse_flip:
set_has_flip();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &flip_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(40)) goto parse_clip;
break;
}
// optional bool clip = 5 [default = true];
case 5: {
if (tag == 40) {
parse_clip:
set_has_clip();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &clip_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(53)) goto parse_variance;
break;
}
// repeated float variance = 6;
case 6: {
if (tag == 53) {
parse_variance:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
1, 53, input, this->mutable_variance())));
} else if (tag == 50) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, this->mutable_variance())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(53)) goto parse_variance;
if (input->ExpectTag(56)) goto parse_img_size;
break;
}
// optional uint32 img_size = 7;
case 7: {
if (tag == 56) {
parse_img_size:
set_has_img_size();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &img_size_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(64)) goto parse_img_h;
break;
}
// optional uint32 img_h = 8;
case 8: {
if (tag == 64) {
parse_img_h:
set_has_img_h();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &img_h_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(72)) goto parse_img_w;
break;
}
// optional uint32 img_w = 9;
case 9: {
if (tag == 72) {
parse_img_w:
set_has_img_w();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &img_w_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(85)) goto parse_step;
break;
}
// optional float step = 10;
case 10: {
if (tag == 85) {
parse_step:
set_has_step();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &step_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(93)) goto parse_step_h;
break;
}
// optional float step_h = 11;
case 11: {
if (tag == 93) {
parse_step_h:
set_has_step_h();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &step_h_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(101)) goto parse_step_w;
break;
}
// optional float step_w = 12;
case 12: {
if (tag == 101) {
parse_step_w:
set_has_step_w();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &step_w_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(109)) goto parse_offset;
break;
}
// optional float offset = 13 [default = 0.5];
case 13: {
if (tag == 109) {
parse_offset:
set_has_offset();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &offset_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(117)) goto parse_offset_h;
break;
}
// repeated float offset_h = 14;
case 14: {
if (tag == 117) {
parse_offset_h:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
1, 117, input, this->mutable_offset_h())));
} else if (tag == 114) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, this->mutable_offset_h())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(117)) goto parse_offset_h;
if (input->ExpectTag(125)) goto parse_offset_w;
break;
}
// repeated float offset_w = 15;
case 15: {
if (tag == 125) {
parse_offset_w:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
1, 125, input, this->mutable_offset_w())));
} else if (tag == 122) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, this->mutable_offset_w())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(125)) goto parse_offset_w;
if (input->ExpectTag(133)) goto parse_width;
break;
}
// repeated float width = 16;
case 16: {
if (tag == 133) {
parse_width:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
2, 133, input, this->mutable_width())));
} else if (tag == 130) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, this->mutable_width())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(133)) goto parse_width;
if (input->ExpectTag(141)) goto parse_height;
break;
}
// repeated float height = 17;
case 17: {
if (tag == 141) {
parse_height:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
2, 141, input, this->mutable_height())));
} else if (tag == 138) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, this->mutable_height())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(141)) goto parse_height;
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.PriorBoxParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.PriorBoxParameter)
return false;
#undef DO_
}
void PriorBoxParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.PriorBoxParameter)
// optional float min_size = 1;
if (has_min_size()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(1, this->min_size(), output);
}
// optional float max_size = 2;
if (has_max_size()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(2, this->max_size(), output);
}
// repeated float aspect_ratio = 3;
for (int i = 0; i < this->aspect_ratio_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteFloat(
3, this->aspect_ratio(i), output);
}
// optional bool flip = 4 [default = true];
if (has_flip()) {
::google::protobuf::internal::WireFormatLite::WriteBool(4, this->flip(), output);
}
// optional bool clip = 5 [default = true];
if (has_clip()) {
::google::protobuf::internal::WireFormatLite::WriteBool(5, this->clip(), output);
}
// repeated float variance = 6;
for (int i = 0; i < this->variance_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteFloat(
6, this->variance(i), output);
}
// optional uint32 img_size = 7;
if (has_img_size()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(7, this->img_size(), output);
}
// optional uint32 img_h = 8;
if (has_img_h()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(8, this->img_h(), output);
}
// optional uint32 img_w = 9;
if (has_img_w()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(9, this->img_w(), output);
}
// optional float step = 10;
if (has_step()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(10, this->step(), output);
}
// optional float step_h = 11;
if (has_step_h()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(11, this->step_h(), output);
}
// optional float step_w = 12;
if (has_step_w()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(12, this->step_w(), output);
}
// optional float offset = 13 [default = 0.5];
if (has_offset()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(13, this->offset(), output);
}
// repeated float offset_h = 14;
for (int i = 0; i < this->offset_h_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteFloat(
14, this->offset_h(i), output);
}
// repeated float offset_w = 15;
for (int i = 0; i < this->offset_w_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteFloat(
15, this->offset_w(i), output);
}
// repeated float width = 16;
for (int i = 0; i < this->width_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteFloat(
16, this->width(i), output);
}
// repeated float height = 17;
for (int i = 0; i < this->height_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteFloat(
17, this->height(i), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.PriorBoxParameter)
}
::google::protobuf::uint8* PriorBoxParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.PriorBoxParameter)
// optional float min_size = 1;
if (has_min_size()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(1, this->min_size(), target);
}
// optional float max_size = 2;
if (has_max_size()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(2, this->max_size(), target);
}
// repeated float aspect_ratio = 3;
for (int i = 0; i < this->aspect_ratio_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteFloatToArray(3, this->aspect_ratio(i), target);
}
// optional bool flip = 4 [default = true];
if (has_flip()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(4, this->flip(), target);
}
// optional bool clip = 5 [default = true];
if (has_clip()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(5, this->clip(), target);
}
// repeated float variance = 6;
for (int i = 0; i < this->variance_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteFloatToArray(6, this->variance(i), target);
}
// optional uint32 img_size = 7;
if (has_img_size()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(7, this->img_size(), target);
}
// optional uint32 img_h = 8;
if (has_img_h()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(8, this->img_h(), target);
}
// optional uint32 img_w = 9;
if (has_img_w()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(9, this->img_w(), target);
}
// optional float step = 10;
if (has_step()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(10, this->step(), target);
}
// optional float step_h = 11;
if (has_step_h()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(11, this->step_h(), target);
}
// optional float step_w = 12;
if (has_step_w()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(12, this->step_w(), target);
}
// optional float offset = 13 [default = 0.5];
if (has_offset()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(13, this->offset(), target);
}
// repeated float offset_h = 14;
for (int i = 0; i < this->offset_h_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteFloatToArray(14, this->offset_h(i), target);
}
// repeated float offset_w = 15;
for (int i = 0; i < this->offset_w_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteFloatToArray(15, this->offset_w(i), target);
}
// repeated float width = 16;
for (int i = 0; i < this->width_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteFloatToArray(16, this->width(i), target);
}
// repeated float height = 17;
for (int i = 0; i < this->height_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteFloatToArray(17, this->height(i), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.PriorBoxParameter)
return target;
}
size_t PriorBoxParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.PriorBoxParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 219u) {
// optional float min_size = 1;
if (has_min_size()) {
total_size += 1 + 4;
}
// optional float max_size = 2;
if (has_max_size()) {
total_size += 1 + 4;
}
// optional bool flip = 4 [default = true];
if (has_flip()) {
total_size += 1 + 1;
}
// optional bool clip = 5 [default = true];
if (has_clip()) {
total_size += 1 + 1;
}
// optional uint32 img_size = 7;
if (has_img_size()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->img_size());
}
// optional uint32 img_h = 8;
if (has_img_h()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->img_h());
}
}
if (_has_bits_[8 / 32] & 7936u) {
// optional uint32 img_w = 9;
if (has_img_w()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->img_w());
}
// optional float step = 10;
if (has_step()) {
total_size += 1 + 4;
}
// optional float step_h = 11;
if (has_step_h()) {
total_size += 1 + 4;
}
// optional float step_w = 12;
if (has_step_w()) {
total_size += 1 + 4;
}
// optional float offset = 13 [default = 0.5];
if (has_offset()) {
total_size += 1 + 4;
}
}
// repeated float aspect_ratio = 3;
{
size_t data_size = 0;
unsigned int count = this->aspect_ratio_size();
data_size = 4UL * count;
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->aspect_ratio_size());
total_size += data_size;
}
// repeated float variance = 6;
{
size_t data_size = 0;
unsigned int count = this->variance_size();
data_size = 4UL * count;
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->variance_size());
total_size += data_size;
}
// repeated float offset_h = 14;
{
size_t data_size = 0;
unsigned int count = this->offset_h_size();
data_size = 4UL * count;
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->offset_h_size());
total_size += data_size;
}
// repeated float offset_w = 15;
{
size_t data_size = 0;
unsigned int count = this->offset_w_size();
data_size = 4UL * count;
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->offset_w_size());
total_size += data_size;
}
// repeated float width = 16;
{
size_t data_size = 0;
unsigned int count = this->width_size();
data_size = 4UL * count;
total_size += 2 *
::google::protobuf::internal::FromIntSize(this->width_size());
total_size += data_size;
}
// repeated float height = 17;
{
size_t data_size = 0;
unsigned int count = this->height_size();
data_size = 4UL * count;
total_size += 2 *
::google::protobuf::internal::FromIntSize(this->height_size());
total_size += data_size;
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void PriorBoxParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.PriorBoxParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const PriorBoxParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const PriorBoxParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.PriorBoxParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.PriorBoxParameter)
UnsafeMergeFrom(*source);
}
}
void PriorBoxParameter::MergeFrom(const PriorBoxParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.PriorBoxParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void PriorBoxParameter::UnsafeMergeFrom(const PriorBoxParameter& from) {
GOOGLE_DCHECK(&from != this);
aspect_ratio_.UnsafeMergeFrom(from.aspect_ratio_);
variance_.UnsafeMergeFrom(from.variance_);
offset_h_.UnsafeMergeFrom(from.offset_h_);
offset_w_.UnsafeMergeFrom(from.offset_w_);
width_.UnsafeMergeFrom(from.width_);
height_.UnsafeMergeFrom(from.height_);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_min_size()) {
set_min_size(from.min_size());
}
if (from.has_max_size()) {
set_max_size(from.max_size());
}
if (from.has_flip()) {
set_flip(from.flip());
}
if (from.has_clip()) {
set_clip(from.clip());
}
if (from.has_img_size()) {
set_img_size(from.img_size());
}
if (from.has_img_h()) {
set_img_h(from.img_h());
}
}
if (from._has_bits_[8 / 32] & (0xffu << (8 % 32))) {
if (from.has_img_w()) {
set_img_w(from.img_w());
}
if (from.has_step()) {
set_step(from.step());
}
if (from.has_step_h()) {
set_step_h(from.step_h());
}
if (from.has_step_w()) {
set_step_w(from.step_w());
}
if (from.has_offset()) {
set_offset(from.offset());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void PriorBoxParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.PriorBoxParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void PriorBoxParameter::CopyFrom(const PriorBoxParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.PriorBoxParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool PriorBoxParameter::IsInitialized() const {
return true;
}
void PriorBoxParameter::Swap(PriorBoxParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void PriorBoxParameter::InternalSwap(PriorBoxParameter* other) {
std::swap(min_size_, other->min_size_);
std::swap(max_size_, other->max_size_);
aspect_ratio_.UnsafeArenaSwap(&other->aspect_ratio_);
std::swap(flip_, other->flip_);
std::swap(clip_, other->clip_);
variance_.UnsafeArenaSwap(&other->variance_);
std::swap(img_size_, other->img_size_);
std::swap(img_h_, other->img_h_);
std::swap(img_w_, other->img_w_);
std::swap(step_, other->step_);
std::swap(step_h_, other->step_h_);
std::swap(step_w_, other->step_w_);
std::swap(offset_, other->offset_);
offset_h_.UnsafeArenaSwap(&other->offset_h_);
offset_w_.UnsafeArenaSwap(&other->offset_w_);
width_.UnsafeArenaSwap(&other->width_);
height_.UnsafeArenaSwap(&other->height_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata PriorBoxParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = PriorBoxParameter_descriptor_;
metadata.reflection = PriorBoxParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// PriorBoxParameter
// optional float min_size = 1;
bool PriorBoxParameter::has_min_size() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void PriorBoxParameter::set_has_min_size() {
_has_bits_[0] |= 0x00000001u;
}
void PriorBoxParameter::clear_has_min_size() {
_has_bits_[0] &= ~0x00000001u;
}
void PriorBoxParameter::clear_min_size() {
min_size_ = 0;
clear_has_min_size();
}
float PriorBoxParameter::min_size() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PriorBoxParameter.min_size)
return min_size_;
}
void PriorBoxParameter::set_min_size(float value) {
set_has_min_size();
min_size_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PriorBoxParameter.min_size)
}
// optional float max_size = 2;
bool PriorBoxParameter::has_max_size() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void PriorBoxParameter::set_has_max_size() {
_has_bits_[0] |= 0x00000002u;
}
void PriorBoxParameter::clear_has_max_size() {
_has_bits_[0] &= ~0x00000002u;
}
void PriorBoxParameter::clear_max_size() {
max_size_ = 0;
clear_has_max_size();
}
float PriorBoxParameter::max_size() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PriorBoxParameter.max_size)
return max_size_;
}
void PriorBoxParameter::set_max_size(float value) {
set_has_max_size();
max_size_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PriorBoxParameter.max_size)
}
// repeated float aspect_ratio = 3;
int PriorBoxParameter::aspect_ratio_size() const {
return aspect_ratio_.size();
}
void PriorBoxParameter::clear_aspect_ratio() {
aspect_ratio_.Clear();
}
float PriorBoxParameter::aspect_ratio(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.PriorBoxParameter.aspect_ratio)
return aspect_ratio_.Get(index);
}
void PriorBoxParameter::set_aspect_ratio(int index, float value) {
aspect_ratio_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.PriorBoxParameter.aspect_ratio)
}
void PriorBoxParameter::add_aspect_ratio(float value) {
aspect_ratio_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.PriorBoxParameter.aspect_ratio)
}
const ::google::protobuf::RepeatedField< float >&
PriorBoxParameter::aspect_ratio() const {
// @@protoc_insertion_point(field_list:opencv_caffe.PriorBoxParameter.aspect_ratio)
return aspect_ratio_;
}
::google::protobuf::RepeatedField< float >*
PriorBoxParameter::mutable_aspect_ratio() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.PriorBoxParameter.aspect_ratio)
return &aspect_ratio_;
}
// optional bool flip = 4 [default = true];
bool PriorBoxParameter::has_flip() const {
return (_has_bits_[0] & 0x00000008u) != 0;
}
void PriorBoxParameter::set_has_flip() {
_has_bits_[0] |= 0x00000008u;
}
void PriorBoxParameter::clear_has_flip() {
_has_bits_[0] &= ~0x00000008u;
}
void PriorBoxParameter::clear_flip() {
flip_ = true;
clear_has_flip();
}
bool PriorBoxParameter::flip() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PriorBoxParameter.flip)
return flip_;
}
void PriorBoxParameter::set_flip(bool value) {
set_has_flip();
flip_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PriorBoxParameter.flip)
}
// optional bool clip = 5 [default = true];
bool PriorBoxParameter::has_clip() const {
return (_has_bits_[0] & 0x00000010u) != 0;
}
void PriorBoxParameter::set_has_clip() {
_has_bits_[0] |= 0x00000010u;
}
void PriorBoxParameter::clear_has_clip() {
_has_bits_[0] &= ~0x00000010u;
}
void PriorBoxParameter::clear_clip() {
clip_ = true;
clear_has_clip();
}
bool PriorBoxParameter::clip() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PriorBoxParameter.clip)
return clip_;
}
void PriorBoxParameter::set_clip(bool value) {
set_has_clip();
clip_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PriorBoxParameter.clip)
}
// repeated float variance = 6;
int PriorBoxParameter::variance_size() const {
return variance_.size();
}
void PriorBoxParameter::clear_variance() {
variance_.Clear();
}
float PriorBoxParameter::variance(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.PriorBoxParameter.variance)
return variance_.Get(index);
}
void PriorBoxParameter::set_variance(int index, float value) {
variance_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.PriorBoxParameter.variance)
}
void PriorBoxParameter::add_variance(float value) {
variance_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.PriorBoxParameter.variance)
}
const ::google::protobuf::RepeatedField< float >&
PriorBoxParameter::variance() const {
// @@protoc_insertion_point(field_list:opencv_caffe.PriorBoxParameter.variance)
return variance_;
}
::google::protobuf::RepeatedField< float >*
PriorBoxParameter::mutable_variance() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.PriorBoxParameter.variance)
return &variance_;
}
// optional uint32 img_size = 7;
bool PriorBoxParameter::has_img_size() const {
return (_has_bits_[0] & 0x00000040u) != 0;
}
void PriorBoxParameter::set_has_img_size() {
_has_bits_[0] |= 0x00000040u;
}
void PriorBoxParameter::clear_has_img_size() {
_has_bits_[0] &= ~0x00000040u;
}
void PriorBoxParameter::clear_img_size() {
img_size_ = 0u;
clear_has_img_size();
}
::google::protobuf::uint32 PriorBoxParameter::img_size() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PriorBoxParameter.img_size)
return img_size_;
}
void PriorBoxParameter::set_img_size(::google::protobuf::uint32 value) {
set_has_img_size();
img_size_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PriorBoxParameter.img_size)
}
// optional uint32 img_h = 8;
bool PriorBoxParameter::has_img_h() const {
return (_has_bits_[0] & 0x00000080u) != 0;
}
void PriorBoxParameter::set_has_img_h() {
_has_bits_[0] |= 0x00000080u;
}
void PriorBoxParameter::clear_has_img_h() {
_has_bits_[0] &= ~0x00000080u;
}
void PriorBoxParameter::clear_img_h() {
img_h_ = 0u;
clear_has_img_h();
}
::google::protobuf::uint32 PriorBoxParameter::img_h() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PriorBoxParameter.img_h)
return img_h_;
}
void PriorBoxParameter::set_img_h(::google::protobuf::uint32 value) {
set_has_img_h();
img_h_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PriorBoxParameter.img_h)
}
// optional uint32 img_w = 9;
bool PriorBoxParameter::has_img_w() const {
return (_has_bits_[0] & 0x00000100u) != 0;
}
void PriorBoxParameter::set_has_img_w() {
_has_bits_[0] |= 0x00000100u;
}
void PriorBoxParameter::clear_has_img_w() {
_has_bits_[0] &= ~0x00000100u;
}
void PriorBoxParameter::clear_img_w() {
img_w_ = 0u;
clear_has_img_w();
}
::google::protobuf::uint32 PriorBoxParameter::img_w() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PriorBoxParameter.img_w)
return img_w_;
}
void PriorBoxParameter::set_img_w(::google::protobuf::uint32 value) {
set_has_img_w();
img_w_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PriorBoxParameter.img_w)
}
// optional float step = 10;
bool PriorBoxParameter::has_step() const {
return (_has_bits_[0] & 0x00000200u) != 0;
}
void PriorBoxParameter::set_has_step() {
_has_bits_[0] |= 0x00000200u;
}
void PriorBoxParameter::clear_has_step() {
_has_bits_[0] &= ~0x00000200u;
}
void PriorBoxParameter::clear_step() {
step_ = 0;
clear_has_step();
}
float PriorBoxParameter::step() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PriorBoxParameter.step)
return step_;
}
void PriorBoxParameter::set_step(float value) {
set_has_step();
step_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PriorBoxParameter.step)
}
// optional float step_h = 11;
bool PriorBoxParameter::has_step_h() const {
return (_has_bits_[0] & 0x00000400u) != 0;
}
void PriorBoxParameter::set_has_step_h() {
_has_bits_[0] |= 0x00000400u;
}
void PriorBoxParameter::clear_has_step_h() {
_has_bits_[0] &= ~0x00000400u;
}
void PriorBoxParameter::clear_step_h() {
step_h_ = 0;
clear_has_step_h();
}
float PriorBoxParameter::step_h() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PriorBoxParameter.step_h)
return step_h_;
}
void PriorBoxParameter::set_step_h(float value) {
set_has_step_h();
step_h_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PriorBoxParameter.step_h)
}
// optional float step_w = 12;
bool PriorBoxParameter::has_step_w() const {
return (_has_bits_[0] & 0x00000800u) != 0;
}
void PriorBoxParameter::set_has_step_w() {
_has_bits_[0] |= 0x00000800u;
}
void PriorBoxParameter::clear_has_step_w() {
_has_bits_[0] &= ~0x00000800u;
}
void PriorBoxParameter::clear_step_w() {
step_w_ = 0;
clear_has_step_w();
}
float PriorBoxParameter::step_w() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PriorBoxParameter.step_w)
return step_w_;
}
void PriorBoxParameter::set_step_w(float value) {
set_has_step_w();
step_w_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PriorBoxParameter.step_w)
}
// optional float offset = 13 [default = 0.5];
bool PriorBoxParameter::has_offset() const {
return (_has_bits_[0] & 0x00001000u) != 0;
}
void PriorBoxParameter::set_has_offset() {
_has_bits_[0] |= 0x00001000u;
}
void PriorBoxParameter::clear_has_offset() {
_has_bits_[0] &= ~0x00001000u;
}
void PriorBoxParameter::clear_offset() {
offset_ = 0.5f;
clear_has_offset();
}
float PriorBoxParameter::offset() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PriorBoxParameter.offset)
return offset_;
}
void PriorBoxParameter::set_offset(float value) {
set_has_offset();
offset_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PriorBoxParameter.offset)
}
// repeated float offset_h = 14;
int PriorBoxParameter::offset_h_size() const {
return offset_h_.size();
}
void PriorBoxParameter::clear_offset_h() {
offset_h_.Clear();
}
float PriorBoxParameter::offset_h(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.PriorBoxParameter.offset_h)
return offset_h_.Get(index);
}
void PriorBoxParameter::set_offset_h(int index, float value) {
offset_h_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.PriorBoxParameter.offset_h)
}
void PriorBoxParameter::add_offset_h(float value) {
offset_h_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.PriorBoxParameter.offset_h)
}
const ::google::protobuf::RepeatedField< float >&
PriorBoxParameter::offset_h() const {
// @@protoc_insertion_point(field_list:opencv_caffe.PriorBoxParameter.offset_h)
return offset_h_;
}
::google::protobuf::RepeatedField< float >*
PriorBoxParameter::mutable_offset_h() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.PriorBoxParameter.offset_h)
return &offset_h_;
}
// repeated float offset_w = 15;
int PriorBoxParameter::offset_w_size() const {
return offset_w_.size();
}
void PriorBoxParameter::clear_offset_w() {
offset_w_.Clear();
}
float PriorBoxParameter::offset_w(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.PriorBoxParameter.offset_w)
return offset_w_.Get(index);
}
void PriorBoxParameter::set_offset_w(int index, float value) {
offset_w_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.PriorBoxParameter.offset_w)
}
void PriorBoxParameter::add_offset_w(float value) {
offset_w_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.PriorBoxParameter.offset_w)
}
const ::google::protobuf::RepeatedField< float >&
PriorBoxParameter::offset_w() const {
// @@protoc_insertion_point(field_list:opencv_caffe.PriorBoxParameter.offset_w)
return offset_w_;
}
::google::protobuf::RepeatedField< float >*
PriorBoxParameter::mutable_offset_w() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.PriorBoxParameter.offset_w)
return &offset_w_;
}
// repeated float width = 16;
int PriorBoxParameter::width_size() const {
return width_.size();
}
void PriorBoxParameter::clear_width() {
width_.Clear();
}
float PriorBoxParameter::width(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.PriorBoxParameter.width)
return width_.Get(index);
}
void PriorBoxParameter::set_width(int index, float value) {
width_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.PriorBoxParameter.width)
}
void PriorBoxParameter::add_width(float value) {
width_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.PriorBoxParameter.width)
}
const ::google::protobuf::RepeatedField< float >&
PriorBoxParameter::width() const {
// @@protoc_insertion_point(field_list:opencv_caffe.PriorBoxParameter.width)
return width_;
}
::google::protobuf::RepeatedField< float >*
PriorBoxParameter::mutable_width() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.PriorBoxParameter.width)
return &width_;
}
// repeated float height = 17;
int PriorBoxParameter::height_size() const {
return height_.size();
}
void PriorBoxParameter::clear_height() {
height_.Clear();
}
float PriorBoxParameter::height(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.PriorBoxParameter.height)
return height_.Get(index);
}
void PriorBoxParameter::set_height(int index, float value) {
height_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.PriorBoxParameter.height)
}
void PriorBoxParameter::add_height(float value) {
height_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.PriorBoxParameter.height)
}
const ::google::protobuf::RepeatedField< float >&
PriorBoxParameter::height() const {
// @@protoc_insertion_point(field_list:opencv_caffe.PriorBoxParameter.height)
return height_;
}
::google::protobuf::RepeatedField< float >*
PriorBoxParameter::mutable_height() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.PriorBoxParameter.height)
return &height_;
}
inline const PriorBoxParameter* PriorBoxParameter::internal_default_instance() {
return &PriorBoxParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int DetectionOutputParameter::kNumClassesFieldNumber;
const int DetectionOutputParameter::kShareLocationFieldNumber;
const int DetectionOutputParameter::kBackgroundLabelIdFieldNumber;
const int DetectionOutputParameter::kNmsParamFieldNumber;
const int DetectionOutputParameter::kSaveOutputParamFieldNumber;
const int DetectionOutputParameter::kCodeTypeFieldNumber;
const int DetectionOutputParameter::kVarianceEncodedInTargetFieldNumber;
const int DetectionOutputParameter::kKeepTopKFieldNumber;
const int DetectionOutputParameter::kConfidenceThresholdFieldNumber;
const int DetectionOutputParameter::kNormalizedBboxFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
DetectionOutputParameter::DetectionOutputParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.DetectionOutputParameter)
}
void DetectionOutputParameter::InitAsDefaultInstance() {
nms_param_ = const_cast< ::opencv_caffe::NonMaximumSuppressionParameter*>(
::opencv_caffe::NonMaximumSuppressionParameter::internal_default_instance());
save_output_param_ = const_cast< ::opencv_caffe::SaveOutputParameter*>(
::opencv_caffe::SaveOutputParameter::internal_default_instance());
}
DetectionOutputParameter::DetectionOutputParameter(const DetectionOutputParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.DetectionOutputParameter)
}
void DetectionOutputParameter::SharedCtor() {
_cached_size_ = 0;
nms_param_ = NULL;
save_output_param_ = NULL;
::memset(&num_classes_, 0, reinterpret_cast<char*>(&confidence_threshold_) -
reinterpret_cast<char*>(&num_classes_) + sizeof(confidence_threshold_));
keep_top_k_ = -1;
code_type_ = 1;
share_location_ = true;
normalized_bbox_ = true;
}
DetectionOutputParameter::~DetectionOutputParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.DetectionOutputParameter)
SharedDtor();
}
void DetectionOutputParameter::SharedDtor() {
if (this != &DetectionOutputParameter_default_instance_.get()) {
delete nms_param_;
delete save_output_param_;
}
}
void DetectionOutputParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* DetectionOutputParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return DetectionOutputParameter_descriptor_;
}
const DetectionOutputParameter& DetectionOutputParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<DetectionOutputParameter> DetectionOutputParameter_default_instance_;
DetectionOutputParameter* DetectionOutputParameter::New(::google::protobuf::Arena* arena) const {
DetectionOutputParameter* n = new DetectionOutputParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void DetectionOutputParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.DetectionOutputParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(DetectionOutputParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<DetectionOutputParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
if (_has_bits_[0 / 32] & 255u) {
ZR_(num_classes_, variance_encoded_in_target_);
share_location_ = true;
if (has_nms_param()) {
if (nms_param_ != NULL) nms_param_->::opencv_caffe::NonMaximumSuppressionParameter::Clear();
}
if (has_save_output_param()) {
if (save_output_param_ != NULL) save_output_param_->::opencv_caffe::SaveOutputParameter::Clear();
}
code_type_ = 1;
keep_top_k_ = -1;
}
if (_has_bits_[8 / 32] & 768u) {
confidence_threshold_ = 0;
normalized_bbox_ = true;
}
#undef ZR_HELPER_
#undef ZR_
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool DetectionOutputParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.DetectionOutputParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional uint32 num_classes = 1;
case 1: {
if (tag == 8) {
set_has_num_classes();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &num_classes_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_share_location;
break;
}
// optional bool share_location = 2 [default = true];
case 2: {
if (tag == 16) {
parse_share_location:
set_has_share_location();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &share_location_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(24)) goto parse_background_label_id;
break;
}
// optional int32 background_label_id = 3 [default = 0];
case 3: {
if (tag == 24) {
parse_background_label_id:
set_has_background_label_id();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &background_label_id_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(34)) goto parse_nms_param;
break;
}
// optional .opencv_caffe.NonMaximumSuppressionParameter nms_param = 4;
case 4: {
if (tag == 34) {
parse_nms_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_nms_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(42)) goto parse_save_output_param;
break;
}
// optional .opencv_caffe.SaveOutputParameter save_output_param = 5;
case 5: {
if (tag == 42) {
parse_save_output_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_save_output_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(48)) goto parse_code_type;
break;
}
// optional .opencv_caffe.PriorBoxParameter.CodeType code_type = 6 [default = CORNER];
case 6: {
if (tag == 48) {
parse_code_type:
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::PriorBoxParameter_CodeType_IsValid(value)) {
set_code_type(static_cast< ::opencv_caffe::PriorBoxParameter_CodeType >(value));
} else {
mutable_unknown_fields()->AddVarint(6, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectTag(56)) goto parse_keep_top_k;
break;
}
// optional int32 keep_top_k = 7 [default = -1];
case 7: {
if (tag == 56) {
parse_keep_top_k:
set_has_keep_top_k();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &keep_top_k_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(64)) goto parse_variance_encoded_in_target;
break;
}
// optional bool variance_encoded_in_target = 8 [default = false];
case 8: {
if (tag == 64) {
parse_variance_encoded_in_target:
set_has_variance_encoded_in_target();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &variance_encoded_in_target_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(77)) goto parse_confidence_threshold;
break;
}
// optional float confidence_threshold = 9;
case 9: {
if (tag == 77) {
parse_confidence_threshold:
set_has_confidence_threshold();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &confidence_threshold_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(80)) goto parse_normalized_bbox;
break;
}
// optional bool normalized_bbox = 10 [default = true];
case 10: {
if (tag == 80) {
parse_normalized_bbox:
set_has_normalized_bbox();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &normalized_bbox_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.DetectionOutputParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.DetectionOutputParameter)
return false;
#undef DO_
}
void DetectionOutputParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.DetectionOutputParameter)
// optional uint32 num_classes = 1;
if (has_num_classes()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(1, this->num_classes(), output);
}
// optional bool share_location = 2 [default = true];
if (has_share_location()) {
::google::protobuf::internal::WireFormatLite::WriteBool(2, this->share_location(), output);
}
// optional int32 background_label_id = 3 [default = 0];
if (has_background_label_id()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(3, this->background_label_id(), output);
}
// optional .opencv_caffe.NonMaximumSuppressionParameter nms_param = 4;
if (has_nms_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
4, *this->nms_param_, output);
}
// optional .opencv_caffe.SaveOutputParameter save_output_param = 5;
if (has_save_output_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
5, *this->save_output_param_, output);
}
// optional .opencv_caffe.PriorBoxParameter.CodeType code_type = 6 [default = CORNER];
if (has_code_type()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
6, this->code_type(), output);
}
// optional int32 keep_top_k = 7 [default = -1];
if (has_keep_top_k()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(7, this->keep_top_k(), output);
}
// optional bool variance_encoded_in_target = 8 [default = false];
if (has_variance_encoded_in_target()) {
::google::protobuf::internal::WireFormatLite::WriteBool(8, this->variance_encoded_in_target(), output);
}
// optional float confidence_threshold = 9;
if (has_confidence_threshold()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(9, this->confidence_threshold(), output);
}
// optional bool normalized_bbox = 10 [default = true];
if (has_normalized_bbox()) {
::google::protobuf::internal::WireFormatLite::WriteBool(10, this->normalized_bbox(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.DetectionOutputParameter)
}
::google::protobuf::uint8* DetectionOutputParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.DetectionOutputParameter)
// optional uint32 num_classes = 1;
if (has_num_classes()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(1, this->num_classes(), target);
}
// optional bool share_location = 2 [default = true];
if (has_share_location()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(2, this->share_location(), target);
}
// optional int32 background_label_id = 3 [default = 0];
if (has_background_label_id()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(3, this->background_label_id(), target);
}
// optional .opencv_caffe.NonMaximumSuppressionParameter nms_param = 4;
if (has_nms_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
4, *this->nms_param_, false, target);
}
// optional .opencv_caffe.SaveOutputParameter save_output_param = 5;
if (has_save_output_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
5, *this->save_output_param_, false, target);
}
// optional .opencv_caffe.PriorBoxParameter.CodeType code_type = 6 [default = CORNER];
if (has_code_type()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
6, this->code_type(), target);
}
// optional int32 keep_top_k = 7 [default = -1];
if (has_keep_top_k()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(7, this->keep_top_k(), target);
}
// optional bool variance_encoded_in_target = 8 [default = false];
if (has_variance_encoded_in_target()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(8, this->variance_encoded_in_target(), target);
}
// optional float confidence_threshold = 9;
if (has_confidence_threshold()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(9, this->confidence_threshold(), target);
}
// optional bool normalized_bbox = 10 [default = true];
if (has_normalized_bbox()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(10, this->normalized_bbox(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.DetectionOutputParameter)
return target;
}
size_t DetectionOutputParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.DetectionOutputParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 255u) {
// optional uint32 num_classes = 1;
if (has_num_classes()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->num_classes());
}
// optional bool share_location = 2 [default = true];
if (has_share_location()) {
total_size += 1 + 1;
}
// optional int32 background_label_id = 3 [default = 0];
if (has_background_label_id()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->background_label_id());
}
// optional .opencv_caffe.NonMaximumSuppressionParameter nms_param = 4;
if (has_nms_param()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->nms_param_);
}
// optional .opencv_caffe.SaveOutputParameter save_output_param = 5;
if (has_save_output_param()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->save_output_param_);
}
// optional .opencv_caffe.PriorBoxParameter.CodeType code_type = 6 [default = CORNER];
if (has_code_type()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->code_type());
}
// optional bool variance_encoded_in_target = 8 [default = false];
if (has_variance_encoded_in_target()) {
total_size += 1 + 1;
}
// optional int32 keep_top_k = 7 [default = -1];
if (has_keep_top_k()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->keep_top_k());
}
}
if (_has_bits_[8 / 32] & 768u) {
// optional float confidence_threshold = 9;
if (has_confidence_threshold()) {
total_size += 1 + 4;
}
// optional bool normalized_bbox = 10 [default = true];
if (has_normalized_bbox()) {
total_size += 1 + 1;
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void DetectionOutputParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.DetectionOutputParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const DetectionOutputParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const DetectionOutputParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.DetectionOutputParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.DetectionOutputParameter)
UnsafeMergeFrom(*source);
}
}
void DetectionOutputParameter::MergeFrom(const DetectionOutputParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.DetectionOutputParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void DetectionOutputParameter::UnsafeMergeFrom(const DetectionOutputParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_num_classes()) {
set_num_classes(from.num_classes());
}
if (from.has_share_location()) {
set_share_location(from.share_location());
}
if (from.has_background_label_id()) {
set_background_label_id(from.background_label_id());
}
if (from.has_nms_param()) {
mutable_nms_param()->::opencv_caffe::NonMaximumSuppressionParameter::MergeFrom(from.nms_param());
}
if (from.has_save_output_param()) {
mutable_save_output_param()->::opencv_caffe::SaveOutputParameter::MergeFrom(from.save_output_param());
}
if (from.has_code_type()) {
set_code_type(from.code_type());
}
if (from.has_variance_encoded_in_target()) {
set_variance_encoded_in_target(from.variance_encoded_in_target());
}
if (from.has_keep_top_k()) {
set_keep_top_k(from.keep_top_k());
}
}
if (from._has_bits_[8 / 32] & (0xffu << (8 % 32))) {
if (from.has_confidence_threshold()) {
set_confidence_threshold(from.confidence_threshold());
}
if (from.has_normalized_bbox()) {
set_normalized_bbox(from.normalized_bbox());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void DetectionOutputParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.DetectionOutputParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void DetectionOutputParameter::CopyFrom(const DetectionOutputParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.DetectionOutputParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool DetectionOutputParameter::IsInitialized() const {
return true;
}
void DetectionOutputParameter::Swap(DetectionOutputParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void DetectionOutputParameter::InternalSwap(DetectionOutputParameter* other) {
std::swap(num_classes_, other->num_classes_);
std::swap(share_location_, other->share_location_);
std::swap(background_label_id_, other->background_label_id_);
std::swap(nms_param_, other->nms_param_);
std::swap(save_output_param_, other->save_output_param_);
std::swap(code_type_, other->code_type_);
std::swap(variance_encoded_in_target_, other->variance_encoded_in_target_);
std::swap(keep_top_k_, other->keep_top_k_);
std::swap(confidence_threshold_, other->confidence_threshold_);
std::swap(normalized_bbox_, other->normalized_bbox_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata DetectionOutputParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = DetectionOutputParameter_descriptor_;
metadata.reflection = DetectionOutputParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// DetectionOutputParameter
// optional uint32 num_classes = 1;
bool DetectionOutputParameter::has_num_classes() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void DetectionOutputParameter::set_has_num_classes() {
_has_bits_[0] |= 0x00000001u;
}
void DetectionOutputParameter::clear_has_num_classes() {
_has_bits_[0] &= ~0x00000001u;
}
void DetectionOutputParameter::clear_num_classes() {
num_classes_ = 0u;
clear_has_num_classes();
}
::google::protobuf::uint32 DetectionOutputParameter::num_classes() const {
// @@protoc_insertion_point(field_get:opencv_caffe.DetectionOutputParameter.num_classes)
return num_classes_;
}
void DetectionOutputParameter::set_num_classes(::google::protobuf::uint32 value) {
set_has_num_classes();
num_classes_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.DetectionOutputParameter.num_classes)
}
// optional bool share_location = 2 [default = true];
bool DetectionOutputParameter::has_share_location() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void DetectionOutputParameter::set_has_share_location() {
_has_bits_[0] |= 0x00000002u;
}
void DetectionOutputParameter::clear_has_share_location() {
_has_bits_[0] &= ~0x00000002u;
}
void DetectionOutputParameter::clear_share_location() {
share_location_ = true;
clear_has_share_location();
}
bool DetectionOutputParameter::share_location() const {
// @@protoc_insertion_point(field_get:opencv_caffe.DetectionOutputParameter.share_location)
return share_location_;
}
void DetectionOutputParameter::set_share_location(bool value) {
set_has_share_location();
share_location_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.DetectionOutputParameter.share_location)
}
// optional int32 background_label_id = 3 [default = 0];
bool DetectionOutputParameter::has_background_label_id() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void DetectionOutputParameter::set_has_background_label_id() {
_has_bits_[0] |= 0x00000004u;
}
void DetectionOutputParameter::clear_has_background_label_id() {
_has_bits_[0] &= ~0x00000004u;
}
void DetectionOutputParameter::clear_background_label_id() {
background_label_id_ = 0;
clear_has_background_label_id();
}
::google::protobuf::int32 DetectionOutputParameter::background_label_id() const {
// @@protoc_insertion_point(field_get:opencv_caffe.DetectionOutputParameter.background_label_id)
return background_label_id_;
}
void DetectionOutputParameter::set_background_label_id(::google::protobuf::int32 value) {
set_has_background_label_id();
background_label_id_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.DetectionOutputParameter.background_label_id)
}
// optional .opencv_caffe.NonMaximumSuppressionParameter nms_param = 4;
bool DetectionOutputParameter::has_nms_param() const {
return (_has_bits_[0] & 0x00000008u) != 0;
}
void DetectionOutputParameter::set_has_nms_param() {
_has_bits_[0] |= 0x00000008u;
}
void DetectionOutputParameter::clear_has_nms_param() {
_has_bits_[0] &= ~0x00000008u;
}
void DetectionOutputParameter::clear_nms_param() {
if (nms_param_ != NULL) nms_param_->::opencv_caffe::NonMaximumSuppressionParameter::Clear();
clear_has_nms_param();
}
const ::opencv_caffe::NonMaximumSuppressionParameter& DetectionOutputParameter::nms_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.DetectionOutputParameter.nms_param)
return nms_param_ != NULL ? *nms_param_
: *::opencv_caffe::NonMaximumSuppressionParameter::internal_default_instance();
}
::opencv_caffe::NonMaximumSuppressionParameter* DetectionOutputParameter::mutable_nms_param() {
set_has_nms_param();
if (nms_param_ == NULL) {
nms_param_ = new ::opencv_caffe::NonMaximumSuppressionParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.DetectionOutputParameter.nms_param)
return nms_param_;
}
::opencv_caffe::NonMaximumSuppressionParameter* DetectionOutputParameter::release_nms_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.DetectionOutputParameter.nms_param)
clear_has_nms_param();
::opencv_caffe::NonMaximumSuppressionParameter* temp = nms_param_;
nms_param_ = NULL;
return temp;
}
void DetectionOutputParameter::set_allocated_nms_param(::opencv_caffe::NonMaximumSuppressionParameter* nms_param) {
delete nms_param_;
nms_param_ = nms_param;
if (nms_param) {
set_has_nms_param();
} else {
clear_has_nms_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.DetectionOutputParameter.nms_param)
}
// optional .opencv_caffe.SaveOutputParameter save_output_param = 5;
bool DetectionOutputParameter::has_save_output_param() const {
return (_has_bits_[0] & 0x00000010u) != 0;
}
void DetectionOutputParameter::set_has_save_output_param() {
_has_bits_[0] |= 0x00000010u;
}
void DetectionOutputParameter::clear_has_save_output_param() {
_has_bits_[0] &= ~0x00000010u;
}
void DetectionOutputParameter::clear_save_output_param() {
if (save_output_param_ != NULL) save_output_param_->::opencv_caffe::SaveOutputParameter::Clear();
clear_has_save_output_param();
}
const ::opencv_caffe::SaveOutputParameter& DetectionOutputParameter::save_output_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.DetectionOutputParameter.save_output_param)
return save_output_param_ != NULL ? *save_output_param_
: *::opencv_caffe::SaveOutputParameter::internal_default_instance();
}
::opencv_caffe::SaveOutputParameter* DetectionOutputParameter::mutable_save_output_param() {
set_has_save_output_param();
if (save_output_param_ == NULL) {
save_output_param_ = new ::opencv_caffe::SaveOutputParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.DetectionOutputParameter.save_output_param)
return save_output_param_;
}
::opencv_caffe::SaveOutputParameter* DetectionOutputParameter::release_save_output_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.DetectionOutputParameter.save_output_param)
clear_has_save_output_param();
::opencv_caffe::SaveOutputParameter* temp = save_output_param_;
save_output_param_ = NULL;
return temp;
}
void DetectionOutputParameter::set_allocated_save_output_param(::opencv_caffe::SaveOutputParameter* save_output_param) {
delete save_output_param_;
save_output_param_ = save_output_param;
if (save_output_param) {
set_has_save_output_param();
} else {
clear_has_save_output_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.DetectionOutputParameter.save_output_param)
}
// optional .opencv_caffe.PriorBoxParameter.CodeType code_type = 6 [default = CORNER];
bool DetectionOutputParameter::has_code_type() const {
return (_has_bits_[0] & 0x00000020u) != 0;
}
void DetectionOutputParameter::set_has_code_type() {
_has_bits_[0] |= 0x00000020u;
}
void DetectionOutputParameter::clear_has_code_type() {
_has_bits_[0] &= ~0x00000020u;
}
void DetectionOutputParameter::clear_code_type() {
code_type_ = 1;
clear_has_code_type();
}
::opencv_caffe::PriorBoxParameter_CodeType DetectionOutputParameter::code_type() const {
// @@protoc_insertion_point(field_get:opencv_caffe.DetectionOutputParameter.code_type)
return static_cast< ::opencv_caffe::PriorBoxParameter_CodeType >(code_type_);
}
void DetectionOutputParameter::set_code_type(::opencv_caffe::PriorBoxParameter_CodeType value) {
assert(::opencv_caffe::PriorBoxParameter_CodeType_IsValid(value));
set_has_code_type();
code_type_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.DetectionOutputParameter.code_type)
}
// optional bool variance_encoded_in_target = 8 [default = false];
bool DetectionOutputParameter::has_variance_encoded_in_target() const {
return (_has_bits_[0] & 0x00000040u) != 0;
}
void DetectionOutputParameter::set_has_variance_encoded_in_target() {
_has_bits_[0] |= 0x00000040u;
}
void DetectionOutputParameter::clear_has_variance_encoded_in_target() {
_has_bits_[0] &= ~0x00000040u;
}
void DetectionOutputParameter::clear_variance_encoded_in_target() {
variance_encoded_in_target_ = false;
clear_has_variance_encoded_in_target();
}
bool DetectionOutputParameter::variance_encoded_in_target() const {
// @@protoc_insertion_point(field_get:opencv_caffe.DetectionOutputParameter.variance_encoded_in_target)
return variance_encoded_in_target_;
}
void DetectionOutputParameter::set_variance_encoded_in_target(bool value) {
set_has_variance_encoded_in_target();
variance_encoded_in_target_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.DetectionOutputParameter.variance_encoded_in_target)
}
// optional int32 keep_top_k = 7 [default = -1];
bool DetectionOutputParameter::has_keep_top_k() const {
return (_has_bits_[0] & 0x00000080u) != 0;
}
void DetectionOutputParameter::set_has_keep_top_k() {
_has_bits_[0] |= 0x00000080u;
}
void DetectionOutputParameter::clear_has_keep_top_k() {
_has_bits_[0] &= ~0x00000080u;
}
void DetectionOutputParameter::clear_keep_top_k() {
keep_top_k_ = -1;
clear_has_keep_top_k();
}
::google::protobuf::int32 DetectionOutputParameter::keep_top_k() const {
// @@protoc_insertion_point(field_get:opencv_caffe.DetectionOutputParameter.keep_top_k)
return keep_top_k_;
}
void DetectionOutputParameter::set_keep_top_k(::google::protobuf::int32 value) {
set_has_keep_top_k();
keep_top_k_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.DetectionOutputParameter.keep_top_k)
}
// optional float confidence_threshold = 9;
bool DetectionOutputParameter::has_confidence_threshold() const {
return (_has_bits_[0] & 0x00000100u) != 0;
}
void DetectionOutputParameter::set_has_confidence_threshold() {
_has_bits_[0] |= 0x00000100u;
}
void DetectionOutputParameter::clear_has_confidence_threshold() {
_has_bits_[0] &= ~0x00000100u;
}
void DetectionOutputParameter::clear_confidence_threshold() {
confidence_threshold_ = 0;
clear_has_confidence_threshold();
}
float DetectionOutputParameter::confidence_threshold() const {
// @@protoc_insertion_point(field_get:opencv_caffe.DetectionOutputParameter.confidence_threshold)
return confidence_threshold_;
}
void DetectionOutputParameter::set_confidence_threshold(float value) {
set_has_confidence_threshold();
confidence_threshold_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.DetectionOutputParameter.confidence_threshold)
}
// optional bool normalized_bbox = 10 [default = true];
bool DetectionOutputParameter::has_normalized_bbox() const {
return (_has_bits_[0] & 0x00000200u) != 0;
}
void DetectionOutputParameter::set_has_normalized_bbox() {
_has_bits_[0] |= 0x00000200u;
}
void DetectionOutputParameter::clear_has_normalized_bbox() {
_has_bits_[0] &= ~0x00000200u;
}
void DetectionOutputParameter::clear_normalized_bbox() {
normalized_bbox_ = true;
clear_has_normalized_bbox();
}
bool DetectionOutputParameter::normalized_bbox() const {
// @@protoc_insertion_point(field_get:opencv_caffe.DetectionOutputParameter.normalized_bbox)
return normalized_bbox_;
}
void DetectionOutputParameter::set_normalized_bbox(bool value) {
set_has_normalized_bbox();
normalized_bbox_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.DetectionOutputParameter.normalized_bbox)
}
inline const DetectionOutputParameter* DetectionOutputParameter::internal_default_instance() {
return &DetectionOutputParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int Datum::kChannelsFieldNumber;
const int Datum::kHeightFieldNumber;
const int Datum::kWidthFieldNumber;
const int Datum::kDataFieldNumber;
const int Datum::kLabelFieldNumber;
const int Datum::kFloatDataFieldNumber;
const int Datum::kEncodedFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
Datum::Datum()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.Datum)
}
void Datum::InitAsDefaultInstance() {
}
Datum::Datum(const Datum& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.Datum)
}
void Datum::SharedCtor() {
_cached_size_ = 0;
data_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
::memset(&channels_, 0, reinterpret_cast<char*>(&encoded_) -
reinterpret_cast<char*>(&channels_) + sizeof(encoded_));
}
Datum::~Datum() {
// @@protoc_insertion_point(destructor:opencv_caffe.Datum)
SharedDtor();
}
void Datum::SharedDtor() {
data_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void Datum::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* Datum::descriptor() {
protobuf_AssignDescriptorsOnce();
return Datum_descriptor_;
}
const Datum& Datum::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<Datum> Datum_default_instance_;
Datum* Datum::New(::google::protobuf::Arena* arena) const {
Datum* n = new Datum;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void Datum::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.Datum)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(Datum, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<Datum*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
if (_has_bits_[0 / 32] & 95u) {
ZR_(channels_, encoded_);
if (has_data()) {
data_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
}
#undef ZR_HELPER_
#undef ZR_
float_data_.Clear();
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool Datum::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.Datum)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional int32 channels = 1;
case 1: {
if (tag == 8) {
set_has_channels();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &channels_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_height;
break;
}
// optional int32 height = 2;
case 2: {
if (tag == 16) {
parse_height:
set_has_height();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &height_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(24)) goto parse_width;
break;
}
// optional int32 width = 3;
case 3: {
if (tag == 24) {
parse_width:
set_has_width();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &width_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(34)) goto parse_data;
break;
}
// optional bytes data = 4;
case 4: {
if (tag == 34) {
parse_data:
DO_(::google::protobuf::internal::WireFormatLite::ReadBytes(
input, this->mutable_data()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(40)) goto parse_label;
break;
}
// optional int32 label = 5;
case 5: {
if (tag == 40) {
parse_label:
set_has_label();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &label_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(53)) goto parse_float_data;
break;
}
// repeated float float_data = 6;
case 6: {
if (tag == 53) {
parse_float_data:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
1, 53, input, this->mutable_float_data())));
} else if (tag == 50) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, this->mutable_float_data())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(53)) goto parse_float_data;
if (input->ExpectTag(56)) goto parse_encoded;
break;
}
// optional bool encoded = 7 [default = false];
case 7: {
if (tag == 56) {
parse_encoded:
set_has_encoded();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &encoded_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.Datum)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.Datum)
return false;
#undef DO_
}
void Datum::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.Datum)
// optional int32 channels = 1;
if (has_channels()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(1, this->channels(), output);
}
// optional int32 height = 2;
if (has_height()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->height(), output);
}
// optional int32 width = 3;
if (has_width()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(3, this->width(), output);
}
// optional bytes data = 4;
if (has_data()) {
::google::protobuf::internal::WireFormatLite::WriteBytesMaybeAliased(
4, this->data(), output);
}
// optional int32 label = 5;
if (has_label()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(5, this->label(), output);
}
// repeated float float_data = 6;
for (int i = 0; i < this->float_data_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteFloat(
6, this->float_data(i), output);
}
// optional bool encoded = 7 [default = false];
if (has_encoded()) {
::google::protobuf::internal::WireFormatLite::WriteBool(7, this->encoded(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.Datum)
}
::google::protobuf::uint8* Datum::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.Datum)
// optional int32 channels = 1;
if (has_channels()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(1, this->channels(), target);
}
// optional int32 height = 2;
if (has_height()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(2, this->height(), target);
}
// optional int32 width = 3;
if (has_width()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(3, this->width(), target);
}
// optional bytes data = 4;
if (has_data()) {
target =
::google::protobuf::internal::WireFormatLite::WriteBytesToArray(
4, this->data(), target);
}
// optional int32 label = 5;
if (has_label()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(5, this->label(), target);
}
// repeated float float_data = 6;
for (int i = 0; i < this->float_data_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteFloatToArray(6, this->float_data(i), target);
}
// optional bool encoded = 7 [default = false];
if (has_encoded()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(7, this->encoded(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.Datum)
return target;
}
size_t Datum::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.Datum)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 95u) {
// optional int32 channels = 1;
if (has_channels()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->channels());
}
// optional int32 height = 2;
if (has_height()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->height());
}
// optional int32 width = 3;
if (has_width()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->width());
}
// optional bytes data = 4;
if (has_data()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::BytesSize(
this->data());
}
// optional int32 label = 5;
if (has_label()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->label());
}
// optional bool encoded = 7 [default = false];
if (has_encoded()) {
total_size += 1 + 1;
}
}
// repeated float float_data = 6;
{
size_t data_size = 0;
unsigned int count = this->float_data_size();
data_size = 4UL * count;
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->float_data_size());
total_size += data_size;
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void Datum::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.Datum)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const Datum* source =
::google::protobuf::internal::DynamicCastToGenerated<const Datum>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.Datum)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.Datum)
UnsafeMergeFrom(*source);
}
}
void Datum::MergeFrom(const Datum& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.Datum)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void Datum::UnsafeMergeFrom(const Datum& from) {
GOOGLE_DCHECK(&from != this);
float_data_.UnsafeMergeFrom(from.float_data_);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_channels()) {
set_channels(from.channels());
}
if (from.has_height()) {
set_height(from.height());
}
if (from.has_width()) {
set_width(from.width());
}
if (from.has_data()) {
set_has_data();
data_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.data_);
}
if (from.has_label()) {
set_label(from.label());
}
if (from.has_encoded()) {
set_encoded(from.encoded());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void Datum::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.Datum)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void Datum::CopyFrom(const Datum& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.Datum)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool Datum::IsInitialized() const {
return true;
}
void Datum::Swap(Datum* other) {
if (other == this) return;
InternalSwap(other);
}
void Datum::InternalSwap(Datum* other) {
std::swap(channels_, other->channels_);
std::swap(height_, other->height_);
std::swap(width_, other->width_);
data_.Swap(&other->data_);
std::swap(label_, other->label_);
float_data_.UnsafeArenaSwap(&other->float_data_);
std::swap(encoded_, other->encoded_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata Datum::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = Datum_descriptor_;
metadata.reflection = Datum_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// Datum
// optional int32 channels = 1;
bool Datum::has_channels() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void Datum::set_has_channels() {
_has_bits_[0] |= 0x00000001u;
}
void Datum::clear_has_channels() {
_has_bits_[0] &= ~0x00000001u;
}
void Datum::clear_channels() {
channels_ = 0;
clear_has_channels();
}
::google::protobuf::int32 Datum::channels() const {
// @@protoc_insertion_point(field_get:opencv_caffe.Datum.channels)
return channels_;
}
void Datum::set_channels(::google::protobuf::int32 value) {
set_has_channels();
channels_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.Datum.channels)
}
// optional int32 height = 2;
bool Datum::has_height() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void Datum::set_has_height() {
_has_bits_[0] |= 0x00000002u;
}
void Datum::clear_has_height() {
_has_bits_[0] &= ~0x00000002u;
}
void Datum::clear_height() {
height_ = 0;
clear_has_height();
}
::google::protobuf::int32 Datum::height() const {
// @@protoc_insertion_point(field_get:opencv_caffe.Datum.height)
return height_;
}
void Datum::set_height(::google::protobuf::int32 value) {
set_has_height();
height_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.Datum.height)
}
// optional int32 width = 3;
bool Datum::has_width() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void Datum::set_has_width() {
_has_bits_[0] |= 0x00000004u;
}
void Datum::clear_has_width() {
_has_bits_[0] &= ~0x00000004u;
}
void Datum::clear_width() {
width_ = 0;
clear_has_width();
}
::google::protobuf::int32 Datum::width() const {
// @@protoc_insertion_point(field_get:opencv_caffe.Datum.width)
return width_;
}
void Datum::set_width(::google::protobuf::int32 value) {
set_has_width();
width_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.Datum.width)
}
// optional bytes data = 4;
bool Datum::has_data() const {
return (_has_bits_[0] & 0x00000008u) != 0;
}
void Datum::set_has_data() {
_has_bits_[0] |= 0x00000008u;
}
void Datum::clear_has_data() {
_has_bits_[0] &= ~0x00000008u;
}
void Datum::clear_data() {
data_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_data();
}
const ::std::string& Datum::data() const {
// @@protoc_insertion_point(field_get:opencv_caffe.Datum.data)
return data_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void Datum::set_data(const ::std::string& value) {
set_has_data();
data_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.Datum.data)
}
void Datum::set_data(const char* value) {
set_has_data();
data_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.Datum.data)
}
void Datum::set_data(const void* value, size_t size) {
set_has_data();
data_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.Datum.data)
}
::std::string* Datum::mutable_data() {
set_has_data();
// @@protoc_insertion_point(field_mutable:opencv_caffe.Datum.data)
return data_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* Datum::release_data() {
// @@protoc_insertion_point(field_release:opencv_caffe.Datum.data)
clear_has_data();
return data_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void Datum::set_allocated_data(::std::string* data) {
if (data != NULL) {
set_has_data();
} else {
clear_has_data();
}
data_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), data);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.Datum.data)
}
// optional int32 label = 5;
bool Datum::has_label() const {
return (_has_bits_[0] & 0x00000010u) != 0;
}
void Datum::set_has_label() {
_has_bits_[0] |= 0x00000010u;
}
void Datum::clear_has_label() {
_has_bits_[0] &= ~0x00000010u;
}
void Datum::clear_label() {
label_ = 0;
clear_has_label();
}
::google::protobuf::int32 Datum::label() const {
// @@protoc_insertion_point(field_get:opencv_caffe.Datum.label)
return label_;
}
void Datum::set_label(::google::protobuf::int32 value) {
set_has_label();
label_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.Datum.label)
}
// repeated float float_data = 6;
int Datum::float_data_size() const {
return float_data_.size();
}
void Datum::clear_float_data() {
float_data_.Clear();
}
float Datum::float_data(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.Datum.float_data)
return float_data_.Get(index);
}
void Datum::set_float_data(int index, float value) {
float_data_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.Datum.float_data)
}
void Datum::add_float_data(float value) {
float_data_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.Datum.float_data)
}
const ::google::protobuf::RepeatedField< float >&
Datum::float_data() const {
// @@protoc_insertion_point(field_list:opencv_caffe.Datum.float_data)
return float_data_;
}
::google::protobuf::RepeatedField< float >*
Datum::mutable_float_data() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.Datum.float_data)
return &float_data_;
}
// optional bool encoded = 7 [default = false];
bool Datum::has_encoded() const {
return (_has_bits_[0] & 0x00000040u) != 0;
}
void Datum::set_has_encoded() {
_has_bits_[0] |= 0x00000040u;
}
void Datum::clear_has_encoded() {
_has_bits_[0] &= ~0x00000040u;
}
void Datum::clear_encoded() {
encoded_ = false;
clear_has_encoded();
}
bool Datum::encoded() const {
// @@protoc_insertion_point(field_get:opencv_caffe.Datum.encoded)
return encoded_;
}
void Datum::set_encoded(bool value) {
set_has_encoded();
encoded_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.Datum.encoded)
}
inline const Datum* Datum::internal_default_instance() {
return &Datum_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
const ::google::protobuf::EnumDescriptor* FillerParameter_VarianceNorm_descriptor() {
protobuf_AssignDescriptorsOnce();
return FillerParameter_VarianceNorm_descriptor_;
}
bool FillerParameter_VarianceNorm_IsValid(int value) {
switch (value) {
case 0:
case 1:
case 2:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const FillerParameter_VarianceNorm FillerParameter::FAN_IN;
const FillerParameter_VarianceNorm FillerParameter::FAN_OUT;
const FillerParameter_VarianceNorm FillerParameter::AVERAGE;
const FillerParameter_VarianceNorm FillerParameter::VarianceNorm_MIN;
const FillerParameter_VarianceNorm FillerParameter::VarianceNorm_MAX;
const int FillerParameter::VarianceNorm_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
::std::string* FillerParameter::_default_type_ = NULL;
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int FillerParameter::kTypeFieldNumber;
const int FillerParameter::kValueFieldNumber;
const int FillerParameter::kMinFieldNumber;
const int FillerParameter::kMaxFieldNumber;
const int FillerParameter::kMeanFieldNumber;
const int FillerParameter::kStdFieldNumber;
const int FillerParameter::kSparseFieldNumber;
const int FillerParameter::kVarianceNormFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
FillerParameter::FillerParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.FillerParameter)
}
void FillerParameter::InitAsDefaultInstance() {
}
FillerParameter::FillerParameter(const FillerParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.FillerParameter)
}
void FillerParameter::SharedCtor() {
_cached_size_ = 0;
type_.UnsafeSetDefault(_default_type_);
::memset(&value_, 0, reinterpret_cast<char*>(&variance_norm_) -
reinterpret_cast<char*>(&value_) + sizeof(variance_norm_));
sparse_ = -1;
max_ = 1;
std_ = 1;
}
FillerParameter::~FillerParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.FillerParameter)
SharedDtor();
}
void FillerParameter::SharedDtor() {
type_.DestroyNoArena(_default_type_);
}
void FillerParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* FillerParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return FillerParameter_descriptor_;
}
const FillerParameter& FillerParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<FillerParameter> FillerParameter_default_instance_;
FillerParameter* FillerParameter::New(::google::protobuf::Arena* arena) const {
FillerParameter* n = new FillerParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void FillerParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.FillerParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(FillerParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<FillerParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
if (_has_bits_[0 / 32] & 255u) {
ZR_(value_, variance_norm_);
if (has_type()) {
type_.ClearToDefaultNoArena(_default_type_);
}
max_ = 1;
std_ = 1;
sparse_ = -1;
}
#undef ZR_HELPER_
#undef ZR_
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool FillerParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.FillerParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional string type = 1 [default = "constant"];
case 1: {
if (tag == 10) {
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_type()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->type().data(), this->type().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.FillerParameter.type");
} else {
goto handle_unusual;
}
if (input->ExpectTag(21)) goto parse_value;
break;
}
// optional float value = 2 [default = 0];
case 2: {
if (tag == 21) {
parse_value:
set_has_value();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &value_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(29)) goto parse_min;
break;
}
// optional float min = 3 [default = 0];
case 3: {
if (tag == 29) {
parse_min:
set_has_min();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &min_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(37)) goto parse_max;
break;
}
// optional float max = 4 [default = 1];
case 4: {
if (tag == 37) {
parse_max:
set_has_max();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &max_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(45)) goto parse_mean;
break;
}
// optional float mean = 5 [default = 0];
case 5: {
if (tag == 45) {
parse_mean:
set_has_mean();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &mean_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(53)) goto parse_std;
break;
}
// optional float std = 6 [default = 1];
case 6: {
if (tag == 53) {
parse_std:
set_has_std();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &std_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(56)) goto parse_sparse;
break;
}
// optional int32 sparse = 7 [default = -1];
case 7: {
if (tag == 56) {
parse_sparse:
set_has_sparse();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &sparse_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(64)) goto parse_variance_norm;
break;
}
// optional .opencv_caffe.FillerParameter.VarianceNorm variance_norm = 8 [default = FAN_IN];
case 8: {
if (tag == 64) {
parse_variance_norm:
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::FillerParameter_VarianceNorm_IsValid(value)) {
set_variance_norm(static_cast< ::opencv_caffe::FillerParameter_VarianceNorm >(value));
} else {
mutable_unknown_fields()->AddVarint(8, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.FillerParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.FillerParameter)
return false;
#undef DO_
}
void FillerParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.FillerParameter)
// optional string type = 1 [default = "constant"];
if (has_type()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->type().data(), this->type().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.FillerParameter.type");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
1, this->type(), output);
}
// optional float value = 2 [default = 0];
if (has_value()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(2, this->value(), output);
}
// optional float min = 3 [default = 0];
if (has_min()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(3, this->min(), output);
}
// optional float max = 4 [default = 1];
if (has_max()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(4, this->max(), output);
}
// optional float mean = 5 [default = 0];
if (has_mean()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(5, this->mean(), output);
}
// optional float std = 6 [default = 1];
if (has_std()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(6, this->std(), output);
}
// optional int32 sparse = 7 [default = -1];
if (has_sparse()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(7, this->sparse(), output);
}
// optional .opencv_caffe.FillerParameter.VarianceNorm variance_norm = 8 [default = FAN_IN];
if (has_variance_norm()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
8, this->variance_norm(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.FillerParameter)
}
::google::protobuf::uint8* FillerParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.FillerParameter)
// optional string type = 1 [default = "constant"];
if (has_type()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->type().data(), this->type().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.FillerParameter.type");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
1, this->type(), target);
}
// optional float value = 2 [default = 0];
if (has_value()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(2, this->value(), target);
}
// optional float min = 3 [default = 0];
if (has_min()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(3, this->min(), target);
}
// optional float max = 4 [default = 1];
if (has_max()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(4, this->max(), target);
}
// optional float mean = 5 [default = 0];
if (has_mean()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(5, this->mean(), target);
}
// optional float std = 6 [default = 1];
if (has_std()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(6, this->std(), target);
}
// optional int32 sparse = 7 [default = -1];
if (has_sparse()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(7, this->sparse(), target);
}
// optional .opencv_caffe.FillerParameter.VarianceNorm variance_norm = 8 [default = FAN_IN];
if (has_variance_norm()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
8, this->variance_norm(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.FillerParameter)
return target;
}
size_t FillerParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.FillerParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 255u) {
// optional string type = 1 [default = "constant"];
if (has_type()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->type());
}
// optional float value = 2 [default = 0];
if (has_value()) {
total_size += 1 + 4;
}
// optional float min = 3 [default = 0];
if (has_min()) {
total_size += 1 + 4;
}
// optional float max = 4 [default = 1];
if (has_max()) {
total_size += 1 + 4;
}
// optional float mean = 5 [default = 0];
if (has_mean()) {
total_size += 1 + 4;
}
// optional float std = 6 [default = 1];
if (has_std()) {
total_size += 1 + 4;
}
// optional int32 sparse = 7 [default = -1];
if (has_sparse()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->sparse());
}
// optional .opencv_caffe.FillerParameter.VarianceNorm variance_norm = 8 [default = FAN_IN];
if (has_variance_norm()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->variance_norm());
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void FillerParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.FillerParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const FillerParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const FillerParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.FillerParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.FillerParameter)
UnsafeMergeFrom(*source);
}
}
void FillerParameter::MergeFrom(const FillerParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.FillerParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void FillerParameter::UnsafeMergeFrom(const FillerParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_type()) {
set_has_type();
type_.AssignWithDefault(_default_type_, from.type_);
}
if (from.has_value()) {
set_value(from.value());
}
if (from.has_min()) {
set_min(from.min());
}
if (from.has_max()) {
set_max(from.max());
}
if (from.has_mean()) {
set_mean(from.mean());
}
if (from.has_std()) {
set_std(from.std());
}
if (from.has_sparse()) {
set_sparse(from.sparse());
}
if (from.has_variance_norm()) {
set_variance_norm(from.variance_norm());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void FillerParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.FillerParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void FillerParameter::CopyFrom(const FillerParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.FillerParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool FillerParameter::IsInitialized() const {
return true;
}
void FillerParameter::Swap(FillerParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void FillerParameter::InternalSwap(FillerParameter* other) {
type_.Swap(&other->type_);
std::swap(value_, other->value_);
std::swap(min_, other->min_);
std::swap(max_, other->max_);
std::swap(mean_, other->mean_);
std::swap(std_, other->std_);
std::swap(sparse_, other->sparse_);
std::swap(variance_norm_, other->variance_norm_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata FillerParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = FillerParameter_descriptor_;
metadata.reflection = FillerParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// FillerParameter
// optional string type = 1 [default = "constant"];
bool FillerParameter::has_type() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void FillerParameter::set_has_type() {
_has_bits_[0] |= 0x00000001u;
}
void FillerParameter::clear_has_type() {
_has_bits_[0] &= ~0x00000001u;
}
void FillerParameter::clear_type() {
type_.ClearToDefaultNoArena(_default_type_);
clear_has_type();
}
const ::std::string& FillerParameter::type() const {
// @@protoc_insertion_point(field_get:opencv_caffe.FillerParameter.type)
return type_.GetNoArena(_default_type_);
}
void FillerParameter::set_type(const ::std::string& value) {
set_has_type();
type_.SetNoArena(_default_type_, value);
// @@protoc_insertion_point(field_set:opencv_caffe.FillerParameter.type)
}
void FillerParameter::set_type(const char* value) {
set_has_type();
type_.SetNoArena(_default_type_, ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.FillerParameter.type)
}
void FillerParameter::set_type(const char* value, size_t size) {
set_has_type();
type_.SetNoArena(_default_type_,
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.FillerParameter.type)
}
::std::string* FillerParameter::mutable_type() {
set_has_type();
// @@protoc_insertion_point(field_mutable:opencv_caffe.FillerParameter.type)
return type_.MutableNoArena(_default_type_);
}
::std::string* FillerParameter::release_type() {
// @@protoc_insertion_point(field_release:opencv_caffe.FillerParameter.type)
clear_has_type();
return type_.ReleaseNoArena(_default_type_);
}
void FillerParameter::set_allocated_type(::std::string* type) {
if (type != NULL) {
set_has_type();
} else {
clear_has_type();
}
type_.SetAllocatedNoArena(_default_type_, type);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.FillerParameter.type)
}
// optional float value = 2 [default = 0];
bool FillerParameter::has_value() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void FillerParameter::set_has_value() {
_has_bits_[0] |= 0x00000002u;
}
void FillerParameter::clear_has_value() {
_has_bits_[0] &= ~0x00000002u;
}
void FillerParameter::clear_value() {
value_ = 0;
clear_has_value();
}
float FillerParameter::value() const {
// @@protoc_insertion_point(field_get:opencv_caffe.FillerParameter.value)
return value_;
}
void FillerParameter::set_value(float value) {
set_has_value();
value_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.FillerParameter.value)
}
// optional float min = 3 [default = 0];
bool FillerParameter::has_min() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void FillerParameter::set_has_min() {
_has_bits_[0] |= 0x00000004u;
}
void FillerParameter::clear_has_min() {
_has_bits_[0] &= ~0x00000004u;
}
void FillerParameter::clear_min() {
min_ = 0;
clear_has_min();
}
float FillerParameter::min() const {
// @@protoc_insertion_point(field_get:opencv_caffe.FillerParameter.min)
return min_;
}
void FillerParameter::set_min(float value) {
set_has_min();
min_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.FillerParameter.min)
}
// optional float max = 4 [default = 1];
bool FillerParameter::has_max() const {
return (_has_bits_[0] & 0x00000008u) != 0;
}
void FillerParameter::set_has_max() {
_has_bits_[0] |= 0x00000008u;
}
void FillerParameter::clear_has_max() {
_has_bits_[0] &= ~0x00000008u;
}
void FillerParameter::clear_max() {
max_ = 1;
clear_has_max();
}
float FillerParameter::max() const {
// @@protoc_insertion_point(field_get:opencv_caffe.FillerParameter.max)
return max_;
}
void FillerParameter::set_max(float value) {
set_has_max();
max_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.FillerParameter.max)
}
// optional float mean = 5 [default = 0];
bool FillerParameter::has_mean() const {
return (_has_bits_[0] & 0x00000010u) != 0;
}
void FillerParameter::set_has_mean() {
_has_bits_[0] |= 0x00000010u;
}
void FillerParameter::clear_has_mean() {
_has_bits_[0] &= ~0x00000010u;
}
void FillerParameter::clear_mean() {
mean_ = 0;
clear_has_mean();
}
float FillerParameter::mean() const {
// @@protoc_insertion_point(field_get:opencv_caffe.FillerParameter.mean)
return mean_;
}
void FillerParameter::set_mean(float value) {
set_has_mean();
mean_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.FillerParameter.mean)
}
// optional float std = 6 [default = 1];
bool FillerParameter::has_std() const {
return (_has_bits_[0] & 0x00000020u) != 0;
}
void FillerParameter::set_has_std() {
_has_bits_[0] |= 0x00000020u;
}
void FillerParameter::clear_has_std() {
_has_bits_[0] &= ~0x00000020u;
}
void FillerParameter::clear_std() {
std_ = 1;
clear_has_std();
}
float FillerParameter::std() const {
// @@protoc_insertion_point(field_get:opencv_caffe.FillerParameter.std)
return std_;
}
void FillerParameter::set_std(float value) {
set_has_std();
std_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.FillerParameter.std)
}
// optional int32 sparse = 7 [default = -1];
bool FillerParameter::has_sparse() const {
return (_has_bits_[0] & 0x00000040u) != 0;
}
void FillerParameter::set_has_sparse() {
_has_bits_[0] |= 0x00000040u;
}
void FillerParameter::clear_has_sparse() {
_has_bits_[0] &= ~0x00000040u;
}
void FillerParameter::clear_sparse() {
sparse_ = -1;
clear_has_sparse();
}
::google::protobuf::int32 FillerParameter::sparse() const {
// @@protoc_insertion_point(field_get:opencv_caffe.FillerParameter.sparse)
return sparse_;
}
void FillerParameter::set_sparse(::google::protobuf::int32 value) {
set_has_sparse();
sparse_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.FillerParameter.sparse)
}
// optional .opencv_caffe.FillerParameter.VarianceNorm variance_norm = 8 [default = FAN_IN];
bool FillerParameter::has_variance_norm() const {
return (_has_bits_[0] & 0x00000080u) != 0;
}
void FillerParameter::set_has_variance_norm() {
_has_bits_[0] |= 0x00000080u;
}
void FillerParameter::clear_has_variance_norm() {
_has_bits_[0] &= ~0x00000080u;
}
void FillerParameter::clear_variance_norm() {
variance_norm_ = 0;
clear_has_variance_norm();
}
::opencv_caffe::FillerParameter_VarianceNorm FillerParameter::variance_norm() const {
// @@protoc_insertion_point(field_get:opencv_caffe.FillerParameter.variance_norm)
return static_cast< ::opencv_caffe::FillerParameter_VarianceNorm >(variance_norm_);
}
void FillerParameter::set_variance_norm(::opencv_caffe::FillerParameter_VarianceNorm value) {
assert(::opencv_caffe::FillerParameter_VarianceNorm_IsValid(value));
set_has_variance_norm();
variance_norm_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.FillerParameter.variance_norm)
}
inline const FillerParameter* FillerParameter::internal_default_instance() {
return &FillerParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int NetParameter::kNameFieldNumber;
const int NetParameter::kInputFieldNumber;
const int NetParameter::kInputShapeFieldNumber;
const int NetParameter::kInputDimFieldNumber;
const int NetParameter::kForceBackwardFieldNumber;
const int NetParameter::kStateFieldNumber;
const int NetParameter::kDebugInfoFieldNumber;
const int NetParameter::kLayerFieldNumber;
const int NetParameter::kLayersFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
NetParameter::NetParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.NetParameter)
}
void NetParameter::InitAsDefaultInstance() {
state_ = const_cast< ::opencv_caffe::NetState*>(
::opencv_caffe::NetState::internal_default_instance());
}
NetParameter::NetParameter(const NetParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.NetParameter)
}
void NetParameter::SharedCtor() {
_cached_size_ = 0;
name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
state_ = NULL;
::memset(&force_backward_, 0, reinterpret_cast<char*>(&debug_info_) -
reinterpret_cast<char*>(&force_backward_) + sizeof(debug_info_));
}
NetParameter::~NetParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.NetParameter)
SharedDtor();
}
void NetParameter::SharedDtor() {
name_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
if (this != &NetParameter_default_instance_.get()) {
delete state_;
}
}
void NetParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* NetParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return NetParameter_descriptor_;
}
const NetParameter& NetParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<NetParameter> NetParameter_default_instance_;
NetParameter* NetParameter::New(::google::protobuf::Arena* arena) const {
NetParameter* n = new NetParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void NetParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.NetParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(NetParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<NetParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
if (_has_bits_[0 / 32] & 113u) {
ZR_(force_backward_, debug_info_);
if (has_name()) {
name_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
if (has_state()) {
if (state_ != NULL) state_->::opencv_caffe::NetState::Clear();
}
}
#undef ZR_HELPER_
#undef ZR_
input_.Clear();
input_shape_.Clear();
input_dim_.Clear();
layer_.Clear();
layers_.Clear();
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool NetParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.NetParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(16383);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional string name = 1;
case 1: {
if (tag == 10) {
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_name()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->name().data(), this->name().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.NetParameter.name");
} else {
goto handle_unusual;
}
if (input->ExpectTag(18)) goto parse_layers;
break;
}
// repeated .opencv_caffe.V1LayerParameter layers = 2;
case 2: {
if (tag == 18) {
parse_layers:
DO_(input->IncrementRecursionDepth());
parse_loop_layers:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtualNoRecursionDepth(
input, add_layers()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(18)) goto parse_loop_layers;
input->UnsafeDecrementRecursionDepth();
if (input->ExpectTag(26)) goto parse_input;
break;
}
// repeated string input = 3;
case 3: {
if (tag == 26) {
parse_input:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->add_input()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->input(this->input_size() - 1).data(),
this->input(this->input_size() - 1).length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.NetParameter.input");
} else {
goto handle_unusual;
}
if (input->ExpectTag(26)) goto parse_input;
if (input->ExpectTag(32)) goto parse_input_dim;
break;
}
// repeated int32 input_dim = 4;
case 4: {
if (tag == 32) {
parse_input_dim:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
1, 32, input, this->mutable_input_dim())));
} else if (tag == 34) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, this->mutable_input_dim())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(32)) goto parse_input_dim;
if (input->ExpectTag(40)) goto parse_force_backward;
break;
}
// optional bool force_backward = 5 [default = false];
case 5: {
if (tag == 40) {
parse_force_backward:
set_has_force_backward();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &force_backward_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(50)) goto parse_state;
break;
}
// optional .opencv_caffe.NetState state = 6;
case 6: {
if (tag == 50) {
parse_state:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_state()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(56)) goto parse_debug_info;
break;
}
// optional bool debug_info = 7 [default = false];
case 7: {
if (tag == 56) {
parse_debug_info:
set_has_debug_info();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &debug_info_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(66)) goto parse_input_shape;
break;
}
// repeated .opencv_caffe.BlobShape input_shape = 8;
case 8: {
if (tag == 66) {
parse_input_shape:
DO_(input->IncrementRecursionDepth());
parse_loop_input_shape:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtualNoRecursionDepth(
input, add_input_shape()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(66)) goto parse_loop_input_shape;
if (input->ExpectTag(802)) goto parse_loop_layer;
input->UnsafeDecrementRecursionDepth();
break;
}
// repeated .opencv_caffe.LayerParameter layer = 100;
case 100: {
if (tag == 802) {
DO_(input->IncrementRecursionDepth());
parse_loop_layer:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtualNoRecursionDepth(
input, add_layer()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(802)) goto parse_loop_layer;
input->UnsafeDecrementRecursionDepth();
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.NetParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.NetParameter)
return false;
#undef DO_
}
void NetParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.NetParameter)
// optional string name = 1;
if (has_name()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->name().data(), this->name().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.NetParameter.name");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
1, this->name(), output);
}
// repeated .opencv_caffe.V1LayerParameter layers = 2;
for (unsigned int i = 0, n = this->layers_size(); i < n; i++) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
2, this->layers(i), output);
}
// repeated string input = 3;
for (int i = 0; i < this->input_size(); i++) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->input(i).data(), this->input(i).length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.NetParameter.input");
::google::protobuf::internal::WireFormatLite::WriteString(
3, this->input(i), output);
}
// repeated int32 input_dim = 4;
for (int i = 0; i < this->input_dim_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteInt32(
4, this->input_dim(i), output);
}
// optional bool force_backward = 5 [default = false];
if (has_force_backward()) {
::google::protobuf::internal::WireFormatLite::WriteBool(5, this->force_backward(), output);
}
// optional .opencv_caffe.NetState state = 6;
if (has_state()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
6, *this->state_, output);
}
// optional bool debug_info = 7 [default = false];
if (has_debug_info()) {
::google::protobuf::internal::WireFormatLite::WriteBool(7, this->debug_info(), output);
}
// repeated .opencv_caffe.BlobShape input_shape = 8;
for (unsigned int i = 0, n = this->input_shape_size(); i < n; i++) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
8, this->input_shape(i), output);
}
// repeated .opencv_caffe.LayerParameter layer = 100;
for (unsigned int i = 0, n = this->layer_size(); i < n; i++) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
100, this->layer(i), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.NetParameter)
}
::google::protobuf::uint8* NetParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.NetParameter)
// optional string name = 1;
if (has_name()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->name().data(), this->name().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.NetParameter.name");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
1, this->name(), target);
}
// repeated .opencv_caffe.V1LayerParameter layers = 2;
for (unsigned int i = 0, n = this->layers_size(); i < n; i++) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
2, this->layers(i), false, target);
}
// repeated string input = 3;
for (int i = 0; i < this->input_size(); i++) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->input(i).data(), this->input(i).length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.NetParameter.input");
target = ::google::protobuf::internal::WireFormatLite::
WriteStringToArray(3, this->input(i), target);
}
// repeated int32 input_dim = 4;
for (int i = 0; i < this->input_dim_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteInt32ToArray(4, this->input_dim(i), target);
}
// optional bool force_backward = 5 [default = false];
if (has_force_backward()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(5, this->force_backward(), target);
}
// optional .opencv_caffe.NetState state = 6;
if (has_state()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
6, *this->state_, false, target);
}
// optional bool debug_info = 7 [default = false];
if (has_debug_info()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(7, this->debug_info(), target);
}
// repeated .opencv_caffe.BlobShape input_shape = 8;
for (unsigned int i = 0, n = this->input_shape_size(); i < n; i++) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
8, this->input_shape(i), false, target);
}
// repeated .opencv_caffe.LayerParameter layer = 100;
for (unsigned int i = 0, n = this->layer_size(); i < n; i++) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
100, this->layer(i), false, target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.NetParameter)
return target;
}
size_t NetParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.NetParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 113u) {
// optional string name = 1;
if (has_name()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->name());
}
// optional bool force_backward = 5 [default = false];
if (has_force_backward()) {
total_size += 1 + 1;
}
// optional .opencv_caffe.NetState state = 6;
if (has_state()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->state_);
}
// optional bool debug_info = 7 [default = false];
if (has_debug_info()) {
total_size += 1 + 1;
}
}
// repeated string input = 3;
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->input_size());
for (int i = 0; i < this->input_size(); i++) {
total_size += ::google::protobuf::internal::WireFormatLite::StringSize(
this->input(i));
}
// repeated .opencv_caffe.BlobShape input_shape = 8;
{
unsigned int count = this->input_shape_size();
total_size += 1UL * count;
for (unsigned int i = 0; i < count; i++) {
total_size +=
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
this->input_shape(i));
}
}
// repeated int32 input_dim = 4;
{
size_t data_size = 0;
unsigned int count = this->input_dim_size();
for (unsigned int i = 0; i < count; i++) {
data_size += ::google::protobuf::internal::WireFormatLite::
Int32Size(this->input_dim(i));
}
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->input_dim_size());
total_size += data_size;
}
// repeated .opencv_caffe.LayerParameter layer = 100;
{
unsigned int count = this->layer_size();
total_size += 2UL * count;
for (unsigned int i = 0; i < count; i++) {
total_size +=
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
this->layer(i));
}
}
// repeated .opencv_caffe.V1LayerParameter layers = 2;
{
unsigned int count = this->layers_size();
total_size += 1UL * count;
for (unsigned int i = 0; i < count; i++) {
total_size +=
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
this->layers(i));
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void NetParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.NetParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const NetParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const NetParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.NetParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.NetParameter)
UnsafeMergeFrom(*source);
}
}
void NetParameter::MergeFrom(const NetParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.NetParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void NetParameter::UnsafeMergeFrom(const NetParameter& from) {
GOOGLE_DCHECK(&from != this);
input_.UnsafeMergeFrom(from.input_);
input_shape_.MergeFrom(from.input_shape_);
input_dim_.UnsafeMergeFrom(from.input_dim_);
layer_.MergeFrom(from.layer_);
layers_.MergeFrom(from.layers_);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_name()) {
set_has_name();
name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.name_);
}
if (from.has_force_backward()) {
set_force_backward(from.force_backward());
}
if (from.has_state()) {
mutable_state()->::opencv_caffe::NetState::MergeFrom(from.state());
}
if (from.has_debug_info()) {
set_debug_info(from.debug_info());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void NetParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.NetParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void NetParameter::CopyFrom(const NetParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.NetParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool NetParameter::IsInitialized() const {
if (!::google::protobuf::internal::AllAreInitialized(this->layer())) return false;
return true;
}
void NetParameter::Swap(NetParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void NetParameter::InternalSwap(NetParameter* other) {
name_.Swap(&other->name_);
input_.UnsafeArenaSwap(&other->input_);
input_shape_.UnsafeArenaSwap(&other->input_shape_);
input_dim_.UnsafeArenaSwap(&other->input_dim_);
std::swap(force_backward_, other->force_backward_);
std::swap(state_, other->state_);
std::swap(debug_info_, other->debug_info_);
layer_.UnsafeArenaSwap(&other->layer_);
layers_.UnsafeArenaSwap(&other->layers_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata NetParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = NetParameter_descriptor_;
metadata.reflection = NetParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// NetParameter
// optional string name = 1;
bool NetParameter::has_name() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void NetParameter::set_has_name() {
_has_bits_[0] |= 0x00000001u;
}
void NetParameter::clear_has_name() {
_has_bits_[0] &= ~0x00000001u;
}
void NetParameter::clear_name() {
name_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_name();
}
const ::std::string& NetParameter::name() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NetParameter.name)
return name_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void NetParameter::set_name(const ::std::string& value) {
set_has_name();
name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.NetParameter.name)
}
void NetParameter::set_name(const char* value) {
set_has_name();
name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.NetParameter.name)
}
void NetParameter::set_name(const char* value, size_t size) {
set_has_name();
name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.NetParameter.name)
}
::std::string* NetParameter::mutable_name() {
set_has_name();
// @@protoc_insertion_point(field_mutable:opencv_caffe.NetParameter.name)
return name_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* NetParameter::release_name() {
// @@protoc_insertion_point(field_release:opencv_caffe.NetParameter.name)
clear_has_name();
return name_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void NetParameter::set_allocated_name(::std::string* name) {
if (name != NULL) {
set_has_name();
} else {
clear_has_name();
}
name_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), name);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.NetParameter.name)
}
// repeated string input = 3;
int NetParameter::input_size() const {
return input_.size();
}
void NetParameter::clear_input() {
input_.Clear();
}
const ::std::string& NetParameter::input(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.NetParameter.input)
return input_.Get(index);
}
::std::string* NetParameter::mutable_input(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.NetParameter.input)
return input_.Mutable(index);
}
void NetParameter::set_input(int index, const ::std::string& value) {
// @@protoc_insertion_point(field_set:opencv_caffe.NetParameter.input)
input_.Mutable(index)->assign(value);
}
void NetParameter::set_input(int index, const char* value) {
input_.Mutable(index)->assign(value);
// @@protoc_insertion_point(field_set_char:opencv_caffe.NetParameter.input)
}
void NetParameter::set_input(int index, const char* value, size_t size) {
input_.Mutable(index)->assign(
reinterpret_cast<const char*>(value), size);
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.NetParameter.input)
}
::std::string* NetParameter::add_input() {
// @@protoc_insertion_point(field_add_mutable:opencv_caffe.NetParameter.input)
return input_.Add();
}
void NetParameter::add_input(const ::std::string& value) {
input_.Add()->assign(value);
// @@protoc_insertion_point(field_add:opencv_caffe.NetParameter.input)
}
void NetParameter::add_input(const char* value) {
input_.Add()->assign(value);
// @@protoc_insertion_point(field_add_char:opencv_caffe.NetParameter.input)
}
void NetParameter::add_input(const char* value, size_t size) {
input_.Add()->assign(reinterpret_cast<const char*>(value), size);
// @@protoc_insertion_point(field_add_pointer:opencv_caffe.NetParameter.input)
}
const ::google::protobuf::RepeatedPtrField< ::std::string>&
NetParameter::input() const {
// @@protoc_insertion_point(field_list:opencv_caffe.NetParameter.input)
return input_;
}
::google::protobuf::RepeatedPtrField< ::std::string>*
NetParameter::mutable_input() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.NetParameter.input)
return &input_;
}
// repeated .opencv_caffe.BlobShape input_shape = 8;
int NetParameter::input_shape_size() const {
return input_shape_.size();
}
void NetParameter::clear_input_shape() {
input_shape_.Clear();
}
const ::opencv_caffe::BlobShape& NetParameter::input_shape(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.NetParameter.input_shape)
return input_shape_.Get(index);
}
::opencv_caffe::BlobShape* NetParameter::mutable_input_shape(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.NetParameter.input_shape)
return input_shape_.Mutable(index);
}
::opencv_caffe::BlobShape* NetParameter::add_input_shape() {
// @@protoc_insertion_point(field_add:opencv_caffe.NetParameter.input_shape)
return input_shape_.Add();
}
::google::protobuf::RepeatedPtrField< ::opencv_caffe::BlobShape >*
NetParameter::mutable_input_shape() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.NetParameter.input_shape)
return &input_shape_;
}
const ::google::protobuf::RepeatedPtrField< ::opencv_caffe::BlobShape >&
NetParameter::input_shape() const {
// @@protoc_insertion_point(field_list:opencv_caffe.NetParameter.input_shape)
return input_shape_;
}
// repeated int32 input_dim = 4;
int NetParameter::input_dim_size() const {
return input_dim_.size();
}
void NetParameter::clear_input_dim() {
input_dim_.Clear();
}
::google::protobuf::int32 NetParameter::input_dim(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.NetParameter.input_dim)
return input_dim_.Get(index);
}
void NetParameter::set_input_dim(int index, ::google::protobuf::int32 value) {
input_dim_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.NetParameter.input_dim)
}
void NetParameter::add_input_dim(::google::protobuf::int32 value) {
input_dim_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.NetParameter.input_dim)
}
const ::google::protobuf::RepeatedField< ::google::protobuf::int32 >&
NetParameter::input_dim() const {
// @@protoc_insertion_point(field_list:opencv_caffe.NetParameter.input_dim)
return input_dim_;
}
::google::protobuf::RepeatedField< ::google::protobuf::int32 >*
NetParameter::mutable_input_dim() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.NetParameter.input_dim)
return &input_dim_;
}
// optional bool force_backward = 5 [default = false];
bool NetParameter::has_force_backward() const {
return (_has_bits_[0] & 0x00000010u) != 0;
}
void NetParameter::set_has_force_backward() {
_has_bits_[0] |= 0x00000010u;
}
void NetParameter::clear_has_force_backward() {
_has_bits_[0] &= ~0x00000010u;
}
void NetParameter::clear_force_backward() {
force_backward_ = false;
clear_has_force_backward();
}
bool NetParameter::force_backward() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NetParameter.force_backward)
return force_backward_;
}
void NetParameter::set_force_backward(bool value) {
set_has_force_backward();
force_backward_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.NetParameter.force_backward)
}
// optional .opencv_caffe.NetState state = 6;
bool NetParameter::has_state() const {
return (_has_bits_[0] & 0x00000020u) != 0;
}
void NetParameter::set_has_state() {
_has_bits_[0] |= 0x00000020u;
}
void NetParameter::clear_has_state() {
_has_bits_[0] &= ~0x00000020u;
}
void NetParameter::clear_state() {
if (state_ != NULL) state_->::opencv_caffe::NetState::Clear();
clear_has_state();
}
const ::opencv_caffe::NetState& NetParameter::state() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NetParameter.state)
return state_ != NULL ? *state_
: *::opencv_caffe::NetState::internal_default_instance();
}
::opencv_caffe::NetState* NetParameter::mutable_state() {
set_has_state();
if (state_ == NULL) {
state_ = new ::opencv_caffe::NetState;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.NetParameter.state)
return state_;
}
::opencv_caffe::NetState* NetParameter::release_state() {
// @@protoc_insertion_point(field_release:opencv_caffe.NetParameter.state)
clear_has_state();
::opencv_caffe::NetState* temp = state_;
state_ = NULL;
return temp;
}
void NetParameter::set_allocated_state(::opencv_caffe::NetState* state) {
delete state_;
state_ = state;
if (state) {
set_has_state();
} else {
clear_has_state();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.NetParameter.state)
}
// optional bool debug_info = 7 [default = false];
bool NetParameter::has_debug_info() const {
return (_has_bits_[0] & 0x00000040u) != 0;
}
void NetParameter::set_has_debug_info() {
_has_bits_[0] |= 0x00000040u;
}
void NetParameter::clear_has_debug_info() {
_has_bits_[0] &= ~0x00000040u;
}
void NetParameter::clear_debug_info() {
debug_info_ = false;
clear_has_debug_info();
}
bool NetParameter::debug_info() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NetParameter.debug_info)
return debug_info_;
}
void NetParameter::set_debug_info(bool value) {
set_has_debug_info();
debug_info_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.NetParameter.debug_info)
}
// repeated .opencv_caffe.LayerParameter layer = 100;
int NetParameter::layer_size() const {
return layer_.size();
}
void NetParameter::clear_layer() {
layer_.Clear();
}
const ::opencv_caffe::LayerParameter& NetParameter::layer(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.NetParameter.layer)
return layer_.Get(index);
}
::opencv_caffe::LayerParameter* NetParameter::mutable_layer(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.NetParameter.layer)
return layer_.Mutable(index);
}
::opencv_caffe::LayerParameter* NetParameter::add_layer() {
// @@protoc_insertion_point(field_add:opencv_caffe.NetParameter.layer)
return layer_.Add();
}
::google::protobuf::RepeatedPtrField< ::opencv_caffe::LayerParameter >*
NetParameter::mutable_layer() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.NetParameter.layer)
return &layer_;
}
const ::google::protobuf::RepeatedPtrField< ::opencv_caffe::LayerParameter >&
NetParameter::layer() const {
// @@protoc_insertion_point(field_list:opencv_caffe.NetParameter.layer)
return layer_;
}
// repeated .opencv_caffe.V1LayerParameter layers = 2;
int NetParameter::layers_size() const {
return layers_.size();
}
void NetParameter::clear_layers() {
layers_.Clear();
}
const ::opencv_caffe::V1LayerParameter& NetParameter::layers(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.NetParameter.layers)
return layers_.Get(index);
}
::opencv_caffe::V1LayerParameter* NetParameter::mutable_layers(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.NetParameter.layers)
return layers_.Mutable(index);
}
::opencv_caffe::V1LayerParameter* NetParameter::add_layers() {
// @@protoc_insertion_point(field_add:opencv_caffe.NetParameter.layers)
return layers_.Add();
}
::google::protobuf::RepeatedPtrField< ::opencv_caffe::V1LayerParameter >*
NetParameter::mutable_layers() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.NetParameter.layers)
return &layers_;
}
const ::google::protobuf::RepeatedPtrField< ::opencv_caffe::V1LayerParameter >&
NetParameter::layers() const {
// @@protoc_insertion_point(field_list:opencv_caffe.NetParameter.layers)
return layers_;
}
inline const NetParameter* NetParameter::internal_default_instance() {
return &NetParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
const ::google::protobuf::EnumDescriptor* SolverParameter_SnapshotFormat_descriptor() {
protobuf_AssignDescriptorsOnce();
return SolverParameter_SnapshotFormat_descriptor_;
}
bool SolverParameter_SnapshotFormat_IsValid(int value) {
switch (value) {
case 0:
case 1:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const SolverParameter_SnapshotFormat SolverParameter::HDF5;
const SolverParameter_SnapshotFormat SolverParameter::BINARYPROTO;
const SolverParameter_SnapshotFormat SolverParameter::SnapshotFormat_MIN;
const SolverParameter_SnapshotFormat SolverParameter::SnapshotFormat_MAX;
const int SolverParameter::SnapshotFormat_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
const ::google::protobuf::EnumDescriptor* SolverParameter_SolverMode_descriptor() {
protobuf_AssignDescriptorsOnce();
return SolverParameter_SolverMode_descriptor_;
}
bool SolverParameter_SolverMode_IsValid(int value) {
switch (value) {
case 0:
case 1:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const SolverParameter_SolverMode SolverParameter::CPU;
const SolverParameter_SolverMode SolverParameter::GPU;
const SolverParameter_SolverMode SolverParameter::SolverMode_MIN;
const SolverParameter_SolverMode SolverParameter::SolverMode_MAX;
const int SolverParameter::SolverMode_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
const ::google::protobuf::EnumDescriptor* SolverParameter_SolverType_descriptor() {
protobuf_AssignDescriptorsOnce();
return SolverParameter_SolverType_descriptor_;
}
bool SolverParameter_SolverType_IsValid(int value) {
switch (value) {
case 0:
case 1:
case 2:
case 3:
case 4:
case 5:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const SolverParameter_SolverType SolverParameter::SGD;
const SolverParameter_SolverType SolverParameter::NESTEROV;
const SolverParameter_SolverType SolverParameter::ADAGRAD;
const SolverParameter_SolverType SolverParameter::RMSPROP;
const SolverParameter_SolverType SolverParameter::ADADELTA;
const SolverParameter_SolverType SolverParameter::ADAM;
const SolverParameter_SolverType SolverParameter::SolverType_MIN;
const SolverParameter_SolverType SolverParameter::SolverType_MAX;
const int SolverParameter::SolverType_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
::std::string* SolverParameter::_default_regularization_type_ = NULL;
::std::string* SolverParameter::_default_type_ = NULL;
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int SolverParameter::kNetFieldNumber;
const int SolverParameter::kNetParamFieldNumber;
const int SolverParameter::kTrainNetFieldNumber;
const int SolverParameter::kTestNetFieldNumber;
const int SolverParameter::kTrainNetParamFieldNumber;
const int SolverParameter::kTestNetParamFieldNumber;
const int SolverParameter::kTrainStateFieldNumber;
const int SolverParameter::kTestStateFieldNumber;
const int SolverParameter::kTestIterFieldNumber;
const int SolverParameter::kTestIntervalFieldNumber;
const int SolverParameter::kTestComputeLossFieldNumber;
const int SolverParameter::kTestInitializationFieldNumber;
const int SolverParameter::kBaseLrFieldNumber;
const int SolverParameter::kDisplayFieldNumber;
const int SolverParameter::kAverageLossFieldNumber;
const int SolverParameter::kMaxIterFieldNumber;
const int SolverParameter::kIterSizeFieldNumber;
const int SolverParameter::kLrPolicyFieldNumber;
const int SolverParameter::kGammaFieldNumber;
const int SolverParameter::kPowerFieldNumber;
const int SolverParameter::kMomentumFieldNumber;
const int SolverParameter::kWeightDecayFieldNumber;
const int SolverParameter::kRegularizationTypeFieldNumber;
const int SolverParameter::kStepsizeFieldNumber;
const int SolverParameter::kStepvalueFieldNumber;
const int SolverParameter::kClipGradientsFieldNumber;
const int SolverParameter::kSnapshotFieldNumber;
const int SolverParameter::kSnapshotPrefixFieldNumber;
const int SolverParameter::kSnapshotDiffFieldNumber;
const int SolverParameter::kSnapshotFormatFieldNumber;
const int SolverParameter::kSolverModeFieldNumber;
const int SolverParameter::kDeviceIdFieldNumber;
const int SolverParameter::kRandomSeedFieldNumber;
const int SolverParameter::kTypeFieldNumber;
const int SolverParameter::kDeltaFieldNumber;
const int SolverParameter::kMomentum2FieldNumber;
const int SolverParameter::kRmsDecayFieldNumber;
const int SolverParameter::kDebugInfoFieldNumber;
const int SolverParameter::kSnapshotAfterTrainFieldNumber;
const int SolverParameter::kSolverTypeFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
SolverParameter::SolverParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.SolverParameter)
}
void SolverParameter::InitAsDefaultInstance() {
net_param_ = const_cast< ::opencv_caffe::NetParameter*>(
::opencv_caffe::NetParameter::internal_default_instance());
train_net_param_ = const_cast< ::opencv_caffe::NetParameter*>(
::opencv_caffe::NetParameter::internal_default_instance());
train_state_ = const_cast< ::opencv_caffe::NetState*>(
::opencv_caffe::NetState::internal_default_instance());
}
SolverParameter::SolverParameter(const SolverParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.SolverParameter)
}
void SolverParameter::SharedCtor() {
net_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
train_net_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
lr_policy_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
regularization_type_.UnsafeSetDefault(_default_regularization_type_);
snapshot_prefix_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
type_.UnsafeSetDefault(_default_type_);
net_param_ = NULL;
train_net_param_ = NULL;
train_state_ = NULL;
::memset(&test_interval_, 0, reinterpret_cast<char*>(&solver_type_) -
reinterpret_cast<char*>(&test_interval_) + sizeof(solver_type_));
rms_decay_ = 0.99f;
average_loss_ = 1;
iter_size_ = 1;
test_initialization_ = true;
snapshot_after_train_ = true;
clip_gradients_ = -1;
snapshot_format_ = 1;
solver_mode_ = 1;
random_seed_ = GOOGLE_LONGLONG(-1);
delta_ = 1e-08f;
momentum2_ = 0.999f;
_cached_size_ = 0;
}
SolverParameter::~SolverParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.SolverParameter)
SharedDtor();
}
void SolverParameter::SharedDtor() {
net_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
train_net_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
lr_policy_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
regularization_type_.DestroyNoArena(_default_regularization_type_);
snapshot_prefix_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
type_.DestroyNoArena(_default_type_);
if (this != &SolverParameter_default_instance_.get()) {
delete net_param_;
delete train_net_param_;
delete train_state_;
}
}
void SolverParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* SolverParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return SolverParameter_descriptor_;
}
const SolverParameter& SolverParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<SolverParameter> SolverParameter_default_instance_;
SolverParameter* SolverParameter::New(::google::protobuf::Arena* arena) const {
SolverParameter* n = new SolverParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void SolverParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.SolverParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(SolverParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<SolverParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
if (_has_bits_[0 / 32] & 87u) {
if (has_net()) {
net_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
if (has_net_param()) {
if (net_param_ != NULL) net_param_->::opencv_caffe::NetParameter::Clear();
}
if (has_train_net()) {
train_net_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
if (has_train_net_param()) {
if (train_net_param_ != NULL) train_net_param_->::opencv_caffe::NetParameter::Clear();
}
if (has_train_state()) {
if (train_state_ != NULL) train_state_->::opencv_caffe::NetState::Clear();
}
}
if (_has_bits_[8 / 32] & 65024u) {
ZR_(test_interval_, max_iter_);
test_compute_loss_ = false;
test_initialization_ = true;
average_loss_ = 1;
}
if (_has_bits_[16 / 32] & 16711680u) {
ZR_(gamma_, stepsize_);
iter_size_ = 1;
if (has_lr_policy()) {
lr_policy_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
if (has_regularization_type()) {
regularization_type_.ClearToDefaultNoArena(_default_regularization_type_);
}
}
if (_has_bits_[24 / 32] & 4261412864u) {
ZR_(snapshot_, device_id_);
clip_gradients_ = -1;
if (has_snapshot_prefix()) {
snapshot_prefix_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
snapshot_diff_ = false;
snapshot_format_ = 1;
solver_mode_ = 1;
}
if (_has_bits_[32 / 32] & 255u) {
random_seed_ = GOOGLE_LONGLONG(-1);
if (has_type()) {
type_.ClearToDefaultNoArena(_default_type_);
}
delta_ = 1e-08f;
momentum2_ = 0.999f;
rms_decay_ = 0.99f;
debug_info_ = false;
snapshot_after_train_ = true;
solver_type_ = 0;
}
#undef ZR_HELPER_
#undef ZR_
test_net_.Clear();
test_net_param_.Clear();
test_state_.Clear();
test_iter_.Clear();
stepvalue_.Clear();
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool SolverParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.SolverParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(16383);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional string train_net = 1;
case 1: {
if (tag == 10) {
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_train_net()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->train_net().data(), this->train_net().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.SolverParameter.train_net");
} else {
goto handle_unusual;
}
if (input->ExpectTag(18)) goto parse_test_net;
break;
}
// repeated string test_net = 2;
case 2: {
if (tag == 18) {
parse_test_net:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->add_test_net()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->test_net(this->test_net_size() - 1).data(),
this->test_net(this->test_net_size() - 1).length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.SolverParameter.test_net");
} else {
goto handle_unusual;
}
if (input->ExpectTag(18)) goto parse_test_net;
if (input->ExpectTag(24)) goto parse_test_iter;
break;
}
// repeated int32 test_iter = 3;
case 3: {
if (tag == 24) {
parse_test_iter:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
1, 24, input, this->mutable_test_iter())));
} else if (tag == 26) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, this->mutable_test_iter())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(24)) goto parse_test_iter;
if (input->ExpectTag(32)) goto parse_test_interval;
break;
}
// optional int32 test_interval = 4 [default = 0];
case 4: {
if (tag == 32) {
parse_test_interval:
set_has_test_interval();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &test_interval_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(45)) goto parse_base_lr;
break;
}
// optional float base_lr = 5;
case 5: {
if (tag == 45) {
parse_base_lr:
set_has_base_lr();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &base_lr_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(48)) goto parse_display;
break;
}
// optional int32 display = 6;
case 6: {
if (tag == 48) {
parse_display:
set_has_display();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &display_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(56)) goto parse_max_iter;
break;
}
// optional int32 max_iter = 7;
case 7: {
if (tag == 56) {
parse_max_iter:
set_has_max_iter();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &max_iter_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(66)) goto parse_lr_policy;
break;
}
// optional string lr_policy = 8;
case 8: {
if (tag == 66) {
parse_lr_policy:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_lr_policy()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->lr_policy().data(), this->lr_policy().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.SolverParameter.lr_policy");
} else {
goto handle_unusual;
}
if (input->ExpectTag(77)) goto parse_gamma;
break;
}
// optional float gamma = 9;
case 9: {
if (tag == 77) {
parse_gamma:
set_has_gamma();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &gamma_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(85)) goto parse_power;
break;
}
// optional float power = 10;
case 10: {
if (tag == 85) {
parse_power:
set_has_power();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &power_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(93)) goto parse_momentum;
break;
}
// optional float momentum = 11;
case 11: {
if (tag == 93) {
parse_momentum:
set_has_momentum();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &momentum_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(101)) goto parse_weight_decay;
break;
}
// optional float weight_decay = 12;
case 12: {
if (tag == 101) {
parse_weight_decay:
set_has_weight_decay();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &weight_decay_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(104)) goto parse_stepsize;
break;
}
// optional int32 stepsize = 13;
case 13: {
if (tag == 104) {
parse_stepsize:
set_has_stepsize();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &stepsize_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(112)) goto parse_snapshot;
break;
}
// optional int32 snapshot = 14 [default = 0];
case 14: {
if (tag == 112) {
parse_snapshot:
set_has_snapshot();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &snapshot_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(122)) goto parse_snapshot_prefix;
break;
}
// optional string snapshot_prefix = 15;
case 15: {
if (tag == 122) {
parse_snapshot_prefix:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_snapshot_prefix()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->snapshot_prefix().data(), this->snapshot_prefix().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.SolverParameter.snapshot_prefix");
} else {
goto handle_unusual;
}
if (input->ExpectTag(128)) goto parse_snapshot_diff;
break;
}
// optional bool snapshot_diff = 16 [default = false];
case 16: {
if (tag == 128) {
parse_snapshot_diff:
set_has_snapshot_diff();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &snapshot_diff_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(136)) goto parse_solver_mode;
break;
}
// optional .opencv_caffe.SolverParameter.SolverMode solver_mode = 17 [default = GPU];
case 17: {
if (tag == 136) {
parse_solver_mode:
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::SolverParameter_SolverMode_IsValid(value)) {
set_solver_mode(static_cast< ::opencv_caffe::SolverParameter_SolverMode >(value));
} else {
mutable_unknown_fields()->AddVarint(17, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectTag(144)) goto parse_device_id;
break;
}
// optional int32 device_id = 18 [default = 0];
case 18: {
if (tag == 144) {
parse_device_id:
set_has_device_id();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &device_id_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(152)) goto parse_test_compute_loss;
break;
}
// optional bool test_compute_loss = 19 [default = false];
case 19: {
if (tag == 152) {
parse_test_compute_loss:
set_has_test_compute_loss();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &test_compute_loss_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(160)) goto parse_random_seed;
break;
}
// optional int64 random_seed = 20 [default = -1];
case 20: {
if (tag == 160) {
parse_random_seed:
set_has_random_seed();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int64, ::google::protobuf::internal::WireFormatLite::TYPE_INT64>(
input, &random_seed_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(170)) goto parse_train_net_param;
break;
}
// optional .opencv_caffe.NetParameter train_net_param = 21;
case 21: {
if (tag == 170) {
parse_train_net_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_train_net_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(178)) goto parse_test_net_param;
break;
}
// repeated .opencv_caffe.NetParameter test_net_param = 22;
case 22: {
if (tag == 178) {
parse_test_net_param:
DO_(input->IncrementRecursionDepth());
parse_loop_test_net_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtualNoRecursionDepth(
input, add_test_net_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(178)) goto parse_loop_test_net_param;
input->UnsafeDecrementRecursionDepth();
if (input->ExpectTag(184)) goto parse_debug_info;
break;
}
// optional bool debug_info = 23 [default = false];
case 23: {
if (tag == 184) {
parse_debug_info:
set_has_debug_info();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &debug_info_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(194)) goto parse_net;
break;
}
// optional string net = 24;
case 24: {
if (tag == 194) {
parse_net:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_net()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->net().data(), this->net().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.SolverParameter.net");
} else {
goto handle_unusual;
}
if (input->ExpectTag(202)) goto parse_net_param;
break;
}
// optional .opencv_caffe.NetParameter net_param = 25;
case 25: {
if (tag == 202) {
parse_net_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_net_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(210)) goto parse_train_state;
break;
}
// optional .opencv_caffe.NetState train_state = 26;
case 26: {
if (tag == 210) {
parse_train_state:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_train_state()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(218)) goto parse_test_state;
break;
}
// repeated .opencv_caffe.NetState test_state = 27;
case 27: {
if (tag == 218) {
parse_test_state:
DO_(input->IncrementRecursionDepth());
parse_loop_test_state:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtualNoRecursionDepth(
input, add_test_state()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(218)) goto parse_loop_test_state;
input->UnsafeDecrementRecursionDepth();
if (input->ExpectTag(224)) goto parse_snapshot_after_train;
break;
}
// optional bool snapshot_after_train = 28 [default = true];
case 28: {
if (tag == 224) {
parse_snapshot_after_train:
set_has_snapshot_after_train();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &snapshot_after_train_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(234)) goto parse_regularization_type;
break;
}
// optional string regularization_type = 29 [default = "L2"];
case 29: {
if (tag == 234) {
parse_regularization_type:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_regularization_type()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->regularization_type().data(), this->regularization_type().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.SolverParameter.regularization_type");
} else {
goto handle_unusual;
}
if (input->ExpectTag(240)) goto parse_solver_type;
break;
}
// optional .opencv_caffe.SolverParameter.SolverType solver_type = 30 [default = SGD];
case 30: {
if (tag == 240) {
parse_solver_type:
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::SolverParameter_SolverType_IsValid(value)) {
set_solver_type(static_cast< ::opencv_caffe::SolverParameter_SolverType >(value));
} else {
mutable_unknown_fields()->AddVarint(30, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectTag(253)) goto parse_delta;
break;
}
// optional float delta = 31 [default = 1e-08];
case 31: {
if (tag == 253) {
parse_delta:
set_has_delta();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &delta_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(256)) goto parse_test_initialization;
break;
}
// optional bool test_initialization = 32 [default = true];
case 32: {
if (tag == 256) {
parse_test_initialization:
set_has_test_initialization();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &test_initialization_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(264)) goto parse_average_loss;
break;
}
// optional int32 average_loss = 33 [default = 1];
case 33: {
if (tag == 264) {
parse_average_loss:
set_has_average_loss();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &average_loss_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(272)) goto parse_stepvalue;
break;
}
// repeated int32 stepvalue = 34;
case 34: {
if (tag == 272) {
parse_stepvalue:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
2, 272, input, this->mutable_stepvalue())));
} else if (tag == 274) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, this->mutable_stepvalue())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(272)) goto parse_stepvalue;
if (input->ExpectTag(285)) goto parse_clip_gradients;
break;
}
// optional float clip_gradients = 35 [default = -1];
case 35: {
if (tag == 285) {
parse_clip_gradients:
set_has_clip_gradients();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &clip_gradients_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(288)) goto parse_iter_size;
break;
}
// optional int32 iter_size = 36 [default = 1];
case 36: {
if (tag == 288) {
parse_iter_size:
set_has_iter_size();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &iter_size_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(296)) goto parse_snapshot_format;
break;
}
// optional .opencv_caffe.SolverParameter.SnapshotFormat snapshot_format = 37 [default = BINARYPROTO];
case 37: {
if (tag == 296) {
parse_snapshot_format:
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::SolverParameter_SnapshotFormat_IsValid(value)) {
set_snapshot_format(static_cast< ::opencv_caffe::SolverParameter_SnapshotFormat >(value));
} else {
mutable_unknown_fields()->AddVarint(37, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectTag(309)) goto parse_rms_decay;
break;
}
// optional float rms_decay = 38 [default = 0.99];
case 38: {
if (tag == 309) {
parse_rms_decay:
set_has_rms_decay();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &rms_decay_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(317)) goto parse_momentum2;
break;
}
// optional float momentum2 = 39 [default = 0.999];
case 39: {
if (tag == 317) {
parse_momentum2:
set_has_momentum2();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &momentum2_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(322)) goto parse_type;
break;
}
// optional string type = 40 [default = "SGD"];
case 40: {
if (tag == 322) {
parse_type:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_type()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->type().data(), this->type().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.SolverParameter.type");
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.SolverParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.SolverParameter)
return false;
#undef DO_
}
void SolverParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.SolverParameter)
// optional string train_net = 1;
if (has_train_net()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->train_net().data(), this->train_net().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SolverParameter.train_net");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
1, this->train_net(), output);
}
// repeated string test_net = 2;
for (int i = 0; i < this->test_net_size(); i++) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->test_net(i).data(), this->test_net(i).length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SolverParameter.test_net");
::google::protobuf::internal::WireFormatLite::WriteString(
2, this->test_net(i), output);
}
// repeated int32 test_iter = 3;
for (int i = 0; i < this->test_iter_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteInt32(
3, this->test_iter(i), output);
}
// optional int32 test_interval = 4 [default = 0];
if (has_test_interval()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(4, this->test_interval(), output);
}
// optional float base_lr = 5;
if (has_base_lr()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(5, this->base_lr(), output);
}
// optional int32 display = 6;
if (has_display()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(6, this->display(), output);
}
// optional int32 max_iter = 7;
if (has_max_iter()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(7, this->max_iter(), output);
}
// optional string lr_policy = 8;
if (has_lr_policy()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->lr_policy().data(), this->lr_policy().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SolverParameter.lr_policy");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
8, this->lr_policy(), output);
}
// optional float gamma = 9;
if (has_gamma()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(9, this->gamma(), output);
}
// optional float power = 10;
if (has_power()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(10, this->power(), output);
}
// optional float momentum = 11;
if (has_momentum()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(11, this->momentum(), output);
}
// optional float weight_decay = 12;
if (has_weight_decay()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(12, this->weight_decay(), output);
}
// optional int32 stepsize = 13;
if (has_stepsize()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(13, this->stepsize(), output);
}
// optional int32 snapshot = 14 [default = 0];
if (has_snapshot()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(14, this->snapshot(), output);
}
// optional string snapshot_prefix = 15;
if (has_snapshot_prefix()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->snapshot_prefix().data(), this->snapshot_prefix().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SolverParameter.snapshot_prefix");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
15, this->snapshot_prefix(), output);
}
// optional bool snapshot_diff = 16 [default = false];
if (has_snapshot_diff()) {
::google::protobuf::internal::WireFormatLite::WriteBool(16, this->snapshot_diff(), output);
}
// optional .opencv_caffe.SolverParameter.SolverMode solver_mode = 17 [default = GPU];
if (has_solver_mode()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
17, this->solver_mode(), output);
}
// optional int32 device_id = 18 [default = 0];
if (has_device_id()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(18, this->device_id(), output);
}
// optional bool test_compute_loss = 19 [default = false];
if (has_test_compute_loss()) {
::google::protobuf::internal::WireFormatLite::WriteBool(19, this->test_compute_loss(), output);
}
// optional int64 random_seed = 20 [default = -1];
if (has_random_seed()) {
::google::protobuf::internal::WireFormatLite::WriteInt64(20, this->random_seed(), output);
}
// optional .opencv_caffe.NetParameter train_net_param = 21;
if (has_train_net_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
21, *this->train_net_param_, output);
}
// repeated .opencv_caffe.NetParameter test_net_param = 22;
for (unsigned int i = 0, n = this->test_net_param_size(); i < n; i++) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
22, this->test_net_param(i), output);
}
// optional bool debug_info = 23 [default = false];
if (has_debug_info()) {
::google::protobuf::internal::WireFormatLite::WriteBool(23, this->debug_info(), output);
}
// optional string net = 24;
if (has_net()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->net().data(), this->net().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SolverParameter.net");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
24, this->net(), output);
}
// optional .opencv_caffe.NetParameter net_param = 25;
if (has_net_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
25, *this->net_param_, output);
}
// optional .opencv_caffe.NetState train_state = 26;
if (has_train_state()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
26, *this->train_state_, output);
}
// repeated .opencv_caffe.NetState test_state = 27;
for (unsigned int i = 0, n = this->test_state_size(); i < n; i++) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
27, this->test_state(i), output);
}
// optional bool snapshot_after_train = 28 [default = true];
if (has_snapshot_after_train()) {
::google::protobuf::internal::WireFormatLite::WriteBool(28, this->snapshot_after_train(), output);
}
// optional string regularization_type = 29 [default = "L2"];
if (has_regularization_type()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->regularization_type().data(), this->regularization_type().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SolverParameter.regularization_type");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
29, this->regularization_type(), output);
}
// optional .opencv_caffe.SolverParameter.SolverType solver_type = 30 [default = SGD];
if (has_solver_type()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
30, this->solver_type(), output);
}
// optional float delta = 31 [default = 1e-08];
if (has_delta()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(31, this->delta(), output);
}
// optional bool test_initialization = 32 [default = true];
if (has_test_initialization()) {
::google::protobuf::internal::WireFormatLite::WriteBool(32, this->test_initialization(), output);
}
// optional int32 average_loss = 33 [default = 1];
if (has_average_loss()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(33, this->average_loss(), output);
}
// repeated int32 stepvalue = 34;
for (int i = 0; i < this->stepvalue_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteInt32(
34, this->stepvalue(i), output);
}
// optional float clip_gradients = 35 [default = -1];
if (has_clip_gradients()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(35, this->clip_gradients(), output);
}
// optional int32 iter_size = 36 [default = 1];
if (has_iter_size()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(36, this->iter_size(), output);
}
// optional .opencv_caffe.SolverParameter.SnapshotFormat snapshot_format = 37 [default = BINARYPROTO];
if (has_snapshot_format()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
37, this->snapshot_format(), output);
}
// optional float rms_decay = 38 [default = 0.99];
if (has_rms_decay()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(38, this->rms_decay(), output);
}
// optional float momentum2 = 39 [default = 0.999];
if (has_momentum2()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(39, this->momentum2(), output);
}
// optional string type = 40 [default = "SGD"];
if (has_type()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->type().data(), this->type().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SolverParameter.type");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
40, this->type(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.SolverParameter)
}
::google::protobuf::uint8* SolverParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.SolverParameter)
// optional string train_net = 1;
if (has_train_net()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->train_net().data(), this->train_net().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SolverParameter.train_net");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
1, this->train_net(), target);
}
// repeated string test_net = 2;
for (int i = 0; i < this->test_net_size(); i++) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->test_net(i).data(), this->test_net(i).length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SolverParameter.test_net");
target = ::google::protobuf::internal::WireFormatLite::
WriteStringToArray(2, this->test_net(i), target);
}
// repeated int32 test_iter = 3;
for (int i = 0; i < this->test_iter_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteInt32ToArray(3, this->test_iter(i), target);
}
// optional int32 test_interval = 4 [default = 0];
if (has_test_interval()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(4, this->test_interval(), target);
}
// optional float base_lr = 5;
if (has_base_lr()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(5, this->base_lr(), target);
}
// optional int32 display = 6;
if (has_display()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(6, this->display(), target);
}
// optional int32 max_iter = 7;
if (has_max_iter()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(7, this->max_iter(), target);
}
// optional string lr_policy = 8;
if (has_lr_policy()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->lr_policy().data(), this->lr_policy().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SolverParameter.lr_policy");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
8, this->lr_policy(), target);
}
// optional float gamma = 9;
if (has_gamma()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(9, this->gamma(), target);
}
// optional float power = 10;
if (has_power()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(10, this->power(), target);
}
// optional float momentum = 11;
if (has_momentum()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(11, this->momentum(), target);
}
// optional float weight_decay = 12;
if (has_weight_decay()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(12, this->weight_decay(), target);
}
// optional int32 stepsize = 13;
if (has_stepsize()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(13, this->stepsize(), target);
}
// optional int32 snapshot = 14 [default = 0];
if (has_snapshot()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(14, this->snapshot(), target);
}
// optional string snapshot_prefix = 15;
if (has_snapshot_prefix()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->snapshot_prefix().data(), this->snapshot_prefix().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SolverParameter.snapshot_prefix");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
15, this->snapshot_prefix(), target);
}
// optional bool snapshot_diff = 16 [default = false];
if (has_snapshot_diff()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(16, this->snapshot_diff(), target);
}
// optional .opencv_caffe.SolverParameter.SolverMode solver_mode = 17 [default = GPU];
if (has_solver_mode()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
17, this->solver_mode(), target);
}
// optional int32 device_id = 18 [default = 0];
if (has_device_id()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(18, this->device_id(), target);
}
// optional bool test_compute_loss = 19 [default = false];
if (has_test_compute_loss()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(19, this->test_compute_loss(), target);
}
// optional int64 random_seed = 20 [default = -1];
if (has_random_seed()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt64ToArray(20, this->random_seed(), target);
}
// optional .opencv_caffe.NetParameter train_net_param = 21;
if (has_train_net_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
21, *this->train_net_param_, false, target);
}
// repeated .opencv_caffe.NetParameter test_net_param = 22;
for (unsigned int i = 0, n = this->test_net_param_size(); i < n; i++) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
22, this->test_net_param(i), false, target);
}
// optional bool debug_info = 23 [default = false];
if (has_debug_info()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(23, this->debug_info(), target);
}
// optional string net = 24;
if (has_net()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->net().data(), this->net().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SolverParameter.net");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
24, this->net(), target);
}
// optional .opencv_caffe.NetParameter net_param = 25;
if (has_net_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
25, *this->net_param_, false, target);
}
// optional .opencv_caffe.NetState train_state = 26;
if (has_train_state()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
26, *this->train_state_, false, target);
}
// repeated .opencv_caffe.NetState test_state = 27;
for (unsigned int i = 0, n = this->test_state_size(); i < n; i++) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
27, this->test_state(i), false, target);
}
// optional bool snapshot_after_train = 28 [default = true];
if (has_snapshot_after_train()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(28, this->snapshot_after_train(), target);
}
// optional string regularization_type = 29 [default = "L2"];
if (has_regularization_type()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->regularization_type().data(), this->regularization_type().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SolverParameter.regularization_type");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
29, this->regularization_type(), target);
}
// optional .opencv_caffe.SolverParameter.SolverType solver_type = 30 [default = SGD];
if (has_solver_type()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
30, this->solver_type(), target);
}
// optional float delta = 31 [default = 1e-08];
if (has_delta()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(31, this->delta(), target);
}
// optional bool test_initialization = 32 [default = true];
if (has_test_initialization()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(32, this->test_initialization(), target);
}
// optional int32 average_loss = 33 [default = 1];
if (has_average_loss()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(33, this->average_loss(), target);
}
// repeated int32 stepvalue = 34;
for (int i = 0; i < this->stepvalue_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteInt32ToArray(34, this->stepvalue(i), target);
}
// optional float clip_gradients = 35 [default = -1];
if (has_clip_gradients()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(35, this->clip_gradients(), target);
}
// optional int32 iter_size = 36 [default = 1];
if (has_iter_size()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(36, this->iter_size(), target);
}
// optional .opencv_caffe.SolverParameter.SnapshotFormat snapshot_format = 37 [default = BINARYPROTO];
if (has_snapshot_format()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
37, this->snapshot_format(), target);
}
// optional float rms_decay = 38 [default = 0.99];
if (has_rms_decay()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(38, this->rms_decay(), target);
}
// optional float momentum2 = 39 [default = 0.999];
if (has_momentum2()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(39, this->momentum2(), target);
}
// optional string type = 40 [default = "SGD"];
if (has_type()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->type().data(), this->type().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SolverParameter.type");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
40, this->type(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.SolverParameter)
return target;
}
size_t SolverParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.SolverParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 87u) {
// optional string net = 24;
if (has_net()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->net());
}
// optional .opencv_caffe.NetParameter net_param = 25;
if (has_net_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->net_param_);
}
// optional string train_net = 1;
if (has_train_net()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->train_net());
}
// optional .opencv_caffe.NetParameter train_net_param = 21;
if (has_train_net_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->train_net_param_);
}
// optional .opencv_caffe.NetState train_state = 26;
if (has_train_state()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->train_state_);
}
}
if (_has_bits_[9 / 32] & 65024u) {
// optional int32 test_interval = 4 [default = 0];
if (has_test_interval()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->test_interval());
}
// optional bool test_compute_loss = 19 [default = false];
if (has_test_compute_loss()) {
total_size += 2 + 1;
}
// optional bool test_initialization = 32 [default = true];
if (has_test_initialization()) {
total_size += 2 + 1;
}
// optional float base_lr = 5;
if (has_base_lr()) {
total_size += 1 + 4;
}
// optional int32 display = 6;
if (has_display()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->display());
}
// optional int32 average_loss = 33 [default = 1];
if (has_average_loss()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->average_loss());
}
// optional int32 max_iter = 7;
if (has_max_iter()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->max_iter());
}
}
if (_has_bits_[16 / 32] & 16711680u) {
// optional int32 iter_size = 36 [default = 1];
if (has_iter_size()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->iter_size());
}
// optional string lr_policy = 8;
if (has_lr_policy()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->lr_policy());
}
// optional float gamma = 9;
if (has_gamma()) {
total_size += 1 + 4;
}
// optional float power = 10;
if (has_power()) {
total_size += 1 + 4;
}
// optional float momentum = 11;
if (has_momentum()) {
total_size += 1 + 4;
}
// optional float weight_decay = 12;
if (has_weight_decay()) {
total_size += 1 + 4;
}
// optional string regularization_type = 29 [default = "L2"];
if (has_regularization_type()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->regularization_type());
}
// optional int32 stepsize = 13;
if (has_stepsize()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->stepsize());
}
}
if (_has_bits_[25 / 32] & 4261412864u) {
// optional float clip_gradients = 35 [default = -1];
if (has_clip_gradients()) {
total_size += 2 + 4;
}
// optional int32 snapshot = 14 [default = 0];
if (has_snapshot()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->snapshot());
}
// optional string snapshot_prefix = 15;
if (has_snapshot_prefix()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->snapshot_prefix());
}
// optional bool snapshot_diff = 16 [default = false];
if (has_snapshot_diff()) {
total_size += 2 + 1;
}
// optional .opencv_caffe.SolverParameter.SnapshotFormat snapshot_format = 37 [default = BINARYPROTO];
if (has_snapshot_format()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->snapshot_format());
}
// optional .opencv_caffe.SolverParameter.SolverMode solver_mode = 17 [default = GPU];
if (has_solver_mode()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->solver_mode());
}
// optional int32 device_id = 18 [default = 0];
if (has_device_id()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->device_id());
}
}
if (_has_bits_[32 / 32] & 255u) {
// optional int64 random_seed = 20 [default = -1];
if (has_random_seed()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::Int64Size(
this->random_seed());
}
// optional string type = 40 [default = "SGD"];
if (has_type()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->type());
}
// optional float delta = 31 [default = 1e-08];
if (has_delta()) {
total_size += 2 + 4;
}
// optional float momentum2 = 39 [default = 0.999];
if (has_momentum2()) {
total_size += 2 + 4;
}
// optional float rms_decay = 38 [default = 0.99];
if (has_rms_decay()) {
total_size += 2 + 4;
}
// optional bool debug_info = 23 [default = false];
if (has_debug_info()) {
total_size += 2 + 1;
}
// optional bool snapshot_after_train = 28 [default = true];
if (has_snapshot_after_train()) {
total_size += 2 + 1;
}
// optional .opencv_caffe.SolverParameter.SolverType solver_type = 30 [default = SGD];
if (has_solver_type()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->solver_type());
}
}
// repeated string test_net = 2;
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->test_net_size());
for (int i = 0; i < this->test_net_size(); i++) {
total_size += ::google::protobuf::internal::WireFormatLite::StringSize(
this->test_net(i));
}
// repeated .opencv_caffe.NetParameter test_net_param = 22;
{
unsigned int count = this->test_net_param_size();
total_size += 2UL * count;
for (unsigned int i = 0; i < count; i++) {
total_size +=
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
this->test_net_param(i));
}
}
// repeated .opencv_caffe.NetState test_state = 27;
{
unsigned int count = this->test_state_size();
total_size += 2UL * count;
for (unsigned int i = 0; i < count; i++) {
total_size +=
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
this->test_state(i));
}
}
// repeated int32 test_iter = 3;
{
size_t data_size = 0;
unsigned int count = this->test_iter_size();
for (unsigned int i = 0; i < count; i++) {
data_size += ::google::protobuf::internal::WireFormatLite::
Int32Size(this->test_iter(i));
}
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->test_iter_size());
total_size += data_size;
}
// repeated int32 stepvalue = 34;
{
size_t data_size = 0;
unsigned int count = this->stepvalue_size();
for (unsigned int i = 0; i < count; i++) {
data_size += ::google::protobuf::internal::WireFormatLite::
Int32Size(this->stepvalue(i));
}
total_size += 2 *
::google::protobuf::internal::FromIntSize(this->stepvalue_size());
total_size += data_size;
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void SolverParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.SolverParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const SolverParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const SolverParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.SolverParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.SolverParameter)
UnsafeMergeFrom(*source);
}
}
void SolverParameter::MergeFrom(const SolverParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.SolverParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void SolverParameter::UnsafeMergeFrom(const SolverParameter& from) {
GOOGLE_DCHECK(&from != this);
test_net_.UnsafeMergeFrom(from.test_net_);
test_net_param_.MergeFrom(from.test_net_param_);
test_state_.MergeFrom(from.test_state_);
test_iter_.UnsafeMergeFrom(from.test_iter_);
stepvalue_.UnsafeMergeFrom(from.stepvalue_);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_net()) {
set_has_net();
net_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.net_);
}
if (from.has_net_param()) {
mutable_net_param()->::opencv_caffe::NetParameter::MergeFrom(from.net_param());
}
if (from.has_train_net()) {
set_has_train_net();
train_net_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.train_net_);
}
if (from.has_train_net_param()) {
mutable_train_net_param()->::opencv_caffe::NetParameter::MergeFrom(from.train_net_param());
}
if (from.has_train_state()) {
mutable_train_state()->::opencv_caffe::NetState::MergeFrom(from.train_state());
}
}
if (from._has_bits_[9 / 32] & (0xffu << (9 % 32))) {
if (from.has_test_interval()) {
set_test_interval(from.test_interval());
}
if (from.has_test_compute_loss()) {
set_test_compute_loss(from.test_compute_loss());
}
if (from.has_test_initialization()) {
set_test_initialization(from.test_initialization());
}
if (from.has_base_lr()) {
set_base_lr(from.base_lr());
}
if (from.has_display()) {
set_display(from.display());
}
if (from.has_average_loss()) {
set_average_loss(from.average_loss());
}
if (from.has_max_iter()) {
set_max_iter(from.max_iter());
}
}
if (from._has_bits_[16 / 32] & (0xffu << (16 % 32))) {
if (from.has_iter_size()) {
set_iter_size(from.iter_size());
}
if (from.has_lr_policy()) {
set_has_lr_policy();
lr_policy_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.lr_policy_);
}
if (from.has_gamma()) {
set_gamma(from.gamma());
}
if (from.has_power()) {
set_power(from.power());
}
if (from.has_momentum()) {
set_momentum(from.momentum());
}
if (from.has_weight_decay()) {
set_weight_decay(from.weight_decay());
}
if (from.has_regularization_type()) {
set_has_regularization_type();
regularization_type_.AssignWithDefault(_default_regularization_type_, from.regularization_type_);
}
if (from.has_stepsize()) {
set_stepsize(from.stepsize());
}
}
if (from._has_bits_[25 / 32] & (0xffu << (25 % 32))) {
if (from.has_clip_gradients()) {
set_clip_gradients(from.clip_gradients());
}
if (from.has_snapshot()) {
set_snapshot(from.snapshot());
}
if (from.has_snapshot_prefix()) {
set_has_snapshot_prefix();
snapshot_prefix_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.snapshot_prefix_);
}
if (from.has_snapshot_diff()) {
set_snapshot_diff(from.snapshot_diff());
}
if (from.has_snapshot_format()) {
set_snapshot_format(from.snapshot_format());
}
if (from.has_solver_mode()) {
set_solver_mode(from.solver_mode());
}
if (from.has_device_id()) {
set_device_id(from.device_id());
}
}
if (from._has_bits_[32 / 32] & (0xffu << (32 % 32))) {
if (from.has_random_seed()) {
set_random_seed(from.random_seed());
}
if (from.has_type()) {
set_has_type();
type_.AssignWithDefault(_default_type_, from.type_);
}
if (from.has_delta()) {
set_delta(from.delta());
}
if (from.has_momentum2()) {
set_momentum2(from.momentum2());
}
if (from.has_rms_decay()) {
set_rms_decay(from.rms_decay());
}
if (from.has_debug_info()) {
set_debug_info(from.debug_info());
}
if (from.has_snapshot_after_train()) {
set_snapshot_after_train(from.snapshot_after_train());
}
if (from.has_solver_type()) {
set_solver_type(from.solver_type());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void SolverParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.SolverParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void SolverParameter::CopyFrom(const SolverParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.SolverParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool SolverParameter::IsInitialized() const {
if (has_net_param()) {
if (!this->net_param_->IsInitialized()) return false;
}
if (has_train_net_param()) {
if (!this->train_net_param_->IsInitialized()) return false;
}
if (!::google::protobuf::internal::AllAreInitialized(this->test_net_param())) return false;
return true;
}
void SolverParameter::Swap(SolverParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void SolverParameter::InternalSwap(SolverParameter* other) {
net_.Swap(&other->net_);
std::swap(net_param_, other->net_param_);
train_net_.Swap(&other->train_net_);
test_net_.UnsafeArenaSwap(&other->test_net_);
std::swap(train_net_param_, other->train_net_param_);
test_net_param_.UnsafeArenaSwap(&other->test_net_param_);
std::swap(train_state_, other->train_state_);
test_state_.UnsafeArenaSwap(&other->test_state_);
test_iter_.UnsafeArenaSwap(&other->test_iter_);
std::swap(test_interval_, other->test_interval_);
std::swap(test_compute_loss_, other->test_compute_loss_);
std::swap(test_initialization_, other->test_initialization_);
std::swap(base_lr_, other->base_lr_);
std::swap(display_, other->display_);
std::swap(average_loss_, other->average_loss_);
std::swap(max_iter_, other->max_iter_);
std::swap(iter_size_, other->iter_size_);
lr_policy_.Swap(&other->lr_policy_);
std::swap(gamma_, other->gamma_);
std::swap(power_, other->power_);
std::swap(momentum_, other->momentum_);
std::swap(weight_decay_, other->weight_decay_);
regularization_type_.Swap(&other->regularization_type_);
std::swap(stepsize_, other->stepsize_);
stepvalue_.UnsafeArenaSwap(&other->stepvalue_);
std::swap(clip_gradients_, other->clip_gradients_);
std::swap(snapshot_, other->snapshot_);
snapshot_prefix_.Swap(&other->snapshot_prefix_);
std::swap(snapshot_diff_, other->snapshot_diff_);
std::swap(snapshot_format_, other->snapshot_format_);
std::swap(solver_mode_, other->solver_mode_);
std::swap(device_id_, other->device_id_);
std::swap(random_seed_, other->random_seed_);
type_.Swap(&other->type_);
std::swap(delta_, other->delta_);
std::swap(momentum2_, other->momentum2_);
std::swap(rms_decay_, other->rms_decay_);
std::swap(debug_info_, other->debug_info_);
std::swap(snapshot_after_train_, other->snapshot_after_train_);
std::swap(solver_type_, other->solver_type_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
std::swap(_has_bits_[1], other->_has_bits_[1]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata SolverParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = SolverParameter_descriptor_;
metadata.reflection = SolverParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// SolverParameter
// optional string net = 24;
bool SolverParameter::has_net() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void SolverParameter::set_has_net() {
_has_bits_[0] |= 0x00000001u;
}
void SolverParameter::clear_has_net() {
_has_bits_[0] &= ~0x00000001u;
}
void SolverParameter::clear_net() {
net_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_net();
}
const ::std::string& SolverParameter::net() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.net)
return net_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void SolverParameter::set_net(const ::std::string& value) {
set_has_net();
net_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.net)
}
void SolverParameter::set_net(const char* value) {
set_has_net();
net_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.SolverParameter.net)
}
void SolverParameter::set_net(const char* value, size_t size) {
set_has_net();
net_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.SolverParameter.net)
}
::std::string* SolverParameter::mutable_net() {
set_has_net();
// @@protoc_insertion_point(field_mutable:opencv_caffe.SolverParameter.net)
return net_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* SolverParameter::release_net() {
// @@protoc_insertion_point(field_release:opencv_caffe.SolverParameter.net)
clear_has_net();
return net_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void SolverParameter::set_allocated_net(::std::string* net) {
if (net != NULL) {
set_has_net();
} else {
clear_has_net();
}
net_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), net);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.SolverParameter.net)
}
// optional .opencv_caffe.NetParameter net_param = 25;
bool SolverParameter::has_net_param() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void SolverParameter::set_has_net_param() {
_has_bits_[0] |= 0x00000002u;
}
void SolverParameter::clear_has_net_param() {
_has_bits_[0] &= ~0x00000002u;
}
void SolverParameter::clear_net_param() {
if (net_param_ != NULL) net_param_->::opencv_caffe::NetParameter::Clear();
clear_has_net_param();
}
const ::opencv_caffe::NetParameter& SolverParameter::net_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.net_param)
return net_param_ != NULL ? *net_param_
: *::opencv_caffe::NetParameter::internal_default_instance();
}
::opencv_caffe::NetParameter* SolverParameter::mutable_net_param() {
set_has_net_param();
if (net_param_ == NULL) {
net_param_ = new ::opencv_caffe::NetParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.SolverParameter.net_param)
return net_param_;
}
::opencv_caffe::NetParameter* SolverParameter::release_net_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.SolverParameter.net_param)
clear_has_net_param();
::opencv_caffe::NetParameter* temp = net_param_;
net_param_ = NULL;
return temp;
}
void SolverParameter::set_allocated_net_param(::opencv_caffe::NetParameter* net_param) {
delete net_param_;
net_param_ = net_param;
if (net_param) {
set_has_net_param();
} else {
clear_has_net_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.SolverParameter.net_param)
}
// optional string train_net = 1;
bool SolverParameter::has_train_net() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void SolverParameter::set_has_train_net() {
_has_bits_[0] |= 0x00000004u;
}
void SolverParameter::clear_has_train_net() {
_has_bits_[0] &= ~0x00000004u;
}
void SolverParameter::clear_train_net() {
train_net_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_train_net();
}
const ::std::string& SolverParameter::train_net() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.train_net)
return train_net_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void SolverParameter::set_train_net(const ::std::string& value) {
set_has_train_net();
train_net_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.train_net)
}
void SolverParameter::set_train_net(const char* value) {
set_has_train_net();
train_net_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.SolverParameter.train_net)
}
void SolverParameter::set_train_net(const char* value, size_t size) {
set_has_train_net();
train_net_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.SolverParameter.train_net)
}
::std::string* SolverParameter::mutable_train_net() {
set_has_train_net();
// @@protoc_insertion_point(field_mutable:opencv_caffe.SolverParameter.train_net)
return train_net_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* SolverParameter::release_train_net() {
// @@protoc_insertion_point(field_release:opencv_caffe.SolverParameter.train_net)
clear_has_train_net();
return train_net_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void SolverParameter::set_allocated_train_net(::std::string* train_net) {
if (train_net != NULL) {
set_has_train_net();
} else {
clear_has_train_net();
}
train_net_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), train_net);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.SolverParameter.train_net)
}
// repeated string test_net = 2;
int SolverParameter::test_net_size() const {
return test_net_.size();
}
void SolverParameter::clear_test_net() {
test_net_.Clear();
}
const ::std::string& SolverParameter::test_net(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.test_net)
return test_net_.Get(index);
}
::std::string* SolverParameter::mutable_test_net(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.SolverParameter.test_net)
return test_net_.Mutable(index);
}
void SolverParameter::set_test_net(int index, const ::std::string& value) {
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.test_net)
test_net_.Mutable(index)->assign(value);
}
void SolverParameter::set_test_net(int index, const char* value) {
test_net_.Mutable(index)->assign(value);
// @@protoc_insertion_point(field_set_char:opencv_caffe.SolverParameter.test_net)
}
void SolverParameter::set_test_net(int index, const char* value, size_t size) {
test_net_.Mutable(index)->assign(
reinterpret_cast<const char*>(value), size);
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.SolverParameter.test_net)
}
::std::string* SolverParameter::add_test_net() {
// @@protoc_insertion_point(field_add_mutable:opencv_caffe.SolverParameter.test_net)
return test_net_.Add();
}
void SolverParameter::add_test_net(const ::std::string& value) {
test_net_.Add()->assign(value);
// @@protoc_insertion_point(field_add:opencv_caffe.SolverParameter.test_net)
}
void SolverParameter::add_test_net(const char* value) {
test_net_.Add()->assign(value);
// @@protoc_insertion_point(field_add_char:opencv_caffe.SolverParameter.test_net)
}
void SolverParameter::add_test_net(const char* value, size_t size) {
test_net_.Add()->assign(reinterpret_cast<const char*>(value), size);
// @@protoc_insertion_point(field_add_pointer:opencv_caffe.SolverParameter.test_net)
}
const ::google::protobuf::RepeatedPtrField< ::std::string>&
SolverParameter::test_net() const {
// @@protoc_insertion_point(field_list:opencv_caffe.SolverParameter.test_net)
return test_net_;
}
::google::protobuf::RepeatedPtrField< ::std::string>*
SolverParameter::mutable_test_net() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.SolverParameter.test_net)
return &test_net_;
}
// optional .opencv_caffe.NetParameter train_net_param = 21;
bool SolverParameter::has_train_net_param() const {
return (_has_bits_[0] & 0x00000010u) != 0;
}
void SolverParameter::set_has_train_net_param() {
_has_bits_[0] |= 0x00000010u;
}
void SolverParameter::clear_has_train_net_param() {
_has_bits_[0] &= ~0x00000010u;
}
void SolverParameter::clear_train_net_param() {
if (train_net_param_ != NULL) train_net_param_->::opencv_caffe::NetParameter::Clear();
clear_has_train_net_param();
}
const ::opencv_caffe::NetParameter& SolverParameter::train_net_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.train_net_param)
return train_net_param_ != NULL ? *train_net_param_
: *::opencv_caffe::NetParameter::internal_default_instance();
}
::opencv_caffe::NetParameter* SolverParameter::mutable_train_net_param() {
set_has_train_net_param();
if (train_net_param_ == NULL) {
train_net_param_ = new ::opencv_caffe::NetParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.SolverParameter.train_net_param)
return train_net_param_;
}
::opencv_caffe::NetParameter* SolverParameter::release_train_net_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.SolverParameter.train_net_param)
clear_has_train_net_param();
::opencv_caffe::NetParameter* temp = train_net_param_;
train_net_param_ = NULL;
return temp;
}
void SolverParameter::set_allocated_train_net_param(::opencv_caffe::NetParameter* train_net_param) {
delete train_net_param_;
train_net_param_ = train_net_param;
if (train_net_param) {
set_has_train_net_param();
} else {
clear_has_train_net_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.SolverParameter.train_net_param)
}
// repeated .opencv_caffe.NetParameter test_net_param = 22;
int SolverParameter::test_net_param_size() const {
return test_net_param_.size();
}
void SolverParameter::clear_test_net_param() {
test_net_param_.Clear();
}
const ::opencv_caffe::NetParameter& SolverParameter::test_net_param(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.test_net_param)
return test_net_param_.Get(index);
}
::opencv_caffe::NetParameter* SolverParameter::mutable_test_net_param(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.SolverParameter.test_net_param)
return test_net_param_.Mutable(index);
}
::opencv_caffe::NetParameter* SolverParameter::add_test_net_param() {
// @@protoc_insertion_point(field_add:opencv_caffe.SolverParameter.test_net_param)
return test_net_param_.Add();
}
::google::protobuf::RepeatedPtrField< ::opencv_caffe::NetParameter >*
SolverParameter::mutable_test_net_param() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.SolverParameter.test_net_param)
return &test_net_param_;
}
const ::google::protobuf::RepeatedPtrField< ::opencv_caffe::NetParameter >&
SolverParameter::test_net_param() const {
// @@protoc_insertion_point(field_list:opencv_caffe.SolverParameter.test_net_param)
return test_net_param_;
}
// optional .opencv_caffe.NetState train_state = 26;
bool SolverParameter::has_train_state() const {
return (_has_bits_[0] & 0x00000040u) != 0;
}
void SolverParameter::set_has_train_state() {
_has_bits_[0] |= 0x00000040u;
}
void SolverParameter::clear_has_train_state() {
_has_bits_[0] &= ~0x00000040u;
}
void SolverParameter::clear_train_state() {
if (train_state_ != NULL) train_state_->::opencv_caffe::NetState::Clear();
clear_has_train_state();
}
const ::opencv_caffe::NetState& SolverParameter::train_state() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.train_state)
return train_state_ != NULL ? *train_state_
: *::opencv_caffe::NetState::internal_default_instance();
}
::opencv_caffe::NetState* SolverParameter::mutable_train_state() {
set_has_train_state();
if (train_state_ == NULL) {
train_state_ = new ::opencv_caffe::NetState;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.SolverParameter.train_state)
return train_state_;
}
::opencv_caffe::NetState* SolverParameter::release_train_state() {
// @@protoc_insertion_point(field_release:opencv_caffe.SolverParameter.train_state)
clear_has_train_state();
::opencv_caffe::NetState* temp = train_state_;
train_state_ = NULL;
return temp;
}
void SolverParameter::set_allocated_train_state(::opencv_caffe::NetState* train_state) {
delete train_state_;
train_state_ = train_state;
if (train_state) {
set_has_train_state();
} else {
clear_has_train_state();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.SolverParameter.train_state)
}
// repeated .opencv_caffe.NetState test_state = 27;
int SolverParameter::test_state_size() const {
return test_state_.size();
}
void SolverParameter::clear_test_state() {
test_state_.Clear();
}
const ::opencv_caffe::NetState& SolverParameter::test_state(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.test_state)
return test_state_.Get(index);
}
::opencv_caffe::NetState* SolverParameter::mutable_test_state(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.SolverParameter.test_state)
return test_state_.Mutable(index);
}
::opencv_caffe::NetState* SolverParameter::add_test_state() {
// @@protoc_insertion_point(field_add:opencv_caffe.SolverParameter.test_state)
return test_state_.Add();
}
::google::protobuf::RepeatedPtrField< ::opencv_caffe::NetState >*
SolverParameter::mutable_test_state() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.SolverParameter.test_state)
return &test_state_;
}
const ::google::protobuf::RepeatedPtrField< ::opencv_caffe::NetState >&
SolverParameter::test_state() const {
// @@protoc_insertion_point(field_list:opencv_caffe.SolverParameter.test_state)
return test_state_;
}
// repeated int32 test_iter = 3;
int SolverParameter::test_iter_size() const {
return test_iter_.size();
}
void SolverParameter::clear_test_iter() {
test_iter_.Clear();
}
::google::protobuf::int32 SolverParameter::test_iter(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.test_iter)
return test_iter_.Get(index);
}
void SolverParameter::set_test_iter(int index, ::google::protobuf::int32 value) {
test_iter_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.test_iter)
}
void SolverParameter::add_test_iter(::google::protobuf::int32 value) {
test_iter_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.SolverParameter.test_iter)
}
const ::google::protobuf::RepeatedField< ::google::protobuf::int32 >&
SolverParameter::test_iter() const {
// @@protoc_insertion_point(field_list:opencv_caffe.SolverParameter.test_iter)
return test_iter_;
}
::google::protobuf::RepeatedField< ::google::protobuf::int32 >*
SolverParameter::mutable_test_iter() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.SolverParameter.test_iter)
return &test_iter_;
}
// optional int32 test_interval = 4 [default = 0];
bool SolverParameter::has_test_interval() const {
return (_has_bits_[0] & 0x00000200u) != 0;
}
void SolverParameter::set_has_test_interval() {
_has_bits_[0] |= 0x00000200u;
}
void SolverParameter::clear_has_test_interval() {
_has_bits_[0] &= ~0x00000200u;
}
void SolverParameter::clear_test_interval() {
test_interval_ = 0;
clear_has_test_interval();
}
::google::protobuf::int32 SolverParameter::test_interval() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.test_interval)
return test_interval_;
}
void SolverParameter::set_test_interval(::google::protobuf::int32 value) {
set_has_test_interval();
test_interval_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.test_interval)
}
// optional bool test_compute_loss = 19 [default = false];
bool SolverParameter::has_test_compute_loss() const {
return (_has_bits_[0] & 0x00000400u) != 0;
}
void SolverParameter::set_has_test_compute_loss() {
_has_bits_[0] |= 0x00000400u;
}
void SolverParameter::clear_has_test_compute_loss() {
_has_bits_[0] &= ~0x00000400u;
}
void SolverParameter::clear_test_compute_loss() {
test_compute_loss_ = false;
clear_has_test_compute_loss();
}
bool SolverParameter::test_compute_loss() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.test_compute_loss)
return test_compute_loss_;
}
void SolverParameter::set_test_compute_loss(bool value) {
set_has_test_compute_loss();
test_compute_loss_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.test_compute_loss)
}
// optional bool test_initialization = 32 [default = true];
bool SolverParameter::has_test_initialization() const {
return (_has_bits_[0] & 0x00000800u) != 0;
}
void SolverParameter::set_has_test_initialization() {
_has_bits_[0] |= 0x00000800u;
}
void SolverParameter::clear_has_test_initialization() {
_has_bits_[0] &= ~0x00000800u;
}
void SolverParameter::clear_test_initialization() {
test_initialization_ = true;
clear_has_test_initialization();
}
bool SolverParameter::test_initialization() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.test_initialization)
return test_initialization_;
}
void SolverParameter::set_test_initialization(bool value) {
set_has_test_initialization();
test_initialization_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.test_initialization)
}
// optional float base_lr = 5;
bool SolverParameter::has_base_lr() const {
return (_has_bits_[0] & 0x00001000u) != 0;
}
void SolverParameter::set_has_base_lr() {
_has_bits_[0] |= 0x00001000u;
}
void SolverParameter::clear_has_base_lr() {
_has_bits_[0] &= ~0x00001000u;
}
void SolverParameter::clear_base_lr() {
base_lr_ = 0;
clear_has_base_lr();
}
float SolverParameter::base_lr() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.base_lr)
return base_lr_;
}
void SolverParameter::set_base_lr(float value) {
set_has_base_lr();
base_lr_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.base_lr)
}
// optional int32 display = 6;
bool SolverParameter::has_display() const {
return (_has_bits_[0] & 0x00002000u) != 0;
}
void SolverParameter::set_has_display() {
_has_bits_[0] |= 0x00002000u;
}
void SolverParameter::clear_has_display() {
_has_bits_[0] &= ~0x00002000u;
}
void SolverParameter::clear_display() {
display_ = 0;
clear_has_display();
}
::google::protobuf::int32 SolverParameter::display() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.display)
return display_;
}
void SolverParameter::set_display(::google::protobuf::int32 value) {
set_has_display();
display_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.display)
}
// optional int32 average_loss = 33 [default = 1];
bool SolverParameter::has_average_loss() const {
return (_has_bits_[0] & 0x00004000u) != 0;
}
void SolverParameter::set_has_average_loss() {
_has_bits_[0] |= 0x00004000u;
}
void SolverParameter::clear_has_average_loss() {
_has_bits_[0] &= ~0x00004000u;
}
void SolverParameter::clear_average_loss() {
average_loss_ = 1;
clear_has_average_loss();
}
::google::protobuf::int32 SolverParameter::average_loss() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.average_loss)
return average_loss_;
}
void SolverParameter::set_average_loss(::google::protobuf::int32 value) {
set_has_average_loss();
average_loss_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.average_loss)
}
// optional int32 max_iter = 7;
bool SolverParameter::has_max_iter() const {
return (_has_bits_[0] & 0x00008000u) != 0;
}
void SolverParameter::set_has_max_iter() {
_has_bits_[0] |= 0x00008000u;
}
void SolverParameter::clear_has_max_iter() {
_has_bits_[0] &= ~0x00008000u;
}
void SolverParameter::clear_max_iter() {
max_iter_ = 0;
clear_has_max_iter();
}
::google::protobuf::int32 SolverParameter::max_iter() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.max_iter)
return max_iter_;
}
void SolverParameter::set_max_iter(::google::protobuf::int32 value) {
set_has_max_iter();
max_iter_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.max_iter)
}
// optional int32 iter_size = 36 [default = 1];
bool SolverParameter::has_iter_size() const {
return (_has_bits_[0] & 0x00010000u) != 0;
}
void SolverParameter::set_has_iter_size() {
_has_bits_[0] |= 0x00010000u;
}
void SolverParameter::clear_has_iter_size() {
_has_bits_[0] &= ~0x00010000u;
}
void SolverParameter::clear_iter_size() {
iter_size_ = 1;
clear_has_iter_size();
}
::google::protobuf::int32 SolverParameter::iter_size() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.iter_size)
return iter_size_;
}
void SolverParameter::set_iter_size(::google::protobuf::int32 value) {
set_has_iter_size();
iter_size_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.iter_size)
}
// optional string lr_policy = 8;
bool SolverParameter::has_lr_policy() const {
return (_has_bits_[0] & 0x00020000u) != 0;
}
void SolverParameter::set_has_lr_policy() {
_has_bits_[0] |= 0x00020000u;
}
void SolverParameter::clear_has_lr_policy() {
_has_bits_[0] &= ~0x00020000u;
}
void SolverParameter::clear_lr_policy() {
lr_policy_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_lr_policy();
}
const ::std::string& SolverParameter::lr_policy() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.lr_policy)
return lr_policy_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void SolverParameter::set_lr_policy(const ::std::string& value) {
set_has_lr_policy();
lr_policy_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.lr_policy)
}
void SolverParameter::set_lr_policy(const char* value) {
set_has_lr_policy();
lr_policy_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.SolverParameter.lr_policy)
}
void SolverParameter::set_lr_policy(const char* value, size_t size) {
set_has_lr_policy();
lr_policy_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.SolverParameter.lr_policy)
}
::std::string* SolverParameter::mutable_lr_policy() {
set_has_lr_policy();
// @@protoc_insertion_point(field_mutable:opencv_caffe.SolverParameter.lr_policy)
return lr_policy_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* SolverParameter::release_lr_policy() {
// @@protoc_insertion_point(field_release:opencv_caffe.SolverParameter.lr_policy)
clear_has_lr_policy();
return lr_policy_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void SolverParameter::set_allocated_lr_policy(::std::string* lr_policy) {
if (lr_policy != NULL) {
set_has_lr_policy();
} else {
clear_has_lr_policy();
}
lr_policy_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), lr_policy);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.SolverParameter.lr_policy)
}
// optional float gamma = 9;
bool SolverParameter::has_gamma() const {
return (_has_bits_[0] & 0x00040000u) != 0;
}
void SolverParameter::set_has_gamma() {
_has_bits_[0] |= 0x00040000u;
}
void SolverParameter::clear_has_gamma() {
_has_bits_[0] &= ~0x00040000u;
}
void SolverParameter::clear_gamma() {
gamma_ = 0;
clear_has_gamma();
}
float SolverParameter::gamma() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.gamma)
return gamma_;
}
void SolverParameter::set_gamma(float value) {
set_has_gamma();
gamma_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.gamma)
}
// optional float power = 10;
bool SolverParameter::has_power() const {
return (_has_bits_[0] & 0x00080000u) != 0;
}
void SolverParameter::set_has_power() {
_has_bits_[0] |= 0x00080000u;
}
void SolverParameter::clear_has_power() {
_has_bits_[0] &= ~0x00080000u;
}
void SolverParameter::clear_power() {
power_ = 0;
clear_has_power();
}
float SolverParameter::power() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.power)
return power_;
}
void SolverParameter::set_power(float value) {
set_has_power();
power_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.power)
}
// optional float momentum = 11;
bool SolverParameter::has_momentum() const {
return (_has_bits_[0] & 0x00100000u) != 0;
}
void SolverParameter::set_has_momentum() {
_has_bits_[0] |= 0x00100000u;
}
void SolverParameter::clear_has_momentum() {
_has_bits_[0] &= ~0x00100000u;
}
void SolverParameter::clear_momentum() {
momentum_ = 0;
clear_has_momentum();
}
float SolverParameter::momentum() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.momentum)
return momentum_;
}
void SolverParameter::set_momentum(float value) {
set_has_momentum();
momentum_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.momentum)
}
// optional float weight_decay = 12;
bool SolverParameter::has_weight_decay() const {
return (_has_bits_[0] & 0x00200000u) != 0;
}
void SolverParameter::set_has_weight_decay() {
_has_bits_[0] |= 0x00200000u;
}
void SolverParameter::clear_has_weight_decay() {
_has_bits_[0] &= ~0x00200000u;
}
void SolverParameter::clear_weight_decay() {
weight_decay_ = 0;
clear_has_weight_decay();
}
float SolverParameter::weight_decay() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.weight_decay)
return weight_decay_;
}
void SolverParameter::set_weight_decay(float value) {
set_has_weight_decay();
weight_decay_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.weight_decay)
}
// optional string regularization_type = 29 [default = "L2"];
bool SolverParameter::has_regularization_type() const {
return (_has_bits_[0] & 0x00400000u) != 0;
}
void SolverParameter::set_has_regularization_type() {
_has_bits_[0] |= 0x00400000u;
}
void SolverParameter::clear_has_regularization_type() {
_has_bits_[0] &= ~0x00400000u;
}
void SolverParameter::clear_regularization_type() {
regularization_type_.ClearToDefaultNoArena(_default_regularization_type_);
clear_has_regularization_type();
}
const ::std::string& SolverParameter::regularization_type() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.regularization_type)
return regularization_type_.GetNoArena(_default_regularization_type_);
}
void SolverParameter::set_regularization_type(const ::std::string& value) {
set_has_regularization_type();
regularization_type_.SetNoArena(_default_regularization_type_, value);
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.regularization_type)
}
void SolverParameter::set_regularization_type(const char* value) {
set_has_regularization_type();
regularization_type_.SetNoArena(_default_regularization_type_, ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.SolverParameter.regularization_type)
}
void SolverParameter::set_regularization_type(const char* value, size_t size) {
set_has_regularization_type();
regularization_type_.SetNoArena(_default_regularization_type_,
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.SolverParameter.regularization_type)
}
::std::string* SolverParameter::mutable_regularization_type() {
set_has_regularization_type();
// @@protoc_insertion_point(field_mutable:opencv_caffe.SolverParameter.regularization_type)
return regularization_type_.MutableNoArena(_default_regularization_type_);
}
::std::string* SolverParameter::release_regularization_type() {
// @@protoc_insertion_point(field_release:opencv_caffe.SolverParameter.regularization_type)
clear_has_regularization_type();
return regularization_type_.ReleaseNoArena(_default_regularization_type_);
}
void SolverParameter::set_allocated_regularization_type(::std::string* regularization_type) {
if (regularization_type != NULL) {
set_has_regularization_type();
} else {
clear_has_regularization_type();
}
regularization_type_.SetAllocatedNoArena(_default_regularization_type_, regularization_type);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.SolverParameter.regularization_type)
}
// optional int32 stepsize = 13;
bool SolverParameter::has_stepsize() const {
return (_has_bits_[0] & 0x00800000u) != 0;
}
void SolverParameter::set_has_stepsize() {
_has_bits_[0] |= 0x00800000u;
}
void SolverParameter::clear_has_stepsize() {
_has_bits_[0] &= ~0x00800000u;
}
void SolverParameter::clear_stepsize() {
stepsize_ = 0;
clear_has_stepsize();
}
::google::protobuf::int32 SolverParameter::stepsize() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.stepsize)
return stepsize_;
}
void SolverParameter::set_stepsize(::google::protobuf::int32 value) {
set_has_stepsize();
stepsize_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.stepsize)
}
// repeated int32 stepvalue = 34;
int SolverParameter::stepvalue_size() const {
return stepvalue_.size();
}
void SolverParameter::clear_stepvalue() {
stepvalue_.Clear();
}
::google::protobuf::int32 SolverParameter::stepvalue(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.stepvalue)
return stepvalue_.Get(index);
}
void SolverParameter::set_stepvalue(int index, ::google::protobuf::int32 value) {
stepvalue_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.stepvalue)
}
void SolverParameter::add_stepvalue(::google::protobuf::int32 value) {
stepvalue_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.SolverParameter.stepvalue)
}
const ::google::protobuf::RepeatedField< ::google::protobuf::int32 >&
SolverParameter::stepvalue() const {
// @@protoc_insertion_point(field_list:opencv_caffe.SolverParameter.stepvalue)
return stepvalue_;
}
::google::protobuf::RepeatedField< ::google::protobuf::int32 >*
SolverParameter::mutable_stepvalue() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.SolverParameter.stepvalue)
return &stepvalue_;
}
// optional float clip_gradients = 35 [default = -1];
bool SolverParameter::has_clip_gradients() const {
return (_has_bits_[0] & 0x02000000u) != 0;
}
void SolverParameter::set_has_clip_gradients() {
_has_bits_[0] |= 0x02000000u;
}
void SolverParameter::clear_has_clip_gradients() {
_has_bits_[0] &= ~0x02000000u;
}
void SolverParameter::clear_clip_gradients() {
clip_gradients_ = -1;
clear_has_clip_gradients();
}
float SolverParameter::clip_gradients() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.clip_gradients)
return clip_gradients_;
}
void SolverParameter::set_clip_gradients(float value) {
set_has_clip_gradients();
clip_gradients_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.clip_gradients)
}
// optional int32 snapshot = 14 [default = 0];
bool SolverParameter::has_snapshot() const {
return (_has_bits_[0] & 0x04000000u) != 0;
}
void SolverParameter::set_has_snapshot() {
_has_bits_[0] |= 0x04000000u;
}
void SolverParameter::clear_has_snapshot() {
_has_bits_[0] &= ~0x04000000u;
}
void SolverParameter::clear_snapshot() {
snapshot_ = 0;
clear_has_snapshot();
}
::google::protobuf::int32 SolverParameter::snapshot() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.snapshot)
return snapshot_;
}
void SolverParameter::set_snapshot(::google::protobuf::int32 value) {
set_has_snapshot();
snapshot_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.snapshot)
}
// optional string snapshot_prefix = 15;
bool SolverParameter::has_snapshot_prefix() const {
return (_has_bits_[0] & 0x08000000u) != 0;
}
void SolverParameter::set_has_snapshot_prefix() {
_has_bits_[0] |= 0x08000000u;
}
void SolverParameter::clear_has_snapshot_prefix() {
_has_bits_[0] &= ~0x08000000u;
}
void SolverParameter::clear_snapshot_prefix() {
snapshot_prefix_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_snapshot_prefix();
}
const ::std::string& SolverParameter::snapshot_prefix() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.snapshot_prefix)
return snapshot_prefix_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void SolverParameter::set_snapshot_prefix(const ::std::string& value) {
set_has_snapshot_prefix();
snapshot_prefix_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.snapshot_prefix)
}
void SolverParameter::set_snapshot_prefix(const char* value) {
set_has_snapshot_prefix();
snapshot_prefix_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.SolverParameter.snapshot_prefix)
}
void SolverParameter::set_snapshot_prefix(const char* value, size_t size) {
set_has_snapshot_prefix();
snapshot_prefix_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.SolverParameter.snapshot_prefix)
}
::std::string* SolverParameter::mutable_snapshot_prefix() {
set_has_snapshot_prefix();
// @@protoc_insertion_point(field_mutable:opencv_caffe.SolverParameter.snapshot_prefix)
return snapshot_prefix_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* SolverParameter::release_snapshot_prefix() {
// @@protoc_insertion_point(field_release:opencv_caffe.SolverParameter.snapshot_prefix)
clear_has_snapshot_prefix();
return snapshot_prefix_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void SolverParameter::set_allocated_snapshot_prefix(::std::string* snapshot_prefix) {
if (snapshot_prefix != NULL) {
set_has_snapshot_prefix();
} else {
clear_has_snapshot_prefix();
}
snapshot_prefix_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), snapshot_prefix);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.SolverParameter.snapshot_prefix)
}
// optional bool snapshot_diff = 16 [default = false];
bool SolverParameter::has_snapshot_diff() const {
return (_has_bits_[0] & 0x10000000u) != 0;
}
void SolverParameter::set_has_snapshot_diff() {
_has_bits_[0] |= 0x10000000u;
}
void SolverParameter::clear_has_snapshot_diff() {
_has_bits_[0] &= ~0x10000000u;
}
void SolverParameter::clear_snapshot_diff() {
snapshot_diff_ = false;
clear_has_snapshot_diff();
}
bool SolverParameter::snapshot_diff() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.snapshot_diff)
return snapshot_diff_;
}
void SolverParameter::set_snapshot_diff(bool value) {
set_has_snapshot_diff();
snapshot_diff_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.snapshot_diff)
}
// optional .opencv_caffe.SolverParameter.SnapshotFormat snapshot_format = 37 [default = BINARYPROTO];
bool SolverParameter::has_snapshot_format() const {
return (_has_bits_[0] & 0x20000000u) != 0;
}
void SolverParameter::set_has_snapshot_format() {
_has_bits_[0] |= 0x20000000u;
}
void SolverParameter::clear_has_snapshot_format() {
_has_bits_[0] &= ~0x20000000u;
}
void SolverParameter::clear_snapshot_format() {
snapshot_format_ = 1;
clear_has_snapshot_format();
}
::opencv_caffe::SolverParameter_SnapshotFormat SolverParameter::snapshot_format() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.snapshot_format)
return static_cast< ::opencv_caffe::SolverParameter_SnapshotFormat >(snapshot_format_);
}
void SolverParameter::set_snapshot_format(::opencv_caffe::SolverParameter_SnapshotFormat value) {
assert(::opencv_caffe::SolverParameter_SnapshotFormat_IsValid(value));
set_has_snapshot_format();
snapshot_format_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.snapshot_format)
}
// optional .opencv_caffe.SolverParameter.SolverMode solver_mode = 17 [default = GPU];
bool SolverParameter::has_solver_mode() const {
return (_has_bits_[0] & 0x40000000u) != 0;
}
void SolverParameter::set_has_solver_mode() {
_has_bits_[0] |= 0x40000000u;
}
void SolverParameter::clear_has_solver_mode() {
_has_bits_[0] &= ~0x40000000u;
}
void SolverParameter::clear_solver_mode() {
solver_mode_ = 1;
clear_has_solver_mode();
}
::opencv_caffe::SolverParameter_SolverMode SolverParameter::solver_mode() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.solver_mode)
return static_cast< ::opencv_caffe::SolverParameter_SolverMode >(solver_mode_);
}
void SolverParameter::set_solver_mode(::opencv_caffe::SolverParameter_SolverMode value) {
assert(::opencv_caffe::SolverParameter_SolverMode_IsValid(value));
set_has_solver_mode();
solver_mode_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.solver_mode)
}
// optional int32 device_id = 18 [default = 0];
bool SolverParameter::has_device_id() const {
return (_has_bits_[0] & 0x80000000u) != 0;
}
void SolverParameter::set_has_device_id() {
_has_bits_[0] |= 0x80000000u;
}
void SolverParameter::clear_has_device_id() {
_has_bits_[0] &= ~0x80000000u;
}
void SolverParameter::clear_device_id() {
device_id_ = 0;
clear_has_device_id();
}
::google::protobuf::int32 SolverParameter::device_id() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.device_id)
return device_id_;
}
void SolverParameter::set_device_id(::google::protobuf::int32 value) {
set_has_device_id();
device_id_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.device_id)
}
// optional int64 random_seed = 20 [default = -1];
bool SolverParameter::has_random_seed() const {
return (_has_bits_[1] & 0x00000001u) != 0;
}
void SolverParameter::set_has_random_seed() {
_has_bits_[1] |= 0x00000001u;
}
void SolverParameter::clear_has_random_seed() {
_has_bits_[1] &= ~0x00000001u;
}
void SolverParameter::clear_random_seed() {
random_seed_ = GOOGLE_LONGLONG(-1);
clear_has_random_seed();
}
::google::protobuf::int64 SolverParameter::random_seed() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.random_seed)
return random_seed_;
}
void SolverParameter::set_random_seed(::google::protobuf::int64 value) {
set_has_random_seed();
random_seed_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.random_seed)
}
// optional string type = 40 [default = "SGD"];
bool SolverParameter::has_type() const {
return (_has_bits_[1] & 0x00000002u) != 0;
}
void SolverParameter::set_has_type() {
_has_bits_[1] |= 0x00000002u;
}
void SolverParameter::clear_has_type() {
_has_bits_[1] &= ~0x00000002u;
}
void SolverParameter::clear_type() {
type_.ClearToDefaultNoArena(_default_type_);
clear_has_type();
}
const ::std::string& SolverParameter::type() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.type)
return type_.GetNoArena(_default_type_);
}
void SolverParameter::set_type(const ::std::string& value) {
set_has_type();
type_.SetNoArena(_default_type_, value);
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.type)
}
void SolverParameter::set_type(const char* value) {
set_has_type();
type_.SetNoArena(_default_type_, ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.SolverParameter.type)
}
void SolverParameter::set_type(const char* value, size_t size) {
set_has_type();
type_.SetNoArena(_default_type_,
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.SolverParameter.type)
}
::std::string* SolverParameter::mutable_type() {
set_has_type();
// @@protoc_insertion_point(field_mutable:opencv_caffe.SolverParameter.type)
return type_.MutableNoArena(_default_type_);
}
::std::string* SolverParameter::release_type() {
// @@protoc_insertion_point(field_release:opencv_caffe.SolverParameter.type)
clear_has_type();
return type_.ReleaseNoArena(_default_type_);
}
void SolverParameter::set_allocated_type(::std::string* type) {
if (type != NULL) {
set_has_type();
} else {
clear_has_type();
}
type_.SetAllocatedNoArena(_default_type_, type);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.SolverParameter.type)
}
// optional float delta = 31 [default = 1e-08];
bool SolverParameter::has_delta() const {
return (_has_bits_[1] & 0x00000004u) != 0;
}
void SolverParameter::set_has_delta() {
_has_bits_[1] |= 0x00000004u;
}
void SolverParameter::clear_has_delta() {
_has_bits_[1] &= ~0x00000004u;
}
void SolverParameter::clear_delta() {
delta_ = 1e-08f;
clear_has_delta();
}
float SolverParameter::delta() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.delta)
return delta_;
}
void SolverParameter::set_delta(float value) {
set_has_delta();
delta_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.delta)
}
// optional float momentum2 = 39 [default = 0.999];
bool SolverParameter::has_momentum2() const {
return (_has_bits_[1] & 0x00000008u) != 0;
}
void SolverParameter::set_has_momentum2() {
_has_bits_[1] |= 0x00000008u;
}
void SolverParameter::clear_has_momentum2() {
_has_bits_[1] &= ~0x00000008u;
}
void SolverParameter::clear_momentum2() {
momentum2_ = 0.999f;
clear_has_momentum2();
}
float SolverParameter::momentum2() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.momentum2)
return momentum2_;
}
void SolverParameter::set_momentum2(float value) {
set_has_momentum2();
momentum2_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.momentum2)
}
// optional float rms_decay = 38 [default = 0.99];
bool SolverParameter::has_rms_decay() const {
return (_has_bits_[1] & 0x00000010u) != 0;
}
void SolverParameter::set_has_rms_decay() {
_has_bits_[1] |= 0x00000010u;
}
void SolverParameter::clear_has_rms_decay() {
_has_bits_[1] &= ~0x00000010u;
}
void SolverParameter::clear_rms_decay() {
rms_decay_ = 0.99f;
clear_has_rms_decay();
}
float SolverParameter::rms_decay() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.rms_decay)
return rms_decay_;
}
void SolverParameter::set_rms_decay(float value) {
set_has_rms_decay();
rms_decay_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.rms_decay)
}
// optional bool debug_info = 23 [default = false];
bool SolverParameter::has_debug_info() const {
return (_has_bits_[1] & 0x00000020u) != 0;
}
void SolverParameter::set_has_debug_info() {
_has_bits_[1] |= 0x00000020u;
}
void SolverParameter::clear_has_debug_info() {
_has_bits_[1] &= ~0x00000020u;
}
void SolverParameter::clear_debug_info() {
debug_info_ = false;
clear_has_debug_info();
}
bool SolverParameter::debug_info() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.debug_info)
return debug_info_;
}
void SolverParameter::set_debug_info(bool value) {
set_has_debug_info();
debug_info_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.debug_info)
}
// optional bool snapshot_after_train = 28 [default = true];
bool SolverParameter::has_snapshot_after_train() const {
return (_has_bits_[1] & 0x00000040u) != 0;
}
void SolverParameter::set_has_snapshot_after_train() {
_has_bits_[1] |= 0x00000040u;
}
void SolverParameter::clear_has_snapshot_after_train() {
_has_bits_[1] &= ~0x00000040u;
}
void SolverParameter::clear_snapshot_after_train() {
snapshot_after_train_ = true;
clear_has_snapshot_after_train();
}
bool SolverParameter::snapshot_after_train() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.snapshot_after_train)
return snapshot_after_train_;
}
void SolverParameter::set_snapshot_after_train(bool value) {
set_has_snapshot_after_train();
snapshot_after_train_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.snapshot_after_train)
}
// optional .opencv_caffe.SolverParameter.SolverType solver_type = 30 [default = SGD];
bool SolverParameter::has_solver_type() const {
return (_has_bits_[1] & 0x00000080u) != 0;
}
void SolverParameter::set_has_solver_type() {
_has_bits_[1] |= 0x00000080u;
}
void SolverParameter::clear_has_solver_type() {
_has_bits_[1] &= ~0x00000080u;
}
void SolverParameter::clear_solver_type() {
solver_type_ = 0;
clear_has_solver_type();
}
::opencv_caffe::SolverParameter_SolverType SolverParameter::solver_type() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverParameter.solver_type)
return static_cast< ::opencv_caffe::SolverParameter_SolverType >(solver_type_);
}
void SolverParameter::set_solver_type(::opencv_caffe::SolverParameter_SolverType value) {
assert(::opencv_caffe::SolverParameter_SolverType_IsValid(value));
set_has_solver_type();
solver_type_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverParameter.solver_type)
}
inline const SolverParameter* SolverParameter::internal_default_instance() {
return &SolverParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int SolverState::kIterFieldNumber;
const int SolverState::kLearnedNetFieldNumber;
const int SolverState::kHistoryFieldNumber;
const int SolverState::kCurrentStepFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
SolverState::SolverState()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.SolverState)
}
void SolverState::InitAsDefaultInstance() {
}
SolverState::SolverState(const SolverState& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.SolverState)
}
void SolverState::SharedCtor() {
_cached_size_ = 0;
learned_net_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
::memset(&iter_, 0, reinterpret_cast<char*>(&current_step_) -
reinterpret_cast<char*>(&iter_) + sizeof(current_step_));
}
SolverState::~SolverState() {
// @@protoc_insertion_point(destructor:opencv_caffe.SolverState)
SharedDtor();
}
void SolverState::SharedDtor() {
learned_net_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void SolverState::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* SolverState::descriptor() {
protobuf_AssignDescriptorsOnce();
return SolverState_descriptor_;
}
const SolverState& SolverState::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<SolverState> SolverState_default_instance_;
SolverState* SolverState::New(::google::protobuf::Arena* arena) const {
SolverState* n = new SolverState;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void SolverState::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.SolverState)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(SolverState, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<SolverState*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
if (_has_bits_[0 / 32] & 11u) {
ZR_(iter_, current_step_);
if (has_learned_net()) {
learned_net_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
}
#undef ZR_HELPER_
#undef ZR_
history_.Clear();
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool SolverState::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.SolverState)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional int32 iter = 1;
case 1: {
if (tag == 8) {
set_has_iter();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &iter_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(18)) goto parse_learned_net;
break;
}
// optional string learned_net = 2;
case 2: {
if (tag == 18) {
parse_learned_net:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_learned_net()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->learned_net().data(), this->learned_net().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.SolverState.learned_net");
} else {
goto handle_unusual;
}
if (input->ExpectTag(26)) goto parse_history;
break;
}
// repeated .opencv_caffe.BlobProto history = 3;
case 3: {
if (tag == 26) {
parse_history:
DO_(input->IncrementRecursionDepth());
parse_loop_history:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtualNoRecursionDepth(
input, add_history()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(26)) goto parse_loop_history;
input->UnsafeDecrementRecursionDepth();
if (input->ExpectTag(32)) goto parse_current_step;
break;
}
// optional int32 current_step = 4 [default = 0];
case 4: {
if (tag == 32) {
parse_current_step:
set_has_current_step();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &current_step_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.SolverState)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.SolverState)
return false;
#undef DO_
}
void SolverState::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.SolverState)
// optional int32 iter = 1;
if (has_iter()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(1, this->iter(), output);
}
// optional string learned_net = 2;
if (has_learned_net()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->learned_net().data(), this->learned_net().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SolverState.learned_net");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
2, this->learned_net(), output);
}
// repeated .opencv_caffe.BlobProto history = 3;
for (unsigned int i = 0, n = this->history_size(); i < n; i++) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
3, this->history(i), output);
}
// optional int32 current_step = 4 [default = 0];
if (has_current_step()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(4, this->current_step(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.SolverState)
}
::google::protobuf::uint8* SolverState::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.SolverState)
// optional int32 iter = 1;
if (has_iter()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(1, this->iter(), target);
}
// optional string learned_net = 2;
if (has_learned_net()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->learned_net().data(), this->learned_net().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SolverState.learned_net");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
2, this->learned_net(), target);
}
// repeated .opencv_caffe.BlobProto history = 3;
for (unsigned int i = 0, n = this->history_size(); i < n; i++) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
3, this->history(i), false, target);
}
// optional int32 current_step = 4 [default = 0];
if (has_current_step()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(4, this->current_step(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.SolverState)
return target;
}
size_t SolverState::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.SolverState)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 11u) {
// optional int32 iter = 1;
if (has_iter()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->iter());
}
// optional string learned_net = 2;
if (has_learned_net()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->learned_net());
}
// optional int32 current_step = 4 [default = 0];
if (has_current_step()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->current_step());
}
}
// repeated .opencv_caffe.BlobProto history = 3;
{
unsigned int count = this->history_size();
total_size += 1UL * count;
for (unsigned int i = 0; i < count; i++) {
total_size +=
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
this->history(i));
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void SolverState::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.SolverState)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const SolverState* source =
::google::protobuf::internal::DynamicCastToGenerated<const SolverState>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.SolverState)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.SolverState)
UnsafeMergeFrom(*source);
}
}
void SolverState::MergeFrom(const SolverState& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.SolverState)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void SolverState::UnsafeMergeFrom(const SolverState& from) {
GOOGLE_DCHECK(&from != this);
history_.MergeFrom(from.history_);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_iter()) {
set_iter(from.iter());
}
if (from.has_learned_net()) {
set_has_learned_net();
learned_net_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.learned_net_);
}
if (from.has_current_step()) {
set_current_step(from.current_step());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void SolverState::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.SolverState)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void SolverState::CopyFrom(const SolverState& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.SolverState)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool SolverState::IsInitialized() const {
return true;
}
void SolverState::Swap(SolverState* other) {
if (other == this) return;
InternalSwap(other);
}
void SolverState::InternalSwap(SolverState* other) {
std::swap(iter_, other->iter_);
learned_net_.Swap(&other->learned_net_);
history_.UnsafeArenaSwap(&other->history_);
std::swap(current_step_, other->current_step_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata SolverState::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = SolverState_descriptor_;
metadata.reflection = SolverState_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// SolverState
// optional int32 iter = 1;
bool SolverState::has_iter() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void SolverState::set_has_iter() {
_has_bits_[0] |= 0x00000001u;
}
void SolverState::clear_has_iter() {
_has_bits_[0] &= ~0x00000001u;
}
void SolverState::clear_iter() {
iter_ = 0;
clear_has_iter();
}
::google::protobuf::int32 SolverState::iter() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverState.iter)
return iter_;
}
void SolverState::set_iter(::google::protobuf::int32 value) {
set_has_iter();
iter_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverState.iter)
}
// optional string learned_net = 2;
bool SolverState::has_learned_net() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void SolverState::set_has_learned_net() {
_has_bits_[0] |= 0x00000002u;
}
void SolverState::clear_has_learned_net() {
_has_bits_[0] &= ~0x00000002u;
}
void SolverState::clear_learned_net() {
learned_net_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_learned_net();
}
const ::std::string& SolverState::learned_net() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverState.learned_net)
return learned_net_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void SolverState::set_learned_net(const ::std::string& value) {
set_has_learned_net();
learned_net_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.SolverState.learned_net)
}
void SolverState::set_learned_net(const char* value) {
set_has_learned_net();
learned_net_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.SolverState.learned_net)
}
void SolverState::set_learned_net(const char* value, size_t size) {
set_has_learned_net();
learned_net_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.SolverState.learned_net)
}
::std::string* SolverState::mutable_learned_net() {
set_has_learned_net();
// @@protoc_insertion_point(field_mutable:opencv_caffe.SolverState.learned_net)
return learned_net_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* SolverState::release_learned_net() {
// @@protoc_insertion_point(field_release:opencv_caffe.SolverState.learned_net)
clear_has_learned_net();
return learned_net_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void SolverState::set_allocated_learned_net(::std::string* learned_net) {
if (learned_net != NULL) {
set_has_learned_net();
} else {
clear_has_learned_net();
}
learned_net_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), learned_net);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.SolverState.learned_net)
}
// repeated .opencv_caffe.BlobProto history = 3;
int SolverState::history_size() const {
return history_.size();
}
void SolverState::clear_history() {
history_.Clear();
}
const ::opencv_caffe::BlobProto& SolverState::history(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverState.history)
return history_.Get(index);
}
::opencv_caffe::BlobProto* SolverState::mutable_history(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.SolverState.history)
return history_.Mutable(index);
}
::opencv_caffe::BlobProto* SolverState::add_history() {
// @@protoc_insertion_point(field_add:opencv_caffe.SolverState.history)
return history_.Add();
}
::google::protobuf::RepeatedPtrField< ::opencv_caffe::BlobProto >*
SolverState::mutable_history() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.SolverState.history)
return &history_;
}
const ::google::protobuf::RepeatedPtrField< ::opencv_caffe::BlobProto >&
SolverState::history() const {
// @@protoc_insertion_point(field_list:opencv_caffe.SolverState.history)
return history_;
}
// optional int32 current_step = 4 [default = 0];
bool SolverState::has_current_step() const {
return (_has_bits_[0] & 0x00000008u) != 0;
}
void SolverState::set_has_current_step() {
_has_bits_[0] |= 0x00000008u;
}
void SolverState::clear_has_current_step() {
_has_bits_[0] &= ~0x00000008u;
}
void SolverState::clear_current_step() {
current_step_ = 0;
clear_has_current_step();
}
::google::protobuf::int32 SolverState::current_step() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SolverState.current_step)
return current_step_;
}
void SolverState::set_current_step(::google::protobuf::int32 value) {
set_has_current_step();
current_step_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SolverState.current_step)
}
inline const SolverState* SolverState::internal_default_instance() {
return &SolverState_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int NetState::kPhaseFieldNumber;
const int NetState::kLevelFieldNumber;
const int NetState::kStageFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
NetState::NetState()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.NetState)
}
void NetState::InitAsDefaultInstance() {
}
NetState::NetState(const NetState& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.NetState)
}
void NetState::SharedCtor() {
_cached_size_ = 0;
level_ = 0;
phase_ = 1;
}
NetState::~NetState() {
// @@protoc_insertion_point(destructor:opencv_caffe.NetState)
SharedDtor();
}
void NetState::SharedDtor() {
}
void NetState::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* NetState::descriptor() {
protobuf_AssignDescriptorsOnce();
return NetState_descriptor_;
}
const NetState& NetState::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<NetState> NetState_default_instance_;
NetState* NetState::New(::google::protobuf::Arena* arena) const {
NetState* n = new NetState;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void NetState::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.NetState)
if (_has_bits_[0 / 32] & 3u) {
phase_ = 1;
level_ = 0;
}
stage_.Clear();
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool NetState::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.NetState)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional .opencv_caffe.Phase phase = 1 [default = TEST];
case 1: {
if (tag == 8) {
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::Phase_IsValid(value)) {
set_phase(static_cast< ::opencv_caffe::Phase >(value));
} else {
mutable_unknown_fields()->AddVarint(1, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_level;
break;
}
// optional int32 level = 2 [default = 0];
case 2: {
if (tag == 16) {
parse_level:
set_has_level();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &level_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(26)) goto parse_stage;
break;
}
// repeated string stage = 3;
case 3: {
if (tag == 26) {
parse_stage:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->add_stage()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->stage(this->stage_size() - 1).data(),
this->stage(this->stage_size() - 1).length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.NetState.stage");
} else {
goto handle_unusual;
}
if (input->ExpectTag(26)) goto parse_stage;
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.NetState)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.NetState)
return false;
#undef DO_
}
void NetState::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.NetState)
// optional .opencv_caffe.Phase phase = 1 [default = TEST];
if (has_phase()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
1, this->phase(), output);
}
// optional int32 level = 2 [default = 0];
if (has_level()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->level(), output);
}
// repeated string stage = 3;
for (int i = 0; i < this->stage_size(); i++) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->stage(i).data(), this->stage(i).length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.NetState.stage");
::google::protobuf::internal::WireFormatLite::WriteString(
3, this->stage(i), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.NetState)
}
::google::protobuf::uint8* NetState::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.NetState)
// optional .opencv_caffe.Phase phase = 1 [default = TEST];
if (has_phase()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
1, this->phase(), target);
}
// optional int32 level = 2 [default = 0];
if (has_level()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(2, this->level(), target);
}
// repeated string stage = 3;
for (int i = 0; i < this->stage_size(); i++) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->stage(i).data(), this->stage(i).length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.NetState.stage");
target = ::google::protobuf::internal::WireFormatLite::
WriteStringToArray(3, this->stage(i), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.NetState)
return target;
}
size_t NetState::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.NetState)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 3u) {
// optional .opencv_caffe.Phase phase = 1 [default = TEST];
if (has_phase()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->phase());
}
// optional int32 level = 2 [default = 0];
if (has_level()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->level());
}
}
// repeated string stage = 3;
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->stage_size());
for (int i = 0; i < this->stage_size(); i++) {
total_size += ::google::protobuf::internal::WireFormatLite::StringSize(
this->stage(i));
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void NetState::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.NetState)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const NetState* source =
::google::protobuf::internal::DynamicCastToGenerated<const NetState>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.NetState)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.NetState)
UnsafeMergeFrom(*source);
}
}
void NetState::MergeFrom(const NetState& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.NetState)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void NetState::UnsafeMergeFrom(const NetState& from) {
GOOGLE_DCHECK(&from != this);
stage_.UnsafeMergeFrom(from.stage_);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_phase()) {
set_phase(from.phase());
}
if (from.has_level()) {
set_level(from.level());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void NetState::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.NetState)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void NetState::CopyFrom(const NetState& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.NetState)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool NetState::IsInitialized() const {
return true;
}
void NetState::Swap(NetState* other) {
if (other == this) return;
InternalSwap(other);
}
void NetState::InternalSwap(NetState* other) {
std::swap(phase_, other->phase_);
std::swap(level_, other->level_);
stage_.UnsafeArenaSwap(&other->stage_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata NetState::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = NetState_descriptor_;
metadata.reflection = NetState_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// NetState
// optional .opencv_caffe.Phase phase = 1 [default = TEST];
bool NetState::has_phase() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void NetState::set_has_phase() {
_has_bits_[0] |= 0x00000001u;
}
void NetState::clear_has_phase() {
_has_bits_[0] &= ~0x00000001u;
}
void NetState::clear_phase() {
phase_ = 1;
clear_has_phase();
}
::opencv_caffe::Phase NetState::phase() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NetState.phase)
return static_cast< ::opencv_caffe::Phase >(phase_);
}
void NetState::set_phase(::opencv_caffe::Phase value) {
assert(::opencv_caffe::Phase_IsValid(value));
set_has_phase();
phase_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.NetState.phase)
}
// optional int32 level = 2 [default = 0];
bool NetState::has_level() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void NetState::set_has_level() {
_has_bits_[0] |= 0x00000002u;
}
void NetState::clear_has_level() {
_has_bits_[0] &= ~0x00000002u;
}
void NetState::clear_level() {
level_ = 0;
clear_has_level();
}
::google::protobuf::int32 NetState::level() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NetState.level)
return level_;
}
void NetState::set_level(::google::protobuf::int32 value) {
set_has_level();
level_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.NetState.level)
}
// repeated string stage = 3;
int NetState::stage_size() const {
return stage_.size();
}
void NetState::clear_stage() {
stage_.Clear();
}
const ::std::string& NetState::stage(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.NetState.stage)
return stage_.Get(index);
}
::std::string* NetState::mutable_stage(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.NetState.stage)
return stage_.Mutable(index);
}
void NetState::set_stage(int index, const ::std::string& value) {
// @@protoc_insertion_point(field_set:opencv_caffe.NetState.stage)
stage_.Mutable(index)->assign(value);
}
void NetState::set_stage(int index, const char* value) {
stage_.Mutable(index)->assign(value);
// @@protoc_insertion_point(field_set_char:opencv_caffe.NetState.stage)
}
void NetState::set_stage(int index, const char* value, size_t size) {
stage_.Mutable(index)->assign(
reinterpret_cast<const char*>(value), size);
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.NetState.stage)
}
::std::string* NetState::add_stage() {
// @@protoc_insertion_point(field_add_mutable:opencv_caffe.NetState.stage)
return stage_.Add();
}
void NetState::add_stage(const ::std::string& value) {
stage_.Add()->assign(value);
// @@protoc_insertion_point(field_add:opencv_caffe.NetState.stage)
}
void NetState::add_stage(const char* value) {
stage_.Add()->assign(value);
// @@protoc_insertion_point(field_add_char:opencv_caffe.NetState.stage)
}
void NetState::add_stage(const char* value, size_t size) {
stage_.Add()->assign(reinterpret_cast<const char*>(value), size);
// @@protoc_insertion_point(field_add_pointer:opencv_caffe.NetState.stage)
}
const ::google::protobuf::RepeatedPtrField< ::std::string>&
NetState::stage() const {
// @@protoc_insertion_point(field_list:opencv_caffe.NetState.stage)
return stage_;
}
::google::protobuf::RepeatedPtrField< ::std::string>*
NetState::mutable_stage() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.NetState.stage)
return &stage_;
}
inline const NetState* NetState::internal_default_instance() {
return &NetState_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int NetStateRule::kPhaseFieldNumber;
const int NetStateRule::kMinLevelFieldNumber;
const int NetStateRule::kMaxLevelFieldNumber;
const int NetStateRule::kStageFieldNumber;
const int NetStateRule::kNotStageFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
NetStateRule::NetStateRule()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.NetStateRule)
}
void NetStateRule::InitAsDefaultInstance() {
}
NetStateRule::NetStateRule(const NetStateRule& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.NetStateRule)
}
void NetStateRule::SharedCtor() {
_cached_size_ = 0;
::memset(&phase_, 0, reinterpret_cast<char*>(&max_level_) -
reinterpret_cast<char*>(&phase_) + sizeof(max_level_));
}
NetStateRule::~NetStateRule() {
// @@protoc_insertion_point(destructor:opencv_caffe.NetStateRule)
SharedDtor();
}
void NetStateRule::SharedDtor() {
}
void NetStateRule::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* NetStateRule::descriptor() {
protobuf_AssignDescriptorsOnce();
return NetStateRule_descriptor_;
}
const NetStateRule& NetStateRule::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<NetStateRule> NetStateRule_default_instance_;
NetStateRule* NetStateRule::New(::google::protobuf::Arena* arena) const {
NetStateRule* n = new NetStateRule;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void NetStateRule::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.NetStateRule)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(NetStateRule, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<NetStateRule*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
ZR_(phase_, max_level_);
#undef ZR_HELPER_
#undef ZR_
stage_.Clear();
not_stage_.Clear();
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool NetStateRule::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.NetStateRule)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional .opencv_caffe.Phase phase = 1;
case 1: {
if (tag == 8) {
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::Phase_IsValid(value)) {
set_phase(static_cast< ::opencv_caffe::Phase >(value));
} else {
mutable_unknown_fields()->AddVarint(1, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_min_level;
break;
}
// optional int32 min_level = 2;
case 2: {
if (tag == 16) {
parse_min_level:
set_has_min_level();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &min_level_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(24)) goto parse_max_level;
break;
}
// optional int32 max_level = 3;
case 3: {
if (tag == 24) {
parse_max_level:
set_has_max_level();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &max_level_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(34)) goto parse_stage;
break;
}
// repeated string stage = 4;
case 4: {
if (tag == 34) {
parse_stage:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->add_stage()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->stage(this->stage_size() - 1).data(),
this->stage(this->stage_size() - 1).length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.NetStateRule.stage");
} else {
goto handle_unusual;
}
if (input->ExpectTag(34)) goto parse_stage;
if (input->ExpectTag(42)) goto parse_not_stage;
break;
}
// repeated string not_stage = 5;
case 5: {
if (tag == 42) {
parse_not_stage:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->add_not_stage()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->not_stage(this->not_stage_size() - 1).data(),
this->not_stage(this->not_stage_size() - 1).length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.NetStateRule.not_stage");
} else {
goto handle_unusual;
}
if (input->ExpectTag(42)) goto parse_not_stage;
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.NetStateRule)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.NetStateRule)
return false;
#undef DO_
}
void NetStateRule::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.NetStateRule)
// optional .opencv_caffe.Phase phase = 1;
if (has_phase()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
1, this->phase(), output);
}
// optional int32 min_level = 2;
if (has_min_level()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->min_level(), output);
}
// optional int32 max_level = 3;
if (has_max_level()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(3, this->max_level(), output);
}
// repeated string stage = 4;
for (int i = 0; i < this->stage_size(); i++) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->stage(i).data(), this->stage(i).length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.NetStateRule.stage");
::google::protobuf::internal::WireFormatLite::WriteString(
4, this->stage(i), output);
}
// repeated string not_stage = 5;
for (int i = 0; i < this->not_stage_size(); i++) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->not_stage(i).data(), this->not_stage(i).length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.NetStateRule.not_stage");
::google::protobuf::internal::WireFormatLite::WriteString(
5, this->not_stage(i), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.NetStateRule)
}
::google::protobuf::uint8* NetStateRule::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.NetStateRule)
// optional .opencv_caffe.Phase phase = 1;
if (has_phase()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
1, this->phase(), target);
}
// optional int32 min_level = 2;
if (has_min_level()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(2, this->min_level(), target);
}
// optional int32 max_level = 3;
if (has_max_level()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(3, this->max_level(), target);
}
// repeated string stage = 4;
for (int i = 0; i < this->stage_size(); i++) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->stage(i).data(), this->stage(i).length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.NetStateRule.stage");
target = ::google::protobuf::internal::WireFormatLite::
WriteStringToArray(4, this->stage(i), target);
}
// repeated string not_stage = 5;
for (int i = 0; i < this->not_stage_size(); i++) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->not_stage(i).data(), this->not_stage(i).length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.NetStateRule.not_stage");
target = ::google::protobuf::internal::WireFormatLite::
WriteStringToArray(5, this->not_stage(i), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.NetStateRule)
return target;
}
size_t NetStateRule::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.NetStateRule)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 7u) {
// optional .opencv_caffe.Phase phase = 1;
if (has_phase()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->phase());
}
// optional int32 min_level = 2;
if (has_min_level()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->min_level());
}
// optional int32 max_level = 3;
if (has_max_level()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->max_level());
}
}
// repeated string stage = 4;
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->stage_size());
for (int i = 0; i < this->stage_size(); i++) {
total_size += ::google::protobuf::internal::WireFormatLite::StringSize(
this->stage(i));
}
// repeated string not_stage = 5;
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->not_stage_size());
for (int i = 0; i < this->not_stage_size(); i++) {
total_size += ::google::protobuf::internal::WireFormatLite::StringSize(
this->not_stage(i));
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void NetStateRule::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.NetStateRule)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const NetStateRule* source =
::google::protobuf::internal::DynamicCastToGenerated<const NetStateRule>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.NetStateRule)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.NetStateRule)
UnsafeMergeFrom(*source);
}
}
void NetStateRule::MergeFrom(const NetStateRule& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.NetStateRule)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void NetStateRule::UnsafeMergeFrom(const NetStateRule& from) {
GOOGLE_DCHECK(&from != this);
stage_.UnsafeMergeFrom(from.stage_);
not_stage_.UnsafeMergeFrom(from.not_stage_);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_phase()) {
set_phase(from.phase());
}
if (from.has_min_level()) {
set_min_level(from.min_level());
}
if (from.has_max_level()) {
set_max_level(from.max_level());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void NetStateRule::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.NetStateRule)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void NetStateRule::CopyFrom(const NetStateRule& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.NetStateRule)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool NetStateRule::IsInitialized() const {
return true;
}
void NetStateRule::Swap(NetStateRule* other) {
if (other == this) return;
InternalSwap(other);
}
void NetStateRule::InternalSwap(NetStateRule* other) {
std::swap(phase_, other->phase_);
std::swap(min_level_, other->min_level_);
std::swap(max_level_, other->max_level_);
stage_.UnsafeArenaSwap(&other->stage_);
not_stage_.UnsafeArenaSwap(&other->not_stage_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata NetStateRule::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = NetStateRule_descriptor_;
metadata.reflection = NetStateRule_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// NetStateRule
// optional .opencv_caffe.Phase phase = 1;
bool NetStateRule::has_phase() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void NetStateRule::set_has_phase() {
_has_bits_[0] |= 0x00000001u;
}
void NetStateRule::clear_has_phase() {
_has_bits_[0] &= ~0x00000001u;
}
void NetStateRule::clear_phase() {
phase_ = 0;
clear_has_phase();
}
::opencv_caffe::Phase NetStateRule::phase() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NetStateRule.phase)
return static_cast< ::opencv_caffe::Phase >(phase_);
}
void NetStateRule::set_phase(::opencv_caffe::Phase value) {
assert(::opencv_caffe::Phase_IsValid(value));
set_has_phase();
phase_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.NetStateRule.phase)
}
// optional int32 min_level = 2;
bool NetStateRule::has_min_level() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void NetStateRule::set_has_min_level() {
_has_bits_[0] |= 0x00000002u;
}
void NetStateRule::clear_has_min_level() {
_has_bits_[0] &= ~0x00000002u;
}
void NetStateRule::clear_min_level() {
min_level_ = 0;
clear_has_min_level();
}
::google::protobuf::int32 NetStateRule::min_level() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NetStateRule.min_level)
return min_level_;
}
void NetStateRule::set_min_level(::google::protobuf::int32 value) {
set_has_min_level();
min_level_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.NetStateRule.min_level)
}
// optional int32 max_level = 3;
bool NetStateRule::has_max_level() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void NetStateRule::set_has_max_level() {
_has_bits_[0] |= 0x00000004u;
}
void NetStateRule::clear_has_max_level() {
_has_bits_[0] &= ~0x00000004u;
}
void NetStateRule::clear_max_level() {
max_level_ = 0;
clear_has_max_level();
}
::google::protobuf::int32 NetStateRule::max_level() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NetStateRule.max_level)
return max_level_;
}
void NetStateRule::set_max_level(::google::protobuf::int32 value) {
set_has_max_level();
max_level_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.NetStateRule.max_level)
}
// repeated string stage = 4;
int NetStateRule::stage_size() const {
return stage_.size();
}
void NetStateRule::clear_stage() {
stage_.Clear();
}
const ::std::string& NetStateRule::stage(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.NetStateRule.stage)
return stage_.Get(index);
}
::std::string* NetStateRule::mutable_stage(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.NetStateRule.stage)
return stage_.Mutable(index);
}
void NetStateRule::set_stage(int index, const ::std::string& value) {
// @@protoc_insertion_point(field_set:opencv_caffe.NetStateRule.stage)
stage_.Mutable(index)->assign(value);
}
void NetStateRule::set_stage(int index, const char* value) {
stage_.Mutable(index)->assign(value);
// @@protoc_insertion_point(field_set_char:opencv_caffe.NetStateRule.stage)
}
void NetStateRule::set_stage(int index, const char* value, size_t size) {
stage_.Mutable(index)->assign(
reinterpret_cast<const char*>(value), size);
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.NetStateRule.stage)
}
::std::string* NetStateRule::add_stage() {
// @@protoc_insertion_point(field_add_mutable:opencv_caffe.NetStateRule.stage)
return stage_.Add();
}
void NetStateRule::add_stage(const ::std::string& value) {
stage_.Add()->assign(value);
// @@protoc_insertion_point(field_add:opencv_caffe.NetStateRule.stage)
}
void NetStateRule::add_stage(const char* value) {
stage_.Add()->assign(value);
// @@protoc_insertion_point(field_add_char:opencv_caffe.NetStateRule.stage)
}
void NetStateRule::add_stage(const char* value, size_t size) {
stage_.Add()->assign(reinterpret_cast<const char*>(value), size);
// @@protoc_insertion_point(field_add_pointer:opencv_caffe.NetStateRule.stage)
}
const ::google::protobuf::RepeatedPtrField< ::std::string>&
NetStateRule::stage() const {
// @@protoc_insertion_point(field_list:opencv_caffe.NetStateRule.stage)
return stage_;
}
::google::protobuf::RepeatedPtrField< ::std::string>*
NetStateRule::mutable_stage() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.NetStateRule.stage)
return &stage_;
}
// repeated string not_stage = 5;
int NetStateRule::not_stage_size() const {
return not_stage_.size();
}
void NetStateRule::clear_not_stage() {
not_stage_.Clear();
}
const ::std::string& NetStateRule::not_stage(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.NetStateRule.not_stage)
return not_stage_.Get(index);
}
::std::string* NetStateRule::mutable_not_stage(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.NetStateRule.not_stage)
return not_stage_.Mutable(index);
}
void NetStateRule::set_not_stage(int index, const ::std::string& value) {
// @@protoc_insertion_point(field_set:opencv_caffe.NetStateRule.not_stage)
not_stage_.Mutable(index)->assign(value);
}
void NetStateRule::set_not_stage(int index, const char* value) {
not_stage_.Mutable(index)->assign(value);
// @@protoc_insertion_point(field_set_char:opencv_caffe.NetStateRule.not_stage)
}
void NetStateRule::set_not_stage(int index, const char* value, size_t size) {
not_stage_.Mutable(index)->assign(
reinterpret_cast<const char*>(value), size);
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.NetStateRule.not_stage)
}
::std::string* NetStateRule::add_not_stage() {
// @@protoc_insertion_point(field_add_mutable:opencv_caffe.NetStateRule.not_stage)
return not_stage_.Add();
}
void NetStateRule::add_not_stage(const ::std::string& value) {
not_stage_.Add()->assign(value);
// @@protoc_insertion_point(field_add:opencv_caffe.NetStateRule.not_stage)
}
void NetStateRule::add_not_stage(const char* value) {
not_stage_.Add()->assign(value);
// @@protoc_insertion_point(field_add_char:opencv_caffe.NetStateRule.not_stage)
}
void NetStateRule::add_not_stage(const char* value, size_t size) {
not_stage_.Add()->assign(reinterpret_cast<const char*>(value), size);
// @@protoc_insertion_point(field_add_pointer:opencv_caffe.NetStateRule.not_stage)
}
const ::google::protobuf::RepeatedPtrField< ::std::string>&
NetStateRule::not_stage() const {
// @@protoc_insertion_point(field_list:opencv_caffe.NetStateRule.not_stage)
return not_stage_;
}
::google::protobuf::RepeatedPtrField< ::std::string>*
NetStateRule::mutable_not_stage() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.NetStateRule.not_stage)
return &not_stage_;
}
inline const NetStateRule* NetStateRule::internal_default_instance() {
return &NetStateRule_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
const ::google::protobuf::EnumDescriptor* ParamSpec_DimCheckMode_descriptor() {
protobuf_AssignDescriptorsOnce();
return ParamSpec_DimCheckMode_descriptor_;
}
bool ParamSpec_DimCheckMode_IsValid(int value) {
switch (value) {
case 0:
case 1:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const ParamSpec_DimCheckMode ParamSpec::STRICT;
const ParamSpec_DimCheckMode ParamSpec::PERMISSIVE;
const ParamSpec_DimCheckMode ParamSpec::DimCheckMode_MIN;
const ParamSpec_DimCheckMode ParamSpec::DimCheckMode_MAX;
const int ParamSpec::DimCheckMode_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int ParamSpec::kNameFieldNumber;
const int ParamSpec::kShareModeFieldNumber;
const int ParamSpec::kLrMultFieldNumber;
const int ParamSpec::kDecayMultFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
ParamSpec::ParamSpec()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.ParamSpec)
}
void ParamSpec::InitAsDefaultInstance() {
}
ParamSpec::ParamSpec(const ParamSpec& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.ParamSpec)
}
void ParamSpec::SharedCtor() {
_cached_size_ = 0;
name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
share_mode_ = 0;
lr_mult_ = 1;
decay_mult_ = 1;
}
ParamSpec::~ParamSpec() {
// @@protoc_insertion_point(destructor:opencv_caffe.ParamSpec)
SharedDtor();
}
void ParamSpec::SharedDtor() {
name_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void ParamSpec::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* ParamSpec::descriptor() {
protobuf_AssignDescriptorsOnce();
return ParamSpec_descriptor_;
}
const ParamSpec& ParamSpec::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<ParamSpec> ParamSpec_default_instance_;
ParamSpec* ParamSpec::New(::google::protobuf::Arena* arena) const {
ParamSpec* n = new ParamSpec;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void ParamSpec::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.ParamSpec)
if (_has_bits_[0 / 32] & 15u) {
if (has_name()) {
name_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
share_mode_ = 0;
lr_mult_ = 1;
decay_mult_ = 1;
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool ParamSpec::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.ParamSpec)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional string name = 1;
case 1: {
if (tag == 10) {
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_name()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->name().data(), this->name().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.ParamSpec.name");
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_share_mode;
break;
}
// optional .opencv_caffe.ParamSpec.DimCheckMode share_mode = 2;
case 2: {
if (tag == 16) {
parse_share_mode:
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::ParamSpec_DimCheckMode_IsValid(value)) {
set_share_mode(static_cast< ::opencv_caffe::ParamSpec_DimCheckMode >(value));
} else {
mutable_unknown_fields()->AddVarint(2, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectTag(29)) goto parse_lr_mult;
break;
}
// optional float lr_mult = 3 [default = 1];
case 3: {
if (tag == 29) {
parse_lr_mult:
set_has_lr_mult();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &lr_mult_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(37)) goto parse_decay_mult;
break;
}
// optional float decay_mult = 4 [default = 1];
case 4: {
if (tag == 37) {
parse_decay_mult:
set_has_decay_mult();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &decay_mult_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.ParamSpec)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.ParamSpec)
return false;
#undef DO_
}
void ParamSpec::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.ParamSpec)
// optional string name = 1;
if (has_name()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->name().data(), this->name().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.ParamSpec.name");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
1, this->name(), output);
}
// optional .opencv_caffe.ParamSpec.DimCheckMode share_mode = 2;
if (has_share_mode()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
2, this->share_mode(), output);
}
// optional float lr_mult = 3 [default = 1];
if (has_lr_mult()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(3, this->lr_mult(), output);
}
// optional float decay_mult = 4 [default = 1];
if (has_decay_mult()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(4, this->decay_mult(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.ParamSpec)
}
::google::protobuf::uint8* ParamSpec::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.ParamSpec)
// optional string name = 1;
if (has_name()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->name().data(), this->name().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.ParamSpec.name");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
1, this->name(), target);
}
// optional .opencv_caffe.ParamSpec.DimCheckMode share_mode = 2;
if (has_share_mode()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
2, this->share_mode(), target);
}
// optional float lr_mult = 3 [default = 1];
if (has_lr_mult()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(3, this->lr_mult(), target);
}
// optional float decay_mult = 4 [default = 1];
if (has_decay_mult()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(4, this->decay_mult(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.ParamSpec)
return target;
}
size_t ParamSpec::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.ParamSpec)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 15u) {
// optional string name = 1;
if (has_name()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->name());
}
// optional .opencv_caffe.ParamSpec.DimCheckMode share_mode = 2;
if (has_share_mode()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->share_mode());
}
// optional float lr_mult = 3 [default = 1];
if (has_lr_mult()) {
total_size += 1 + 4;
}
// optional float decay_mult = 4 [default = 1];
if (has_decay_mult()) {
total_size += 1 + 4;
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void ParamSpec::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.ParamSpec)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const ParamSpec* source =
::google::protobuf::internal::DynamicCastToGenerated<const ParamSpec>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.ParamSpec)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.ParamSpec)
UnsafeMergeFrom(*source);
}
}
void ParamSpec::MergeFrom(const ParamSpec& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.ParamSpec)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void ParamSpec::UnsafeMergeFrom(const ParamSpec& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_name()) {
set_has_name();
name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.name_);
}
if (from.has_share_mode()) {
set_share_mode(from.share_mode());
}
if (from.has_lr_mult()) {
set_lr_mult(from.lr_mult());
}
if (from.has_decay_mult()) {
set_decay_mult(from.decay_mult());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void ParamSpec::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.ParamSpec)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void ParamSpec::CopyFrom(const ParamSpec& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.ParamSpec)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool ParamSpec::IsInitialized() const {
return true;
}
void ParamSpec::Swap(ParamSpec* other) {
if (other == this) return;
InternalSwap(other);
}
void ParamSpec::InternalSwap(ParamSpec* other) {
name_.Swap(&other->name_);
std::swap(share_mode_, other->share_mode_);
std::swap(lr_mult_, other->lr_mult_);
std::swap(decay_mult_, other->decay_mult_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata ParamSpec::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = ParamSpec_descriptor_;
metadata.reflection = ParamSpec_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// ParamSpec
// optional string name = 1;
bool ParamSpec::has_name() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void ParamSpec::set_has_name() {
_has_bits_[0] |= 0x00000001u;
}
void ParamSpec::clear_has_name() {
_has_bits_[0] &= ~0x00000001u;
}
void ParamSpec::clear_name() {
name_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_name();
}
const ::std::string& ParamSpec::name() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ParamSpec.name)
return name_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void ParamSpec::set_name(const ::std::string& value) {
set_has_name();
name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.ParamSpec.name)
}
void ParamSpec::set_name(const char* value) {
set_has_name();
name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.ParamSpec.name)
}
void ParamSpec::set_name(const char* value, size_t size) {
set_has_name();
name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.ParamSpec.name)
}
::std::string* ParamSpec::mutable_name() {
set_has_name();
// @@protoc_insertion_point(field_mutable:opencv_caffe.ParamSpec.name)
return name_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* ParamSpec::release_name() {
// @@protoc_insertion_point(field_release:opencv_caffe.ParamSpec.name)
clear_has_name();
return name_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void ParamSpec::set_allocated_name(::std::string* name) {
if (name != NULL) {
set_has_name();
} else {
clear_has_name();
}
name_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), name);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.ParamSpec.name)
}
// optional .opencv_caffe.ParamSpec.DimCheckMode share_mode = 2;
bool ParamSpec::has_share_mode() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void ParamSpec::set_has_share_mode() {
_has_bits_[0] |= 0x00000002u;
}
void ParamSpec::clear_has_share_mode() {
_has_bits_[0] &= ~0x00000002u;
}
void ParamSpec::clear_share_mode() {
share_mode_ = 0;
clear_has_share_mode();
}
::opencv_caffe::ParamSpec_DimCheckMode ParamSpec::share_mode() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ParamSpec.share_mode)
return static_cast< ::opencv_caffe::ParamSpec_DimCheckMode >(share_mode_);
}
void ParamSpec::set_share_mode(::opencv_caffe::ParamSpec_DimCheckMode value) {
assert(::opencv_caffe::ParamSpec_DimCheckMode_IsValid(value));
set_has_share_mode();
share_mode_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ParamSpec.share_mode)
}
// optional float lr_mult = 3 [default = 1];
bool ParamSpec::has_lr_mult() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void ParamSpec::set_has_lr_mult() {
_has_bits_[0] |= 0x00000004u;
}
void ParamSpec::clear_has_lr_mult() {
_has_bits_[0] &= ~0x00000004u;
}
void ParamSpec::clear_lr_mult() {
lr_mult_ = 1;
clear_has_lr_mult();
}
float ParamSpec::lr_mult() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ParamSpec.lr_mult)
return lr_mult_;
}
void ParamSpec::set_lr_mult(float value) {
set_has_lr_mult();
lr_mult_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ParamSpec.lr_mult)
}
// optional float decay_mult = 4 [default = 1];
bool ParamSpec::has_decay_mult() const {
return (_has_bits_[0] & 0x00000008u) != 0;
}
void ParamSpec::set_has_decay_mult() {
_has_bits_[0] |= 0x00000008u;
}
void ParamSpec::clear_has_decay_mult() {
_has_bits_[0] &= ~0x00000008u;
}
void ParamSpec::clear_decay_mult() {
decay_mult_ = 1;
clear_has_decay_mult();
}
float ParamSpec::decay_mult() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ParamSpec.decay_mult)
return decay_mult_;
}
void ParamSpec::set_decay_mult(float value) {
set_has_decay_mult();
decay_mult_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ParamSpec.decay_mult)
}
inline const ParamSpec* ParamSpec::internal_default_instance() {
return &ParamSpec_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int LayerParameter::kNameFieldNumber;
const int LayerParameter::kTypeFieldNumber;
const int LayerParameter::kBottomFieldNumber;
const int LayerParameter::kTopFieldNumber;
const int LayerParameter::kPhaseFieldNumber;
const int LayerParameter::kLossWeightFieldNumber;
const int LayerParameter::kParamFieldNumber;
const int LayerParameter::kBlobsFieldNumber;
const int LayerParameter::kPropagateDownFieldNumber;
const int LayerParameter::kIncludeFieldNumber;
const int LayerParameter::kExcludeFieldNumber;
const int LayerParameter::kTransformParamFieldNumber;
const int LayerParameter::kLossParamFieldNumber;
const int LayerParameter::kAccuracyParamFieldNumber;
const int LayerParameter::kArgmaxParamFieldNumber;
const int LayerParameter::kBatchNormParamFieldNumber;
const int LayerParameter::kBiasParamFieldNumber;
const int LayerParameter::kConcatParamFieldNumber;
const int LayerParameter::kContrastiveLossParamFieldNumber;
const int LayerParameter::kConvolutionParamFieldNumber;
const int LayerParameter::kCropParamFieldNumber;
const int LayerParameter::kDataParamFieldNumber;
const int LayerParameter::kDetectionOutputParamFieldNumber;
const int LayerParameter::kDropoutParamFieldNumber;
const int LayerParameter::kDummyDataParamFieldNumber;
const int LayerParameter::kEltwiseParamFieldNumber;
const int LayerParameter::kEluParamFieldNumber;
const int LayerParameter::kEmbedParamFieldNumber;
const int LayerParameter::kExpParamFieldNumber;
const int LayerParameter::kFlattenParamFieldNumber;
const int LayerParameter::kHdf5DataParamFieldNumber;
const int LayerParameter::kHdf5OutputParamFieldNumber;
const int LayerParameter::kHingeLossParamFieldNumber;
const int LayerParameter::kImageDataParamFieldNumber;
const int LayerParameter::kInfogainLossParamFieldNumber;
const int LayerParameter::kInnerProductParamFieldNumber;
const int LayerParameter::kInputParamFieldNumber;
const int LayerParameter::kLogParamFieldNumber;
const int LayerParameter::kLrnParamFieldNumber;
const int LayerParameter::kMemoryDataParamFieldNumber;
const int LayerParameter::kMvnParamFieldNumber;
const int LayerParameter::kNormParamFieldNumber;
const int LayerParameter::kPermuteParamFieldNumber;
const int LayerParameter::kParameterParamFieldNumber;
const int LayerParameter::kPoolingParamFieldNumber;
const int LayerParameter::kPowerParamFieldNumber;
const int LayerParameter::kPreluParamFieldNumber;
const int LayerParameter::kPriorBoxParamFieldNumber;
const int LayerParameter::kProposalParamFieldNumber;
const int LayerParameter::kPsroiPoolingParamFieldNumber;
const int LayerParameter::kPythonParamFieldNumber;
const int LayerParameter::kRecurrentParamFieldNumber;
const int LayerParameter::kReductionParamFieldNumber;
const int LayerParameter::kReluParamFieldNumber;
const int LayerParameter::kReshapeParamFieldNumber;
const int LayerParameter::kRoiPoolingParamFieldNumber;
const int LayerParameter::kScaleParamFieldNumber;
const int LayerParameter::kSigmoidParamFieldNumber;
const int LayerParameter::kSoftmaxParamFieldNumber;
const int LayerParameter::kSppParamFieldNumber;
const int LayerParameter::kSliceParamFieldNumber;
const int LayerParameter::kTanhParamFieldNumber;
const int LayerParameter::kThresholdParamFieldNumber;
const int LayerParameter::kTileParamFieldNumber;
const int LayerParameter::kWindowDataParamFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
LayerParameter::LayerParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.LayerParameter)
}
void LayerParameter::InitAsDefaultInstance() {
transform_param_ = const_cast< ::opencv_caffe::TransformationParameter*>(
::opencv_caffe::TransformationParameter::internal_default_instance());
loss_param_ = const_cast< ::opencv_caffe::LossParameter*>(
::opencv_caffe::LossParameter::internal_default_instance());
accuracy_param_ = const_cast< ::opencv_caffe::AccuracyParameter*>(
::opencv_caffe::AccuracyParameter::internal_default_instance());
argmax_param_ = const_cast< ::opencv_caffe::ArgMaxParameter*>(
::opencv_caffe::ArgMaxParameter::internal_default_instance());
batch_norm_param_ = const_cast< ::opencv_caffe::BatchNormParameter*>(
::opencv_caffe::BatchNormParameter::internal_default_instance());
bias_param_ = const_cast< ::opencv_caffe::BiasParameter*>(
::opencv_caffe::BiasParameter::internal_default_instance());
concat_param_ = const_cast< ::opencv_caffe::ConcatParameter*>(
::opencv_caffe::ConcatParameter::internal_default_instance());
contrastive_loss_param_ = const_cast< ::opencv_caffe::ContrastiveLossParameter*>(
::opencv_caffe::ContrastiveLossParameter::internal_default_instance());
convolution_param_ = const_cast< ::opencv_caffe::ConvolutionParameter*>(
::opencv_caffe::ConvolutionParameter::internal_default_instance());
crop_param_ = const_cast< ::opencv_caffe::CropParameter*>(
::opencv_caffe::CropParameter::internal_default_instance());
data_param_ = const_cast< ::opencv_caffe::DataParameter*>(
::opencv_caffe::DataParameter::internal_default_instance());
detection_output_param_ = const_cast< ::opencv_caffe::DetectionOutputParameter*>(
::opencv_caffe::DetectionOutputParameter::internal_default_instance());
dropout_param_ = const_cast< ::opencv_caffe::DropoutParameter*>(
::opencv_caffe::DropoutParameter::internal_default_instance());
dummy_data_param_ = const_cast< ::opencv_caffe::DummyDataParameter*>(
::opencv_caffe::DummyDataParameter::internal_default_instance());
eltwise_param_ = const_cast< ::opencv_caffe::EltwiseParameter*>(
::opencv_caffe::EltwiseParameter::internal_default_instance());
elu_param_ = const_cast< ::opencv_caffe::ELUParameter*>(
::opencv_caffe::ELUParameter::internal_default_instance());
embed_param_ = const_cast< ::opencv_caffe::EmbedParameter*>(
::opencv_caffe::EmbedParameter::internal_default_instance());
exp_param_ = const_cast< ::opencv_caffe::ExpParameter*>(
::opencv_caffe::ExpParameter::internal_default_instance());
flatten_param_ = const_cast< ::opencv_caffe::FlattenParameter*>(
::opencv_caffe::FlattenParameter::internal_default_instance());
hdf5_data_param_ = const_cast< ::opencv_caffe::HDF5DataParameter*>(
::opencv_caffe::HDF5DataParameter::internal_default_instance());
hdf5_output_param_ = const_cast< ::opencv_caffe::HDF5OutputParameter*>(
::opencv_caffe::HDF5OutputParameter::internal_default_instance());
hinge_loss_param_ = const_cast< ::opencv_caffe::HingeLossParameter*>(
::opencv_caffe::HingeLossParameter::internal_default_instance());
image_data_param_ = const_cast< ::opencv_caffe::ImageDataParameter*>(
::opencv_caffe::ImageDataParameter::internal_default_instance());
infogain_loss_param_ = const_cast< ::opencv_caffe::InfogainLossParameter*>(
::opencv_caffe::InfogainLossParameter::internal_default_instance());
inner_product_param_ = const_cast< ::opencv_caffe::InnerProductParameter*>(
::opencv_caffe::InnerProductParameter::internal_default_instance());
input_param_ = const_cast< ::opencv_caffe::InputParameter*>(
::opencv_caffe::InputParameter::internal_default_instance());
log_param_ = const_cast< ::opencv_caffe::LogParameter*>(
::opencv_caffe::LogParameter::internal_default_instance());
lrn_param_ = const_cast< ::opencv_caffe::LRNParameter*>(
::opencv_caffe::LRNParameter::internal_default_instance());
memory_data_param_ = const_cast< ::opencv_caffe::MemoryDataParameter*>(
::opencv_caffe::MemoryDataParameter::internal_default_instance());
mvn_param_ = const_cast< ::opencv_caffe::MVNParameter*>(
::opencv_caffe::MVNParameter::internal_default_instance());
norm_param_ = const_cast< ::opencv_caffe::NormalizeBBoxParameter*>(
::opencv_caffe::NormalizeBBoxParameter::internal_default_instance());
permute_param_ = const_cast< ::opencv_caffe::PermuteParameter*>(
::opencv_caffe::PermuteParameter::internal_default_instance());
parameter_param_ = const_cast< ::opencv_caffe::ParameterParameter*>(
::opencv_caffe::ParameterParameter::internal_default_instance());
pooling_param_ = const_cast< ::opencv_caffe::PoolingParameter*>(
::opencv_caffe::PoolingParameter::internal_default_instance());
power_param_ = const_cast< ::opencv_caffe::PowerParameter*>(
::opencv_caffe::PowerParameter::internal_default_instance());
prelu_param_ = const_cast< ::opencv_caffe::PReLUParameter*>(
::opencv_caffe::PReLUParameter::internal_default_instance());
prior_box_param_ = const_cast< ::opencv_caffe::PriorBoxParameter*>(
::opencv_caffe::PriorBoxParameter::internal_default_instance());
proposal_param_ = const_cast< ::opencv_caffe::ProposalParameter*>(
::opencv_caffe::ProposalParameter::internal_default_instance());
psroi_pooling_param_ = const_cast< ::opencv_caffe::PSROIPoolingParameter*>(
::opencv_caffe::PSROIPoolingParameter::internal_default_instance());
python_param_ = const_cast< ::opencv_caffe::PythonParameter*>(
::opencv_caffe::PythonParameter::internal_default_instance());
recurrent_param_ = const_cast< ::opencv_caffe::RecurrentParameter*>(
::opencv_caffe::RecurrentParameter::internal_default_instance());
reduction_param_ = const_cast< ::opencv_caffe::ReductionParameter*>(
::opencv_caffe::ReductionParameter::internal_default_instance());
relu_param_ = const_cast< ::opencv_caffe::ReLUParameter*>(
::opencv_caffe::ReLUParameter::internal_default_instance());
reshape_param_ = const_cast< ::opencv_caffe::ReshapeParameter*>(
::opencv_caffe::ReshapeParameter::internal_default_instance());
roi_pooling_param_ = const_cast< ::opencv_caffe::ROIPoolingParameter*>(
::opencv_caffe::ROIPoolingParameter::internal_default_instance());
scale_param_ = const_cast< ::opencv_caffe::ScaleParameter*>(
::opencv_caffe::ScaleParameter::internal_default_instance());
sigmoid_param_ = const_cast< ::opencv_caffe::SigmoidParameter*>(
::opencv_caffe::SigmoidParameter::internal_default_instance());
softmax_param_ = const_cast< ::opencv_caffe::SoftmaxParameter*>(
::opencv_caffe::SoftmaxParameter::internal_default_instance());
spp_param_ = const_cast< ::opencv_caffe::SPPParameter*>(
::opencv_caffe::SPPParameter::internal_default_instance());
slice_param_ = const_cast< ::opencv_caffe::SliceParameter*>(
::opencv_caffe::SliceParameter::internal_default_instance());
tanh_param_ = const_cast< ::opencv_caffe::TanHParameter*>(
::opencv_caffe::TanHParameter::internal_default_instance());
threshold_param_ = const_cast< ::opencv_caffe::ThresholdParameter*>(
::opencv_caffe::ThresholdParameter::internal_default_instance());
tile_param_ = const_cast< ::opencv_caffe::TileParameter*>(
::opencv_caffe::TileParameter::internal_default_instance());
window_data_param_ = const_cast< ::opencv_caffe::WindowDataParameter*>(
::opencv_caffe::WindowDataParameter::internal_default_instance());
}
LayerParameter::LayerParameter(const LayerParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.LayerParameter)
}
void LayerParameter::SharedCtor() {
_cached_size_ = 0;
name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
type_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
transform_param_ = NULL;
loss_param_ = NULL;
accuracy_param_ = NULL;
argmax_param_ = NULL;
batch_norm_param_ = NULL;
bias_param_ = NULL;
concat_param_ = NULL;
contrastive_loss_param_ = NULL;
convolution_param_ = NULL;
crop_param_ = NULL;
data_param_ = NULL;
detection_output_param_ = NULL;
dropout_param_ = NULL;
dummy_data_param_ = NULL;
eltwise_param_ = NULL;
elu_param_ = NULL;
embed_param_ = NULL;
exp_param_ = NULL;
flatten_param_ = NULL;
hdf5_data_param_ = NULL;
hdf5_output_param_ = NULL;
hinge_loss_param_ = NULL;
image_data_param_ = NULL;
infogain_loss_param_ = NULL;
inner_product_param_ = NULL;
input_param_ = NULL;
log_param_ = NULL;
lrn_param_ = NULL;
memory_data_param_ = NULL;
mvn_param_ = NULL;
norm_param_ = NULL;
permute_param_ = NULL;
parameter_param_ = NULL;
pooling_param_ = NULL;
power_param_ = NULL;
prelu_param_ = NULL;
prior_box_param_ = NULL;
proposal_param_ = NULL;
psroi_pooling_param_ = NULL;
python_param_ = NULL;
recurrent_param_ = NULL;
reduction_param_ = NULL;
relu_param_ = NULL;
reshape_param_ = NULL;
roi_pooling_param_ = NULL;
scale_param_ = NULL;
sigmoid_param_ = NULL;
softmax_param_ = NULL;
spp_param_ = NULL;
slice_param_ = NULL;
tanh_param_ = NULL;
threshold_param_ = NULL;
tile_param_ = NULL;
window_data_param_ = NULL;
phase_ = 0;
}
LayerParameter::~LayerParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.LayerParameter)
SharedDtor();
}
void LayerParameter::SharedDtor() {
name_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
type_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
if (this != &LayerParameter_default_instance_.get()) {
delete transform_param_;
delete loss_param_;
delete accuracy_param_;
delete argmax_param_;
delete batch_norm_param_;
delete bias_param_;
delete concat_param_;
delete contrastive_loss_param_;
delete convolution_param_;
delete crop_param_;
delete data_param_;
delete detection_output_param_;
delete dropout_param_;
delete dummy_data_param_;
delete eltwise_param_;
delete elu_param_;
delete embed_param_;
delete exp_param_;
delete flatten_param_;
delete hdf5_data_param_;
delete hdf5_output_param_;
delete hinge_loss_param_;
delete image_data_param_;
delete infogain_loss_param_;
delete inner_product_param_;
delete input_param_;
delete log_param_;
delete lrn_param_;
delete memory_data_param_;
delete mvn_param_;
delete norm_param_;
delete permute_param_;
delete parameter_param_;
delete pooling_param_;
delete power_param_;
delete prelu_param_;
delete prior_box_param_;
delete proposal_param_;
delete psroi_pooling_param_;
delete python_param_;
delete recurrent_param_;
delete reduction_param_;
delete relu_param_;
delete reshape_param_;
delete roi_pooling_param_;
delete scale_param_;
delete sigmoid_param_;
delete softmax_param_;
delete spp_param_;
delete slice_param_;
delete tanh_param_;
delete threshold_param_;
delete tile_param_;
delete window_data_param_;
}
}
void LayerParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* LayerParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return LayerParameter_descriptor_;
}
const LayerParameter& LayerParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<LayerParameter> LayerParameter_default_instance_;
LayerParameter* LayerParameter::New(::google::protobuf::Arena* arena) const {
LayerParameter* n = new LayerParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void LayerParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.LayerParameter)
if (_has_bits_[0 / 32] & 19u) {
if (has_name()) {
name_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
if (has_type()) {
type_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
phase_ = 0;
}
if (_has_bits_[8 / 32] & 63488u) {
if (has_transform_param()) {
if (transform_param_ != NULL) transform_param_->::opencv_caffe::TransformationParameter::Clear();
}
if (has_loss_param()) {
if (loss_param_ != NULL) loss_param_->::opencv_caffe::LossParameter::Clear();
}
if (has_accuracy_param()) {
if (accuracy_param_ != NULL) accuracy_param_->::opencv_caffe::AccuracyParameter::Clear();
}
if (has_argmax_param()) {
if (argmax_param_ != NULL) argmax_param_->::opencv_caffe::ArgMaxParameter::Clear();
}
if (has_batch_norm_param()) {
if (batch_norm_param_ != NULL) batch_norm_param_->::opencv_caffe::BatchNormParameter::Clear();
}
}
if (_has_bits_[16 / 32] & 16711680u) {
if (has_bias_param()) {
if (bias_param_ != NULL) bias_param_->::opencv_caffe::BiasParameter::Clear();
}
if (has_concat_param()) {
if (concat_param_ != NULL) concat_param_->::opencv_caffe::ConcatParameter::Clear();
}
if (has_contrastive_loss_param()) {
if (contrastive_loss_param_ != NULL) contrastive_loss_param_->::opencv_caffe::ContrastiveLossParameter::Clear();
}
if (has_convolution_param()) {
if (convolution_param_ != NULL) convolution_param_->::opencv_caffe::ConvolutionParameter::Clear();
}
if (has_crop_param()) {
if (crop_param_ != NULL) crop_param_->::opencv_caffe::CropParameter::Clear();
}
if (has_data_param()) {
if (data_param_ != NULL) data_param_->::opencv_caffe::DataParameter::Clear();
}
if (has_detection_output_param()) {
if (detection_output_param_ != NULL) detection_output_param_->::opencv_caffe::DetectionOutputParameter::Clear();
}
if (has_dropout_param()) {
if (dropout_param_ != NULL) dropout_param_->::opencv_caffe::DropoutParameter::Clear();
}
}
if (_has_bits_[24 / 32] & 4278190080u) {
if (has_dummy_data_param()) {
if (dummy_data_param_ != NULL) dummy_data_param_->::opencv_caffe::DummyDataParameter::Clear();
}
if (has_eltwise_param()) {
if (eltwise_param_ != NULL) eltwise_param_->::opencv_caffe::EltwiseParameter::Clear();
}
if (has_elu_param()) {
if (elu_param_ != NULL) elu_param_->::opencv_caffe::ELUParameter::Clear();
}
if (has_embed_param()) {
if (embed_param_ != NULL) embed_param_->::opencv_caffe::EmbedParameter::Clear();
}
if (has_exp_param()) {
if (exp_param_ != NULL) exp_param_->::opencv_caffe::ExpParameter::Clear();
}
if (has_flatten_param()) {
if (flatten_param_ != NULL) flatten_param_->::opencv_caffe::FlattenParameter::Clear();
}
if (has_hdf5_data_param()) {
if (hdf5_data_param_ != NULL) hdf5_data_param_->::opencv_caffe::HDF5DataParameter::Clear();
}
if (has_hdf5_output_param()) {
if (hdf5_output_param_ != NULL) hdf5_output_param_->::opencv_caffe::HDF5OutputParameter::Clear();
}
}
if (_has_bits_[32 / 32] & 255u) {
if (has_hinge_loss_param()) {
if (hinge_loss_param_ != NULL) hinge_loss_param_->::opencv_caffe::HingeLossParameter::Clear();
}
if (has_image_data_param()) {
if (image_data_param_ != NULL) image_data_param_->::opencv_caffe::ImageDataParameter::Clear();
}
if (has_infogain_loss_param()) {
if (infogain_loss_param_ != NULL) infogain_loss_param_->::opencv_caffe::InfogainLossParameter::Clear();
}
if (has_inner_product_param()) {
if (inner_product_param_ != NULL) inner_product_param_->::opencv_caffe::InnerProductParameter::Clear();
}
if (has_input_param()) {
if (input_param_ != NULL) input_param_->::opencv_caffe::InputParameter::Clear();
}
if (has_log_param()) {
if (log_param_ != NULL) log_param_->::opencv_caffe::LogParameter::Clear();
}
if (has_lrn_param()) {
if (lrn_param_ != NULL) lrn_param_->::opencv_caffe::LRNParameter::Clear();
}
if (has_memory_data_param()) {
if (memory_data_param_ != NULL) memory_data_param_->::opencv_caffe::MemoryDataParameter::Clear();
}
}
if (_has_bits_[40 / 32] & 65280u) {
if (has_mvn_param()) {
if (mvn_param_ != NULL) mvn_param_->::opencv_caffe::MVNParameter::Clear();
}
if (has_norm_param()) {
if (norm_param_ != NULL) norm_param_->::opencv_caffe::NormalizeBBoxParameter::Clear();
}
if (has_permute_param()) {
if (permute_param_ != NULL) permute_param_->::opencv_caffe::PermuteParameter::Clear();
}
if (has_parameter_param()) {
if (parameter_param_ != NULL) parameter_param_->::opencv_caffe::ParameterParameter::Clear();
}
if (has_pooling_param()) {
if (pooling_param_ != NULL) pooling_param_->::opencv_caffe::PoolingParameter::Clear();
}
if (has_power_param()) {
if (power_param_ != NULL) power_param_->::opencv_caffe::PowerParameter::Clear();
}
if (has_prelu_param()) {
if (prelu_param_ != NULL) prelu_param_->::opencv_caffe::PReLUParameter::Clear();
}
if (has_prior_box_param()) {
if (prior_box_param_ != NULL) prior_box_param_->::opencv_caffe::PriorBoxParameter::Clear();
}
}
if (_has_bits_[48 / 32] & 16711680u) {
if (has_proposal_param()) {
if (proposal_param_ != NULL) proposal_param_->::opencv_caffe::ProposalParameter::Clear();
}
if (has_psroi_pooling_param()) {
if (psroi_pooling_param_ != NULL) psroi_pooling_param_->::opencv_caffe::PSROIPoolingParameter::Clear();
}
if (has_python_param()) {
if (python_param_ != NULL) python_param_->::opencv_caffe::PythonParameter::Clear();
}
if (has_recurrent_param()) {
if (recurrent_param_ != NULL) recurrent_param_->::opencv_caffe::RecurrentParameter::Clear();
}
if (has_reduction_param()) {
if (reduction_param_ != NULL) reduction_param_->::opencv_caffe::ReductionParameter::Clear();
}
if (has_relu_param()) {
if (relu_param_ != NULL) relu_param_->::opencv_caffe::ReLUParameter::Clear();
}
if (has_reshape_param()) {
if (reshape_param_ != NULL) reshape_param_->::opencv_caffe::ReshapeParameter::Clear();
}
if (has_roi_pooling_param()) {
if (roi_pooling_param_ != NULL) roi_pooling_param_->::opencv_caffe::ROIPoolingParameter::Clear();
}
}
if (_has_bits_[56 / 32] & 4278190080u) {
if (has_scale_param()) {
if (scale_param_ != NULL) scale_param_->::opencv_caffe::ScaleParameter::Clear();
}
if (has_sigmoid_param()) {
if (sigmoid_param_ != NULL) sigmoid_param_->::opencv_caffe::SigmoidParameter::Clear();
}
if (has_softmax_param()) {
if (softmax_param_ != NULL) softmax_param_->::opencv_caffe::SoftmaxParameter::Clear();
}
if (has_spp_param()) {
if (spp_param_ != NULL) spp_param_->::opencv_caffe::SPPParameter::Clear();
}
if (has_slice_param()) {
if (slice_param_ != NULL) slice_param_->::opencv_caffe::SliceParameter::Clear();
}
if (has_tanh_param()) {
if (tanh_param_ != NULL) tanh_param_->::opencv_caffe::TanHParameter::Clear();
}
if (has_threshold_param()) {
if (threshold_param_ != NULL) threshold_param_->::opencv_caffe::ThresholdParameter::Clear();
}
if (has_tile_param()) {
if (tile_param_ != NULL) tile_param_->::opencv_caffe::TileParameter::Clear();
}
}
if (has_window_data_param()) {
if (window_data_param_ != NULL) window_data_param_->::opencv_caffe::WindowDataParameter::Clear();
}
bottom_.Clear();
top_.Clear();
loss_weight_.Clear();
param_.Clear();
blobs_.Clear();
propagate_down_.Clear();
include_.Clear();
exclude_.Clear();
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool LayerParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.LayerParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(66133690);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional string name = 1;
case 1: {
if (tag == 10) {
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_name()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->name().data(), this->name().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.LayerParameter.name");
} else {
goto handle_unusual;
}
if (input->ExpectTag(18)) goto parse_type;
break;
}
// optional string type = 2;
case 2: {
if (tag == 18) {
parse_type:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_type()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->type().data(), this->type().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.LayerParameter.type");
} else {
goto handle_unusual;
}
if (input->ExpectTag(26)) goto parse_bottom;
break;
}
// repeated string bottom = 3;
case 3: {
if (tag == 26) {
parse_bottom:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->add_bottom()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->bottom(this->bottom_size() - 1).data(),
this->bottom(this->bottom_size() - 1).length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.LayerParameter.bottom");
} else {
goto handle_unusual;
}
if (input->ExpectTag(26)) goto parse_bottom;
if (input->ExpectTag(34)) goto parse_top;
break;
}
// repeated string top = 4;
case 4: {
if (tag == 34) {
parse_top:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->add_top()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->top(this->top_size() - 1).data(),
this->top(this->top_size() - 1).length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.LayerParameter.top");
} else {
goto handle_unusual;
}
if (input->ExpectTag(34)) goto parse_top;
if (input->ExpectTag(45)) goto parse_loss_weight;
break;
}
// repeated float loss_weight = 5;
case 5: {
if (tag == 45) {
parse_loss_weight:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
1, 45, input, this->mutable_loss_weight())));
} else if (tag == 42) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, this->mutable_loss_weight())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(45)) goto parse_loss_weight;
if (input->ExpectTag(50)) goto parse_param;
break;
}
// repeated .opencv_caffe.ParamSpec param = 6;
case 6: {
if (tag == 50) {
parse_param:
DO_(input->IncrementRecursionDepth());
parse_loop_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtualNoRecursionDepth(
input, add_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(50)) goto parse_loop_param;
if (input->ExpectTag(58)) goto parse_loop_blobs;
input->UnsafeDecrementRecursionDepth();
break;
}
// repeated .opencv_caffe.BlobProto blobs = 7;
case 7: {
if (tag == 58) {
DO_(input->IncrementRecursionDepth());
parse_loop_blobs:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtualNoRecursionDepth(
input, add_blobs()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(58)) goto parse_loop_blobs;
if (input->ExpectTag(66)) goto parse_loop_include;
input->UnsafeDecrementRecursionDepth();
break;
}
// repeated .opencv_caffe.NetStateRule include = 8;
case 8: {
if (tag == 66) {
DO_(input->IncrementRecursionDepth());
parse_loop_include:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtualNoRecursionDepth(
input, add_include()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(66)) goto parse_loop_include;
if (input->ExpectTag(74)) goto parse_loop_exclude;
input->UnsafeDecrementRecursionDepth();
break;
}
// repeated .opencv_caffe.NetStateRule exclude = 9;
case 9: {
if (tag == 74) {
DO_(input->IncrementRecursionDepth());
parse_loop_exclude:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtualNoRecursionDepth(
input, add_exclude()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(74)) goto parse_loop_exclude;
input->UnsafeDecrementRecursionDepth();
if (input->ExpectTag(80)) goto parse_phase;
break;
}
// optional .opencv_caffe.Phase phase = 10;
case 10: {
if (tag == 80) {
parse_phase:
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::Phase_IsValid(value)) {
set_phase(static_cast< ::opencv_caffe::Phase >(value));
} else {
mutable_unknown_fields()->AddVarint(10, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectTag(88)) goto parse_propagate_down;
break;
}
// repeated bool propagate_down = 11;
case 11: {
if (tag == 88) {
parse_propagate_down:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
1, 88, input, this->mutable_propagate_down())));
} else if (tag == 90) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, this->mutable_propagate_down())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(88)) goto parse_propagate_down;
if (input->ExpectTag(802)) goto parse_transform_param;
break;
}
// optional .opencv_caffe.TransformationParameter transform_param = 100;
case 100: {
if (tag == 802) {
parse_transform_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_transform_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(810)) goto parse_loss_param;
break;
}
// optional .opencv_caffe.LossParameter loss_param = 101;
case 101: {
if (tag == 810) {
parse_loss_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_loss_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(818)) goto parse_accuracy_param;
break;
}
// optional .opencv_caffe.AccuracyParameter accuracy_param = 102;
case 102: {
if (tag == 818) {
parse_accuracy_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_accuracy_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(826)) goto parse_argmax_param;
break;
}
// optional .opencv_caffe.ArgMaxParameter argmax_param = 103;
case 103: {
if (tag == 826) {
parse_argmax_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_argmax_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(834)) goto parse_concat_param;
break;
}
// optional .opencv_caffe.ConcatParameter concat_param = 104;
case 104: {
if (tag == 834) {
parse_concat_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_concat_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(842)) goto parse_contrastive_loss_param;
break;
}
// optional .opencv_caffe.ContrastiveLossParameter contrastive_loss_param = 105;
case 105: {
if (tag == 842) {
parse_contrastive_loss_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_contrastive_loss_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(850)) goto parse_convolution_param;
break;
}
// optional .opencv_caffe.ConvolutionParameter convolution_param = 106;
case 106: {
if (tag == 850) {
parse_convolution_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_convolution_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(858)) goto parse_data_param;
break;
}
// optional .opencv_caffe.DataParameter data_param = 107;
case 107: {
if (tag == 858) {
parse_data_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_data_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(866)) goto parse_dropout_param;
break;
}
// optional .opencv_caffe.DropoutParameter dropout_param = 108;
case 108: {
if (tag == 866) {
parse_dropout_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_dropout_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(874)) goto parse_dummy_data_param;
break;
}
// optional .opencv_caffe.DummyDataParameter dummy_data_param = 109;
case 109: {
if (tag == 874) {
parse_dummy_data_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_dummy_data_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(882)) goto parse_eltwise_param;
break;
}
// optional .opencv_caffe.EltwiseParameter eltwise_param = 110;
case 110: {
if (tag == 882) {
parse_eltwise_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_eltwise_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(890)) goto parse_exp_param;
break;
}
// optional .opencv_caffe.ExpParameter exp_param = 111;
case 111: {
if (tag == 890) {
parse_exp_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_exp_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(898)) goto parse_hdf5_data_param;
break;
}
// optional .opencv_caffe.HDF5DataParameter hdf5_data_param = 112;
case 112: {
if (tag == 898) {
parse_hdf5_data_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_hdf5_data_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(906)) goto parse_hdf5_output_param;
break;
}
// optional .opencv_caffe.HDF5OutputParameter hdf5_output_param = 113;
case 113: {
if (tag == 906) {
parse_hdf5_output_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_hdf5_output_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(914)) goto parse_hinge_loss_param;
break;
}
// optional .opencv_caffe.HingeLossParameter hinge_loss_param = 114;
case 114: {
if (tag == 914) {
parse_hinge_loss_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_hinge_loss_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(922)) goto parse_image_data_param;
break;
}
// optional .opencv_caffe.ImageDataParameter image_data_param = 115;
case 115: {
if (tag == 922) {
parse_image_data_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_image_data_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(930)) goto parse_infogain_loss_param;
break;
}
// optional .opencv_caffe.InfogainLossParameter infogain_loss_param = 116;
case 116: {
if (tag == 930) {
parse_infogain_loss_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_infogain_loss_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(938)) goto parse_inner_product_param;
break;
}
// optional .opencv_caffe.InnerProductParameter inner_product_param = 117;
case 117: {
if (tag == 938) {
parse_inner_product_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_inner_product_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(946)) goto parse_lrn_param;
break;
}
// optional .opencv_caffe.LRNParameter lrn_param = 118;
case 118: {
if (tag == 946) {
parse_lrn_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_lrn_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(954)) goto parse_memory_data_param;
break;
}
// optional .opencv_caffe.MemoryDataParameter memory_data_param = 119;
case 119: {
if (tag == 954) {
parse_memory_data_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_memory_data_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(962)) goto parse_mvn_param;
break;
}
// optional .opencv_caffe.MVNParameter mvn_param = 120;
case 120: {
if (tag == 962) {
parse_mvn_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_mvn_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(970)) goto parse_pooling_param;
break;
}
// optional .opencv_caffe.PoolingParameter pooling_param = 121;
case 121: {
if (tag == 970) {
parse_pooling_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_pooling_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(978)) goto parse_power_param;
break;
}
// optional .opencv_caffe.PowerParameter power_param = 122;
case 122: {
if (tag == 978) {
parse_power_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_power_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(986)) goto parse_relu_param;
break;
}
// optional .opencv_caffe.ReLUParameter relu_param = 123;
case 123: {
if (tag == 986) {
parse_relu_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_relu_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(994)) goto parse_sigmoid_param;
break;
}
// optional .opencv_caffe.SigmoidParameter sigmoid_param = 124;
case 124: {
if (tag == 994) {
parse_sigmoid_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_sigmoid_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1002)) goto parse_softmax_param;
break;
}
// optional .opencv_caffe.SoftmaxParameter softmax_param = 125;
case 125: {
if (tag == 1002) {
parse_softmax_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_softmax_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1010)) goto parse_slice_param;
break;
}
// optional .opencv_caffe.SliceParameter slice_param = 126;
case 126: {
if (tag == 1010) {
parse_slice_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_slice_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1018)) goto parse_tanh_param;
break;
}
// optional .opencv_caffe.TanHParameter tanh_param = 127;
case 127: {
if (tag == 1018) {
parse_tanh_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_tanh_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1026)) goto parse_threshold_param;
break;
}
// optional .opencv_caffe.ThresholdParameter threshold_param = 128;
case 128: {
if (tag == 1026) {
parse_threshold_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_threshold_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1034)) goto parse_window_data_param;
break;
}
// optional .opencv_caffe.WindowDataParameter window_data_param = 129;
case 129: {
if (tag == 1034) {
parse_window_data_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_window_data_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1042)) goto parse_python_param;
break;
}
// optional .opencv_caffe.PythonParameter python_param = 130;
case 130: {
if (tag == 1042) {
parse_python_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_python_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1050)) goto parse_prelu_param;
break;
}
// optional .opencv_caffe.PReLUParameter prelu_param = 131;
case 131: {
if (tag == 1050) {
parse_prelu_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_prelu_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1058)) goto parse_spp_param;
break;
}
// optional .opencv_caffe.SPPParameter spp_param = 132;
case 132: {
if (tag == 1058) {
parse_spp_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_spp_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1066)) goto parse_reshape_param;
break;
}
// optional .opencv_caffe.ReshapeParameter reshape_param = 133;
case 133: {
if (tag == 1066) {
parse_reshape_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_reshape_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1074)) goto parse_log_param;
break;
}
// optional .opencv_caffe.LogParameter log_param = 134;
case 134: {
if (tag == 1074) {
parse_log_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_log_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1082)) goto parse_flatten_param;
break;
}
// optional .opencv_caffe.FlattenParameter flatten_param = 135;
case 135: {
if (tag == 1082) {
parse_flatten_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_flatten_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1090)) goto parse_reduction_param;
break;
}
// optional .opencv_caffe.ReductionParameter reduction_param = 136;
case 136: {
if (tag == 1090) {
parse_reduction_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_reduction_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1098)) goto parse_embed_param;
break;
}
// optional .opencv_caffe.EmbedParameter embed_param = 137;
case 137: {
if (tag == 1098) {
parse_embed_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_embed_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1106)) goto parse_tile_param;
break;
}
// optional .opencv_caffe.TileParameter tile_param = 138;
case 138: {
if (tag == 1106) {
parse_tile_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_tile_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1114)) goto parse_batch_norm_param;
break;
}
// optional .opencv_caffe.BatchNormParameter batch_norm_param = 139;
case 139: {
if (tag == 1114) {
parse_batch_norm_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_batch_norm_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1122)) goto parse_elu_param;
break;
}
// optional .opencv_caffe.ELUParameter elu_param = 140;
case 140: {
if (tag == 1122) {
parse_elu_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_elu_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1130)) goto parse_bias_param;
break;
}
// optional .opencv_caffe.BiasParameter bias_param = 141;
case 141: {
if (tag == 1130) {
parse_bias_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_bias_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1138)) goto parse_scale_param;
break;
}
// optional .opencv_caffe.ScaleParameter scale_param = 142;
case 142: {
if (tag == 1138) {
parse_scale_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_scale_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1146)) goto parse_input_param;
break;
}
// optional .opencv_caffe.InputParameter input_param = 143;
case 143: {
if (tag == 1146) {
parse_input_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_input_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1154)) goto parse_crop_param;
break;
}
// optional .opencv_caffe.CropParameter crop_param = 144;
case 144: {
if (tag == 1154) {
parse_crop_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_crop_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1162)) goto parse_parameter_param;
break;
}
// optional .opencv_caffe.ParameterParameter parameter_param = 145;
case 145: {
if (tag == 1162) {
parse_parameter_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_parameter_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1170)) goto parse_recurrent_param;
break;
}
// optional .opencv_caffe.RecurrentParameter recurrent_param = 146;
case 146: {
if (tag == 1170) {
parse_recurrent_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_recurrent_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1178)) goto parse_detection_output_param;
break;
}
// optional .opencv_caffe.DetectionOutputParameter detection_output_param = 147;
case 147: {
if (tag == 1178) {
parse_detection_output_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_detection_output_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1186)) goto parse_permute_param;
break;
}
// optional .opencv_caffe.PermuteParameter permute_param = 148;
case 148: {
if (tag == 1186) {
parse_permute_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_permute_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1194)) goto parse_norm_param;
break;
}
// optional .opencv_caffe.NormalizeBBoxParameter norm_param = 149;
case 149: {
if (tag == 1194) {
parse_norm_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_norm_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1202)) goto parse_prior_box_param;
break;
}
// optional .opencv_caffe.PriorBoxParameter prior_box_param = 150;
case 150: {
if (tag == 1202) {
parse_prior_box_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_prior_box_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(1610)) goto parse_proposal_param;
break;
}
// optional .opencv_caffe.ProposalParameter proposal_param = 201;
case 201: {
if (tag == 1610) {
parse_proposal_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_proposal_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(80010)) goto parse_psroi_pooling_param;
break;
}
// optional .opencv_caffe.PSROIPoolingParameter psroi_pooling_param = 10001;
case 10001: {
if (tag == 80010) {
parse_psroi_pooling_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_psroi_pooling_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(66133690)) goto parse_roi_pooling_param;
break;
}
// optional .opencv_caffe.ROIPoolingParameter roi_pooling_param = 8266711;
case 8266711: {
if (tag == 66133690) {
parse_roi_pooling_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_roi_pooling_param()));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.LayerParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.LayerParameter)
return false;
#undef DO_
}
void LayerParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.LayerParameter)
// optional string name = 1;
if (has_name()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->name().data(), this->name().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.LayerParameter.name");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
1, this->name(), output);
}
// optional string type = 2;
if (has_type()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->type().data(), this->type().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.LayerParameter.type");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
2, this->type(), output);
}
// repeated string bottom = 3;
for (int i = 0; i < this->bottom_size(); i++) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->bottom(i).data(), this->bottom(i).length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.LayerParameter.bottom");
::google::protobuf::internal::WireFormatLite::WriteString(
3, this->bottom(i), output);
}
// repeated string top = 4;
for (int i = 0; i < this->top_size(); i++) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->top(i).data(), this->top(i).length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.LayerParameter.top");
::google::protobuf::internal::WireFormatLite::WriteString(
4, this->top(i), output);
}
// repeated float loss_weight = 5;
for (int i = 0; i < this->loss_weight_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteFloat(
5, this->loss_weight(i), output);
}
// repeated .opencv_caffe.ParamSpec param = 6;
for (unsigned int i = 0, n = this->param_size(); i < n; i++) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
6, this->param(i), output);
}
// repeated .opencv_caffe.BlobProto blobs = 7;
for (unsigned int i = 0, n = this->blobs_size(); i < n; i++) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
7, this->blobs(i), output);
}
// repeated .opencv_caffe.NetStateRule include = 8;
for (unsigned int i = 0, n = this->include_size(); i < n; i++) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
8, this->include(i), output);
}
// repeated .opencv_caffe.NetStateRule exclude = 9;
for (unsigned int i = 0, n = this->exclude_size(); i < n; i++) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
9, this->exclude(i), output);
}
// optional .opencv_caffe.Phase phase = 10;
if (has_phase()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
10, this->phase(), output);
}
// repeated bool propagate_down = 11;
for (int i = 0; i < this->propagate_down_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteBool(
11, this->propagate_down(i), output);
}
// optional .opencv_caffe.TransformationParameter transform_param = 100;
if (has_transform_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
100, *this->transform_param_, output);
}
// optional .opencv_caffe.LossParameter loss_param = 101;
if (has_loss_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
101, *this->loss_param_, output);
}
// optional .opencv_caffe.AccuracyParameter accuracy_param = 102;
if (has_accuracy_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
102, *this->accuracy_param_, output);
}
// optional .opencv_caffe.ArgMaxParameter argmax_param = 103;
if (has_argmax_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
103, *this->argmax_param_, output);
}
// optional .opencv_caffe.ConcatParameter concat_param = 104;
if (has_concat_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
104, *this->concat_param_, output);
}
// optional .opencv_caffe.ContrastiveLossParameter contrastive_loss_param = 105;
if (has_contrastive_loss_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
105, *this->contrastive_loss_param_, output);
}
// optional .opencv_caffe.ConvolutionParameter convolution_param = 106;
if (has_convolution_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
106, *this->convolution_param_, output);
}
// optional .opencv_caffe.DataParameter data_param = 107;
if (has_data_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
107, *this->data_param_, output);
}
// optional .opencv_caffe.DropoutParameter dropout_param = 108;
if (has_dropout_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
108, *this->dropout_param_, output);
}
// optional .opencv_caffe.DummyDataParameter dummy_data_param = 109;
if (has_dummy_data_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
109, *this->dummy_data_param_, output);
}
// optional .opencv_caffe.EltwiseParameter eltwise_param = 110;
if (has_eltwise_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
110, *this->eltwise_param_, output);
}
// optional .opencv_caffe.ExpParameter exp_param = 111;
if (has_exp_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
111, *this->exp_param_, output);
}
// optional .opencv_caffe.HDF5DataParameter hdf5_data_param = 112;
if (has_hdf5_data_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
112, *this->hdf5_data_param_, output);
}
// optional .opencv_caffe.HDF5OutputParameter hdf5_output_param = 113;
if (has_hdf5_output_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
113, *this->hdf5_output_param_, output);
}
// optional .opencv_caffe.HingeLossParameter hinge_loss_param = 114;
if (has_hinge_loss_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
114, *this->hinge_loss_param_, output);
}
// optional .opencv_caffe.ImageDataParameter image_data_param = 115;
if (has_image_data_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
115, *this->image_data_param_, output);
}
// optional .opencv_caffe.InfogainLossParameter infogain_loss_param = 116;
if (has_infogain_loss_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
116, *this->infogain_loss_param_, output);
}
// optional .opencv_caffe.InnerProductParameter inner_product_param = 117;
if (has_inner_product_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
117, *this->inner_product_param_, output);
}
// optional .opencv_caffe.LRNParameter lrn_param = 118;
if (has_lrn_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
118, *this->lrn_param_, output);
}
// optional .opencv_caffe.MemoryDataParameter memory_data_param = 119;
if (has_memory_data_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
119, *this->memory_data_param_, output);
}
// optional .opencv_caffe.MVNParameter mvn_param = 120;
if (has_mvn_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
120, *this->mvn_param_, output);
}
// optional .opencv_caffe.PoolingParameter pooling_param = 121;
if (has_pooling_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
121, *this->pooling_param_, output);
}
// optional .opencv_caffe.PowerParameter power_param = 122;
if (has_power_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
122, *this->power_param_, output);
}
// optional .opencv_caffe.ReLUParameter relu_param = 123;
if (has_relu_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
123, *this->relu_param_, output);
}
// optional .opencv_caffe.SigmoidParameter sigmoid_param = 124;
if (has_sigmoid_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
124, *this->sigmoid_param_, output);
}
// optional .opencv_caffe.SoftmaxParameter softmax_param = 125;
if (has_softmax_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
125, *this->softmax_param_, output);
}
// optional .opencv_caffe.SliceParameter slice_param = 126;
if (has_slice_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
126, *this->slice_param_, output);
}
// optional .opencv_caffe.TanHParameter tanh_param = 127;
if (has_tanh_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
127, *this->tanh_param_, output);
}
// optional .opencv_caffe.ThresholdParameter threshold_param = 128;
if (has_threshold_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
128, *this->threshold_param_, output);
}
// optional .opencv_caffe.WindowDataParameter window_data_param = 129;
if (has_window_data_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
129, *this->window_data_param_, output);
}
// optional .opencv_caffe.PythonParameter python_param = 130;
if (has_python_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
130, *this->python_param_, output);
}
// optional .opencv_caffe.PReLUParameter prelu_param = 131;
if (has_prelu_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
131, *this->prelu_param_, output);
}
// optional .opencv_caffe.SPPParameter spp_param = 132;
if (has_spp_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
132, *this->spp_param_, output);
}
// optional .opencv_caffe.ReshapeParameter reshape_param = 133;
if (has_reshape_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
133, *this->reshape_param_, output);
}
// optional .opencv_caffe.LogParameter log_param = 134;
if (has_log_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
134, *this->log_param_, output);
}
// optional .opencv_caffe.FlattenParameter flatten_param = 135;
if (has_flatten_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
135, *this->flatten_param_, output);
}
// optional .opencv_caffe.ReductionParameter reduction_param = 136;
if (has_reduction_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
136, *this->reduction_param_, output);
}
// optional .opencv_caffe.EmbedParameter embed_param = 137;
if (has_embed_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
137, *this->embed_param_, output);
}
// optional .opencv_caffe.TileParameter tile_param = 138;
if (has_tile_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
138, *this->tile_param_, output);
}
// optional .opencv_caffe.BatchNormParameter batch_norm_param = 139;
if (has_batch_norm_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
139, *this->batch_norm_param_, output);
}
// optional .opencv_caffe.ELUParameter elu_param = 140;
if (has_elu_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
140, *this->elu_param_, output);
}
// optional .opencv_caffe.BiasParameter bias_param = 141;
if (has_bias_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
141, *this->bias_param_, output);
}
// optional .opencv_caffe.ScaleParameter scale_param = 142;
if (has_scale_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
142, *this->scale_param_, output);
}
// optional .opencv_caffe.InputParameter input_param = 143;
if (has_input_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
143, *this->input_param_, output);
}
// optional .opencv_caffe.CropParameter crop_param = 144;
if (has_crop_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
144, *this->crop_param_, output);
}
// optional .opencv_caffe.ParameterParameter parameter_param = 145;
if (has_parameter_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
145, *this->parameter_param_, output);
}
// optional .opencv_caffe.RecurrentParameter recurrent_param = 146;
if (has_recurrent_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
146, *this->recurrent_param_, output);
}
// optional .opencv_caffe.DetectionOutputParameter detection_output_param = 147;
if (has_detection_output_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
147, *this->detection_output_param_, output);
}
// optional .opencv_caffe.PermuteParameter permute_param = 148;
if (has_permute_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
148, *this->permute_param_, output);
}
// optional .opencv_caffe.NormalizeBBoxParameter norm_param = 149;
if (has_norm_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
149, *this->norm_param_, output);
}
// optional .opencv_caffe.PriorBoxParameter prior_box_param = 150;
if (has_prior_box_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
150, *this->prior_box_param_, output);
}
// optional .opencv_caffe.ProposalParameter proposal_param = 201;
if (has_proposal_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
201, *this->proposal_param_, output);
}
// optional .opencv_caffe.PSROIPoolingParameter psroi_pooling_param = 10001;
if (has_psroi_pooling_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
10001, *this->psroi_pooling_param_, output);
}
// optional .opencv_caffe.ROIPoolingParameter roi_pooling_param = 8266711;
if (has_roi_pooling_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
8266711, *this->roi_pooling_param_, output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.LayerParameter)
}
::google::protobuf::uint8* LayerParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.LayerParameter)
// optional string name = 1;
if (has_name()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->name().data(), this->name().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.LayerParameter.name");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
1, this->name(), target);
}
// optional string type = 2;
if (has_type()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->type().data(), this->type().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.LayerParameter.type");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
2, this->type(), target);
}
// repeated string bottom = 3;
for (int i = 0; i < this->bottom_size(); i++) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->bottom(i).data(), this->bottom(i).length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.LayerParameter.bottom");
target = ::google::protobuf::internal::WireFormatLite::
WriteStringToArray(3, this->bottom(i), target);
}
// repeated string top = 4;
for (int i = 0; i < this->top_size(); i++) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->top(i).data(), this->top(i).length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.LayerParameter.top");
target = ::google::protobuf::internal::WireFormatLite::
WriteStringToArray(4, this->top(i), target);
}
// repeated float loss_weight = 5;
for (int i = 0; i < this->loss_weight_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteFloatToArray(5, this->loss_weight(i), target);
}
// repeated .opencv_caffe.ParamSpec param = 6;
for (unsigned int i = 0, n = this->param_size(); i < n; i++) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
6, this->param(i), false, target);
}
// repeated .opencv_caffe.BlobProto blobs = 7;
for (unsigned int i = 0, n = this->blobs_size(); i < n; i++) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
7, this->blobs(i), false, target);
}
// repeated .opencv_caffe.NetStateRule include = 8;
for (unsigned int i = 0, n = this->include_size(); i < n; i++) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
8, this->include(i), false, target);
}
// repeated .opencv_caffe.NetStateRule exclude = 9;
for (unsigned int i = 0, n = this->exclude_size(); i < n; i++) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
9, this->exclude(i), false, target);
}
// optional .opencv_caffe.Phase phase = 10;
if (has_phase()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
10, this->phase(), target);
}
// repeated bool propagate_down = 11;
for (int i = 0; i < this->propagate_down_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteBoolToArray(11, this->propagate_down(i), target);
}
// optional .opencv_caffe.TransformationParameter transform_param = 100;
if (has_transform_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
100, *this->transform_param_, false, target);
}
// optional .opencv_caffe.LossParameter loss_param = 101;
if (has_loss_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
101, *this->loss_param_, false, target);
}
// optional .opencv_caffe.AccuracyParameter accuracy_param = 102;
if (has_accuracy_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
102, *this->accuracy_param_, false, target);
}
// optional .opencv_caffe.ArgMaxParameter argmax_param = 103;
if (has_argmax_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
103, *this->argmax_param_, false, target);
}
// optional .opencv_caffe.ConcatParameter concat_param = 104;
if (has_concat_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
104, *this->concat_param_, false, target);
}
// optional .opencv_caffe.ContrastiveLossParameter contrastive_loss_param = 105;
if (has_contrastive_loss_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
105, *this->contrastive_loss_param_, false, target);
}
// optional .opencv_caffe.ConvolutionParameter convolution_param = 106;
if (has_convolution_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
106, *this->convolution_param_, false, target);
}
// optional .opencv_caffe.DataParameter data_param = 107;
if (has_data_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
107, *this->data_param_, false, target);
}
// optional .opencv_caffe.DropoutParameter dropout_param = 108;
if (has_dropout_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
108, *this->dropout_param_, false, target);
}
// optional .opencv_caffe.DummyDataParameter dummy_data_param = 109;
if (has_dummy_data_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
109, *this->dummy_data_param_, false, target);
}
// optional .opencv_caffe.EltwiseParameter eltwise_param = 110;
if (has_eltwise_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
110, *this->eltwise_param_, false, target);
}
// optional .opencv_caffe.ExpParameter exp_param = 111;
if (has_exp_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
111, *this->exp_param_, false, target);
}
// optional .opencv_caffe.HDF5DataParameter hdf5_data_param = 112;
if (has_hdf5_data_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
112, *this->hdf5_data_param_, false, target);
}
// optional .opencv_caffe.HDF5OutputParameter hdf5_output_param = 113;
if (has_hdf5_output_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
113, *this->hdf5_output_param_, false, target);
}
// optional .opencv_caffe.HingeLossParameter hinge_loss_param = 114;
if (has_hinge_loss_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
114, *this->hinge_loss_param_, false, target);
}
// optional .opencv_caffe.ImageDataParameter image_data_param = 115;
if (has_image_data_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
115, *this->image_data_param_, false, target);
}
// optional .opencv_caffe.InfogainLossParameter infogain_loss_param = 116;
if (has_infogain_loss_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
116, *this->infogain_loss_param_, false, target);
}
// optional .opencv_caffe.InnerProductParameter inner_product_param = 117;
if (has_inner_product_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
117, *this->inner_product_param_, false, target);
}
// optional .opencv_caffe.LRNParameter lrn_param = 118;
if (has_lrn_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
118, *this->lrn_param_, false, target);
}
// optional .opencv_caffe.MemoryDataParameter memory_data_param = 119;
if (has_memory_data_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
119, *this->memory_data_param_, false, target);
}
// optional .opencv_caffe.MVNParameter mvn_param = 120;
if (has_mvn_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
120, *this->mvn_param_, false, target);
}
// optional .opencv_caffe.PoolingParameter pooling_param = 121;
if (has_pooling_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
121, *this->pooling_param_, false, target);
}
// optional .opencv_caffe.PowerParameter power_param = 122;
if (has_power_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
122, *this->power_param_, false, target);
}
// optional .opencv_caffe.ReLUParameter relu_param = 123;
if (has_relu_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
123, *this->relu_param_, false, target);
}
// optional .opencv_caffe.SigmoidParameter sigmoid_param = 124;
if (has_sigmoid_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
124, *this->sigmoid_param_, false, target);
}
// optional .opencv_caffe.SoftmaxParameter softmax_param = 125;
if (has_softmax_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
125, *this->softmax_param_, false, target);
}
// optional .opencv_caffe.SliceParameter slice_param = 126;
if (has_slice_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
126, *this->slice_param_, false, target);
}
// optional .opencv_caffe.TanHParameter tanh_param = 127;
if (has_tanh_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
127, *this->tanh_param_, false, target);
}
// optional .opencv_caffe.ThresholdParameter threshold_param = 128;
if (has_threshold_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
128, *this->threshold_param_, false, target);
}
// optional .opencv_caffe.WindowDataParameter window_data_param = 129;
if (has_window_data_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
129, *this->window_data_param_, false, target);
}
// optional .opencv_caffe.PythonParameter python_param = 130;
if (has_python_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
130, *this->python_param_, false, target);
}
// optional .opencv_caffe.PReLUParameter prelu_param = 131;
if (has_prelu_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
131, *this->prelu_param_, false, target);
}
// optional .opencv_caffe.SPPParameter spp_param = 132;
if (has_spp_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
132, *this->spp_param_, false, target);
}
// optional .opencv_caffe.ReshapeParameter reshape_param = 133;
if (has_reshape_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
133, *this->reshape_param_, false, target);
}
// optional .opencv_caffe.LogParameter log_param = 134;
if (has_log_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
134, *this->log_param_, false, target);
}
// optional .opencv_caffe.FlattenParameter flatten_param = 135;
if (has_flatten_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
135, *this->flatten_param_, false, target);
}
// optional .opencv_caffe.ReductionParameter reduction_param = 136;
if (has_reduction_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
136, *this->reduction_param_, false, target);
}
// optional .opencv_caffe.EmbedParameter embed_param = 137;
if (has_embed_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
137, *this->embed_param_, false, target);
}
// optional .opencv_caffe.TileParameter tile_param = 138;
if (has_tile_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
138, *this->tile_param_, false, target);
}
// optional .opencv_caffe.BatchNormParameter batch_norm_param = 139;
if (has_batch_norm_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
139, *this->batch_norm_param_, false, target);
}
// optional .opencv_caffe.ELUParameter elu_param = 140;
if (has_elu_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
140, *this->elu_param_, false, target);
}
// optional .opencv_caffe.BiasParameter bias_param = 141;
if (has_bias_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
141, *this->bias_param_, false, target);
}
// optional .opencv_caffe.ScaleParameter scale_param = 142;
if (has_scale_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
142, *this->scale_param_, false, target);
}
// optional .opencv_caffe.InputParameter input_param = 143;
if (has_input_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
143, *this->input_param_, false, target);
}
// optional .opencv_caffe.CropParameter crop_param = 144;
if (has_crop_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
144, *this->crop_param_, false, target);
}
// optional .opencv_caffe.ParameterParameter parameter_param = 145;
if (has_parameter_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
145, *this->parameter_param_, false, target);
}
// optional .opencv_caffe.RecurrentParameter recurrent_param = 146;
if (has_recurrent_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
146, *this->recurrent_param_, false, target);
}
// optional .opencv_caffe.DetectionOutputParameter detection_output_param = 147;
if (has_detection_output_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
147, *this->detection_output_param_, false, target);
}
// optional .opencv_caffe.PermuteParameter permute_param = 148;
if (has_permute_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
148, *this->permute_param_, false, target);
}
// optional .opencv_caffe.NormalizeBBoxParameter norm_param = 149;
if (has_norm_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
149, *this->norm_param_, false, target);
}
// optional .opencv_caffe.PriorBoxParameter prior_box_param = 150;
if (has_prior_box_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
150, *this->prior_box_param_, false, target);
}
// optional .opencv_caffe.ProposalParameter proposal_param = 201;
if (has_proposal_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
201, *this->proposal_param_, false, target);
}
// optional .opencv_caffe.PSROIPoolingParameter psroi_pooling_param = 10001;
if (has_psroi_pooling_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
10001, *this->psroi_pooling_param_, false, target);
}
// optional .opencv_caffe.ROIPoolingParameter roi_pooling_param = 8266711;
if (has_roi_pooling_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
8266711, *this->roi_pooling_param_, false, target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.LayerParameter)
return target;
}
size_t LayerParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.LayerParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 19u) {
// optional string name = 1;
if (has_name()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->name());
}
// optional string type = 2;
if (has_type()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->type());
}
// optional .opencv_caffe.Phase phase = 10;
if (has_phase()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->phase());
}
}
if (_has_bits_[11 / 32] & 63488u) {
// optional .opencv_caffe.TransformationParameter transform_param = 100;
if (has_transform_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->transform_param_);
}
// optional .opencv_caffe.LossParameter loss_param = 101;
if (has_loss_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->loss_param_);
}
// optional .opencv_caffe.AccuracyParameter accuracy_param = 102;
if (has_accuracy_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->accuracy_param_);
}
// optional .opencv_caffe.ArgMaxParameter argmax_param = 103;
if (has_argmax_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->argmax_param_);
}
// optional .opencv_caffe.BatchNormParameter batch_norm_param = 139;
if (has_batch_norm_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->batch_norm_param_);
}
}
if (_has_bits_[16 / 32] & 16711680u) {
// optional .opencv_caffe.BiasParameter bias_param = 141;
if (has_bias_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->bias_param_);
}
// optional .opencv_caffe.ConcatParameter concat_param = 104;
if (has_concat_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->concat_param_);
}
// optional .opencv_caffe.ContrastiveLossParameter contrastive_loss_param = 105;
if (has_contrastive_loss_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->contrastive_loss_param_);
}
// optional .opencv_caffe.ConvolutionParameter convolution_param = 106;
if (has_convolution_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->convolution_param_);
}
// optional .opencv_caffe.CropParameter crop_param = 144;
if (has_crop_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->crop_param_);
}
// optional .opencv_caffe.DataParameter data_param = 107;
if (has_data_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->data_param_);
}
// optional .opencv_caffe.DetectionOutputParameter detection_output_param = 147;
if (has_detection_output_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->detection_output_param_);
}
// optional .opencv_caffe.DropoutParameter dropout_param = 108;
if (has_dropout_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->dropout_param_);
}
}
if (_has_bits_[24 / 32] & 4278190080u) {
// optional .opencv_caffe.DummyDataParameter dummy_data_param = 109;
if (has_dummy_data_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->dummy_data_param_);
}
// optional .opencv_caffe.EltwiseParameter eltwise_param = 110;
if (has_eltwise_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->eltwise_param_);
}
// optional .opencv_caffe.ELUParameter elu_param = 140;
if (has_elu_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->elu_param_);
}
// optional .opencv_caffe.EmbedParameter embed_param = 137;
if (has_embed_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->embed_param_);
}
// optional .opencv_caffe.ExpParameter exp_param = 111;
if (has_exp_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->exp_param_);
}
// optional .opencv_caffe.FlattenParameter flatten_param = 135;
if (has_flatten_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->flatten_param_);
}
// optional .opencv_caffe.HDF5DataParameter hdf5_data_param = 112;
if (has_hdf5_data_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->hdf5_data_param_);
}
// optional .opencv_caffe.HDF5OutputParameter hdf5_output_param = 113;
if (has_hdf5_output_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->hdf5_output_param_);
}
}
if (_has_bits_[32 / 32] & 255u) {
// optional .opencv_caffe.HingeLossParameter hinge_loss_param = 114;
if (has_hinge_loss_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->hinge_loss_param_);
}
// optional .opencv_caffe.ImageDataParameter image_data_param = 115;
if (has_image_data_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->image_data_param_);
}
// optional .opencv_caffe.InfogainLossParameter infogain_loss_param = 116;
if (has_infogain_loss_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->infogain_loss_param_);
}
// optional .opencv_caffe.InnerProductParameter inner_product_param = 117;
if (has_inner_product_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->inner_product_param_);
}
// optional .opencv_caffe.InputParameter input_param = 143;
if (has_input_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->input_param_);
}
// optional .opencv_caffe.LogParameter log_param = 134;
if (has_log_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->log_param_);
}
// optional .opencv_caffe.LRNParameter lrn_param = 118;
if (has_lrn_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->lrn_param_);
}
// optional .opencv_caffe.MemoryDataParameter memory_data_param = 119;
if (has_memory_data_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->memory_data_param_);
}
}
if (_has_bits_[40 / 32] & 65280u) {
// optional .opencv_caffe.MVNParameter mvn_param = 120;
if (has_mvn_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->mvn_param_);
}
// optional .opencv_caffe.NormalizeBBoxParameter norm_param = 149;
if (has_norm_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->norm_param_);
}
// optional .opencv_caffe.PermuteParameter permute_param = 148;
if (has_permute_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->permute_param_);
}
// optional .opencv_caffe.ParameterParameter parameter_param = 145;
if (has_parameter_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->parameter_param_);
}
// optional .opencv_caffe.PoolingParameter pooling_param = 121;
if (has_pooling_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->pooling_param_);
}
// optional .opencv_caffe.PowerParameter power_param = 122;
if (has_power_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->power_param_);
}
// optional .opencv_caffe.PReLUParameter prelu_param = 131;
if (has_prelu_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->prelu_param_);
}
// optional .opencv_caffe.PriorBoxParameter prior_box_param = 150;
if (has_prior_box_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->prior_box_param_);
}
}
if (_has_bits_[48 / 32] & 16711680u) {
// optional .opencv_caffe.ProposalParameter proposal_param = 201;
if (has_proposal_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->proposal_param_);
}
// optional .opencv_caffe.PSROIPoolingParameter psroi_pooling_param = 10001;
if (has_psroi_pooling_param()) {
total_size += 3 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->psroi_pooling_param_);
}
// optional .opencv_caffe.PythonParameter python_param = 130;
if (has_python_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->python_param_);
}
// optional .opencv_caffe.RecurrentParameter recurrent_param = 146;
if (has_recurrent_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->recurrent_param_);
}
// optional .opencv_caffe.ReductionParameter reduction_param = 136;
if (has_reduction_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->reduction_param_);
}
// optional .opencv_caffe.ReLUParameter relu_param = 123;
if (has_relu_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->relu_param_);
}
// optional .opencv_caffe.ReshapeParameter reshape_param = 133;
if (has_reshape_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->reshape_param_);
}
// optional .opencv_caffe.ROIPoolingParameter roi_pooling_param = 8266711;
if (has_roi_pooling_param()) {
total_size += 4 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->roi_pooling_param_);
}
}
if (_has_bits_[56 / 32] & 4278190080u) {
// optional .opencv_caffe.ScaleParameter scale_param = 142;
if (has_scale_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->scale_param_);
}
// optional .opencv_caffe.SigmoidParameter sigmoid_param = 124;
if (has_sigmoid_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->sigmoid_param_);
}
// optional .opencv_caffe.SoftmaxParameter softmax_param = 125;
if (has_softmax_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->softmax_param_);
}
// optional .opencv_caffe.SPPParameter spp_param = 132;
if (has_spp_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->spp_param_);
}
// optional .opencv_caffe.SliceParameter slice_param = 126;
if (has_slice_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->slice_param_);
}
// optional .opencv_caffe.TanHParameter tanh_param = 127;
if (has_tanh_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->tanh_param_);
}
// optional .opencv_caffe.ThresholdParameter threshold_param = 128;
if (has_threshold_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->threshold_param_);
}
// optional .opencv_caffe.TileParameter tile_param = 138;
if (has_tile_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->tile_param_);
}
}
// optional .opencv_caffe.WindowDataParameter window_data_param = 129;
if (has_window_data_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->window_data_param_);
}
// repeated string bottom = 3;
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->bottom_size());
for (int i = 0; i < this->bottom_size(); i++) {
total_size += ::google::protobuf::internal::WireFormatLite::StringSize(
this->bottom(i));
}
// repeated string top = 4;
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->top_size());
for (int i = 0; i < this->top_size(); i++) {
total_size += ::google::protobuf::internal::WireFormatLite::StringSize(
this->top(i));
}
// repeated float loss_weight = 5;
{
size_t data_size = 0;
unsigned int count = this->loss_weight_size();
data_size = 4UL * count;
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->loss_weight_size());
total_size += data_size;
}
// repeated .opencv_caffe.ParamSpec param = 6;
{
unsigned int count = this->param_size();
total_size += 1UL * count;
for (unsigned int i = 0; i < count; i++) {
total_size +=
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
this->param(i));
}
}
// repeated .opencv_caffe.BlobProto blobs = 7;
{
unsigned int count = this->blobs_size();
total_size += 1UL * count;
for (unsigned int i = 0; i < count; i++) {
total_size +=
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
this->blobs(i));
}
}
// repeated bool propagate_down = 11;
{
size_t data_size = 0;
unsigned int count = this->propagate_down_size();
data_size = 1UL * count;
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->propagate_down_size());
total_size += data_size;
}
// repeated .opencv_caffe.NetStateRule include = 8;
{
unsigned int count = this->include_size();
total_size += 1UL * count;
for (unsigned int i = 0; i < count; i++) {
total_size +=
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
this->include(i));
}
}
// repeated .opencv_caffe.NetStateRule exclude = 9;
{
unsigned int count = this->exclude_size();
total_size += 1UL * count;
for (unsigned int i = 0; i < count; i++) {
total_size +=
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
this->exclude(i));
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void LayerParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.LayerParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const LayerParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const LayerParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.LayerParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.LayerParameter)
UnsafeMergeFrom(*source);
}
}
void LayerParameter::MergeFrom(const LayerParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.LayerParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void LayerParameter::UnsafeMergeFrom(const LayerParameter& from) {
GOOGLE_DCHECK(&from != this);
bottom_.UnsafeMergeFrom(from.bottom_);
top_.UnsafeMergeFrom(from.top_);
loss_weight_.UnsafeMergeFrom(from.loss_weight_);
param_.MergeFrom(from.param_);
blobs_.MergeFrom(from.blobs_);
propagate_down_.UnsafeMergeFrom(from.propagate_down_);
include_.MergeFrom(from.include_);
exclude_.MergeFrom(from.exclude_);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_name()) {
set_has_name();
name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.name_);
}
if (from.has_type()) {
set_has_type();
type_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.type_);
}
if (from.has_phase()) {
set_phase(from.phase());
}
}
if (from._has_bits_[11 / 32] & (0xffu << (11 % 32))) {
if (from.has_transform_param()) {
mutable_transform_param()->::opencv_caffe::TransformationParameter::MergeFrom(from.transform_param());
}
if (from.has_loss_param()) {
mutable_loss_param()->::opencv_caffe::LossParameter::MergeFrom(from.loss_param());
}
if (from.has_accuracy_param()) {
mutable_accuracy_param()->::opencv_caffe::AccuracyParameter::MergeFrom(from.accuracy_param());
}
if (from.has_argmax_param()) {
mutable_argmax_param()->::opencv_caffe::ArgMaxParameter::MergeFrom(from.argmax_param());
}
if (from.has_batch_norm_param()) {
mutable_batch_norm_param()->::opencv_caffe::BatchNormParameter::MergeFrom(from.batch_norm_param());
}
}
if (from._has_bits_[16 / 32] & (0xffu << (16 % 32))) {
if (from.has_bias_param()) {
mutable_bias_param()->::opencv_caffe::BiasParameter::MergeFrom(from.bias_param());
}
if (from.has_concat_param()) {
mutable_concat_param()->::opencv_caffe::ConcatParameter::MergeFrom(from.concat_param());
}
if (from.has_contrastive_loss_param()) {
mutable_contrastive_loss_param()->::opencv_caffe::ContrastiveLossParameter::MergeFrom(from.contrastive_loss_param());
}
if (from.has_convolution_param()) {
mutable_convolution_param()->::opencv_caffe::ConvolutionParameter::MergeFrom(from.convolution_param());
}
if (from.has_crop_param()) {
mutable_crop_param()->::opencv_caffe::CropParameter::MergeFrom(from.crop_param());
}
if (from.has_data_param()) {
mutable_data_param()->::opencv_caffe::DataParameter::MergeFrom(from.data_param());
}
if (from.has_detection_output_param()) {
mutable_detection_output_param()->::opencv_caffe::DetectionOutputParameter::MergeFrom(from.detection_output_param());
}
if (from.has_dropout_param()) {
mutable_dropout_param()->::opencv_caffe::DropoutParameter::MergeFrom(from.dropout_param());
}
}
if (from._has_bits_[24 / 32] & (0xffu << (24 % 32))) {
if (from.has_dummy_data_param()) {
mutable_dummy_data_param()->::opencv_caffe::DummyDataParameter::MergeFrom(from.dummy_data_param());
}
if (from.has_eltwise_param()) {
mutable_eltwise_param()->::opencv_caffe::EltwiseParameter::MergeFrom(from.eltwise_param());
}
if (from.has_elu_param()) {
mutable_elu_param()->::opencv_caffe::ELUParameter::MergeFrom(from.elu_param());
}
if (from.has_embed_param()) {
mutable_embed_param()->::opencv_caffe::EmbedParameter::MergeFrom(from.embed_param());
}
if (from.has_exp_param()) {
mutable_exp_param()->::opencv_caffe::ExpParameter::MergeFrom(from.exp_param());
}
if (from.has_flatten_param()) {
mutable_flatten_param()->::opencv_caffe::FlattenParameter::MergeFrom(from.flatten_param());
}
if (from.has_hdf5_data_param()) {
mutable_hdf5_data_param()->::opencv_caffe::HDF5DataParameter::MergeFrom(from.hdf5_data_param());
}
if (from.has_hdf5_output_param()) {
mutable_hdf5_output_param()->::opencv_caffe::HDF5OutputParameter::MergeFrom(from.hdf5_output_param());
}
}
if (from._has_bits_[32 / 32] & (0xffu << (32 % 32))) {
if (from.has_hinge_loss_param()) {
mutable_hinge_loss_param()->::opencv_caffe::HingeLossParameter::MergeFrom(from.hinge_loss_param());
}
if (from.has_image_data_param()) {
mutable_image_data_param()->::opencv_caffe::ImageDataParameter::MergeFrom(from.image_data_param());
}
if (from.has_infogain_loss_param()) {
mutable_infogain_loss_param()->::opencv_caffe::InfogainLossParameter::MergeFrom(from.infogain_loss_param());
}
if (from.has_inner_product_param()) {
mutable_inner_product_param()->::opencv_caffe::InnerProductParameter::MergeFrom(from.inner_product_param());
}
if (from.has_input_param()) {
mutable_input_param()->::opencv_caffe::InputParameter::MergeFrom(from.input_param());
}
if (from.has_log_param()) {
mutable_log_param()->::opencv_caffe::LogParameter::MergeFrom(from.log_param());
}
if (from.has_lrn_param()) {
mutable_lrn_param()->::opencv_caffe::LRNParameter::MergeFrom(from.lrn_param());
}
if (from.has_memory_data_param()) {
mutable_memory_data_param()->::opencv_caffe::MemoryDataParameter::MergeFrom(from.memory_data_param());
}
}
if (from._has_bits_[40 / 32] & (0xffu << (40 % 32))) {
if (from.has_mvn_param()) {
mutable_mvn_param()->::opencv_caffe::MVNParameter::MergeFrom(from.mvn_param());
}
if (from.has_norm_param()) {
mutable_norm_param()->::opencv_caffe::NormalizeBBoxParameter::MergeFrom(from.norm_param());
}
if (from.has_permute_param()) {
mutable_permute_param()->::opencv_caffe::PermuteParameter::MergeFrom(from.permute_param());
}
if (from.has_parameter_param()) {
mutable_parameter_param()->::opencv_caffe::ParameterParameter::MergeFrom(from.parameter_param());
}
if (from.has_pooling_param()) {
mutable_pooling_param()->::opencv_caffe::PoolingParameter::MergeFrom(from.pooling_param());
}
if (from.has_power_param()) {
mutable_power_param()->::opencv_caffe::PowerParameter::MergeFrom(from.power_param());
}
if (from.has_prelu_param()) {
mutable_prelu_param()->::opencv_caffe::PReLUParameter::MergeFrom(from.prelu_param());
}
if (from.has_prior_box_param()) {
mutable_prior_box_param()->::opencv_caffe::PriorBoxParameter::MergeFrom(from.prior_box_param());
}
}
if (from._has_bits_[48 / 32] & (0xffu << (48 % 32))) {
if (from.has_proposal_param()) {
mutable_proposal_param()->::opencv_caffe::ProposalParameter::MergeFrom(from.proposal_param());
}
if (from.has_psroi_pooling_param()) {
mutable_psroi_pooling_param()->::opencv_caffe::PSROIPoolingParameter::MergeFrom(from.psroi_pooling_param());
}
if (from.has_python_param()) {
mutable_python_param()->::opencv_caffe::PythonParameter::MergeFrom(from.python_param());
}
if (from.has_recurrent_param()) {
mutable_recurrent_param()->::opencv_caffe::RecurrentParameter::MergeFrom(from.recurrent_param());
}
if (from.has_reduction_param()) {
mutable_reduction_param()->::opencv_caffe::ReductionParameter::MergeFrom(from.reduction_param());
}
if (from.has_relu_param()) {
mutable_relu_param()->::opencv_caffe::ReLUParameter::MergeFrom(from.relu_param());
}
if (from.has_reshape_param()) {
mutable_reshape_param()->::opencv_caffe::ReshapeParameter::MergeFrom(from.reshape_param());
}
if (from.has_roi_pooling_param()) {
mutable_roi_pooling_param()->::opencv_caffe::ROIPoolingParameter::MergeFrom(from.roi_pooling_param());
}
}
if (from._has_bits_[56 / 32] & (0xffu << (56 % 32))) {
if (from.has_scale_param()) {
mutable_scale_param()->::opencv_caffe::ScaleParameter::MergeFrom(from.scale_param());
}
if (from.has_sigmoid_param()) {
mutable_sigmoid_param()->::opencv_caffe::SigmoidParameter::MergeFrom(from.sigmoid_param());
}
if (from.has_softmax_param()) {
mutable_softmax_param()->::opencv_caffe::SoftmaxParameter::MergeFrom(from.softmax_param());
}
if (from.has_spp_param()) {
mutable_spp_param()->::opencv_caffe::SPPParameter::MergeFrom(from.spp_param());
}
if (from.has_slice_param()) {
mutable_slice_param()->::opencv_caffe::SliceParameter::MergeFrom(from.slice_param());
}
if (from.has_tanh_param()) {
mutable_tanh_param()->::opencv_caffe::TanHParameter::MergeFrom(from.tanh_param());
}
if (from.has_threshold_param()) {
mutable_threshold_param()->::opencv_caffe::ThresholdParameter::MergeFrom(from.threshold_param());
}
if (from.has_tile_param()) {
mutable_tile_param()->::opencv_caffe::TileParameter::MergeFrom(from.tile_param());
}
}
if (from._has_bits_[64 / 32] & (0xffu << (64 % 32))) {
if (from.has_window_data_param()) {
mutable_window_data_param()->::opencv_caffe::WindowDataParameter::MergeFrom(from.window_data_param());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void LayerParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.LayerParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void LayerParameter::CopyFrom(const LayerParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.LayerParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool LayerParameter::IsInitialized() const {
if (has_psroi_pooling_param()) {
if (!this->psroi_pooling_param_->IsInitialized()) return false;
}
return true;
}
void LayerParameter::Swap(LayerParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void LayerParameter::InternalSwap(LayerParameter* other) {
name_.Swap(&other->name_);
type_.Swap(&other->type_);
bottom_.UnsafeArenaSwap(&other->bottom_);
top_.UnsafeArenaSwap(&other->top_);
std::swap(phase_, other->phase_);
loss_weight_.UnsafeArenaSwap(&other->loss_weight_);
param_.UnsafeArenaSwap(&other->param_);
blobs_.UnsafeArenaSwap(&other->blobs_);
propagate_down_.UnsafeArenaSwap(&other->propagate_down_);
include_.UnsafeArenaSwap(&other->include_);
exclude_.UnsafeArenaSwap(&other->exclude_);
std::swap(transform_param_, other->transform_param_);
std::swap(loss_param_, other->loss_param_);
std::swap(accuracy_param_, other->accuracy_param_);
std::swap(argmax_param_, other->argmax_param_);
std::swap(batch_norm_param_, other->batch_norm_param_);
std::swap(bias_param_, other->bias_param_);
std::swap(concat_param_, other->concat_param_);
std::swap(contrastive_loss_param_, other->contrastive_loss_param_);
std::swap(convolution_param_, other->convolution_param_);
std::swap(crop_param_, other->crop_param_);
std::swap(data_param_, other->data_param_);
std::swap(detection_output_param_, other->detection_output_param_);
std::swap(dropout_param_, other->dropout_param_);
std::swap(dummy_data_param_, other->dummy_data_param_);
std::swap(eltwise_param_, other->eltwise_param_);
std::swap(elu_param_, other->elu_param_);
std::swap(embed_param_, other->embed_param_);
std::swap(exp_param_, other->exp_param_);
std::swap(flatten_param_, other->flatten_param_);
std::swap(hdf5_data_param_, other->hdf5_data_param_);
std::swap(hdf5_output_param_, other->hdf5_output_param_);
std::swap(hinge_loss_param_, other->hinge_loss_param_);
std::swap(image_data_param_, other->image_data_param_);
std::swap(infogain_loss_param_, other->infogain_loss_param_);
std::swap(inner_product_param_, other->inner_product_param_);
std::swap(input_param_, other->input_param_);
std::swap(log_param_, other->log_param_);
std::swap(lrn_param_, other->lrn_param_);
std::swap(memory_data_param_, other->memory_data_param_);
std::swap(mvn_param_, other->mvn_param_);
std::swap(norm_param_, other->norm_param_);
std::swap(permute_param_, other->permute_param_);
std::swap(parameter_param_, other->parameter_param_);
std::swap(pooling_param_, other->pooling_param_);
std::swap(power_param_, other->power_param_);
std::swap(prelu_param_, other->prelu_param_);
std::swap(prior_box_param_, other->prior_box_param_);
std::swap(proposal_param_, other->proposal_param_);
std::swap(psroi_pooling_param_, other->psroi_pooling_param_);
std::swap(python_param_, other->python_param_);
std::swap(recurrent_param_, other->recurrent_param_);
std::swap(reduction_param_, other->reduction_param_);
std::swap(relu_param_, other->relu_param_);
std::swap(reshape_param_, other->reshape_param_);
std::swap(roi_pooling_param_, other->roi_pooling_param_);
std::swap(scale_param_, other->scale_param_);
std::swap(sigmoid_param_, other->sigmoid_param_);
std::swap(softmax_param_, other->softmax_param_);
std::swap(spp_param_, other->spp_param_);
std::swap(slice_param_, other->slice_param_);
std::swap(tanh_param_, other->tanh_param_);
std::swap(threshold_param_, other->threshold_param_);
std::swap(tile_param_, other->tile_param_);
std::swap(window_data_param_, other->window_data_param_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
std::swap(_has_bits_[1], other->_has_bits_[1]);
std::swap(_has_bits_[2], other->_has_bits_[2]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata LayerParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = LayerParameter_descriptor_;
metadata.reflection = LayerParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// LayerParameter
// optional string name = 1;
bool LayerParameter::has_name() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void LayerParameter::set_has_name() {
_has_bits_[0] |= 0x00000001u;
}
void LayerParameter::clear_has_name() {
_has_bits_[0] &= ~0x00000001u;
}
void LayerParameter::clear_name() {
name_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_name();
}
const ::std::string& LayerParameter::name() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.name)
return name_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void LayerParameter::set_name(const ::std::string& value) {
set_has_name();
name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.LayerParameter.name)
}
void LayerParameter::set_name(const char* value) {
set_has_name();
name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.LayerParameter.name)
}
void LayerParameter::set_name(const char* value, size_t size) {
set_has_name();
name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.LayerParameter.name)
}
::std::string* LayerParameter::mutable_name() {
set_has_name();
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.name)
return name_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* LayerParameter::release_name() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.name)
clear_has_name();
return name_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void LayerParameter::set_allocated_name(::std::string* name) {
if (name != NULL) {
set_has_name();
} else {
clear_has_name();
}
name_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), name);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.name)
}
// optional string type = 2;
bool LayerParameter::has_type() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void LayerParameter::set_has_type() {
_has_bits_[0] |= 0x00000002u;
}
void LayerParameter::clear_has_type() {
_has_bits_[0] &= ~0x00000002u;
}
void LayerParameter::clear_type() {
type_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_type();
}
const ::std::string& LayerParameter::type() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.type)
return type_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void LayerParameter::set_type(const ::std::string& value) {
set_has_type();
type_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.LayerParameter.type)
}
void LayerParameter::set_type(const char* value) {
set_has_type();
type_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.LayerParameter.type)
}
void LayerParameter::set_type(const char* value, size_t size) {
set_has_type();
type_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.LayerParameter.type)
}
::std::string* LayerParameter::mutable_type() {
set_has_type();
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.type)
return type_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* LayerParameter::release_type() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.type)
clear_has_type();
return type_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void LayerParameter::set_allocated_type(::std::string* type) {
if (type != NULL) {
set_has_type();
} else {
clear_has_type();
}
type_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), type);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.type)
}
// repeated string bottom = 3;
int LayerParameter::bottom_size() const {
return bottom_.size();
}
void LayerParameter::clear_bottom() {
bottom_.Clear();
}
const ::std::string& LayerParameter::bottom(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.bottom)
return bottom_.Get(index);
}
::std::string* LayerParameter::mutable_bottom(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.bottom)
return bottom_.Mutable(index);
}
void LayerParameter::set_bottom(int index, const ::std::string& value) {
// @@protoc_insertion_point(field_set:opencv_caffe.LayerParameter.bottom)
bottom_.Mutable(index)->assign(value);
}
void LayerParameter::set_bottom(int index, const char* value) {
bottom_.Mutable(index)->assign(value);
// @@protoc_insertion_point(field_set_char:opencv_caffe.LayerParameter.bottom)
}
void LayerParameter::set_bottom(int index, const char* value, size_t size) {
bottom_.Mutable(index)->assign(
reinterpret_cast<const char*>(value), size);
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.LayerParameter.bottom)
}
::std::string* LayerParameter::add_bottom() {
// @@protoc_insertion_point(field_add_mutable:opencv_caffe.LayerParameter.bottom)
return bottom_.Add();
}
void LayerParameter::add_bottom(const ::std::string& value) {
bottom_.Add()->assign(value);
// @@protoc_insertion_point(field_add:opencv_caffe.LayerParameter.bottom)
}
void LayerParameter::add_bottom(const char* value) {
bottom_.Add()->assign(value);
// @@protoc_insertion_point(field_add_char:opencv_caffe.LayerParameter.bottom)
}
void LayerParameter::add_bottom(const char* value, size_t size) {
bottom_.Add()->assign(reinterpret_cast<const char*>(value), size);
// @@protoc_insertion_point(field_add_pointer:opencv_caffe.LayerParameter.bottom)
}
const ::google::protobuf::RepeatedPtrField< ::std::string>&
LayerParameter::bottom() const {
// @@protoc_insertion_point(field_list:opencv_caffe.LayerParameter.bottom)
return bottom_;
}
::google::protobuf::RepeatedPtrField< ::std::string>*
LayerParameter::mutable_bottom() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.LayerParameter.bottom)
return &bottom_;
}
// repeated string top = 4;
int LayerParameter::top_size() const {
return top_.size();
}
void LayerParameter::clear_top() {
top_.Clear();
}
const ::std::string& LayerParameter::top(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.top)
return top_.Get(index);
}
::std::string* LayerParameter::mutable_top(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.top)
return top_.Mutable(index);
}
void LayerParameter::set_top(int index, const ::std::string& value) {
// @@protoc_insertion_point(field_set:opencv_caffe.LayerParameter.top)
top_.Mutable(index)->assign(value);
}
void LayerParameter::set_top(int index, const char* value) {
top_.Mutable(index)->assign(value);
// @@protoc_insertion_point(field_set_char:opencv_caffe.LayerParameter.top)
}
void LayerParameter::set_top(int index, const char* value, size_t size) {
top_.Mutable(index)->assign(
reinterpret_cast<const char*>(value), size);
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.LayerParameter.top)
}
::std::string* LayerParameter::add_top() {
// @@protoc_insertion_point(field_add_mutable:opencv_caffe.LayerParameter.top)
return top_.Add();
}
void LayerParameter::add_top(const ::std::string& value) {
top_.Add()->assign(value);
// @@protoc_insertion_point(field_add:opencv_caffe.LayerParameter.top)
}
void LayerParameter::add_top(const char* value) {
top_.Add()->assign(value);
// @@protoc_insertion_point(field_add_char:opencv_caffe.LayerParameter.top)
}
void LayerParameter::add_top(const char* value, size_t size) {
top_.Add()->assign(reinterpret_cast<const char*>(value), size);
// @@protoc_insertion_point(field_add_pointer:opencv_caffe.LayerParameter.top)
}
const ::google::protobuf::RepeatedPtrField< ::std::string>&
LayerParameter::top() const {
// @@protoc_insertion_point(field_list:opencv_caffe.LayerParameter.top)
return top_;
}
::google::protobuf::RepeatedPtrField< ::std::string>*
LayerParameter::mutable_top() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.LayerParameter.top)
return &top_;
}
// optional .opencv_caffe.Phase phase = 10;
bool LayerParameter::has_phase() const {
return (_has_bits_[0] & 0x00000010u) != 0;
}
void LayerParameter::set_has_phase() {
_has_bits_[0] |= 0x00000010u;
}
void LayerParameter::clear_has_phase() {
_has_bits_[0] &= ~0x00000010u;
}
void LayerParameter::clear_phase() {
phase_ = 0;
clear_has_phase();
}
::opencv_caffe::Phase LayerParameter::phase() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.phase)
return static_cast< ::opencv_caffe::Phase >(phase_);
}
void LayerParameter::set_phase(::opencv_caffe::Phase value) {
assert(::opencv_caffe::Phase_IsValid(value));
set_has_phase();
phase_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.LayerParameter.phase)
}
// repeated float loss_weight = 5;
int LayerParameter::loss_weight_size() const {
return loss_weight_.size();
}
void LayerParameter::clear_loss_weight() {
loss_weight_.Clear();
}
float LayerParameter::loss_weight(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.loss_weight)
return loss_weight_.Get(index);
}
void LayerParameter::set_loss_weight(int index, float value) {
loss_weight_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.LayerParameter.loss_weight)
}
void LayerParameter::add_loss_weight(float value) {
loss_weight_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.LayerParameter.loss_weight)
}
const ::google::protobuf::RepeatedField< float >&
LayerParameter::loss_weight() const {
// @@protoc_insertion_point(field_list:opencv_caffe.LayerParameter.loss_weight)
return loss_weight_;
}
::google::protobuf::RepeatedField< float >*
LayerParameter::mutable_loss_weight() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.LayerParameter.loss_weight)
return &loss_weight_;
}
// repeated .opencv_caffe.ParamSpec param = 6;
int LayerParameter::param_size() const {
return param_.size();
}
void LayerParameter::clear_param() {
param_.Clear();
}
const ::opencv_caffe::ParamSpec& LayerParameter::param(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.param)
return param_.Get(index);
}
::opencv_caffe::ParamSpec* LayerParameter::mutable_param(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.param)
return param_.Mutable(index);
}
::opencv_caffe::ParamSpec* LayerParameter::add_param() {
// @@protoc_insertion_point(field_add:opencv_caffe.LayerParameter.param)
return param_.Add();
}
::google::protobuf::RepeatedPtrField< ::opencv_caffe::ParamSpec >*
LayerParameter::mutable_param() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.LayerParameter.param)
return &param_;
}
const ::google::protobuf::RepeatedPtrField< ::opencv_caffe::ParamSpec >&
LayerParameter::param() const {
// @@protoc_insertion_point(field_list:opencv_caffe.LayerParameter.param)
return param_;
}
// repeated .opencv_caffe.BlobProto blobs = 7;
int LayerParameter::blobs_size() const {
return blobs_.size();
}
void LayerParameter::clear_blobs() {
blobs_.Clear();
}
const ::opencv_caffe::BlobProto& LayerParameter::blobs(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.blobs)
return blobs_.Get(index);
}
::opencv_caffe::BlobProto* LayerParameter::mutable_blobs(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.blobs)
return blobs_.Mutable(index);
}
::opencv_caffe::BlobProto* LayerParameter::add_blobs() {
// @@protoc_insertion_point(field_add:opencv_caffe.LayerParameter.blobs)
return blobs_.Add();
}
::google::protobuf::RepeatedPtrField< ::opencv_caffe::BlobProto >*
LayerParameter::mutable_blobs() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.LayerParameter.blobs)
return &blobs_;
}
const ::google::protobuf::RepeatedPtrField< ::opencv_caffe::BlobProto >&
LayerParameter::blobs() const {
// @@protoc_insertion_point(field_list:opencv_caffe.LayerParameter.blobs)
return blobs_;
}
// repeated bool propagate_down = 11;
int LayerParameter::propagate_down_size() const {
return propagate_down_.size();
}
void LayerParameter::clear_propagate_down() {
propagate_down_.Clear();
}
bool LayerParameter::propagate_down(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.propagate_down)
return propagate_down_.Get(index);
}
void LayerParameter::set_propagate_down(int index, bool value) {
propagate_down_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.LayerParameter.propagate_down)
}
void LayerParameter::add_propagate_down(bool value) {
propagate_down_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.LayerParameter.propagate_down)
}
const ::google::protobuf::RepeatedField< bool >&
LayerParameter::propagate_down() const {
// @@protoc_insertion_point(field_list:opencv_caffe.LayerParameter.propagate_down)
return propagate_down_;
}
::google::protobuf::RepeatedField< bool >*
LayerParameter::mutable_propagate_down() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.LayerParameter.propagate_down)
return &propagate_down_;
}
// repeated .opencv_caffe.NetStateRule include = 8;
int LayerParameter::include_size() const {
return include_.size();
}
void LayerParameter::clear_include() {
include_.Clear();
}
const ::opencv_caffe::NetStateRule& LayerParameter::include(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.include)
return include_.Get(index);
}
::opencv_caffe::NetStateRule* LayerParameter::mutable_include(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.include)
return include_.Mutable(index);
}
::opencv_caffe::NetStateRule* LayerParameter::add_include() {
// @@protoc_insertion_point(field_add:opencv_caffe.LayerParameter.include)
return include_.Add();
}
::google::protobuf::RepeatedPtrField< ::opencv_caffe::NetStateRule >*
LayerParameter::mutable_include() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.LayerParameter.include)
return &include_;
}
const ::google::protobuf::RepeatedPtrField< ::opencv_caffe::NetStateRule >&
LayerParameter::include() const {
// @@protoc_insertion_point(field_list:opencv_caffe.LayerParameter.include)
return include_;
}
// repeated .opencv_caffe.NetStateRule exclude = 9;
int LayerParameter::exclude_size() const {
return exclude_.size();
}
void LayerParameter::clear_exclude() {
exclude_.Clear();
}
const ::opencv_caffe::NetStateRule& LayerParameter::exclude(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.exclude)
return exclude_.Get(index);
}
::opencv_caffe::NetStateRule* LayerParameter::mutable_exclude(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.exclude)
return exclude_.Mutable(index);
}
::opencv_caffe::NetStateRule* LayerParameter::add_exclude() {
// @@protoc_insertion_point(field_add:opencv_caffe.LayerParameter.exclude)
return exclude_.Add();
}
::google::protobuf::RepeatedPtrField< ::opencv_caffe::NetStateRule >*
LayerParameter::mutable_exclude() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.LayerParameter.exclude)
return &exclude_;
}
const ::google::protobuf::RepeatedPtrField< ::opencv_caffe::NetStateRule >&
LayerParameter::exclude() const {
// @@protoc_insertion_point(field_list:opencv_caffe.LayerParameter.exclude)
return exclude_;
}
// optional .opencv_caffe.TransformationParameter transform_param = 100;
bool LayerParameter::has_transform_param() const {
return (_has_bits_[0] & 0x00000800u) != 0;
}
void LayerParameter::set_has_transform_param() {
_has_bits_[0] |= 0x00000800u;
}
void LayerParameter::clear_has_transform_param() {
_has_bits_[0] &= ~0x00000800u;
}
void LayerParameter::clear_transform_param() {
if (transform_param_ != NULL) transform_param_->::opencv_caffe::TransformationParameter::Clear();
clear_has_transform_param();
}
const ::opencv_caffe::TransformationParameter& LayerParameter::transform_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.transform_param)
return transform_param_ != NULL ? *transform_param_
: *::opencv_caffe::TransformationParameter::internal_default_instance();
}
::opencv_caffe::TransformationParameter* LayerParameter::mutable_transform_param() {
set_has_transform_param();
if (transform_param_ == NULL) {
transform_param_ = new ::opencv_caffe::TransformationParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.transform_param)
return transform_param_;
}
::opencv_caffe::TransformationParameter* LayerParameter::release_transform_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.transform_param)
clear_has_transform_param();
::opencv_caffe::TransformationParameter* temp = transform_param_;
transform_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_transform_param(::opencv_caffe::TransformationParameter* transform_param) {
delete transform_param_;
transform_param_ = transform_param;
if (transform_param) {
set_has_transform_param();
} else {
clear_has_transform_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.transform_param)
}
// optional .opencv_caffe.LossParameter loss_param = 101;
bool LayerParameter::has_loss_param() const {
return (_has_bits_[0] & 0x00001000u) != 0;
}
void LayerParameter::set_has_loss_param() {
_has_bits_[0] |= 0x00001000u;
}
void LayerParameter::clear_has_loss_param() {
_has_bits_[0] &= ~0x00001000u;
}
void LayerParameter::clear_loss_param() {
if (loss_param_ != NULL) loss_param_->::opencv_caffe::LossParameter::Clear();
clear_has_loss_param();
}
const ::opencv_caffe::LossParameter& LayerParameter::loss_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.loss_param)
return loss_param_ != NULL ? *loss_param_
: *::opencv_caffe::LossParameter::internal_default_instance();
}
::opencv_caffe::LossParameter* LayerParameter::mutable_loss_param() {
set_has_loss_param();
if (loss_param_ == NULL) {
loss_param_ = new ::opencv_caffe::LossParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.loss_param)
return loss_param_;
}
::opencv_caffe::LossParameter* LayerParameter::release_loss_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.loss_param)
clear_has_loss_param();
::opencv_caffe::LossParameter* temp = loss_param_;
loss_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_loss_param(::opencv_caffe::LossParameter* loss_param) {
delete loss_param_;
loss_param_ = loss_param;
if (loss_param) {
set_has_loss_param();
} else {
clear_has_loss_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.loss_param)
}
// optional .opencv_caffe.AccuracyParameter accuracy_param = 102;
bool LayerParameter::has_accuracy_param() const {
return (_has_bits_[0] & 0x00002000u) != 0;
}
void LayerParameter::set_has_accuracy_param() {
_has_bits_[0] |= 0x00002000u;
}
void LayerParameter::clear_has_accuracy_param() {
_has_bits_[0] &= ~0x00002000u;
}
void LayerParameter::clear_accuracy_param() {
if (accuracy_param_ != NULL) accuracy_param_->::opencv_caffe::AccuracyParameter::Clear();
clear_has_accuracy_param();
}
const ::opencv_caffe::AccuracyParameter& LayerParameter::accuracy_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.accuracy_param)
return accuracy_param_ != NULL ? *accuracy_param_
: *::opencv_caffe::AccuracyParameter::internal_default_instance();
}
::opencv_caffe::AccuracyParameter* LayerParameter::mutable_accuracy_param() {
set_has_accuracy_param();
if (accuracy_param_ == NULL) {
accuracy_param_ = new ::opencv_caffe::AccuracyParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.accuracy_param)
return accuracy_param_;
}
::opencv_caffe::AccuracyParameter* LayerParameter::release_accuracy_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.accuracy_param)
clear_has_accuracy_param();
::opencv_caffe::AccuracyParameter* temp = accuracy_param_;
accuracy_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_accuracy_param(::opencv_caffe::AccuracyParameter* accuracy_param) {
delete accuracy_param_;
accuracy_param_ = accuracy_param;
if (accuracy_param) {
set_has_accuracy_param();
} else {
clear_has_accuracy_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.accuracy_param)
}
// optional .opencv_caffe.ArgMaxParameter argmax_param = 103;
bool LayerParameter::has_argmax_param() const {
return (_has_bits_[0] & 0x00004000u) != 0;
}
void LayerParameter::set_has_argmax_param() {
_has_bits_[0] |= 0x00004000u;
}
void LayerParameter::clear_has_argmax_param() {
_has_bits_[0] &= ~0x00004000u;
}
void LayerParameter::clear_argmax_param() {
if (argmax_param_ != NULL) argmax_param_->::opencv_caffe::ArgMaxParameter::Clear();
clear_has_argmax_param();
}
const ::opencv_caffe::ArgMaxParameter& LayerParameter::argmax_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.argmax_param)
return argmax_param_ != NULL ? *argmax_param_
: *::opencv_caffe::ArgMaxParameter::internal_default_instance();
}
::opencv_caffe::ArgMaxParameter* LayerParameter::mutable_argmax_param() {
set_has_argmax_param();
if (argmax_param_ == NULL) {
argmax_param_ = new ::opencv_caffe::ArgMaxParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.argmax_param)
return argmax_param_;
}
::opencv_caffe::ArgMaxParameter* LayerParameter::release_argmax_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.argmax_param)
clear_has_argmax_param();
::opencv_caffe::ArgMaxParameter* temp = argmax_param_;
argmax_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_argmax_param(::opencv_caffe::ArgMaxParameter* argmax_param) {
delete argmax_param_;
argmax_param_ = argmax_param;
if (argmax_param) {
set_has_argmax_param();
} else {
clear_has_argmax_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.argmax_param)
}
// optional .opencv_caffe.BatchNormParameter batch_norm_param = 139;
bool LayerParameter::has_batch_norm_param() const {
return (_has_bits_[0] & 0x00008000u) != 0;
}
void LayerParameter::set_has_batch_norm_param() {
_has_bits_[0] |= 0x00008000u;
}
void LayerParameter::clear_has_batch_norm_param() {
_has_bits_[0] &= ~0x00008000u;
}
void LayerParameter::clear_batch_norm_param() {
if (batch_norm_param_ != NULL) batch_norm_param_->::opencv_caffe::BatchNormParameter::Clear();
clear_has_batch_norm_param();
}
const ::opencv_caffe::BatchNormParameter& LayerParameter::batch_norm_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.batch_norm_param)
return batch_norm_param_ != NULL ? *batch_norm_param_
: *::opencv_caffe::BatchNormParameter::internal_default_instance();
}
::opencv_caffe::BatchNormParameter* LayerParameter::mutable_batch_norm_param() {
set_has_batch_norm_param();
if (batch_norm_param_ == NULL) {
batch_norm_param_ = new ::opencv_caffe::BatchNormParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.batch_norm_param)
return batch_norm_param_;
}
::opencv_caffe::BatchNormParameter* LayerParameter::release_batch_norm_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.batch_norm_param)
clear_has_batch_norm_param();
::opencv_caffe::BatchNormParameter* temp = batch_norm_param_;
batch_norm_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_batch_norm_param(::opencv_caffe::BatchNormParameter* batch_norm_param) {
delete batch_norm_param_;
batch_norm_param_ = batch_norm_param;
if (batch_norm_param) {
set_has_batch_norm_param();
} else {
clear_has_batch_norm_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.batch_norm_param)
}
// optional .opencv_caffe.BiasParameter bias_param = 141;
bool LayerParameter::has_bias_param() const {
return (_has_bits_[0] & 0x00010000u) != 0;
}
void LayerParameter::set_has_bias_param() {
_has_bits_[0] |= 0x00010000u;
}
void LayerParameter::clear_has_bias_param() {
_has_bits_[0] &= ~0x00010000u;
}
void LayerParameter::clear_bias_param() {
if (bias_param_ != NULL) bias_param_->::opencv_caffe::BiasParameter::Clear();
clear_has_bias_param();
}
const ::opencv_caffe::BiasParameter& LayerParameter::bias_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.bias_param)
return bias_param_ != NULL ? *bias_param_
: *::opencv_caffe::BiasParameter::internal_default_instance();
}
::opencv_caffe::BiasParameter* LayerParameter::mutable_bias_param() {
set_has_bias_param();
if (bias_param_ == NULL) {
bias_param_ = new ::opencv_caffe::BiasParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.bias_param)
return bias_param_;
}
::opencv_caffe::BiasParameter* LayerParameter::release_bias_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.bias_param)
clear_has_bias_param();
::opencv_caffe::BiasParameter* temp = bias_param_;
bias_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_bias_param(::opencv_caffe::BiasParameter* bias_param) {
delete bias_param_;
bias_param_ = bias_param;
if (bias_param) {
set_has_bias_param();
} else {
clear_has_bias_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.bias_param)
}
// optional .opencv_caffe.ConcatParameter concat_param = 104;
bool LayerParameter::has_concat_param() const {
return (_has_bits_[0] & 0x00020000u) != 0;
}
void LayerParameter::set_has_concat_param() {
_has_bits_[0] |= 0x00020000u;
}
void LayerParameter::clear_has_concat_param() {
_has_bits_[0] &= ~0x00020000u;
}
void LayerParameter::clear_concat_param() {
if (concat_param_ != NULL) concat_param_->::opencv_caffe::ConcatParameter::Clear();
clear_has_concat_param();
}
const ::opencv_caffe::ConcatParameter& LayerParameter::concat_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.concat_param)
return concat_param_ != NULL ? *concat_param_
: *::opencv_caffe::ConcatParameter::internal_default_instance();
}
::opencv_caffe::ConcatParameter* LayerParameter::mutable_concat_param() {
set_has_concat_param();
if (concat_param_ == NULL) {
concat_param_ = new ::opencv_caffe::ConcatParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.concat_param)
return concat_param_;
}
::opencv_caffe::ConcatParameter* LayerParameter::release_concat_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.concat_param)
clear_has_concat_param();
::opencv_caffe::ConcatParameter* temp = concat_param_;
concat_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_concat_param(::opencv_caffe::ConcatParameter* concat_param) {
delete concat_param_;
concat_param_ = concat_param;
if (concat_param) {
set_has_concat_param();
} else {
clear_has_concat_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.concat_param)
}
// optional .opencv_caffe.ContrastiveLossParameter contrastive_loss_param = 105;
bool LayerParameter::has_contrastive_loss_param() const {
return (_has_bits_[0] & 0x00040000u) != 0;
}
void LayerParameter::set_has_contrastive_loss_param() {
_has_bits_[0] |= 0x00040000u;
}
void LayerParameter::clear_has_contrastive_loss_param() {
_has_bits_[0] &= ~0x00040000u;
}
void LayerParameter::clear_contrastive_loss_param() {
if (contrastive_loss_param_ != NULL) contrastive_loss_param_->::opencv_caffe::ContrastiveLossParameter::Clear();
clear_has_contrastive_loss_param();
}
const ::opencv_caffe::ContrastiveLossParameter& LayerParameter::contrastive_loss_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.contrastive_loss_param)
return contrastive_loss_param_ != NULL ? *contrastive_loss_param_
: *::opencv_caffe::ContrastiveLossParameter::internal_default_instance();
}
::opencv_caffe::ContrastiveLossParameter* LayerParameter::mutable_contrastive_loss_param() {
set_has_contrastive_loss_param();
if (contrastive_loss_param_ == NULL) {
contrastive_loss_param_ = new ::opencv_caffe::ContrastiveLossParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.contrastive_loss_param)
return contrastive_loss_param_;
}
::opencv_caffe::ContrastiveLossParameter* LayerParameter::release_contrastive_loss_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.contrastive_loss_param)
clear_has_contrastive_loss_param();
::opencv_caffe::ContrastiveLossParameter* temp = contrastive_loss_param_;
contrastive_loss_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_contrastive_loss_param(::opencv_caffe::ContrastiveLossParameter* contrastive_loss_param) {
delete contrastive_loss_param_;
contrastive_loss_param_ = contrastive_loss_param;
if (contrastive_loss_param) {
set_has_contrastive_loss_param();
} else {
clear_has_contrastive_loss_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.contrastive_loss_param)
}
// optional .opencv_caffe.ConvolutionParameter convolution_param = 106;
bool LayerParameter::has_convolution_param() const {
return (_has_bits_[0] & 0x00080000u) != 0;
}
void LayerParameter::set_has_convolution_param() {
_has_bits_[0] |= 0x00080000u;
}
void LayerParameter::clear_has_convolution_param() {
_has_bits_[0] &= ~0x00080000u;
}
void LayerParameter::clear_convolution_param() {
if (convolution_param_ != NULL) convolution_param_->::opencv_caffe::ConvolutionParameter::Clear();
clear_has_convolution_param();
}
const ::opencv_caffe::ConvolutionParameter& LayerParameter::convolution_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.convolution_param)
return convolution_param_ != NULL ? *convolution_param_
: *::opencv_caffe::ConvolutionParameter::internal_default_instance();
}
::opencv_caffe::ConvolutionParameter* LayerParameter::mutable_convolution_param() {
set_has_convolution_param();
if (convolution_param_ == NULL) {
convolution_param_ = new ::opencv_caffe::ConvolutionParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.convolution_param)
return convolution_param_;
}
::opencv_caffe::ConvolutionParameter* LayerParameter::release_convolution_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.convolution_param)
clear_has_convolution_param();
::opencv_caffe::ConvolutionParameter* temp = convolution_param_;
convolution_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_convolution_param(::opencv_caffe::ConvolutionParameter* convolution_param) {
delete convolution_param_;
convolution_param_ = convolution_param;
if (convolution_param) {
set_has_convolution_param();
} else {
clear_has_convolution_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.convolution_param)
}
// optional .opencv_caffe.CropParameter crop_param = 144;
bool LayerParameter::has_crop_param() const {
return (_has_bits_[0] & 0x00100000u) != 0;
}
void LayerParameter::set_has_crop_param() {
_has_bits_[0] |= 0x00100000u;
}
void LayerParameter::clear_has_crop_param() {
_has_bits_[0] &= ~0x00100000u;
}
void LayerParameter::clear_crop_param() {
if (crop_param_ != NULL) crop_param_->::opencv_caffe::CropParameter::Clear();
clear_has_crop_param();
}
const ::opencv_caffe::CropParameter& LayerParameter::crop_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.crop_param)
return crop_param_ != NULL ? *crop_param_
: *::opencv_caffe::CropParameter::internal_default_instance();
}
::opencv_caffe::CropParameter* LayerParameter::mutable_crop_param() {
set_has_crop_param();
if (crop_param_ == NULL) {
crop_param_ = new ::opencv_caffe::CropParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.crop_param)
return crop_param_;
}
::opencv_caffe::CropParameter* LayerParameter::release_crop_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.crop_param)
clear_has_crop_param();
::opencv_caffe::CropParameter* temp = crop_param_;
crop_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_crop_param(::opencv_caffe::CropParameter* crop_param) {
delete crop_param_;
crop_param_ = crop_param;
if (crop_param) {
set_has_crop_param();
} else {
clear_has_crop_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.crop_param)
}
// optional .opencv_caffe.DataParameter data_param = 107;
bool LayerParameter::has_data_param() const {
return (_has_bits_[0] & 0x00200000u) != 0;
}
void LayerParameter::set_has_data_param() {
_has_bits_[0] |= 0x00200000u;
}
void LayerParameter::clear_has_data_param() {
_has_bits_[0] &= ~0x00200000u;
}
void LayerParameter::clear_data_param() {
if (data_param_ != NULL) data_param_->::opencv_caffe::DataParameter::Clear();
clear_has_data_param();
}
const ::opencv_caffe::DataParameter& LayerParameter::data_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.data_param)
return data_param_ != NULL ? *data_param_
: *::opencv_caffe::DataParameter::internal_default_instance();
}
::opencv_caffe::DataParameter* LayerParameter::mutable_data_param() {
set_has_data_param();
if (data_param_ == NULL) {
data_param_ = new ::opencv_caffe::DataParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.data_param)
return data_param_;
}
::opencv_caffe::DataParameter* LayerParameter::release_data_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.data_param)
clear_has_data_param();
::opencv_caffe::DataParameter* temp = data_param_;
data_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_data_param(::opencv_caffe::DataParameter* data_param) {
delete data_param_;
data_param_ = data_param;
if (data_param) {
set_has_data_param();
} else {
clear_has_data_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.data_param)
}
// optional .opencv_caffe.DetectionOutputParameter detection_output_param = 147;
bool LayerParameter::has_detection_output_param() const {
return (_has_bits_[0] & 0x00400000u) != 0;
}
void LayerParameter::set_has_detection_output_param() {
_has_bits_[0] |= 0x00400000u;
}
void LayerParameter::clear_has_detection_output_param() {
_has_bits_[0] &= ~0x00400000u;
}
void LayerParameter::clear_detection_output_param() {
if (detection_output_param_ != NULL) detection_output_param_->::opencv_caffe::DetectionOutputParameter::Clear();
clear_has_detection_output_param();
}
const ::opencv_caffe::DetectionOutputParameter& LayerParameter::detection_output_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.detection_output_param)
return detection_output_param_ != NULL ? *detection_output_param_
: *::opencv_caffe::DetectionOutputParameter::internal_default_instance();
}
::opencv_caffe::DetectionOutputParameter* LayerParameter::mutable_detection_output_param() {
set_has_detection_output_param();
if (detection_output_param_ == NULL) {
detection_output_param_ = new ::opencv_caffe::DetectionOutputParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.detection_output_param)
return detection_output_param_;
}
::opencv_caffe::DetectionOutputParameter* LayerParameter::release_detection_output_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.detection_output_param)
clear_has_detection_output_param();
::opencv_caffe::DetectionOutputParameter* temp = detection_output_param_;
detection_output_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_detection_output_param(::opencv_caffe::DetectionOutputParameter* detection_output_param) {
delete detection_output_param_;
detection_output_param_ = detection_output_param;
if (detection_output_param) {
set_has_detection_output_param();
} else {
clear_has_detection_output_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.detection_output_param)
}
// optional .opencv_caffe.DropoutParameter dropout_param = 108;
bool LayerParameter::has_dropout_param() const {
return (_has_bits_[0] & 0x00800000u) != 0;
}
void LayerParameter::set_has_dropout_param() {
_has_bits_[0] |= 0x00800000u;
}
void LayerParameter::clear_has_dropout_param() {
_has_bits_[0] &= ~0x00800000u;
}
void LayerParameter::clear_dropout_param() {
if (dropout_param_ != NULL) dropout_param_->::opencv_caffe::DropoutParameter::Clear();
clear_has_dropout_param();
}
const ::opencv_caffe::DropoutParameter& LayerParameter::dropout_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.dropout_param)
return dropout_param_ != NULL ? *dropout_param_
: *::opencv_caffe::DropoutParameter::internal_default_instance();
}
::opencv_caffe::DropoutParameter* LayerParameter::mutable_dropout_param() {
set_has_dropout_param();
if (dropout_param_ == NULL) {
dropout_param_ = new ::opencv_caffe::DropoutParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.dropout_param)
return dropout_param_;
}
::opencv_caffe::DropoutParameter* LayerParameter::release_dropout_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.dropout_param)
clear_has_dropout_param();
::opencv_caffe::DropoutParameter* temp = dropout_param_;
dropout_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_dropout_param(::opencv_caffe::DropoutParameter* dropout_param) {
delete dropout_param_;
dropout_param_ = dropout_param;
if (dropout_param) {
set_has_dropout_param();
} else {
clear_has_dropout_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.dropout_param)
}
// optional .opencv_caffe.DummyDataParameter dummy_data_param = 109;
bool LayerParameter::has_dummy_data_param() const {
return (_has_bits_[0] & 0x01000000u) != 0;
}
void LayerParameter::set_has_dummy_data_param() {
_has_bits_[0] |= 0x01000000u;
}
void LayerParameter::clear_has_dummy_data_param() {
_has_bits_[0] &= ~0x01000000u;
}
void LayerParameter::clear_dummy_data_param() {
if (dummy_data_param_ != NULL) dummy_data_param_->::opencv_caffe::DummyDataParameter::Clear();
clear_has_dummy_data_param();
}
const ::opencv_caffe::DummyDataParameter& LayerParameter::dummy_data_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.dummy_data_param)
return dummy_data_param_ != NULL ? *dummy_data_param_
: *::opencv_caffe::DummyDataParameter::internal_default_instance();
}
::opencv_caffe::DummyDataParameter* LayerParameter::mutable_dummy_data_param() {
set_has_dummy_data_param();
if (dummy_data_param_ == NULL) {
dummy_data_param_ = new ::opencv_caffe::DummyDataParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.dummy_data_param)
return dummy_data_param_;
}
::opencv_caffe::DummyDataParameter* LayerParameter::release_dummy_data_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.dummy_data_param)
clear_has_dummy_data_param();
::opencv_caffe::DummyDataParameter* temp = dummy_data_param_;
dummy_data_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_dummy_data_param(::opencv_caffe::DummyDataParameter* dummy_data_param) {
delete dummy_data_param_;
dummy_data_param_ = dummy_data_param;
if (dummy_data_param) {
set_has_dummy_data_param();
} else {
clear_has_dummy_data_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.dummy_data_param)
}
// optional .opencv_caffe.EltwiseParameter eltwise_param = 110;
bool LayerParameter::has_eltwise_param() const {
return (_has_bits_[0] & 0x02000000u) != 0;
}
void LayerParameter::set_has_eltwise_param() {
_has_bits_[0] |= 0x02000000u;
}
void LayerParameter::clear_has_eltwise_param() {
_has_bits_[0] &= ~0x02000000u;
}
void LayerParameter::clear_eltwise_param() {
if (eltwise_param_ != NULL) eltwise_param_->::opencv_caffe::EltwiseParameter::Clear();
clear_has_eltwise_param();
}
const ::opencv_caffe::EltwiseParameter& LayerParameter::eltwise_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.eltwise_param)
return eltwise_param_ != NULL ? *eltwise_param_
: *::opencv_caffe::EltwiseParameter::internal_default_instance();
}
::opencv_caffe::EltwiseParameter* LayerParameter::mutable_eltwise_param() {
set_has_eltwise_param();
if (eltwise_param_ == NULL) {
eltwise_param_ = new ::opencv_caffe::EltwiseParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.eltwise_param)
return eltwise_param_;
}
::opencv_caffe::EltwiseParameter* LayerParameter::release_eltwise_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.eltwise_param)
clear_has_eltwise_param();
::opencv_caffe::EltwiseParameter* temp = eltwise_param_;
eltwise_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_eltwise_param(::opencv_caffe::EltwiseParameter* eltwise_param) {
delete eltwise_param_;
eltwise_param_ = eltwise_param;
if (eltwise_param) {
set_has_eltwise_param();
} else {
clear_has_eltwise_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.eltwise_param)
}
// optional .opencv_caffe.ELUParameter elu_param = 140;
bool LayerParameter::has_elu_param() const {
return (_has_bits_[0] & 0x04000000u) != 0;
}
void LayerParameter::set_has_elu_param() {
_has_bits_[0] |= 0x04000000u;
}
void LayerParameter::clear_has_elu_param() {
_has_bits_[0] &= ~0x04000000u;
}
void LayerParameter::clear_elu_param() {
if (elu_param_ != NULL) elu_param_->::opencv_caffe::ELUParameter::Clear();
clear_has_elu_param();
}
const ::opencv_caffe::ELUParameter& LayerParameter::elu_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.elu_param)
return elu_param_ != NULL ? *elu_param_
: *::opencv_caffe::ELUParameter::internal_default_instance();
}
::opencv_caffe::ELUParameter* LayerParameter::mutable_elu_param() {
set_has_elu_param();
if (elu_param_ == NULL) {
elu_param_ = new ::opencv_caffe::ELUParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.elu_param)
return elu_param_;
}
::opencv_caffe::ELUParameter* LayerParameter::release_elu_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.elu_param)
clear_has_elu_param();
::opencv_caffe::ELUParameter* temp = elu_param_;
elu_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_elu_param(::opencv_caffe::ELUParameter* elu_param) {
delete elu_param_;
elu_param_ = elu_param;
if (elu_param) {
set_has_elu_param();
} else {
clear_has_elu_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.elu_param)
}
// optional .opencv_caffe.EmbedParameter embed_param = 137;
bool LayerParameter::has_embed_param() const {
return (_has_bits_[0] & 0x08000000u) != 0;
}
void LayerParameter::set_has_embed_param() {
_has_bits_[0] |= 0x08000000u;
}
void LayerParameter::clear_has_embed_param() {
_has_bits_[0] &= ~0x08000000u;
}
void LayerParameter::clear_embed_param() {
if (embed_param_ != NULL) embed_param_->::opencv_caffe::EmbedParameter::Clear();
clear_has_embed_param();
}
const ::opencv_caffe::EmbedParameter& LayerParameter::embed_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.embed_param)
return embed_param_ != NULL ? *embed_param_
: *::opencv_caffe::EmbedParameter::internal_default_instance();
}
::opencv_caffe::EmbedParameter* LayerParameter::mutable_embed_param() {
set_has_embed_param();
if (embed_param_ == NULL) {
embed_param_ = new ::opencv_caffe::EmbedParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.embed_param)
return embed_param_;
}
::opencv_caffe::EmbedParameter* LayerParameter::release_embed_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.embed_param)
clear_has_embed_param();
::opencv_caffe::EmbedParameter* temp = embed_param_;
embed_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_embed_param(::opencv_caffe::EmbedParameter* embed_param) {
delete embed_param_;
embed_param_ = embed_param;
if (embed_param) {
set_has_embed_param();
} else {
clear_has_embed_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.embed_param)
}
// optional .opencv_caffe.ExpParameter exp_param = 111;
bool LayerParameter::has_exp_param() const {
return (_has_bits_[0] & 0x10000000u) != 0;
}
void LayerParameter::set_has_exp_param() {
_has_bits_[0] |= 0x10000000u;
}
void LayerParameter::clear_has_exp_param() {
_has_bits_[0] &= ~0x10000000u;
}
void LayerParameter::clear_exp_param() {
if (exp_param_ != NULL) exp_param_->::opencv_caffe::ExpParameter::Clear();
clear_has_exp_param();
}
const ::opencv_caffe::ExpParameter& LayerParameter::exp_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.exp_param)
return exp_param_ != NULL ? *exp_param_
: *::opencv_caffe::ExpParameter::internal_default_instance();
}
::opencv_caffe::ExpParameter* LayerParameter::mutable_exp_param() {
set_has_exp_param();
if (exp_param_ == NULL) {
exp_param_ = new ::opencv_caffe::ExpParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.exp_param)
return exp_param_;
}
::opencv_caffe::ExpParameter* LayerParameter::release_exp_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.exp_param)
clear_has_exp_param();
::opencv_caffe::ExpParameter* temp = exp_param_;
exp_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_exp_param(::opencv_caffe::ExpParameter* exp_param) {
delete exp_param_;
exp_param_ = exp_param;
if (exp_param) {
set_has_exp_param();
} else {
clear_has_exp_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.exp_param)
}
// optional .opencv_caffe.FlattenParameter flatten_param = 135;
bool LayerParameter::has_flatten_param() const {
return (_has_bits_[0] & 0x20000000u) != 0;
}
void LayerParameter::set_has_flatten_param() {
_has_bits_[0] |= 0x20000000u;
}
void LayerParameter::clear_has_flatten_param() {
_has_bits_[0] &= ~0x20000000u;
}
void LayerParameter::clear_flatten_param() {
if (flatten_param_ != NULL) flatten_param_->::opencv_caffe::FlattenParameter::Clear();
clear_has_flatten_param();
}
const ::opencv_caffe::FlattenParameter& LayerParameter::flatten_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.flatten_param)
return flatten_param_ != NULL ? *flatten_param_
: *::opencv_caffe::FlattenParameter::internal_default_instance();
}
::opencv_caffe::FlattenParameter* LayerParameter::mutable_flatten_param() {
set_has_flatten_param();
if (flatten_param_ == NULL) {
flatten_param_ = new ::opencv_caffe::FlattenParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.flatten_param)
return flatten_param_;
}
::opencv_caffe::FlattenParameter* LayerParameter::release_flatten_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.flatten_param)
clear_has_flatten_param();
::opencv_caffe::FlattenParameter* temp = flatten_param_;
flatten_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_flatten_param(::opencv_caffe::FlattenParameter* flatten_param) {
delete flatten_param_;
flatten_param_ = flatten_param;
if (flatten_param) {
set_has_flatten_param();
} else {
clear_has_flatten_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.flatten_param)
}
// optional .opencv_caffe.HDF5DataParameter hdf5_data_param = 112;
bool LayerParameter::has_hdf5_data_param() const {
return (_has_bits_[0] & 0x40000000u) != 0;
}
void LayerParameter::set_has_hdf5_data_param() {
_has_bits_[0] |= 0x40000000u;
}
void LayerParameter::clear_has_hdf5_data_param() {
_has_bits_[0] &= ~0x40000000u;
}
void LayerParameter::clear_hdf5_data_param() {
if (hdf5_data_param_ != NULL) hdf5_data_param_->::opencv_caffe::HDF5DataParameter::Clear();
clear_has_hdf5_data_param();
}
const ::opencv_caffe::HDF5DataParameter& LayerParameter::hdf5_data_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.hdf5_data_param)
return hdf5_data_param_ != NULL ? *hdf5_data_param_
: *::opencv_caffe::HDF5DataParameter::internal_default_instance();
}
::opencv_caffe::HDF5DataParameter* LayerParameter::mutable_hdf5_data_param() {
set_has_hdf5_data_param();
if (hdf5_data_param_ == NULL) {
hdf5_data_param_ = new ::opencv_caffe::HDF5DataParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.hdf5_data_param)
return hdf5_data_param_;
}
::opencv_caffe::HDF5DataParameter* LayerParameter::release_hdf5_data_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.hdf5_data_param)
clear_has_hdf5_data_param();
::opencv_caffe::HDF5DataParameter* temp = hdf5_data_param_;
hdf5_data_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_hdf5_data_param(::opencv_caffe::HDF5DataParameter* hdf5_data_param) {
delete hdf5_data_param_;
hdf5_data_param_ = hdf5_data_param;
if (hdf5_data_param) {
set_has_hdf5_data_param();
} else {
clear_has_hdf5_data_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.hdf5_data_param)
}
// optional .opencv_caffe.HDF5OutputParameter hdf5_output_param = 113;
bool LayerParameter::has_hdf5_output_param() const {
return (_has_bits_[0] & 0x80000000u) != 0;
}
void LayerParameter::set_has_hdf5_output_param() {
_has_bits_[0] |= 0x80000000u;
}
void LayerParameter::clear_has_hdf5_output_param() {
_has_bits_[0] &= ~0x80000000u;
}
void LayerParameter::clear_hdf5_output_param() {
if (hdf5_output_param_ != NULL) hdf5_output_param_->::opencv_caffe::HDF5OutputParameter::Clear();
clear_has_hdf5_output_param();
}
const ::opencv_caffe::HDF5OutputParameter& LayerParameter::hdf5_output_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.hdf5_output_param)
return hdf5_output_param_ != NULL ? *hdf5_output_param_
: *::opencv_caffe::HDF5OutputParameter::internal_default_instance();
}
::opencv_caffe::HDF5OutputParameter* LayerParameter::mutable_hdf5_output_param() {
set_has_hdf5_output_param();
if (hdf5_output_param_ == NULL) {
hdf5_output_param_ = new ::opencv_caffe::HDF5OutputParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.hdf5_output_param)
return hdf5_output_param_;
}
::opencv_caffe::HDF5OutputParameter* LayerParameter::release_hdf5_output_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.hdf5_output_param)
clear_has_hdf5_output_param();
::opencv_caffe::HDF5OutputParameter* temp = hdf5_output_param_;
hdf5_output_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_hdf5_output_param(::opencv_caffe::HDF5OutputParameter* hdf5_output_param) {
delete hdf5_output_param_;
hdf5_output_param_ = hdf5_output_param;
if (hdf5_output_param) {
set_has_hdf5_output_param();
} else {
clear_has_hdf5_output_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.hdf5_output_param)
}
// optional .opencv_caffe.HingeLossParameter hinge_loss_param = 114;
bool LayerParameter::has_hinge_loss_param() const {
return (_has_bits_[1] & 0x00000001u) != 0;
}
void LayerParameter::set_has_hinge_loss_param() {
_has_bits_[1] |= 0x00000001u;
}
void LayerParameter::clear_has_hinge_loss_param() {
_has_bits_[1] &= ~0x00000001u;
}
void LayerParameter::clear_hinge_loss_param() {
if (hinge_loss_param_ != NULL) hinge_loss_param_->::opencv_caffe::HingeLossParameter::Clear();
clear_has_hinge_loss_param();
}
const ::opencv_caffe::HingeLossParameter& LayerParameter::hinge_loss_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.hinge_loss_param)
return hinge_loss_param_ != NULL ? *hinge_loss_param_
: *::opencv_caffe::HingeLossParameter::internal_default_instance();
}
::opencv_caffe::HingeLossParameter* LayerParameter::mutable_hinge_loss_param() {
set_has_hinge_loss_param();
if (hinge_loss_param_ == NULL) {
hinge_loss_param_ = new ::opencv_caffe::HingeLossParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.hinge_loss_param)
return hinge_loss_param_;
}
::opencv_caffe::HingeLossParameter* LayerParameter::release_hinge_loss_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.hinge_loss_param)
clear_has_hinge_loss_param();
::opencv_caffe::HingeLossParameter* temp = hinge_loss_param_;
hinge_loss_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_hinge_loss_param(::opencv_caffe::HingeLossParameter* hinge_loss_param) {
delete hinge_loss_param_;
hinge_loss_param_ = hinge_loss_param;
if (hinge_loss_param) {
set_has_hinge_loss_param();
} else {
clear_has_hinge_loss_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.hinge_loss_param)
}
// optional .opencv_caffe.ImageDataParameter image_data_param = 115;
bool LayerParameter::has_image_data_param() const {
return (_has_bits_[1] & 0x00000002u) != 0;
}
void LayerParameter::set_has_image_data_param() {
_has_bits_[1] |= 0x00000002u;
}
void LayerParameter::clear_has_image_data_param() {
_has_bits_[1] &= ~0x00000002u;
}
void LayerParameter::clear_image_data_param() {
if (image_data_param_ != NULL) image_data_param_->::opencv_caffe::ImageDataParameter::Clear();
clear_has_image_data_param();
}
const ::opencv_caffe::ImageDataParameter& LayerParameter::image_data_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.image_data_param)
return image_data_param_ != NULL ? *image_data_param_
: *::opencv_caffe::ImageDataParameter::internal_default_instance();
}
::opencv_caffe::ImageDataParameter* LayerParameter::mutable_image_data_param() {
set_has_image_data_param();
if (image_data_param_ == NULL) {
image_data_param_ = new ::opencv_caffe::ImageDataParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.image_data_param)
return image_data_param_;
}
::opencv_caffe::ImageDataParameter* LayerParameter::release_image_data_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.image_data_param)
clear_has_image_data_param();
::opencv_caffe::ImageDataParameter* temp = image_data_param_;
image_data_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_image_data_param(::opencv_caffe::ImageDataParameter* image_data_param) {
delete image_data_param_;
image_data_param_ = image_data_param;
if (image_data_param) {
set_has_image_data_param();
} else {
clear_has_image_data_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.image_data_param)
}
// optional .opencv_caffe.InfogainLossParameter infogain_loss_param = 116;
bool LayerParameter::has_infogain_loss_param() const {
return (_has_bits_[1] & 0x00000004u) != 0;
}
void LayerParameter::set_has_infogain_loss_param() {
_has_bits_[1] |= 0x00000004u;
}
void LayerParameter::clear_has_infogain_loss_param() {
_has_bits_[1] &= ~0x00000004u;
}
void LayerParameter::clear_infogain_loss_param() {
if (infogain_loss_param_ != NULL) infogain_loss_param_->::opencv_caffe::InfogainLossParameter::Clear();
clear_has_infogain_loss_param();
}
const ::opencv_caffe::InfogainLossParameter& LayerParameter::infogain_loss_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.infogain_loss_param)
return infogain_loss_param_ != NULL ? *infogain_loss_param_
: *::opencv_caffe::InfogainLossParameter::internal_default_instance();
}
::opencv_caffe::InfogainLossParameter* LayerParameter::mutable_infogain_loss_param() {
set_has_infogain_loss_param();
if (infogain_loss_param_ == NULL) {
infogain_loss_param_ = new ::opencv_caffe::InfogainLossParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.infogain_loss_param)
return infogain_loss_param_;
}
::opencv_caffe::InfogainLossParameter* LayerParameter::release_infogain_loss_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.infogain_loss_param)
clear_has_infogain_loss_param();
::opencv_caffe::InfogainLossParameter* temp = infogain_loss_param_;
infogain_loss_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_infogain_loss_param(::opencv_caffe::InfogainLossParameter* infogain_loss_param) {
delete infogain_loss_param_;
infogain_loss_param_ = infogain_loss_param;
if (infogain_loss_param) {
set_has_infogain_loss_param();
} else {
clear_has_infogain_loss_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.infogain_loss_param)
}
// optional .opencv_caffe.InnerProductParameter inner_product_param = 117;
bool LayerParameter::has_inner_product_param() const {
return (_has_bits_[1] & 0x00000008u) != 0;
}
void LayerParameter::set_has_inner_product_param() {
_has_bits_[1] |= 0x00000008u;
}
void LayerParameter::clear_has_inner_product_param() {
_has_bits_[1] &= ~0x00000008u;
}
void LayerParameter::clear_inner_product_param() {
if (inner_product_param_ != NULL) inner_product_param_->::opencv_caffe::InnerProductParameter::Clear();
clear_has_inner_product_param();
}
const ::opencv_caffe::InnerProductParameter& LayerParameter::inner_product_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.inner_product_param)
return inner_product_param_ != NULL ? *inner_product_param_
: *::opencv_caffe::InnerProductParameter::internal_default_instance();
}
::opencv_caffe::InnerProductParameter* LayerParameter::mutable_inner_product_param() {
set_has_inner_product_param();
if (inner_product_param_ == NULL) {
inner_product_param_ = new ::opencv_caffe::InnerProductParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.inner_product_param)
return inner_product_param_;
}
::opencv_caffe::InnerProductParameter* LayerParameter::release_inner_product_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.inner_product_param)
clear_has_inner_product_param();
::opencv_caffe::InnerProductParameter* temp = inner_product_param_;
inner_product_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_inner_product_param(::opencv_caffe::InnerProductParameter* inner_product_param) {
delete inner_product_param_;
inner_product_param_ = inner_product_param;
if (inner_product_param) {
set_has_inner_product_param();
} else {
clear_has_inner_product_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.inner_product_param)
}
// optional .opencv_caffe.InputParameter input_param = 143;
bool LayerParameter::has_input_param() const {
return (_has_bits_[1] & 0x00000010u) != 0;
}
void LayerParameter::set_has_input_param() {
_has_bits_[1] |= 0x00000010u;
}
void LayerParameter::clear_has_input_param() {
_has_bits_[1] &= ~0x00000010u;
}
void LayerParameter::clear_input_param() {
if (input_param_ != NULL) input_param_->::opencv_caffe::InputParameter::Clear();
clear_has_input_param();
}
const ::opencv_caffe::InputParameter& LayerParameter::input_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.input_param)
return input_param_ != NULL ? *input_param_
: *::opencv_caffe::InputParameter::internal_default_instance();
}
::opencv_caffe::InputParameter* LayerParameter::mutable_input_param() {
set_has_input_param();
if (input_param_ == NULL) {
input_param_ = new ::opencv_caffe::InputParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.input_param)
return input_param_;
}
::opencv_caffe::InputParameter* LayerParameter::release_input_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.input_param)
clear_has_input_param();
::opencv_caffe::InputParameter* temp = input_param_;
input_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_input_param(::opencv_caffe::InputParameter* input_param) {
delete input_param_;
input_param_ = input_param;
if (input_param) {
set_has_input_param();
} else {
clear_has_input_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.input_param)
}
// optional .opencv_caffe.LogParameter log_param = 134;
bool LayerParameter::has_log_param() const {
return (_has_bits_[1] & 0x00000020u) != 0;
}
void LayerParameter::set_has_log_param() {
_has_bits_[1] |= 0x00000020u;
}
void LayerParameter::clear_has_log_param() {
_has_bits_[1] &= ~0x00000020u;
}
void LayerParameter::clear_log_param() {
if (log_param_ != NULL) log_param_->::opencv_caffe::LogParameter::Clear();
clear_has_log_param();
}
const ::opencv_caffe::LogParameter& LayerParameter::log_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.log_param)
return log_param_ != NULL ? *log_param_
: *::opencv_caffe::LogParameter::internal_default_instance();
}
::opencv_caffe::LogParameter* LayerParameter::mutable_log_param() {
set_has_log_param();
if (log_param_ == NULL) {
log_param_ = new ::opencv_caffe::LogParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.log_param)
return log_param_;
}
::opencv_caffe::LogParameter* LayerParameter::release_log_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.log_param)
clear_has_log_param();
::opencv_caffe::LogParameter* temp = log_param_;
log_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_log_param(::opencv_caffe::LogParameter* log_param) {
delete log_param_;
log_param_ = log_param;
if (log_param) {
set_has_log_param();
} else {
clear_has_log_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.log_param)
}
// optional .opencv_caffe.LRNParameter lrn_param = 118;
bool LayerParameter::has_lrn_param() const {
return (_has_bits_[1] & 0x00000040u) != 0;
}
void LayerParameter::set_has_lrn_param() {
_has_bits_[1] |= 0x00000040u;
}
void LayerParameter::clear_has_lrn_param() {
_has_bits_[1] &= ~0x00000040u;
}
void LayerParameter::clear_lrn_param() {
if (lrn_param_ != NULL) lrn_param_->::opencv_caffe::LRNParameter::Clear();
clear_has_lrn_param();
}
const ::opencv_caffe::LRNParameter& LayerParameter::lrn_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.lrn_param)
return lrn_param_ != NULL ? *lrn_param_
: *::opencv_caffe::LRNParameter::internal_default_instance();
}
::opencv_caffe::LRNParameter* LayerParameter::mutable_lrn_param() {
set_has_lrn_param();
if (lrn_param_ == NULL) {
lrn_param_ = new ::opencv_caffe::LRNParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.lrn_param)
return lrn_param_;
}
::opencv_caffe::LRNParameter* LayerParameter::release_lrn_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.lrn_param)
clear_has_lrn_param();
::opencv_caffe::LRNParameter* temp = lrn_param_;
lrn_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_lrn_param(::opencv_caffe::LRNParameter* lrn_param) {
delete lrn_param_;
lrn_param_ = lrn_param;
if (lrn_param) {
set_has_lrn_param();
} else {
clear_has_lrn_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.lrn_param)
}
// optional .opencv_caffe.MemoryDataParameter memory_data_param = 119;
bool LayerParameter::has_memory_data_param() const {
return (_has_bits_[1] & 0x00000080u) != 0;
}
void LayerParameter::set_has_memory_data_param() {
_has_bits_[1] |= 0x00000080u;
}
void LayerParameter::clear_has_memory_data_param() {
_has_bits_[1] &= ~0x00000080u;
}
void LayerParameter::clear_memory_data_param() {
if (memory_data_param_ != NULL) memory_data_param_->::opencv_caffe::MemoryDataParameter::Clear();
clear_has_memory_data_param();
}
const ::opencv_caffe::MemoryDataParameter& LayerParameter::memory_data_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.memory_data_param)
return memory_data_param_ != NULL ? *memory_data_param_
: *::opencv_caffe::MemoryDataParameter::internal_default_instance();
}
::opencv_caffe::MemoryDataParameter* LayerParameter::mutable_memory_data_param() {
set_has_memory_data_param();
if (memory_data_param_ == NULL) {
memory_data_param_ = new ::opencv_caffe::MemoryDataParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.memory_data_param)
return memory_data_param_;
}
::opencv_caffe::MemoryDataParameter* LayerParameter::release_memory_data_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.memory_data_param)
clear_has_memory_data_param();
::opencv_caffe::MemoryDataParameter* temp = memory_data_param_;
memory_data_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_memory_data_param(::opencv_caffe::MemoryDataParameter* memory_data_param) {
delete memory_data_param_;
memory_data_param_ = memory_data_param;
if (memory_data_param) {
set_has_memory_data_param();
} else {
clear_has_memory_data_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.memory_data_param)
}
// optional .opencv_caffe.MVNParameter mvn_param = 120;
bool LayerParameter::has_mvn_param() const {
return (_has_bits_[1] & 0x00000100u) != 0;
}
void LayerParameter::set_has_mvn_param() {
_has_bits_[1] |= 0x00000100u;
}
void LayerParameter::clear_has_mvn_param() {
_has_bits_[1] &= ~0x00000100u;
}
void LayerParameter::clear_mvn_param() {
if (mvn_param_ != NULL) mvn_param_->::opencv_caffe::MVNParameter::Clear();
clear_has_mvn_param();
}
const ::opencv_caffe::MVNParameter& LayerParameter::mvn_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.mvn_param)
return mvn_param_ != NULL ? *mvn_param_
: *::opencv_caffe::MVNParameter::internal_default_instance();
}
::opencv_caffe::MVNParameter* LayerParameter::mutable_mvn_param() {
set_has_mvn_param();
if (mvn_param_ == NULL) {
mvn_param_ = new ::opencv_caffe::MVNParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.mvn_param)
return mvn_param_;
}
::opencv_caffe::MVNParameter* LayerParameter::release_mvn_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.mvn_param)
clear_has_mvn_param();
::opencv_caffe::MVNParameter* temp = mvn_param_;
mvn_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_mvn_param(::opencv_caffe::MVNParameter* mvn_param) {
delete mvn_param_;
mvn_param_ = mvn_param;
if (mvn_param) {
set_has_mvn_param();
} else {
clear_has_mvn_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.mvn_param)
}
// optional .opencv_caffe.NormalizeBBoxParameter norm_param = 149;
bool LayerParameter::has_norm_param() const {
return (_has_bits_[1] & 0x00000200u) != 0;
}
void LayerParameter::set_has_norm_param() {
_has_bits_[1] |= 0x00000200u;
}
void LayerParameter::clear_has_norm_param() {
_has_bits_[1] &= ~0x00000200u;
}
void LayerParameter::clear_norm_param() {
if (norm_param_ != NULL) norm_param_->::opencv_caffe::NormalizeBBoxParameter::Clear();
clear_has_norm_param();
}
const ::opencv_caffe::NormalizeBBoxParameter& LayerParameter::norm_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.norm_param)
return norm_param_ != NULL ? *norm_param_
: *::opencv_caffe::NormalizeBBoxParameter::internal_default_instance();
}
::opencv_caffe::NormalizeBBoxParameter* LayerParameter::mutable_norm_param() {
set_has_norm_param();
if (norm_param_ == NULL) {
norm_param_ = new ::opencv_caffe::NormalizeBBoxParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.norm_param)
return norm_param_;
}
::opencv_caffe::NormalizeBBoxParameter* LayerParameter::release_norm_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.norm_param)
clear_has_norm_param();
::opencv_caffe::NormalizeBBoxParameter* temp = norm_param_;
norm_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_norm_param(::opencv_caffe::NormalizeBBoxParameter* norm_param) {
delete norm_param_;
norm_param_ = norm_param;
if (norm_param) {
set_has_norm_param();
} else {
clear_has_norm_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.norm_param)
}
// optional .opencv_caffe.PermuteParameter permute_param = 148;
bool LayerParameter::has_permute_param() const {
return (_has_bits_[1] & 0x00000400u) != 0;
}
void LayerParameter::set_has_permute_param() {
_has_bits_[1] |= 0x00000400u;
}
void LayerParameter::clear_has_permute_param() {
_has_bits_[1] &= ~0x00000400u;
}
void LayerParameter::clear_permute_param() {
if (permute_param_ != NULL) permute_param_->::opencv_caffe::PermuteParameter::Clear();
clear_has_permute_param();
}
const ::opencv_caffe::PermuteParameter& LayerParameter::permute_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.permute_param)
return permute_param_ != NULL ? *permute_param_
: *::opencv_caffe::PermuteParameter::internal_default_instance();
}
::opencv_caffe::PermuteParameter* LayerParameter::mutable_permute_param() {
set_has_permute_param();
if (permute_param_ == NULL) {
permute_param_ = new ::opencv_caffe::PermuteParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.permute_param)
return permute_param_;
}
::opencv_caffe::PermuteParameter* LayerParameter::release_permute_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.permute_param)
clear_has_permute_param();
::opencv_caffe::PermuteParameter* temp = permute_param_;
permute_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_permute_param(::opencv_caffe::PermuteParameter* permute_param) {
delete permute_param_;
permute_param_ = permute_param;
if (permute_param) {
set_has_permute_param();
} else {
clear_has_permute_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.permute_param)
}
// optional .opencv_caffe.ParameterParameter parameter_param = 145;
bool LayerParameter::has_parameter_param() const {
return (_has_bits_[1] & 0x00000800u) != 0;
}
void LayerParameter::set_has_parameter_param() {
_has_bits_[1] |= 0x00000800u;
}
void LayerParameter::clear_has_parameter_param() {
_has_bits_[1] &= ~0x00000800u;
}
void LayerParameter::clear_parameter_param() {
if (parameter_param_ != NULL) parameter_param_->::opencv_caffe::ParameterParameter::Clear();
clear_has_parameter_param();
}
const ::opencv_caffe::ParameterParameter& LayerParameter::parameter_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.parameter_param)
return parameter_param_ != NULL ? *parameter_param_
: *::opencv_caffe::ParameterParameter::internal_default_instance();
}
::opencv_caffe::ParameterParameter* LayerParameter::mutable_parameter_param() {
set_has_parameter_param();
if (parameter_param_ == NULL) {
parameter_param_ = new ::opencv_caffe::ParameterParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.parameter_param)
return parameter_param_;
}
::opencv_caffe::ParameterParameter* LayerParameter::release_parameter_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.parameter_param)
clear_has_parameter_param();
::opencv_caffe::ParameterParameter* temp = parameter_param_;
parameter_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_parameter_param(::opencv_caffe::ParameterParameter* parameter_param) {
delete parameter_param_;
parameter_param_ = parameter_param;
if (parameter_param) {
set_has_parameter_param();
} else {
clear_has_parameter_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.parameter_param)
}
// optional .opencv_caffe.PoolingParameter pooling_param = 121;
bool LayerParameter::has_pooling_param() const {
return (_has_bits_[1] & 0x00001000u) != 0;
}
void LayerParameter::set_has_pooling_param() {
_has_bits_[1] |= 0x00001000u;
}
void LayerParameter::clear_has_pooling_param() {
_has_bits_[1] &= ~0x00001000u;
}
void LayerParameter::clear_pooling_param() {
if (pooling_param_ != NULL) pooling_param_->::opencv_caffe::PoolingParameter::Clear();
clear_has_pooling_param();
}
const ::opencv_caffe::PoolingParameter& LayerParameter::pooling_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.pooling_param)
return pooling_param_ != NULL ? *pooling_param_
: *::opencv_caffe::PoolingParameter::internal_default_instance();
}
::opencv_caffe::PoolingParameter* LayerParameter::mutable_pooling_param() {
set_has_pooling_param();
if (pooling_param_ == NULL) {
pooling_param_ = new ::opencv_caffe::PoolingParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.pooling_param)
return pooling_param_;
}
::opencv_caffe::PoolingParameter* LayerParameter::release_pooling_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.pooling_param)
clear_has_pooling_param();
::opencv_caffe::PoolingParameter* temp = pooling_param_;
pooling_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_pooling_param(::opencv_caffe::PoolingParameter* pooling_param) {
delete pooling_param_;
pooling_param_ = pooling_param;
if (pooling_param) {
set_has_pooling_param();
} else {
clear_has_pooling_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.pooling_param)
}
// optional .opencv_caffe.PowerParameter power_param = 122;
bool LayerParameter::has_power_param() const {
return (_has_bits_[1] & 0x00002000u) != 0;
}
void LayerParameter::set_has_power_param() {
_has_bits_[1] |= 0x00002000u;
}
void LayerParameter::clear_has_power_param() {
_has_bits_[1] &= ~0x00002000u;
}
void LayerParameter::clear_power_param() {
if (power_param_ != NULL) power_param_->::opencv_caffe::PowerParameter::Clear();
clear_has_power_param();
}
const ::opencv_caffe::PowerParameter& LayerParameter::power_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.power_param)
return power_param_ != NULL ? *power_param_
: *::opencv_caffe::PowerParameter::internal_default_instance();
}
::opencv_caffe::PowerParameter* LayerParameter::mutable_power_param() {
set_has_power_param();
if (power_param_ == NULL) {
power_param_ = new ::opencv_caffe::PowerParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.power_param)
return power_param_;
}
::opencv_caffe::PowerParameter* LayerParameter::release_power_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.power_param)
clear_has_power_param();
::opencv_caffe::PowerParameter* temp = power_param_;
power_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_power_param(::opencv_caffe::PowerParameter* power_param) {
delete power_param_;
power_param_ = power_param;
if (power_param) {
set_has_power_param();
} else {
clear_has_power_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.power_param)
}
// optional .opencv_caffe.PReLUParameter prelu_param = 131;
bool LayerParameter::has_prelu_param() const {
return (_has_bits_[1] & 0x00004000u) != 0;
}
void LayerParameter::set_has_prelu_param() {
_has_bits_[1] |= 0x00004000u;
}
void LayerParameter::clear_has_prelu_param() {
_has_bits_[1] &= ~0x00004000u;
}
void LayerParameter::clear_prelu_param() {
if (prelu_param_ != NULL) prelu_param_->::opencv_caffe::PReLUParameter::Clear();
clear_has_prelu_param();
}
const ::opencv_caffe::PReLUParameter& LayerParameter::prelu_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.prelu_param)
return prelu_param_ != NULL ? *prelu_param_
: *::opencv_caffe::PReLUParameter::internal_default_instance();
}
::opencv_caffe::PReLUParameter* LayerParameter::mutable_prelu_param() {
set_has_prelu_param();
if (prelu_param_ == NULL) {
prelu_param_ = new ::opencv_caffe::PReLUParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.prelu_param)
return prelu_param_;
}
::opencv_caffe::PReLUParameter* LayerParameter::release_prelu_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.prelu_param)
clear_has_prelu_param();
::opencv_caffe::PReLUParameter* temp = prelu_param_;
prelu_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_prelu_param(::opencv_caffe::PReLUParameter* prelu_param) {
delete prelu_param_;
prelu_param_ = prelu_param;
if (prelu_param) {
set_has_prelu_param();
} else {
clear_has_prelu_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.prelu_param)
}
// optional .opencv_caffe.PriorBoxParameter prior_box_param = 150;
bool LayerParameter::has_prior_box_param() const {
return (_has_bits_[1] & 0x00008000u) != 0;
}
void LayerParameter::set_has_prior_box_param() {
_has_bits_[1] |= 0x00008000u;
}
void LayerParameter::clear_has_prior_box_param() {
_has_bits_[1] &= ~0x00008000u;
}
void LayerParameter::clear_prior_box_param() {
if (prior_box_param_ != NULL) prior_box_param_->::opencv_caffe::PriorBoxParameter::Clear();
clear_has_prior_box_param();
}
const ::opencv_caffe::PriorBoxParameter& LayerParameter::prior_box_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.prior_box_param)
return prior_box_param_ != NULL ? *prior_box_param_
: *::opencv_caffe::PriorBoxParameter::internal_default_instance();
}
::opencv_caffe::PriorBoxParameter* LayerParameter::mutable_prior_box_param() {
set_has_prior_box_param();
if (prior_box_param_ == NULL) {
prior_box_param_ = new ::opencv_caffe::PriorBoxParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.prior_box_param)
return prior_box_param_;
}
::opencv_caffe::PriorBoxParameter* LayerParameter::release_prior_box_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.prior_box_param)
clear_has_prior_box_param();
::opencv_caffe::PriorBoxParameter* temp = prior_box_param_;
prior_box_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_prior_box_param(::opencv_caffe::PriorBoxParameter* prior_box_param) {
delete prior_box_param_;
prior_box_param_ = prior_box_param;
if (prior_box_param) {
set_has_prior_box_param();
} else {
clear_has_prior_box_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.prior_box_param)
}
// optional .opencv_caffe.ProposalParameter proposal_param = 201;
bool LayerParameter::has_proposal_param() const {
return (_has_bits_[1] & 0x00010000u) != 0;
}
void LayerParameter::set_has_proposal_param() {
_has_bits_[1] |= 0x00010000u;
}
void LayerParameter::clear_has_proposal_param() {
_has_bits_[1] &= ~0x00010000u;
}
void LayerParameter::clear_proposal_param() {
if (proposal_param_ != NULL) proposal_param_->::opencv_caffe::ProposalParameter::Clear();
clear_has_proposal_param();
}
const ::opencv_caffe::ProposalParameter& LayerParameter::proposal_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.proposal_param)
return proposal_param_ != NULL ? *proposal_param_
: *::opencv_caffe::ProposalParameter::internal_default_instance();
}
::opencv_caffe::ProposalParameter* LayerParameter::mutable_proposal_param() {
set_has_proposal_param();
if (proposal_param_ == NULL) {
proposal_param_ = new ::opencv_caffe::ProposalParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.proposal_param)
return proposal_param_;
}
::opencv_caffe::ProposalParameter* LayerParameter::release_proposal_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.proposal_param)
clear_has_proposal_param();
::opencv_caffe::ProposalParameter* temp = proposal_param_;
proposal_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_proposal_param(::opencv_caffe::ProposalParameter* proposal_param) {
delete proposal_param_;
proposal_param_ = proposal_param;
if (proposal_param) {
set_has_proposal_param();
} else {
clear_has_proposal_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.proposal_param)
}
// optional .opencv_caffe.PSROIPoolingParameter psroi_pooling_param = 10001;
bool LayerParameter::has_psroi_pooling_param() const {
return (_has_bits_[1] & 0x00020000u) != 0;
}
void LayerParameter::set_has_psroi_pooling_param() {
_has_bits_[1] |= 0x00020000u;
}
void LayerParameter::clear_has_psroi_pooling_param() {
_has_bits_[1] &= ~0x00020000u;
}
void LayerParameter::clear_psroi_pooling_param() {
if (psroi_pooling_param_ != NULL) psroi_pooling_param_->::opencv_caffe::PSROIPoolingParameter::Clear();
clear_has_psroi_pooling_param();
}
const ::opencv_caffe::PSROIPoolingParameter& LayerParameter::psroi_pooling_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.psroi_pooling_param)
return psroi_pooling_param_ != NULL ? *psroi_pooling_param_
: *::opencv_caffe::PSROIPoolingParameter::internal_default_instance();
}
::opencv_caffe::PSROIPoolingParameter* LayerParameter::mutable_psroi_pooling_param() {
set_has_psroi_pooling_param();
if (psroi_pooling_param_ == NULL) {
psroi_pooling_param_ = new ::opencv_caffe::PSROIPoolingParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.psroi_pooling_param)
return psroi_pooling_param_;
}
::opencv_caffe::PSROIPoolingParameter* LayerParameter::release_psroi_pooling_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.psroi_pooling_param)
clear_has_psroi_pooling_param();
::opencv_caffe::PSROIPoolingParameter* temp = psroi_pooling_param_;
psroi_pooling_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_psroi_pooling_param(::opencv_caffe::PSROIPoolingParameter* psroi_pooling_param) {
delete psroi_pooling_param_;
psroi_pooling_param_ = psroi_pooling_param;
if (psroi_pooling_param) {
set_has_psroi_pooling_param();
} else {
clear_has_psroi_pooling_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.psroi_pooling_param)
}
// optional .opencv_caffe.PythonParameter python_param = 130;
bool LayerParameter::has_python_param() const {
return (_has_bits_[1] & 0x00040000u) != 0;
}
void LayerParameter::set_has_python_param() {
_has_bits_[1] |= 0x00040000u;
}
void LayerParameter::clear_has_python_param() {
_has_bits_[1] &= ~0x00040000u;
}
void LayerParameter::clear_python_param() {
if (python_param_ != NULL) python_param_->::opencv_caffe::PythonParameter::Clear();
clear_has_python_param();
}
const ::opencv_caffe::PythonParameter& LayerParameter::python_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.python_param)
return python_param_ != NULL ? *python_param_
: *::opencv_caffe::PythonParameter::internal_default_instance();
}
::opencv_caffe::PythonParameter* LayerParameter::mutable_python_param() {
set_has_python_param();
if (python_param_ == NULL) {
python_param_ = new ::opencv_caffe::PythonParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.python_param)
return python_param_;
}
::opencv_caffe::PythonParameter* LayerParameter::release_python_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.python_param)
clear_has_python_param();
::opencv_caffe::PythonParameter* temp = python_param_;
python_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_python_param(::opencv_caffe::PythonParameter* python_param) {
delete python_param_;
python_param_ = python_param;
if (python_param) {
set_has_python_param();
} else {
clear_has_python_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.python_param)
}
// optional .opencv_caffe.RecurrentParameter recurrent_param = 146;
bool LayerParameter::has_recurrent_param() const {
return (_has_bits_[1] & 0x00080000u) != 0;
}
void LayerParameter::set_has_recurrent_param() {
_has_bits_[1] |= 0x00080000u;
}
void LayerParameter::clear_has_recurrent_param() {
_has_bits_[1] &= ~0x00080000u;
}
void LayerParameter::clear_recurrent_param() {
if (recurrent_param_ != NULL) recurrent_param_->::opencv_caffe::RecurrentParameter::Clear();
clear_has_recurrent_param();
}
const ::opencv_caffe::RecurrentParameter& LayerParameter::recurrent_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.recurrent_param)
return recurrent_param_ != NULL ? *recurrent_param_
: *::opencv_caffe::RecurrentParameter::internal_default_instance();
}
::opencv_caffe::RecurrentParameter* LayerParameter::mutable_recurrent_param() {
set_has_recurrent_param();
if (recurrent_param_ == NULL) {
recurrent_param_ = new ::opencv_caffe::RecurrentParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.recurrent_param)
return recurrent_param_;
}
::opencv_caffe::RecurrentParameter* LayerParameter::release_recurrent_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.recurrent_param)
clear_has_recurrent_param();
::opencv_caffe::RecurrentParameter* temp = recurrent_param_;
recurrent_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_recurrent_param(::opencv_caffe::RecurrentParameter* recurrent_param) {
delete recurrent_param_;
recurrent_param_ = recurrent_param;
if (recurrent_param) {
set_has_recurrent_param();
} else {
clear_has_recurrent_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.recurrent_param)
}
// optional .opencv_caffe.ReductionParameter reduction_param = 136;
bool LayerParameter::has_reduction_param() const {
return (_has_bits_[1] & 0x00100000u) != 0;
}
void LayerParameter::set_has_reduction_param() {
_has_bits_[1] |= 0x00100000u;
}
void LayerParameter::clear_has_reduction_param() {
_has_bits_[1] &= ~0x00100000u;
}
void LayerParameter::clear_reduction_param() {
if (reduction_param_ != NULL) reduction_param_->::opencv_caffe::ReductionParameter::Clear();
clear_has_reduction_param();
}
const ::opencv_caffe::ReductionParameter& LayerParameter::reduction_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.reduction_param)
return reduction_param_ != NULL ? *reduction_param_
: *::opencv_caffe::ReductionParameter::internal_default_instance();
}
::opencv_caffe::ReductionParameter* LayerParameter::mutable_reduction_param() {
set_has_reduction_param();
if (reduction_param_ == NULL) {
reduction_param_ = new ::opencv_caffe::ReductionParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.reduction_param)
return reduction_param_;
}
::opencv_caffe::ReductionParameter* LayerParameter::release_reduction_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.reduction_param)
clear_has_reduction_param();
::opencv_caffe::ReductionParameter* temp = reduction_param_;
reduction_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_reduction_param(::opencv_caffe::ReductionParameter* reduction_param) {
delete reduction_param_;
reduction_param_ = reduction_param;
if (reduction_param) {
set_has_reduction_param();
} else {
clear_has_reduction_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.reduction_param)
}
// optional .opencv_caffe.ReLUParameter relu_param = 123;
bool LayerParameter::has_relu_param() const {
return (_has_bits_[1] & 0x00200000u) != 0;
}
void LayerParameter::set_has_relu_param() {
_has_bits_[1] |= 0x00200000u;
}
void LayerParameter::clear_has_relu_param() {
_has_bits_[1] &= ~0x00200000u;
}
void LayerParameter::clear_relu_param() {
if (relu_param_ != NULL) relu_param_->::opencv_caffe::ReLUParameter::Clear();
clear_has_relu_param();
}
const ::opencv_caffe::ReLUParameter& LayerParameter::relu_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.relu_param)
return relu_param_ != NULL ? *relu_param_
: *::opencv_caffe::ReLUParameter::internal_default_instance();
}
::opencv_caffe::ReLUParameter* LayerParameter::mutable_relu_param() {
set_has_relu_param();
if (relu_param_ == NULL) {
relu_param_ = new ::opencv_caffe::ReLUParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.relu_param)
return relu_param_;
}
::opencv_caffe::ReLUParameter* LayerParameter::release_relu_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.relu_param)
clear_has_relu_param();
::opencv_caffe::ReLUParameter* temp = relu_param_;
relu_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_relu_param(::opencv_caffe::ReLUParameter* relu_param) {
delete relu_param_;
relu_param_ = relu_param;
if (relu_param) {
set_has_relu_param();
} else {
clear_has_relu_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.relu_param)
}
// optional .opencv_caffe.ReshapeParameter reshape_param = 133;
bool LayerParameter::has_reshape_param() const {
return (_has_bits_[1] & 0x00400000u) != 0;
}
void LayerParameter::set_has_reshape_param() {
_has_bits_[1] |= 0x00400000u;
}
void LayerParameter::clear_has_reshape_param() {
_has_bits_[1] &= ~0x00400000u;
}
void LayerParameter::clear_reshape_param() {
if (reshape_param_ != NULL) reshape_param_->::opencv_caffe::ReshapeParameter::Clear();
clear_has_reshape_param();
}
const ::opencv_caffe::ReshapeParameter& LayerParameter::reshape_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.reshape_param)
return reshape_param_ != NULL ? *reshape_param_
: *::opencv_caffe::ReshapeParameter::internal_default_instance();
}
::opencv_caffe::ReshapeParameter* LayerParameter::mutable_reshape_param() {
set_has_reshape_param();
if (reshape_param_ == NULL) {
reshape_param_ = new ::opencv_caffe::ReshapeParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.reshape_param)
return reshape_param_;
}
::opencv_caffe::ReshapeParameter* LayerParameter::release_reshape_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.reshape_param)
clear_has_reshape_param();
::opencv_caffe::ReshapeParameter* temp = reshape_param_;
reshape_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_reshape_param(::opencv_caffe::ReshapeParameter* reshape_param) {
delete reshape_param_;
reshape_param_ = reshape_param;
if (reshape_param) {
set_has_reshape_param();
} else {
clear_has_reshape_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.reshape_param)
}
// optional .opencv_caffe.ROIPoolingParameter roi_pooling_param = 8266711;
bool LayerParameter::has_roi_pooling_param() const {
return (_has_bits_[1] & 0x00800000u) != 0;
}
void LayerParameter::set_has_roi_pooling_param() {
_has_bits_[1] |= 0x00800000u;
}
void LayerParameter::clear_has_roi_pooling_param() {
_has_bits_[1] &= ~0x00800000u;
}
void LayerParameter::clear_roi_pooling_param() {
if (roi_pooling_param_ != NULL) roi_pooling_param_->::opencv_caffe::ROIPoolingParameter::Clear();
clear_has_roi_pooling_param();
}
const ::opencv_caffe::ROIPoolingParameter& LayerParameter::roi_pooling_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.roi_pooling_param)
return roi_pooling_param_ != NULL ? *roi_pooling_param_
: *::opencv_caffe::ROIPoolingParameter::internal_default_instance();
}
::opencv_caffe::ROIPoolingParameter* LayerParameter::mutable_roi_pooling_param() {
set_has_roi_pooling_param();
if (roi_pooling_param_ == NULL) {
roi_pooling_param_ = new ::opencv_caffe::ROIPoolingParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.roi_pooling_param)
return roi_pooling_param_;
}
::opencv_caffe::ROIPoolingParameter* LayerParameter::release_roi_pooling_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.roi_pooling_param)
clear_has_roi_pooling_param();
::opencv_caffe::ROIPoolingParameter* temp = roi_pooling_param_;
roi_pooling_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_roi_pooling_param(::opencv_caffe::ROIPoolingParameter* roi_pooling_param) {
delete roi_pooling_param_;
roi_pooling_param_ = roi_pooling_param;
if (roi_pooling_param) {
set_has_roi_pooling_param();
} else {
clear_has_roi_pooling_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.roi_pooling_param)
}
// optional .opencv_caffe.ScaleParameter scale_param = 142;
bool LayerParameter::has_scale_param() const {
return (_has_bits_[1] & 0x01000000u) != 0;
}
void LayerParameter::set_has_scale_param() {
_has_bits_[1] |= 0x01000000u;
}
void LayerParameter::clear_has_scale_param() {
_has_bits_[1] &= ~0x01000000u;
}
void LayerParameter::clear_scale_param() {
if (scale_param_ != NULL) scale_param_->::opencv_caffe::ScaleParameter::Clear();
clear_has_scale_param();
}
const ::opencv_caffe::ScaleParameter& LayerParameter::scale_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.scale_param)
return scale_param_ != NULL ? *scale_param_
: *::opencv_caffe::ScaleParameter::internal_default_instance();
}
::opencv_caffe::ScaleParameter* LayerParameter::mutable_scale_param() {
set_has_scale_param();
if (scale_param_ == NULL) {
scale_param_ = new ::opencv_caffe::ScaleParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.scale_param)
return scale_param_;
}
::opencv_caffe::ScaleParameter* LayerParameter::release_scale_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.scale_param)
clear_has_scale_param();
::opencv_caffe::ScaleParameter* temp = scale_param_;
scale_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_scale_param(::opencv_caffe::ScaleParameter* scale_param) {
delete scale_param_;
scale_param_ = scale_param;
if (scale_param) {
set_has_scale_param();
} else {
clear_has_scale_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.scale_param)
}
// optional .opencv_caffe.SigmoidParameter sigmoid_param = 124;
bool LayerParameter::has_sigmoid_param() const {
return (_has_bits_[1] & 0x02000000u) != 0;
}
void LayerParameter::set_has_sigmoid_param() {
_has_bits_[1] |= 0x02000000u;
}
void LayerParameter::clear_has_sigmoid_param() {
_has_bits_[1] &= ~0x02000000u;
}
void LayerParameter::clear_sigmoid_param() {
if (sigmoid_param_ != NULL) sigmoid_param_->::opencv_caffe::SigmoidParameter::Clear();
clear_has_sigmoid_param();
}
const ::opencv_caffe::SigmoidParameter& LayerParameter::sigmoid_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.sigmoid_param)
return sigmoid_param_ != NULL ? *sigmoid_param_
: *::opencv_caffe::SigmoidParameter::internal_default_instance();
}
::opencv_caffe::SigmoidParameter* LayerParameter::mutable_sigmoid_param() {
set_has_sigmoid_param();
if (sigmoid_param_ == NULL) {
sigmoid_param_ = new ::opencv_caffe::SigmoidParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.sigmoid_param)
return sigmoid_param_;
}
::opencv_caffe::SigmoidParameter* LayerParameter::release_sigmoid_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.sigmoid_param)
clear_has_sigmoid_param();
::opencv_caffe::SigmoidParameter* temp = sigmoid_param_;
sigmoid_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_sigmoid_param(::opencv_caffe::SigmoidParameter* sigmoid_param) {
delete sigmoid_param_;
sigmoid_param_ = sigmoid_param;
if (sigmoid_param) {
set_has_sigmoid_param();
} else {
clear_has_sigmoid_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.sigmoid_param)
}
// optional .opencv_caffe.SoftmaxParameter softmax_param = 125;
bool LayerParameter::has_softmax_param() const {
return (_has_bits_[1] & 0x04000000u) != 0;
}
void LayerParameter::set_has_softmax_param() {
_has_bits_[1] |= 0x04000000u;
}
void LayerParameter::clear_has_softmax_param() {
_has_bits_[1] &= ~0x04000000u;
}
void LayerParameter::clear_softmax_param() {
if (softmax_param_ != NULL) softmax_param_->::opencv_caffe::SoftmaxParameter::Clear();
clear_has_softmax_param();
}
const ::opencv_caffe::SoftmaxParameter& LayerParameter::softmax_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.softmax_param)
return softmax_param_ != NULL ? *softmax_param_
: *::opencv_caffe::SoftmaxParameter::internal_default_instance();
}
::opencv_caffe::SoftmaxParameter* LayerParameter::mutable_softmax_param() {
set_has_softmax_param();
if (softmax_param_ == NULL) {
softmax_param_ = new ::opencv_caffe::SoftmaxParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.softmax_param)
return softmax_param_;
}
::opencv_caffe::SoftmaxParameter* LayerParameter::release_softmax_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.softmax_param)
clear_has_softmax_param();
::opencv_caffe::SoftmaxParameter* temp = softmax_param_;
softmax_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_softmax_param(::opencv_caffe::SoftmaxParameter* softmax_param) {
delete softmax_param_;
softmax_param_ = softmax_param;
if (softmax_param) {
set_has_softmax_param();
} else {
clear_has_softmax_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.softmax_param)
}
// optional .opencv_caffe.SPPParameter spp_param = 132;
bool LayerParameter::has_spp_param() const {
return (_has_bits_[1] & 0x08000000u) != 0;
}
void LayerParameter::set_has_spp_param() {
_has_bits_[1] |= 0x08000000u;
}
void LayerParameter::clear_has_spp_param() {
_has_bits_[1] &= ~0x08000000u;
}
void LayerParameter::clear_spp_param() {
if (spp_param_ != NULL) spp_param_->::opencv_caffe::SPPParameter::Clear();
clear_has_spp_param();
}
const ::opencv_caffe::SPPParameter& LayerParameter::spp_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.spp_param)
return spp_param_ != NULL ? *spp_param_
: *::opencv_caffe::SPPParameter::internal_default_instance();
}
::opencv_caffe::SPPParameter* LayerParameter::mutable_spp_param() {
set_has_spp_param();
if (spp_param_ == NULL) {
spp_param_ = new ::opencv_caffe::SPPParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.spp_param)
return spp_param_;
}
::opencv_caffe::SPPParameter* LayerParameter::release_spp_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.spp_param)
clear_has_spp_param();
::opencv_caffe::SPPParameter* temp = spp_param_;
spp_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_spp_param(::opencv_caffe::SPPParameter* spp_param) {
delete spp_param_;
spp_param_ = spp_param;
if (spp_param) {
set_has_spp_param();
} else {
clear_has_spp_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.spp_param)
}
// optional .opencv_caffe.SliceParameter slice_param = 126;
bool LayerParameter::has_slice_param() const {
return (_has_bits_[1] & 0x10000000u) != 0;
}
void LayerParameter::set_has_slice_param() {
_has_bits_[1] |= 0x10000000u;
}
void LayerParameter::clear_has_slice_param() {
_has_bits_[1] &= ~0x10000000u;
}
void LayerParameter::clear_slice_param() {
if (slice_param_ != NULL) slice_param_->::opencv_caffe::SliceParameter::Clear();
clear_has_slice_param();
}
const ::opencv_caffe::SliceParameter& LayerParameter::slice_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.slice_param)
return slice_param_ != NULL ? *slice_param_
: *::opencv_caffe::SliceParameter::internal_default_instance();
}
::opencv_caffe::SliceParameter* LayerParameter::mutable_slice_param() {
set_has_slice_param();
if (slice_param_ == NULL) {
slice_param_ = new ::opencv_caffe::SliceParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.slice_param)
return slice_param_;
}
::opencv_caffe::SliceParameter* LayerParameter::release_slice_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.slice_param)
clear_has_slice_param();
::opencv_caffe::SliceParameter* temp = slice_param_;
slice_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_slice_param(::opencv_caffe::SliceParameter* slice_param) {
delete slice_param_;
slice_param_ = slice_param;
if (slice_param) {
set_has_slice_param();
} else {
clear_has_slice_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.slice_param)
}
// optional .opencv_caffe.TanHParameter tanh_param = 127;
bool LayerParameter::has_tanh_param() const {
return (_has_bits_[1] & 0x20000000u) != 0;
}
void LayerParameter::set_has_tanh_param() {
_has_bits_[1] |= 0x20000000u;
}
void LayerParameter::clear_has_tanh_param() {
_has_bits_[1] &= ~0x20000000u;
}
void LayerParameter::clear_tanh_param() {
if (tanh_param_ != NULL) tanh_param_->::opencv_caffe::TanHParameter::Clear();
clear_has_tanh_param();
}
const ::opencv_caffe::TanHParameter& LayerParameter::tanh_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.tanh_param)
return tanh_param_ != NULL ? *tanh_param_
: *::opencv_caffe::TanHParameter::internal_default_instance();
}
::opencv_caffe::TanHParameter* LayerParameter::mutable_tanh_param() {
set_has_tanh_param();
if (tanh_param_ == NULL) {
tanh_param_ = new ::opencv_caffe::TanHParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.tanh_param)
return tanh_param_;
}
::opencv_caffe::TanHParameter* LayerParameter::release_tanh_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.tanh_param)
clear_has_tanh_param();
::opencv_caffe::TanHParameter* temp = tanh_param_;
tanh_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_tanh_param(::opencv_caffe::TanHParameter* tanh_param) {
delete tanh_param_;
tanh_param_ = tanh_param;
if (tanh_param) {
set_has_tanh_param();
} else {
clear_has_tanh_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.tanh_param)
}
// optional .opencv_caffe.ThresholdParameter threshold_param = 128;
bool LayerParameter::has_threshold_param() const {
return (_has_bits_[1] & 0x40000000u) != 0;
}
void LayerParameter::set_has_threshold_param() {
_has_bits_[1] |= 0x40000000u;
}
void LayerParameter::clear_has_threshold_param() {
_has_bits_[1] &= ~0x40000000u;
}
void LayerParameter::clear_threshold_param() {
if (threshold_param_ != NULL) threshold_param_->::opencv_caffe::ThresholdParameter::Clear();
clear_has_threshold_param();
}
const ::opencv_caffe::ThresholdParameter& LayerParameter::threshold_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.threshold_param)
return threshold_param_ != NULL ? *threshold_param_
: *::opencv_caffe::ThresholdParameter::internal_default_instance();
}
::opencv_caffe::ThresholdParameter* LayerParameter::mutable_threshold_param() {
set_has_threshold_param();
if (threshold_param_ == NULL) {
threshold_param_ = new ::opencv_caffe::ThresholdParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.threshold_param)
return threshold_param_;
}
::opencv_caffe::ThresholdParameter* LayerParameter::release_threshold_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.threshold_param)
clear_has_threshold_param();
::opencv_caffe::ThresholdParameter* temp = threshold_param_;
threshold_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_threshold_param(::opencv_caffe::ThresholdParameter* threshold_param) {
delete threshold_param_;
threshold_param_ = threshold_param;
if (threshold_param) {
set_has_threshold_param();
} else {
clear_has_threshold_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.threshold_param)
}
// optional .opencv_caffe.TileParameter tile_param = 138;
bool LayerParameter::has_tile_param() const {
return (_has_bits_[1] & 0x80000000u) != 0;
}
void LayerParameter::set_has_tile_param() {
_has_bits_[1] |= 0x80000000u;
}
void LayerParameter::clear_has_tile_param() {
_has_bits_[1] &= ~0x80000000u;
}
void LayerParameter::clear_tile_param() {
if (tile_param_ != NULL) tile_param_->::opencv_caffe::TileParameter::Clear();
clear_has_tile_param();
}
const ::opencv_caffe::TileParameter& LayerParameter::tile_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.tile_param)
return tile_param_ != NULL ? *tile_param_
: *::opencv_caffe::TileParameter::internal_default_instance();
}
::opencv_caffe::TileParameter* LayerParameter::mutable_tile_param() {
set_has_tile_param();
if (tile_param_ == NULL) {
tile_param_ = new ::opencv_caffe::TileParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.tile_param)
return tile_param_;
}
::opencv_caffe::TileParameter* LayerParameter::release_tile_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.tile_param)
clear_has_tile_param();
::opencv_caffe::TileParameter* temp = tile_param_;
tile_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_tile_param(::opencv_caffe::TileParameter* tile_param) {
delete tile_param_;
tile_param_ = tile_param;
if (tile_param) {
set_has_tile_param();
} else {
clear_has_tile_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.tile_param)
}
// optional .opencv_caffe.WindowDataParameter window_data_param = 129;
bool LayerParameter::has_window_data_param() const {
return (_has_bits_[2] & 0x00000001u) != 0;
}
void LayerParameter::set_has_window_data_param() {
_has_bits_[2] |= 0x00000001u;
}
void LayerParameter::clear_has_window_data_param() {
_has_bits_[2] &= ~0x00000001u;
}
void LayerParameter::clear_window_data_param() {
if (window_data_param_ != NULL) window_data_param_->::opencv_caffe::WindowDataParameter::Clear();
clear_has_window_data_param();
}
const ::opencv_caffe::WindowDataParameter& LayerParameter::window_data_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LayerParameter.window_data_param)
return window_data_param_ != NULL ? *window_data_param_
: *::opencv_caffe::WindowDataParameter::internal_default_instance();
}
::opencv_caffe::WindowDataParameter* LayerParameter::mutable_window_data_param() {
set_has_window_data_param();
if (window_data_param_ == NULL) {
window_data_param_ = new ::opencv_caffe::WindowDataParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.LayerParameter.window_data_param)
return window_data_param_;
}
::opencv_caffe::WindowDataParameter* LayerParameter::release_window_data_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.LayerParameter.window_data_param)
clear_has_window_data_param();
::opencv_caffe::WindowDataParameter* temp = window_data_param_;
window_data_param_ = NULL;
return temp;
}
void LayerParameter::set_allocated_window_data_param(::opencv_caffe::WindowDataParameter* window_data_param) {
delete window_data_param_;
window_data_param_ = window_data_param;
if (window_data_param) {
set_has_window_data_param();
} else {
clear_has_window_data_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.LayerParameter.window_data_param)
}
inline const LayerParameter* LayerParameter::internal_default_instance() {
return &LayerParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int TransformationParameter::kScaleFieldNumber;
const int TransformationParameter::kMirrorFieldNumber;
const int TransformationParameter::kCropSizeFieldNumber;
const int TransformationParameter::kMeanFileFieldNumber;
const int TransformationParameter::kMeanValueFieldNumber;
const int TransformationParameter::kForceColorFieldNumber;
const int TransformationParameter::kForceGrayFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
TransformationParameter::TransformationParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.TransformationParameter)
}
void TransformationParameter::InitAsDefaultInstance() {
}
TransformationParameter::TransformationParameter(const TransformationParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.TransformationParameter)
}
void TransformationParameter::SharedCtor() {
_cached_size_ = 0;
mean_file_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
::memset(&crop_size_, 0, reinterpret_cast<char*>(&force_gray_) -
reinterpret_cast<char*>(&crop_size_) + sizeof(force_gray_));
scale_ = 1;
}
TransformationParameter::~TransformationParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.TransformationParameter)
SharedDtor();
}
void TransformationParameter::SharedDtor() {
mean_file_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void TransformationParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* TransformationParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return TransformationParameter_descriptor_;
}
const TransformationParameter& TransformationParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<TransformationParameter> TransformationParameter_default_instance_;
TransformationParameter* TransformationParameter::New(::google::protobuf::Arena* arena) const {
TransformationParameter* n = new TransformationParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void TransformationParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.TransformationParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(TransformationParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<TransformationParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
if (_has_bits_[0 / 32] & 111u) {
ZR_(crop_size_, force_gray_);
scale_ = 1;
if (has_mean_file()) {
mean_file_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
}
#undef ZR_HELPER_
#undef ZR_
mean_value_.Clear();
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool TransformationParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.TransformationParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional float scale = 1 [default = 1];
case 1: {
if (tag == 13) {
set_has_scale();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &scale_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_mirror;
break;
}
// optional bool mirror = 2 [default = false];
case 2: {
if (tag == 16) {
parse_mirror:
set_has_mirror();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &mirror_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(24)) goto parse_crop_size;
break;
}
// optional uint32 crop_size = 3 [default = 0];
case 3: {
if (tag == 24) {
parse_crop_size:
set_has_crop_size();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &crop_size_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(34)) goto parse_mean_file;
break;
}
// optional string mean_file = 4;
case 4: {
if (tag == 34) {
parse_mean_file:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_mean_file()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->mean_file().data(), this->mean_file().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.TransformationParameter.mean_file");
} else {
goto handle_unusual;
}
if (input->ExpectTag(45)) goto parse_mean_value;
break;
}
// repeated float mean_value = 5;
case 5: {
if (tag == 45) {
parse_mean_value:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
1, 45, input, this->mutable_mean_value())));
} else if (tag == 42) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, this->mutable_mean_value())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(45)) goto parse_mean_value;
if (input->ExpectTag(48)) goto parse_force_color;
break;
}
// optional bool force_color = 6 [default = false];
case 6: {
if (tag == 48) {
parse_force_color:
set_has_force_color();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &force_color_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(56)) goto parse_force_gray;
break;
}
// optional bool force_gray = 7 [default = false];
case 7: {
if (tag == 56) {
parse_force_gray:
set_has_force_gray();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &force_gray_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.TransformationParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.TransformationParameter)
return false;
#undef DO_
}
void TransformationParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.TransformationParameter)
// optional float scale = 1 [default = 1];
if (has_scale()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(1, this->scale(), output);
}
// optional bool mirror = 2 [default = false];
if (has_mirror()) {
::google::protobuf::internal::WireFormatLite::WriteBool(2, this->mirror(), output);
}
// optional uint32 crop_size = 3 [default = 0];
if (has_crop_size()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(3, this->crop_size(), output);
}
// optional string mean_file = 4;
if (has_mean_file()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->mean_file().data(), this->mean_file().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.TransformationParameter.mean_file");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
4, this->mean_file(), output);
}
// repeated float mean_value = 5;
for (int i = 0; i < this->mean_value_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteFloat(
5, this->mean_value(i), output);
}
// optional bool force_color = 6 [default = false];
if (has_force_color()) {
::google::protobuf::internal::WireFormatLite::WriteBool(6, this->force_color(), output);
}
// optional bool force_gray = 7 [default = false];
if (has_force_gray()) {
::google::protobuf::internal::WireFormatLite::WriteBool(7, this->force_gray(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.TransformationParameter)
}
::google::protobuf::uint8* TransformationParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.TransformationParameter)
// optional float scale = 1 [default = 1];
if (has_scale()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(1, this->scale(), target);
}
// optional bool mirror = 2 [default = false];
if (has_mirror()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(2, this->mirror(), target);
}
// optional uint32 crop_size = 3 [default = 0];
if (has_crop_size()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(3, this->crop_size(), target);
}
// optional string mean_file = 4;
if (has_mean_file()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->mean_file().data(), this->mean_file().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.TransformationParameter.mean_file");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
4, this->mean_file(), target);
}
// repeated float mean_value = 5;
for (int i = 0; i < this->mean_value_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteFloatToArray(5, this->mean_value(i), target);
}
// optional bool force_color = 6 [default = false];
if (has_force_color()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(6, this->force_color(), target);
}
// optional bool force_gray = 7 [default = false];
if (has_force_gray()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(7, this->force_gray(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.TransformationParameter)
return target;
}
size_t TransformationParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.TransformationParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 111u) {
// optional float scale = 1 [default = 1];
if (has_scale()) {
total_size += 1 + 4;
}
// optional bool mirror = 2 [default = false];
if (has_mirror()) {
total_size += 1 + 1;
}
// optional uint32 crop_size = 3 [default = 0];
if (has_crop_size()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->crop_size());
}
// optional string mean_file = 4;
if (has_mean_file()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->mean_file());
}
// optional bool force_color = 6 [default = false];
if (has_force_color()) {
total_size += 1 + 1;
}
// optional bool force_gray = 7 [default = false];
if (has_force_gray()) {
total_size += 1 + 1;
}
}
// repeated float mean_value = 5;
{
size_t data_size = 0;
unsigned int count = this->mean_value_size();
data_size = 4UL * count;
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->mean_value_size());
total_size += data_size;
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void TransformationParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.TransformationParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const TransformationParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const TransformationParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.TransformationParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.TransformationParameter)
UnsafeMergeFrom(*source);
}
}
void TransformationParameter::MergeFrom(const TransformationParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.TransformationParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void TransformationParameter::UnsafeMergeFrom(const TransformationParameter& from) {
GOOGLE_DCHECK(&from != this);
mean_value_.UnsafeMergeFrom(from.mean_value_);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_scale()) {
set_scale(from.scale());
}
if (from.has_mirror()) {
set_mirror(from.mirror());
}
if (from.has_crop_size()) {
set_crop_size(from.crop_size());
}
if (from.has_mean_file()) {
set_has_mean_file();
mean_file_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.mean_file_);
}
if (from.has_force_color()) {
set_force_color(from.force_color());
}
if (from.has_force_gray()) {
set_force_gray(from.force_gray());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void TransformationParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.TransformationParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void TransformationParameter::CopyFrom(const TransformationParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.TransformationParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool TransformationParameter::IsInitialized() const {
return true;
}
void TransformationParameter::Swap(TransformationParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void TransformationParameter::InternalSwap(TransformationParameter* other) {
std::swap(scale_, other->scale_);
std::swap(mirror_, other->mirror_);
std::swap(crop_size_, other->crop_size_);
mean_file_.Swap(&other->mean_file_);
mean_value_.UnsafeArenaSwap(&other->mean_value_);
std::swap(force_color_, other->force_color_);
std::swap(force_gray_, other->force_gray_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata TransformationParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = TransformationParameter_descriptor_;
metadata.reflection = TransformationParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// TransformationParameter
// optional float scale = 1 [default = 1];
bool TransformationParameter::has_scale() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void TransformationParameter::set_has_scale() {
_has_bits_[0] |= 0x00000001u;
}
void TransformationParameter::clear_has_scale() {
_has_bits_[0] &= ~0x00000001u;
}
void TransformationParameter::clear_scale() {
scale_ = 1;
clear_has_scale();
}
float TransformationParameter::scale() const {
// @@protoc_insertion_point(field_get:opencv_caffe.TransformationParameter.scale)
return scale_;
}
void TransformationParameter::set_scale(float value) {
set_has_scale();
scale_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.TransformationParameter.scale)
}
// optional bool mirror = 2 [default = false];
bool TransformationParameter::has_mirror() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void TransformationParameter::set_has_mirror() {
_has_bits_[0] |= 0x00000002u;
}
void TransformationParameter::clear_has_mirror() {
_has_bits_[0] &= ~0x00000002u;
}
void TransformationParameter::clear_mirror() {
mirror_ = false;
clear_has_mirror();
}
bool TransformationParameter::mirror() const {
// @@protoc_insertion_point(field_get:opencv_caffe.TransformationParameter.mirror)
return mirror_;
}
void TransformationParameter::set_mirror(bool value) {
set_has_mirror();
mirror_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.TransformationParameter.mirror)
}
// optional uint32 crop_size = 3 [default = 0];
bool TransformationParameter::has_crop_size() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void TransformationParameter::set_has_crop_size() {
_has_bits_[0] |= 0x00000004u;
}
void TransformationParameter::clear_has_crop_size() {
_has_bits_[0] &= ~0x00000004u;
}
void TransformationParameter::clear_crop_size() {
crop_size_ = 0u;
clear_has_crop_size();
}
::google::protobuf::uint32 TransformationParameter::crop_size() const {
// @@protoc_insertion_point(field_get:opencv_caffe.TransformationParameter.crop_size)
return crop_size_;
}
void TransformationParameter::set_crop_size(::google::protobuf::uint32 value) {
set_has_crop_size();
crop_size_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.TransformationParameter.crop_size)
}
// optional string mean_file = 4;
bool TransformationParameter::has_mean_file() const {
return (_has_bits_[0] & 0x00000008u) != 0;
}
void TransformationParameter::set_has_mean_file() {
_has_bits_[0] |= 0x00000008u;
}
void TransformationParameter::clear_has_mean_file() {
_has_bits_[0] &= ~0x00000008u;
}
void TransformationParameter::clear_mean_file() {
mean_file_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_mean_file();
}
const ::std::string& TransformationParameter::mean_file() const {
// @@protoc_insertion_point(field_get:opencv_caffe.TransformationParameter.mean_file)
return mean_file_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void TransformationParameter::set_mean_file(const ::std::string& value) {
set_has_mean_file();
mean_file_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.TransformationParameter.mean_file)
}
void TransformationParameter::set_mean_file(const char* value) {
set_has_mean_file();
mean_file_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.TransformationParameter.mean_file)
}
void TransformationParameter::set_mean_file(const char* value, size_t size) {
set_has_mean_file();
mean_file_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.TransformationParameter.mean_file)
}
::std::string* TransformationParameter::mutable_mean_file() {
set_has_mean_file();
// @@protoc_insertion_point(field_mutable:opencv_caffe.TransformationParameter.mean_file)
return mean_file_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* TransformationParameter::release_mean_file() {
// @@protoc_insertion_point(field_release:opencv_caffe.TransformationParameter.mean_file)
clear_has_mean_file();
return mean_file_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void TransformationParameter::set_allocated_mean_file(::std::string* mean_file) {
if (mean_file != NULL) {
set_has_mean_file();
} else {
clear_has_mean_file();
}
mean_file_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), mean_file);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.TransformationParameter.mean_file)
}
// repeated float mean_value = 5;
int TransformationParameter::mean_value_size() const {
return mean_value_.size();
}
void TransformationParameter::clear_mean_value() {
mean_value_.Clear();
}
float TransformationParameter::mean_value(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.TransformationParameter.mean_value)
return mean_value_.Get(index);
}
void TransformationParameter::set_mean_value(int index, float value) {
mean_value_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.TransformationParameter.mean_value)
}
void TransformationParameter::add_mean_value(float value) {
mean_value_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.TransformationParameter.mean_value)
}
const ::google::protobuf::RepeatedField< float >&
TransformationParameter::mean_value() const {
// @@protoc_insertion_point(field_list:opencv_caffe.TransformationParameter.mean_value)
return mean_value_;
}
::google::protobuf::RepeatedField< float >*
TransformationParameter::mutable_mean_value() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.TransformationParameter.mean_value)
return &mean_value_;
}
// optional bool force_color = 6 [default = false];
bool TransformationParameter::has_force_color() const {
return (_has_bits_[0] & 0x00000020u) != 0;
}
void TransformationParameter::set_has_force_color() {
_has_bits_[0] |= 0x00000020u;
}
void TransformationParameter::clear_has_force_color() {
_has_bits_[0] &= ~0x00000020u;
}
void TransformationParameter::clear_force_color() {
force_color_ = false;
clear_has_force_color();
}
bool TransformationParameter::force_color() const {
// @@protoc_insertion_point(field_get:opencv_caffe.TransformationParameter.force_color)
return force_color_;
}
void TransformationParameter::set_force_color(bool value) {
set_has_force_color();
force_color_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.TransformationParameter.force_color)
}
// optional bool force_gray = 7 [default = false];
bool TransformationParameter::has_force_gray() const {
return (_has_bits_[0] & 0x00000040u) != 0;
}
void TransformationParameter::set_has_force_gray() {
_has_bits_[0] |= 0x00000040u;
}
void TransformationParameter::clear_has_force_gray() {
_has_bits_[0] &= ~0x00000040u;
}
void TransformationParameter::clear_force_gray() {
force_gray_ = false;
clear_has_force_gray();
}
bool TransformationParameter::force_gray() const {
// @@protoc_insertion_point(field_get:opencv_caffe.TransformationParameter.force_gray)
return force_gray_;
}
void TransformationParameter::set_force_gray(bool value) {
set_has_force_gray();
force_gray_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.TransformationParameter.force_gray)
}
inline const TransformationParameter* TransformationParameter::internal_default_instance() {
return &TransformationParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
const ::google::protobuf::EnumDescriptor* LossParameter_NormalizationMode_descriptor() {
protobuf_AssignDescriptorsOnce();
return LossParameter_NormalizationMode_descriptor_;
}
bool LossParameter_NormalizationMode_IsValid(int value) {
switch (value) {
case 0:
case 1:
case 2:
case 3:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const LossParameter_NormalizationMode LossParameter::FULL;
const LossParameter_NormalizationMode LossParameter::VALID;
const LossParameter_NormalizationMode LossParameter::BATCH_SIZE;
const LossParameter_NormalizationMode LossParameter::NONE;
const LossParameter_NormalizationMode LossParameter::NormalizationMode_MIN;
const LossParameter_NormalizationMode LossParameter::NormalizationMode_MAX;
const int LossParameter::NormalizationMode_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int LossParameter::kIgnoreLabelFieldNumber;
const int LossParameter::kNormalizationFieldNumber;
const int LossParameter::kNormalizeFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
LossParameter::LossParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.LossParameter)
}
void LossParameter::InitAsDefaultInstance() {
}
LossParameter::LossParameter(const LossParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.LossParameter)
}
void LossParameter::SharedCtor() {
_cached_size_ = 0;
::memset(&ignore_label_, 0, reinterpret_cast<char*>(&normalize_) -
reinterpret_cast<char*>(&ignore_label_) + sizeof(normalize_));
normalization_ = 1;
}
LossParameter::~LossParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.LossParameter)
SharedDtor();
}
void LossParameter::SharedDtor() {
}
void LossParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* LossParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return LossParameter_descriptor_;
}
const LossParameter& LossParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<LossParameter> LossParameter_default_instance_;
LossParameter* LossParameter::New(::google::protobuf::Arena* arena) const {
LossParameter* n = new LossParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void LossParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.LossParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(LossParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<LossParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
if (_has_bits_[0 / 32] & 7u) {
ZR_(ignore_label_, normalize_);
normalization_ = 1;
}
#undef ZR_HELPER_
#undef ZR_
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool LossParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.LossParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional int32 ignore_label = 1;
case 1: {
if (tag == 8) {
set_has_ignore_label();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &ignore_label_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_normalize;
break;
}
// optional bool normalize = 2;
case 2: {
if (tag == 16) {
parse_normalize:
set_has_normalize();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &normalize_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(24)) goto parse_normalization;
break;
}
// optional .opencv_caffe.LossParameter.NormalizationMode normalization = 3 [default = VALID];
case 3: {
if (tag == 24) {
parse_normalization:
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::LossParameter_NormalizationMode_IsValid(value)) {
set_normalization(static_cast< ::opencv_caffe::LossParameter_NormalizationMode >(value));
} else {
mutable_unknown_fields()->AddVarint(3, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.LossParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.LossParameter)
return false;
#undef DO_
}
void LossParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.LossParameter)
// optional int32 ignore_label = 1;
if (has_ignore_label()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(1, this->ignore_label(), output);
}
// optional bool normalize = 2;
if (has_normalize()) {
::google::protobuf::internal::WireFormatLite::WriteBool(2, this->normalize(), output);
}
// optional .opencv_caffe.LossParameter.NormalizationMode normalization = 3 [default = VALID];
if (has_normalization()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
3, this->normalization(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.LossParameter)
}
::google::protobuf::uint8* LossParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.LossParameter)
// optional int32 ignore_label = 1;
if (has_ignore_label()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(1, this->ignore_label(), target);
}
// optional bool normalize = 2;
if (has_normalize()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(2, this->normalize(), target);
}
// optional .opencv_caffe.LossParameter.NormalizationMode normalization = 3 [default = VALID];
if (has_normalization()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
3, this->normalization(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.LossParameter)
return target;
}
size_t LossParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.LossParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 7u) {
// optional int32 ignore_label = 1;
if (has_ignore_label()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->ignore_label());
}
// optional .opencv_caffe.LossParameter.NormalizationMode normalization = 3 [default = VALID];
if (has_normalization()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->normalization());
}
// optional bool normalize = 2;
if (has_normalize()) {
total_size += 1 + 1;
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void LossParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.LossParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const LossParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const LossParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.LossParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.LossParameter)
UnsafeMergeFrom(*source);
}
}
void LossParameter::MergeFrom(const LossParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.LossParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void LossParameter::UnsafeMergeFrom(const LossParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_ignore_label()) {
set_ignore_label(from.ignore_label());
}
if (from.has_normalization()) {
set_normalization(from.normalization());
}
if (from.has_normalize()) {
set_normalize(from.normalize());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void LossParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.LossParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void LossParameter::CopyFrom(const LossParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.LossParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool LossParameter::IsInitialized() const {
return true;
}
void LossParameter::Swap(LossParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void LossParameter::InternalSwap(LossParameter* other) {
std::swap(ignore_label_, other->ignore_label_);
std::swap(normalization_, other->normalization_);
std::swap(normalize_, other->normalize_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata LossParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = LossParameter_descriptor_;
metadata.reflection = LossParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// LossParameter
// optional int32 ignore_label = 1;
bool LossParameter::has_ignore_label() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void LossParameter::set_has_ignore_label() {
_has_bits_[0] |= 0x00000001u;
}
void LossParameter::clear_has_ignore_label() {
_has_bits_[0] &= ~0x00000001u;
}
void LossParameter::clear_ignore_label() {
ignore_label_ = 0;
clear_has_ignore_label();
}
::google::protobuf::int32 LossParameter::ignore_label() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LossParameter.ignore_label)
return ignore_label_;
}
void LossParameter::set_ignore_label(::google::protobuf::int32 value) {
set_has_ignore_label();
ignore_label_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.LossParameter.ignore_label)
}
// optional .opencv_caffe.LossParameter.NormalizationMode normalization = 3 [default = VALID];
bool LossParameter::has_normalization() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void LossParameter::set_has_normalization() {
_has_bits_[0] |= 0x00000002u;
}
void LossParameter::clear_has_normalization() {
_has_bits_[0] &= ~0x00000002u;
}
void LossParameter::clear_normalization() {
normalization_ = 1;
clear_has_normalization();
}
::opencv_caffe::LossParameter_NormalizationMode LossParameter::normalization() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LossParameter.normalization)
return static_cast< ::opencv_caffe::LossParameter_NormalizationMode >(normalization_);
}
void LossParameter::set_normalization(::opencv_caffe::LossParameter_NormalizationMode value) {
assert(::opencv_caffe::LossParameter_NormalizationMode_IsValid(value));
set_has_normalization();
normalization_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.LossParameter.normalization)
}
// optional bool normalize = 2;
bool LossParameter::has_normalize() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void LossParameter::set_has_normalize() {
_has_bits_[0] |= 0x00000004u;
}
void LossParameter::clear_has_normalize() {
_has_bits_[0] &= ~0x00000004u;
}
void LossParameter::clear_normalize() {
normalize_ = false;
clear_has_normalize();
}
bool LossParameter::normalize() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LossParameter.normalize)
return normalize_;
}
void LossParameter::set_normalize(bool value) {
set_has_normalize();
normalize_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.LossParameter.normalize)
}
inline const LossParameter* LossParameter::internal_default_instance() {
return &LossParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int AccuracyParameter::kTopKFieldNumber;
const int AccuracyParameter::kAxisFieldNumber;
const int AccuracyParameter::kIgnoreLabelFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
AccuracyParameter::AccuracyParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.AccuracyParameter)
}
void AccuracyParameter::InitAsDefaultInstance() {
}
AccuracyParameter::AccuracyParameter(const AccuracyParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.AccuracyParameter)
}
void AccuracyParameter::SharedCtor() {
_cached_size_ = 0;
ignore_label_ = 0;
top_k_ = 1u;
axis_ = 1;
}
AccuracyParameter::~AccuracyParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.AccuracyParameter)
SharedDtor();
}
void AccuracyParameter::SharedDtor() {
}
void AccuracyParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* AccuracyParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return AccuracyParameter_descriptor_;
}
const AccuracyParameter& AccuracyParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<AccuracyParameter> AccuracyParameter_default_instance_;
AccuracyParameter* AccuracyParameter::New(::google::protobuf::Arena* arena) const {
AccuracyParameter* n = new AccuracyParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void AccuracyParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.AccuracyParameter)
if (_has_bits_[0 / 32] & 7u) {
top_k_ = 1u;
axis_ = 1;
ignore_label_ = 0;
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool AccuracyParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.AccuracyParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional uint32 top_k = 1 [default = 1];
case 1: {
if (tag == 8) {
set_has_top_k();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &top_k_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_axis;
break;
}
// optional int32 axis = 2 [default = 1];
case 2: {
if (tag == 16) {
parse_axis:
set_has_axis();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &axis_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(24)) goto parse_ignore_label;
break;
}
// optional int32 ignore_label = 3;
case 3: {
if (tag == 24) {
parse_ignore_label:
set_has_ignore_label();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &ignore_label_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.AccuracyParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.AccuracyParameter)
return false;
#undef DO_
}
void AccuracyParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.AccuracyParameter)
// optional uint32 top_k = 1 [default = 1];
if (has_top_k()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(1, this->top_k(), output);
}
// optional int32 axis = 2 [default = 1];
if (has_axis()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->axis(), output);
}
// optional int32 ignore_label = 3;
if (has_ignore_label()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(3, this->ignore_label(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.AccuracyParameter)
}
::google::protobuf::uint8* AccuracyParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.AccuracyParameter)
// optional uint32 top_k = 1 [default = 1];
if (has_top_k()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(1, this->top_k(), target);
}
// optional int32 axis = 2 [default = 1];
if (has_axis()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(2, this->axis(), target);
}
// optional int32 ignore_label = 3;
if (has_ignore_label()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(3, this->ignore_label(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.AccuracyParameter)
return target;
}
size_t AccuracyParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.AccuracyParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 7u) {
// optional uint32 top_k = 1 [default = 1];
if (has_top_k()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->top_k());
}
// optional int32 axis = 2 [default = 1];
if (has_axis()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->axis());
}
// optional int32 ignore_label = 3;
if (has_ignore_label()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->ignore_label());
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void AccuracyParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.AccuracyParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const AccuracyParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const AccuracyParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.AccuracyParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.AccuracyParameter)
UnsafeMergeFrom(*source);
}
}
void AccuracyParameter::MergeFrom(const AccuracyParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.AccuracyParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void AccuracyParameter::UnsafeMergeFrom(const AccuracyParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_top_k()) {
set_top_k(from.top_k());
}
if (from.has_axis()) {
set_axis(from.axis());
}
if (from.has_ignore_label()) {
set_ignore_label(from.ignore_label());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void AccuracyParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.AccuracyParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void AccuracyParameter::CopyFrom(const AccuracyParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.AccuracyParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool AccuracyParameter::IsInitialized() const {
return true;
}
void AccuracyParameter::Swap(AccuracyParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void AccuracyParameter::InternalSwap(AccuracyParameter* other) {
std::swap(top_k_, other->top_k_);
std::swap(axis_, other->axis_);
std::swap(ignore_label_, other->ignore_label_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata AccuracyParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = AccuracyParameter_descriptor_;
metadata.reflection = AccuracyParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// AccuracyParameter
// optional uint32 top_k = 1 [default = 1];
bool AccuracyParameter::has_top_k() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void AccuracyParameter::set_has_top_k() {
_has_bits_[0] |= 0x00000001u;
}
void AccuracyParameter::clear_has_top_k() {
_has_bits_[0] &= ~0x00000001u;
}
void AccuracyParameter::clear_top_k() {
top_k_ = 1u;
clear_has_top_k();
}
::google::protobuf::uint32 AccuracyParameter::top_k() const {
// @@protoc_insertion_point(field_get:opencv_caffe.AccuracyParameter.top_k)
return top_k_;
}
void AccuracyParameter::set_top_k(::google::protobuf::uint32 value) {
set_has_top_k();
top_k_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.AccuracyParameter.top_k)
}
// optional int32 axis = 2 [default = 1];
bool AccuracyParameter::has_axis() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void AccuracyParameter::set_has_axis() {
_has_bits_[0] |= 0x00000002u;
}
void AccuracyParameter::clear_has_axis() {
_has_bits_[0] &= ~0x00000002u;
}
void AccuracyParameter::clear_axis() {
axis_ = 1;
clear_has_axis();
}
::google::protobuf::int32 AccuracyParameter::axis() const {
// @@protoc_insertion_point(field_get:opencv_caffe.AccuracyParameter.axis)
return axis_;
}
void AccuracyParameter::set_axis(::google::protobuf::int32 value) {
set_has_axis();
axis_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.AccuracyParameter.axis)
}
// optional int32 ignore_label = 3;
bool AccuracyParameter::has_ignore_label() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void AccuracyParameter::set_has_ignore_label() {
_has_bits_[0] |= 0x00000004u;
}
void AccuracyParameter::clear_has_ignore_label() {
_has_bits_[0] &= ~0x00000004u;
}
void AccuracyParameter::clear_ignore_label() {
ignore_label_ = 0;
clear_has_ignore_label();
}
::google::protobuf::int32 AccuracyParameter::ignore_label() const {
// @@protoc_insertion_point(field_get:opencv_caffe.AccuracyParameter.ignore_label)
return ignore_label_;
}
void AccuracyParameter::set_ignore_label(::google::protobuf::int32 value) {
set_has_ignore_label();
ignore_label_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.AccuracyParameter.ignore_label)
}
inline const AccuracyParameter* AccuracyParameter::internal_default_instance() {
return &AccuracyParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int ArgMaxParameter::kOutMaxValFieldNumber;
const int ArgMaxParameter::kTopKFieldNumber;
const int ArgMaxParameter::kAxisFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
ArgMaxParameter::ArgMaxParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.ArgMaxParameter)
}
void ArgMaxParameter::InitAsDefaultInstance() {
}
ArgMaxParameter::ArgMaxParameter(const ArgMaxParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.ArgMaxParameter)
}
void ArgMaxParameter::SharedCtor() {
_cached_size_ = 0;
::memset(&out_max_val_, 0, reinterpret_cast<char*>(&axis_) -
reinterpret_cast<char*>(&out_max_val_) + sizeof(axis_));
top_k_ = 1u;
}
ArgMaxParameter::~ArgMaxParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.ArgMaxParameter)
SharedDtor();
}
void ArgMaxParameter::SharedDtor() {
}
void ArgMaxParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* ArgMaxParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return ArgMaxParameter_descriptor_;
}
const ArgMaxParameter& ArgMaxParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<ArgMaxParameter> ArgMaxParameter_default_instance_;
ArgMaxParameter* ArgMaxParameter::New(::google::protobuf::Arena* arena) const {
ArgMaxParameter* n = new ArgMaxParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void ArgMaxParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.ArgMaxParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(ArgMaxParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<ArgMaxParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
if (_has_bits_[0 / 32] & 7u) {
ZR_(out_max_val_, axis_);
top_k_ = 1u;
}
#undef ZR_HELPER_
#undef ZR_
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool ArgMaxParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.ArgMaxParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional bool out_max_val = 1 [default = false];
case 1: {
if (tag == 8) {
set_has_out_max_val();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &out_max_val_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_top_k;
break;
}
// optional uint32 top_k = 2 [default = 1];
case 2: {
if (tag == 16) {
parse_top_k:
set_has_top_k();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &top_k_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(24)) goto parse_axis;
break;
}
// optional int32 axis = 3;
case 3: {
if (tag == 24) {
parse_axis:
set_has_axis();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &axis_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.ArgMaxParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.ArgMaxParameter)
return false;
#undef DO_
}
void ArgMaxParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.ArgMaxParameter)
// optional bool out_max_val = 1 [default = false];
if (has_out_max_val()) {
::google::protobuf::internal::WireFormatLite::WriteBool(1, this->out_max_val(), output);
}
// optional uint32 top_k = 2 [default = 1];
if (has_top_k()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(2, this->top_k(), output);
}
// optional int32 axis = 3;
if (has_axis()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(3, this->axis(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.ArgMaxParameter)
}
::google::protobuf::uint8* ArgMaxParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.ArgMaxParameter)
// optional bool out_max_val = 1 [default = false];
if (has_out_max_val()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(1, this->out_max_val(), target);
}
// optional uint32 top_k = 2 [default = 1];
if (has_top_k()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(2, this->top_k(), target);
}
// optional int32 axis = 3;
if (has_axis()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(3, this->axis(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.ArgMaxParameter)
return target;
}
size_t ArgMaxParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.ArgMaxParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 7u) {
// optional bool out_max_val = 1 [default = false];
if (has_out_max_val()) {
total_size += 1 + 1;
}
// optional uint32 top_k = 2 [default = 1];
if (has_top_k()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->top_k());
}
// optional int32 axis = 3;
if (has_axis()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->axis());
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void ArgMaxParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.ArgMaxParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const ArgMaxParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const ArgMaxParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.ArgMaxParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.ArgMaxParameter)
UnsafeMergeFrom(*source);
}
}
void ArgMaxParameter::MergeFrom(const ArgMaxParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.ArgMaxParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void ArgMaxParameter::UnsafeMergeFrom(const ArgMaxParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_out_max_val()) {
set_out_max_val(from.out_max_val());
}
if (from.has_top_k()) {
set_top_k(from.top_k());
}
if (from.has_axis()) {
set_axis(from.axis());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void ArgMaxParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.ArgMaxParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void ArgMaxParameter::CopyFrom(const ArgMaxParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.ArgMaxParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool ArgMaxParameter::IsInitialized() const {
return true;
}
void ArgMaxParameter::Swap(ArgMaxParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void ArgMaxParameter::InternalSwap(ArgMaxParameter* other) {
std::swap(out_max_val_, other->out_max_val_);
std::swap(top_k_, other->top_k_);
std::swap(axis_, other->axis_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata ArgMaxParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = ArgMaxParameter_descriptor_;
metadata.reflection = ArgMaxParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// ArgMaxParameter
// optional bool out_max_val = 1 [default = false];
bool ArgMaxParameter::has_out_max_val() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void ArgMaxParameter::set_has_out_max_val() {
_has_bits_[0] |= 0x00000001u;
}
void ArgMaxParameter::clear_has_out_max_val() {
_has_bits_[0] &= ~0x00000001u;
}
void ArgMaxParameter::clear_out_max_val() {
out_max_val_ = false;
clear_has_out_max_val();
}
bool ArgMaxParameter::out_max_val() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ArgMaxParameter.out_max_val)
return out_max_val_;
}
void ArgMaxParameter::set_out_max_val(bool value) {
set_has_out_max_val();
out_max_val_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ArgMaxParameter.out_max_val)
}
// optional uint32 top_k = 2 [default = 1];
bool ArgMaxParameter::has_top_k() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void ArgMaxParameter::set_has_top_k() {
_has_bits_[0] |= 0x00000002u;
}
void ArgMaxParameter::clear_has_top_k() {
_has_bits_[0] &= ~0x00000002u;
}
void ArgMaxParameter::clear_top_k() {
top_k_ = 1u;
clear_has_top_k();
}
::google::protobuf::uint32 ArgMaxParameter::top_k() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ArgMaxParameter.top_k)
return top_k_;
}
void ArgMaxParameter::set_top_k(::google::protobuf::uint32 value) {
set_has_top_k();
top_k_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ArgMaxParameter.top_k)
}
// optional int32 axis = 3;
bool ArgMaxParameter::has_axis() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void ArgMaxParameter::set_has_axis() {
_has_bits_[0] |= 0x00000004u;
}
void ArgMaxParameter::clear_has_axis() {
_has_bits_[0] &= ~0x00000004u;
}
void ArgMaxParameter::clear_axis() {
axis_ = 0;
clear_has_axis();
}
::google::protobuf::int32 ArgMaxParameter::axis() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ArgMaxParameter.axis)
return axis_;
}
void ArgMaxParameter::set_axis(::google::protobuf::int32 value) {
set_has_axis();
axis_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ArgMaxParameter.axis)
}
inline const ArgMaxParameter* ArgMaxParameter::internal_default_instance() {
return &ArgMaxParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int ConcatParameter::kAxisFieldNumber;
const int ConcatParameter::kConcatDimFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
ConcatParameter::ConcatParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.ConcatParameter)
}
void ConcatParameter::InitAsDefaultInstance() {
}
ConcatParameter::ConcatParameter(const ConcatParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.ConcatParameter)
}
void ConcatParameter::SharedCtor() {
_cached_size_ = 0;
axis_ = 1;
concat_dim_ = 1u;
}
ConcatParameter::~ConcatParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.ConcatParameter)
SharedDtor();
}
void ConcatParameter::SharedDtor() {
}
void ConcatParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* ConcatParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return ConcatParameter_descriptor_;
}
const ConcatParameter& ConcatParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<ConcatParameter> ConcatParameter_default_instance_;
ConcatParameter* ConcatParameter::New(::google::protobuf::Arena* arena) const {
ConcatParameter* n = new ConcatParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void ConcatParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.ConcatParameter)
if (_has_bits_[0 / 32] & 3u) {
axis_ = 1;
concat_dim_ = 1u;
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool ConcatParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.ConcatParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional uint32 concat_dim = 1 [default = 1];
case 1: {
if (tag == 8) {
set_has_concat_dim();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &concat_dim_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_axis;
break;
}
// optional int32 axis = 2 [default = 1];
case 2: {
if (tag == 16) {
parse_axis:
set_has_axis();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &axis_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.ConcatParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.ConcatParameter)
return false;
#undef DO_
}
void ConcatParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.ConcatParameter)
// optional uint32 concat_dim = 1 [default = 1];
if (has_concat_dim()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(1, this->concat_dim(), output);
}
// optional int32 axis = 2 [default = 1];
if (has_axis()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->axis(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.ConcatParameter)
}
::google::protobuf::uint8* ConcatParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.ConcatParameter)
// optional uint32 concat_dim = 1 [default = 1];
if (has_concat_dim()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(1, this->concat_dim(), target);
}
// optional int32 axis = 2 [default = 1];
if (has_axis()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(2, this->axis(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.ConcatParameter)
return target;
}
size_t ConcatParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.ConcatParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 3u) {
// optional int32 axis = 2 [default = 1];
if (has_axis()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->axis());
}
// optional uint32 concat_dim = 1 [default = 1];
if (has_concat_dim()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->concat_dim());
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void ConcatParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.ConcatParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const ConcatParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const ConcatParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.ConcatParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.ConcatParameter)
UnsafeMergeFrom(*source);
}
}
void ConcatParameter::MergeFrom(const ConcatParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.ConcatParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void ConcatParameter::UnsafeMergeFrom(const ConcatParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_axis()) {
set_axis(from.axis());
}
if (from.has_concat_dim()) {
set_concat_dim(from.concat_dim());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void ConcatParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.ConcatParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void ConcatParameter::CopyFrom(const ConcatParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.ConcatParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool ConcatParameter::IsInitialized() const {
return true;
}
void ConcatParameter::Swap(ConcatParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void ConcatParameter::InternalSwap(ConcatParameter* other) {
std::swap(axis_, other->axis_);
std::swap(concat_dim_, other->concat_dim_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata ConcatParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = ConcatParameter_descriptor_;
metadata.reflection = ConcatParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// ConcatParameter
// optional int32 axis = 2 [default = 1];
bool ConcatParameter::has_axis() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void ConcatParameter::set_has_axis() {
_has_bits_[0] |= 0x00000001u;
}
void ConcatParameter::clear_has_axis() {
_has_bits_[0] &= ~0x00000001u;
}
void ConcatParameter::clear_axis() {
axis_ = 1;
clear_has_axis();
}
::google::protobuf::int32 ConcatParameter::axis() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ConcatParameter.axis)
return axis_;
}
void ConcatParameter::set_axis(::google::protobuf::int32 value) {
set_has_axis();
axis_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ConcatParameter.axis)
}
// optional uint32 concat_dim = 1 [default = 1];
bool ConcatParameter::has_concat_dim() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void ConcatParameter::set_has_concat_dim() {
_has_bits_[0] |= 0x00000002u;
}
void ConcatParameter::clear_has_concat_dim() {
_has_bits_[0] &= ~0x00000002u;
}
void ConcatParameter::clear_concat_dim() {
concat_dim_ = 1u;
clear_has_concat_dim();
}
::google::protobuf::uint32 ConcatParameter::concat_dim() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ConcatParameter.concat_dim)
return concat_dim_;
}
void ConcatParameter::set_concat_dim(::google::protobuf::uint32 value) {
set_has_concat_dim();
concat_dim_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ConcatParameter.concat_dim)
}
inline const ConcatParameter* ConcatParameter::internal_default_instance() {
return &ConcatParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int BatchNormParameter::kUseGlobalStatsFieldNumber;
const int BatchNormParameter::kMovingAverageFractionFieldNumber;
const int BatchNormParameter::kEpsFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
BatchNormParameter::BatchNormParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.BatchNormParameter)
}
void BatchNormParameter::InitAsDefaultInstance() {
}
BatchNormParameter::BatchNormParameter(const BatchNormParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.BatchNormParameter)
}
void BatchNormParameter::SharedCtor() {
_cached_size_ = 0;
use_global_stats_ = false;
moving_average_fraction_ = 0.999f;
eps_ = 1e-05f;
}
BatchNormParameter::~BatchNormParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.BatchNormParameter)
SharedDtor();
}
void BatchNormParameter::SharedDtor() {
}
void BatchNormParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* BatchNormParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return BatchNormParameter_descriptor_;
}
const BatchNormParameter& BatchNormParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<BatchNormParameter> BatchNormParameter_default_instance_;
BatchNormParameter* BatchNormParameter::New(::google::protobuf::Arena* arena) const {
BatchNormParameter* n = new BatchNormParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void BatchNormParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.BatchNormParameter)
if (_has_bits_[0 / 32] & 7u) {
use_global_stats_ = false;
moving_average_fraction_ = 0.999f;
eps_ = 1e-05f;
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool BatchNormParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.BatchNormParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional bool use_global_stats = 1;
case 1: {
if (tag == 8) {
set_has_use_global_stats();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &use_global_stats_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(21)) goto parse_moving_average_fraction;
break;
}
// optional float moving_average_fraction = 2 [default = 0.999];
case 2: {
if (tag == 21) {
parse_moving_average_fraction:
set_has_moving_average_fraction();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &moving_average_fraction_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(29)) goto parse_eps;
break;
}
// optional float eps = 3 [default = 1e-05];
case 3: {
if (tag == 29) {
parse_eps:
set_has_eps();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &eps_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.BatchNormParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.BatchNormParameter)
return false;
#undef DO_
}
void BatchNormParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.BatchNormParameter)
// optional bool use_global_stats = 1;
if (has_use_global_stats()) {
::google::protobuf::internal::WireFormatLite::WriteBool(1, this->use_global_stats(), output);
}
// optional float moving_average_fraction = 2 [default = 0.999];
if (has_moving_average_fraction()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(2, this->moving_average_fraction(), output);
}
// optional float eps = 3 [default = 1e-05];
if (has_eps()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(3, this->eps(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.BatchNormParameter)
}
::google::protobuf::uint8* BatchNormParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.BatchNormParameter)
// optional bool use_global_stats = 1;
if (has_use_global_stats()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(1, this->use_global_stats(), target);
}
// optional float moving_average_fraction = 2 [default = 0.999];
if (has_moving_average_fraction()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(2, this->moving_average_fraction(), target);
}
// optional float eps = 3 [default = 1e-05];
if (has_eps()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(3, this->eps(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.BatchNormParameter)
return target;
}
size_t BatchNormParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.BatchNormParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 7u) {
// optional bool use_global_stats = 1;
if (has_use_global_stats()) {
total_size += 1 + 1;
}
// optional float moving_average_fraction = 2 [default = 0.999];
if (has_moving_average_fraction()) {
total_size += 1 + 4;
}
// optional float eps = 3 [default = 1e-05];
if (has_eps()) {
total_size += 1 + 4;
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void BatchNormParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.BatchNormParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const BatchNormParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const BatchNormParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.BatchNormParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.BatchNormParameter)
UnsafeMergeFrom(*source);
}
}
void BatchNormParameter::MergeFrom(const BatchNormParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.BatchNormParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void BatchNormParameter::UnsafeMergeFrom(const BatchNormParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_use_global_stats()) {
set_use_global_stats(from.use_global_stats());
}
if (from.has_moving_average_fraction()) {
set_moving_average_fraction(from.moving_average_fraction());
}
if (from.has_eps()) {
set_eps(from.eps());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void BatchNormParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.BatchNormParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void BatchNormParameter::CopyFrom(const BatchNormParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.BatchNormParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool BatchNormParameter::IsInitialized() const {
return true;
}
void BatchNormParameter::Swap(BatchNormParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void BatchNormParameter::InternalSwap(BatchNormParameter* other) {
std::swap(use_global_stats_, other->use_global_stats_);
std::swap(moving_average_fraction_, other->moving_average_fraction_);
std::swap(eps_, other->eps_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata BatchNormParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = BatchNormParameter_descriptor_;
metadata.reflection = BatchNormParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// BatchNormParameter
// optional bool use_global_stats = 1;
bool BatchNormParameter::has_use_global_stats() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void BatchNormParameter::set_has_use_global_stats() {
_has_bits_[0] |= 0x00000001u;
}
void BatchNormParameter::clear_has_use_global_stats() {
_has_bits_[0] &= ~0x00000001u;
}
void BatchNormParameter::clear_use_global_stats() {
use_global_stats_ = false;
clear_has_use_global_stats();
}
bool BatchNormParameter::use_global_stats() const {
// @@protoc_insertion_point(field_get:opencv_caffe.BatchNormParameter.use_global_stats)
return use_global_stats_;
}
void BatchNormParameter::set_use_global_stats(bool value) {
set_has_use_global_stats();
use_global_stats_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.BatchNormParameter.use_global_stats)
}
// optional float moving_average_fraction = 2 [default = 0.999];
bool BatchNormParameter::has_moving_average_fraction() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void BatchNormParameter::set_has_moving_average_fraction() {
_has_bits_[0] |= 0x00000002u;
}
void BatchNormParameter::clear_has_moving_average_fraction() {
_has_bits_[0] &= ~0x00000002u;
}
void BatchNormParameter::clear_moving_average_fraction() {
moving_average_fraction_ = 0.999f;
clear_has_moving_average_fraction();
}
float BatchNormParameter::moving_average_fraction() const {
// @@protoc_insertion_point(field_get:opencv_caffe.BatchNormParameter.moving_average_fraction)
return moving_average_fraction_;
}
void BatchNormParameter::set_moving_average_fraction(float value) {
set_has_moving_average_fraction();
moving_average_fraction_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.BatchNormParameter.moving_average_fraction)
}
// optional float eps = 3 [default = 1e-05];
bool BatchNormParameter::has_eps() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void BatchNormParameter::set_has_eps() {
_has_bits_[0] |= 0x00000004u;
}
void BatchNormParameter::clear_has_eps() {
_has_bits_[0] &= ~0x00000004u;
}
void BatchNormParameter::clear_eps() {
eps_ = 1e-05f;
clear_has_eps();
}
float BatchNormParameter::eps() const {
// @@protoc_insertion_point(field_get:opencv_caffe.BatchNormParameter.eps)
return eps_;
}
void BatchNormParameter::set_eps(float value) {
set_has_eps();
eps_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.BatchNormParameter.eps)
}
inline const BatchNormParameter* BatchNormParameter::internal_default_instance() {
return &BatchNormParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int BiasParameter::kAxisFieldNumber;
const int BiasParameter::kNumAxesFieldNumber;
const int BiasParameter::kFillerFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
BiasParameter::BiasParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.BiasParameter)
}
void BiasParameter::InitAsDefaultInstance() {
filler_ = const_cast< ::opencv_caffe::FillerParameter*>(
::opencv_caffe::FillerParameter::internal_default_instance());
}
BiasParameter::BiasParameter(const BiasParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.BiasParameter)
}
void BiasParameter::SharedCtor() {
_cached_size_ = 0;
filler_ = NULL;
axis_ = 1;
num_axes_ = 1;
}
BiasParameter::~BiasParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.BiasParameter)
SharedDtor();
}
void BiasParameter::SharedDtor() {
if (this != &BiasParameter_default_instance_.get()) {
delete filler_;
}
}
void BiasParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* BiasParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return BiasParameter_descriptor_;
}
const BiasParameter& BiasParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<BiasParameter> BiasParameter_default_instance_;
BiasParameter* BiasParameter::New(::google::protobuf::Arena* arena) const {
BiasParameter* n = new BiasParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void BiasParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.BiasParameter)
if (_has_bits_[0 / 32] & 7u) {
axis_ = 1;
num_axes_ = 1;
if (has_filler()) {
if (filler_ != NULL) filler_->::opencv_caffe::FillerParameter::Clear();
}
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool BiasParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.BiasParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional int32 axis = 1 [default = 1];
case 1: {
if (tag == 8) {
set_has_axis();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &axis_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_num_axes;
break;
}
// optional int32 num_axes = 2 [default = 1];
case 2: {
if (tag == 16) {
parse_num_axes:
set_has_num_axes();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &num_axes_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(26)) goto parse_filler;
break;
}
// optional .opencv_caffe.FillerParameter filler = 3;
case 3: {
if (tag == 26) {
parse_filler:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_filler()));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.BiasParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.BiasParameter)
return false;
#undef DO_
}
void BiasParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.BiasParameter)
// optional int32 axis = 1 [default = 1];
if (has_axis()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(1, this->axis(), output);
}
// optional int32 num_axes = 2 [default = 1];
if (has_num_axes()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->num_axes(), output);
}
// optional .opencv_caffe.FillerParameter filler = 3;
if (has_filler()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
3, *this->filler_, output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.BiasParameter)
}
::google::protobuf::uint8* BiasParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.BiasParameter)
// optional int32 axis = 1 [default = 1];
if (has_axis()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(1, this->axis(), target);
}
// optional int32 num_axes = 2 [default = 1];
if (has_num_axes()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(2, this->num_axes(), target);
}
// optional .opencv_caffe.FillerParameter filler = 3;
if (has_filler()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
3, *this->filler_, false, target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.BiasParameter)
return target;
}
size_t BiasParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.BiasParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 7u) {
// optional int32 axis = 1 [default = 1];
if (has_axis()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->axis());
}
// optional int32 num_axes = 2 [default = 1];
if (has_num_axes()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->num_axes());
}
// optional .opencv_caffe.FillerParameter filler = 3;
if (has_filler()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->filler_);
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void BiasParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.BiasParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const BiasParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const BiasParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.BiasParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.BiasParameter)
UnsafeMergeFrom(*source);
}
}
void BiasParameter::MergeFrom(const BiasParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.BiasParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void BiasParameter::UnsafeMergeFrom(const BiasParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_axis()) {
set_axis(from.axis());
}
if (from.has_num_axes()) {
set_num_axes(from.num_axes());
}
if (from.has_filler()) {
mutable_filler()->::opencv_caffe::FillerParameter::MergeFrom(from.filler());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void BiasParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.BiasParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void BiasParameter::CopyFrom(const BiasParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.BiasParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool BiasParameter::IsInitialized() const {
return true;
}
void BiasParameter::Swap(BiasParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void BiasParameter::InternalSwap(BiasParameter* other) {
std::swap(axis_, other->axis_);
std::swap(num_axes_, other->num_axes_);
std::swap(filler_, other->filler_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata BiasParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = BiasParameter_descriptor_;
metadata.reflection = BiasParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// BiasParameter
// optional int32 axis = 1 [default = 1];
bool BiasParameter::has_axis() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void BiasParameter::set_has_axis() {
_has_bits_[0] |= 0x00000001u;
}
void BiasParameter::clear_has_axis() {
_has_bits_[0] &= ~0x00000001u;
}
void BiasParameter::clear_axis() {
axis_ = 1;
clear_has_axis();
}
::google::protobuf::int32 BiasParameter::axis() const {
// @@protoc_insertion_point(field_get:opencv_caffe.BiasParameter.axis)
return axis_;
}
void BiasParameter::set_axis(::google::protobuf::int32 value) {
set_has_axis();
axis_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.BiasParameter.axis)
}
// optional int32 num_axes = 2 [default = 1];
bool BiasParameter::has_num_axes() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void BiasParameter::set_has_num_axes() {
_has_bits_[0] |= 0x00000002u;
}
void BiasParameter::clear_has_num_axes() {
_has_bits_[0] &= ~0x00000002u;
}
void BiasParameter::clear_num_axes() {
num_axes_ = 1;
clear_has_num_axes();
}
::google::protobuf::int32 BiasParameter::num_axes() const {
// @@protoc_insertion_point(field_get:opencv_caffe.BiasParameter.num_axes)
return num_axes_;
}
void BiasParameter::set_num_axes(::google::protobuf::int32 value) {
set_has_num_axes();
num_axes_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.BiasParameter.num_axes)
}
// optional .opencv_caffe.FillerParameter filler = 3;
bool BiasParameter::has_filler() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void BiasParameter::set_has_filler() {
_has_bits_[0] |= 0x00000004u;
}
void BiasParameter::clear_has_filler() {
_has_bits_[0] &= ~0x00000004u;
}
void BiasParameter::clear_filler() {
if (filler_ != NULL) filler_->::opencv_caffe::FillerParameter::Clear();
clear_has_filler();
}
const ::opencv_caffe::FillerParameter& BiasParameter::filler() const {
// @@protoc_insertion_point(field_get:opencv_caffe.BiasParameter.filler)
return filler_ != NULL ? *filler_
: *::opencv_caffe::FillerParameter::internal_default_instance();
}
::opencv_caffe::FillerParameter* BiasParameter::mutable_filler() {
set_has_filler();
if (filler_ == NULL) {
filler_ = new ::opencv_caffe::FillerParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.BiasParameter.filler)
return filler_;
}
::opencv_caffe::FillerParameter* BiasParameter::release_filler() {
// @@protoc_insertion_point(field_release:opencv_caffe.BiasParameter.filler)
clear_has_filler();
::opencv_caffe::FillerParameter* temp = filler_;
filler_ = NULL;
return temp;
}
void BiasParameter::set_allocated_filler(::opencv_caffe::FillerParameter* filler) {
delete filler_;
filler_ = filler;
if (filler) {
set_has_filler();
} else {
clear_has_filler();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.BiasParameter.filler)
}
inline const BiasParameter* BiasParameter::internal_default_instance() {
return &BiasParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int ContrastiveLossParameter::kMarginFieldNumber;
const int ContrastiveLossParameter::kLegacyVersionFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
ContrastiveLossParameter::ContrastiveLossParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.ContrastiveLossParameter)
}
void ContrastiveLossParameter::InitAsDefaultInstance() {
}
ContrastiveLossParameter::ContrastiveLossParameter(const ContrastiveLossParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.ContrastiveLossParameter)
}
void ContrastiveLossParameter::SharedCtor() {
_cached_size_ = 0;
legacy_version_ = false;
margin_ = 1;
}
ContrastiveLossParameter::~ContrastiveLossParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.ContrastiveLossParameter)
SharedDtor();
}
void ContrastiveLossParameter::SharedDtor() {
}
void ContrastiveLossParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* ContrastiveLossParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return ContrastiveLossParameter_descriptor_;
}
const ContrastiveLossParameter& ContrastiveLossParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<ContrastiveLossParameter> ContrastiveLossParameter_default_instance_;
ContrastiveLossParameter* ContrastiveLossParameter::New(::google::protobuf::Arena* arena) const {
ContrastiveLossParameter* n = new ContrastiveLossParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void ContrastiveLossParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.ContrastiveLossParameter)
if (_has_bits_[0 / 32] & 3u) {
margin_ = 1;
legacy_version_ = false;
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool ContrastiveLossParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.ContrastiveLossParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional float margin = 1 [default = 1];
case 1: {
if (tag == 13) {
set_has_margin();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &margin_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_legacy_version;
break;
}
// optional bool legacy_version = 2 [default = false];
case 2: {
if (tag == 16) {
parse_legacy_version:
set_has_legacy_version();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &legacy_version_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.ContrastiveLossParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.ContrastiveLossParameter)
return false;
#undef DO_
}
void ContrastiveLossParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.ContrastiveLossParameter)
// optional float margin = 1 [default = 1];
if (has_margin()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(1, this->margin(), output);
}
// optional bool legacy_version = 2 [default = false];
if (has_legacy_version()) {
::google::protobuf::internal::WireFormatLite::WriteBool(2, this->legacy_version(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.ContrastiveLossParameter)
}
::google::protobuf::uint8* ContrastiveLossParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.ContrastiveLossParameter)
// optional float margin = 1 [default = 1];
if (has_margin()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(1, this->margin(), target);
}
// optional bool legacy_version = 2 [default = false];
if (has_legacy_version()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(2, this->legacy_version(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.ContrastiveLossParameter)
return target;
}
size_t ContrastiveLossParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.ContrastiveLossParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 3u) {
// optional float margin = 1 [default = 1];
if (has_margin()) {
total_size += 1 + 4;
}
// optional bool legacy_version = 2 [default = false];
if (has_legacy_version()) {
total_size += 1 + 1;
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void ContrastiveLossParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.ContrastiveLossParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const ContrastiveLossParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const ContrastiveLossParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.ContrastiveLossParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.ContrastiveLossParameter)
UnsafeMergeFrom(*source);
}
}
void ContrastiveLossParameter::MergeFrom(const ContrastiveLossParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.ContrastiveLossParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void ContrastiveLossParameter::UnsafeMergeFrom(const ContrastiveLossParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_margin()) {
set_margin(from.margin());
}
if (from.has_legacy_version()) {
set_legacy_version(from.legacy_version());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void ContrastiveLossParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.ContrastiveLossParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void ContrastiveLossParameter::CopyFrom(const ContrastiveLossParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.ContrastiveLossParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool ContrastiveLossParameter::IsInitialized() const {
return true;
}
void ContrastiveLossParameter::Swap(ContrastiveLossParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void ContrastiveLossParameter::InternalSwap(ContrastiveLossParameter* other) {
std::swap(margin_, other->margin_);
std::swap(legacy_version_, other->legacy_version_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata ContrastiveLossParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = ContrastiveLossParameter_descriptor_;
metadata.reflection = ContrastiveLossParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// ContrastiveLossParameter
// optional float margin = 1 [default = 1];
bool ContrastiveLossParameter::has_margin() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void ContrastiveLossParameter::set_has_margin() {
_has_bits_[0] |= 0x00000001u;
}
void ContrastiveLossParameter::clear_has_margin() {
_has_bits_[0] &= ~0x00000001u;
}
void ContrastiveLossParameter::clear_margin() {
margin_ = 1;
clear_has_margin();
}
float ContrastiveLossParameter::margin() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ContrastiveLossParameter.margin)
return margin_;
}
void ContrastiveLossParameter::set_margin(float value) {
set_has_margin();
margin_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ContrastiveLossParameter.margin)
}
// optional bool legacy_version = 2 [default = false];
bool ContrastiveLossParameter::has_legacy_version() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void ContrastiveLossParameter::set_has_legacy_version() {
_has_bits_[0] |= 0x00000002u;
}
void ContrastiveLossParameter::clear_has_legacy_version() {
_has_bits_[0] &= ~0x00000002u;
}
void ContrastiveLossParameter::clear_legacy_version() {
legacy_version_ = false;
clear_has_legacy_version();
}
bool ContrastiveLossParameter::legacy_version() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ContrastiveLossParameter.legacy_version)
return legacy_version_;
}
void ContrastiveLossParameter::set_legacy_version(bool value) {
set_has_legacy_version();
legacy_version_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ContrastiveLossParameter.legacy_version)
}
inline const ContrastiveLossParameter* ContrastiveLossParameter::internal_default_instance() {
return &ContrastiveLossParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
const ::google::protobuf::EnumDescriptor* ConvolutionParameter_Engine_descriptor() {
protobuf_AssignDescriptorsOnce();
return ConvolutionParameter_Engine_descriptor_;
}
bool ConvolutionParameter_Engine_IsValid(int value) {
switch (value) {
case 0:
case 1:
case 2:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const ConvolutionParameter_Engine ConvolutionParameter::DEFAULT;
const ConvolutionParameter_Engine ConvolutionParameter::CAFFE;
const ConvolutionParameter_Engine ConvolutionParameter::CUDNN;
const ConvolutionParameter_Engine ConvolutionParameter::Engine_MIN;
const ConvolutionParameter_Engine ConvolutionParameter::Engine_MAX;
const int ConvolutionParameter::Engine_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int ConvolutionParameter::kNumOutputFieldNumber;
const int ConvolutionParameter::kBiasTermFieldNumber;
const int ConvolutionParameter::kPadFieldNumber;
const int ConvolutionParameter::kKernelSizeFieldNumber;
const int ConvolutionParameter::kStrideFieldNumber;
const int ConvolutionParameter::kDilationFieldNumber;
const int ConvolutionParameter::kPadHFieldNumber;
const int ConvolutionParameter::kPadWFieldNumber;
const int ConvolutionParameter::kKernelHFieldNumber;
const int ConvolutionParameter::kKernelWFieldNumber;
const int ConvolutionParameter::kStrideHFieldNumber;
const int ConvolutionParameter::kStrideWFieldNumber;
const int ConvolutionParameter::kGroupFieldNumber;
const int ConvolutionParameter::kWeightFillerFieldNumber;
const int ConvolutionParameter::kBiasFillerFieldNumber;
const int ConvolutionParameter::kEngineFieldNumber;
const int ConvolutionParameter::kAxisFieldNumber;
const int ConvolutionParameter::kForceNdIm2ColFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
ConvolutionParameter::ConvolutionParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.ConvolutionParameter)
}
void ConvolutionParameter::InitAsDefaultInstance() {
weight_filler_ = const_cast< ::opencv_caffe::FillerParameter*>(
::opencv_caffe::FillerParameter::internal_default_instance());
bias_filler_ = const_cast< ::opencv_caffe::FillerParameter*>(
::opencv_caffe::FillerParameter::internal_default_instance());
}
ConvolutionParameter::ConvolutionParameter(const ConvolutionParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.ConvolutionParameter)
}
void ConvolutionParameter::SharedCtor() {
_cached_size_ = 0;
weight_filler_ = NULL;
bias_filler_ = NULL;
::memset(&num_output_, 0, reinterpret_cast<char*>(&force_nd_im2col_) -
reinterpret_cast<char*>(&num_output_) + sizeof(force_nd_im2col_));
axis_ = 1;
bias_term_ = true;
group_ = 1u;
}
ConvolutionParameter::~ConvolutionParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.ConvolutionParameter)
SharedDtor();
}
void ConvolutionParameter::SharedDtor() {
if (this != &ConvolutionParameter_default_instance_.get()) {
delete weight_filler_;
delete bias_filler_;
}
}
void ConvolutionParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* ConvolutionParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return ConvolutionParameter_descriptor_;
}
const ConvolutionParameter& ConvolutionParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<ConvolutionParameter> ConvolutionParameter_default_instance_;
ConvolutionParameter* ConvolutionParameter::New(::google::protobuf::Arena* arena) const {
ConvolutionParameter* n = new ConvolutionParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void ConvolutionParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.ConvolutionParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(ConvolutionParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<ConvolutionParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
if (_has_bits_[0 / 32] & 195u) {
ZR_(num_output_, pad_w_);
bias_term_ = true;
}
if (_has_bits_[8 / 32] & 65280u) {
ZR_(kernel_h_, engine_);
group_ = 1u;
if (has_weight_filler()) {
if (weight_filler_ != NULL) weight_filler_->::opencv_caffe::FillerParameter::Clear();
}
if (has_bias_filler()) {
if (bias_filler_ != NULL) bias_filler_->::opencv_caffe::FillerParameter::Clear();
}
}
if (_has_bits_[16 / 32] & 196608u) {
axis_ = 1;
force_nd_im2col_ = false;
}
#undef ZR_HELPER_
#undef ZR_
pad_.Clear();
kernel_size_.Clear();
stride_.Clear();
dilation_.Clear();
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool ConvolutionParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.ConvolutionParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(16383);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional uint32 num_output = 1;
case 1: {
if (tag == 8) {
set_has_num_output();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &num_output_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_bias_term;
break;
}
// optional bool bias_term = 2 [default = true];
case 2: {
if (tag == 16) {
parse_bias_term:
set_has_bias_term();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &bias_term_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(24)) goto parse_pad;
break;
}
// repeated uint32 pad = 3;
case 3: {
if (tag == 24) {
parse_pad:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
1, 24, input, this->mutable_pad())));
} else if (tag == 26) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, this->mutable_pad())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(24)) goto parse_pad;
if (input->ExpectTag(32)) goto parse_kernel_size;
break;
}
// repeated uint32 kernel_size = 4;
case 4: {
if (tag == 32) {
parse_kernel_size:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
1, 32, input, this->mutable_kernel_size())));
} else if (tag == 34) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, this->mutable_kernel_size())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(32)) goto parse_kernel_size;
if (input->ExpectTag(40)) goto parse_group;
break;
}
// optional uint32 group = 5 [default = 1];
case 5: {
if (tag == 40) {
parse_group:
set_has_group();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &group_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(48)) goto parse_stride;
break;
}
// repeated uint32 stride = 6;
case 6: {
if (tag == 48) {
parse_stride:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
1, 48, input, this->mutable_stride())));
} else if (tag == 50) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, this->mutable_stride())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(48)) goto parse_stride;
if (input->ExpectTag(58)) goto parse_weight_filler;
break;
}
// optional .opencv_caffe.FillerParameter weight_filler = 7;
case 7: {
if (tag == 58) {
parse_weight_filler:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_weight_filler()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(66)) goto parse_bias_filler;
break;
}
// optional .opencv_caffe.FillerParameter bias_filler = 8;
case 8: {
if (tag == 66) {
parse_bias_filler:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_bias_filler()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(72)) goto parse_pad_h;
break;
}
// optional uint32 pad_h = 9 [default = 0];
case 9: {
if (tag == 72) {
parse_pad_h:
set_has_pad_h();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &pad_h_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(80)) goto parse_pad_w;
break;
}
// optional uint32 pad_w = 10 [default = 0];
case 10: {
if (tag == 80) {
parse_pad_w:
set_has_pad_w();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &pad_w_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(88)) goto parse_kernel_h;
break;
}
// optional uint32 kernel_h = 11;
case 11: {
if (tag == 88) {
parse_kernel_h:
set_has_kernel_h();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &kernel_h_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(96)) goto parse_kernel_w;
break;
}
// optional uint32 kernel_w = 12;
case 12: {
if (tag == 96) {
parse_kernel_w:
set_has_kernel_w();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &kernel_w_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(104)) goto parse_stride_h;
break;
}
// optional uint32 stride_h = 13;
case 13: {
if (tag == 104) {
parse_stride_h:
set_has_stride_h();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &stride_h_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(112)) goto parse_stride_w;
break;
}
// optional uint32 stride_w = 14;
case 14: {
if (tag == 112) {
parse_stride_w:
set_has_stride_w();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &stride_w_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(120)) goto parse_engine;
break;
}
// optional .opencv_caffe.ConvolutionParameter.Engine engine = 15 [default = DEFAULT];
case 15: {
if (tag == 120) {
parse_engine:
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::ConvolutionParameter_Engine_IsValid(value)) {
set_engine(static_cast< ::opencv_caffe::ConvolutionParameter_Engine >(value));
} else {
mutable_unknown_fields()->AddVarint(15, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectTag(128)) goto parse_axis;
break;
}
// optional int32 axis = 16 [default = 1];
case 16: {
if (tag == 128) {
parse_axis:
set_has_axis();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &axis_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(136)) goto parse_force_nd_im2col;
break;
}
// optional bool force_nd_im2col = 17 [default = false];
case 17: {
if (tag == 136) {
parse_force_nd_im2col:
set_has_force_nd_im2col();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &force_nd_im2col_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(144)) goto parse_dilation;
break;
}
// repeated uint32 dilation = 18;
case 18: {
if (tag == 144) {
parse_dilation:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
2, 144, input, this->mutable_dilation())));
} else if (tag == 146) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, this->mutable_dilation())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(144)) goto parse_dilation;
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.ConvolutionParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.ConvolutionParameter)
return false;
#undef DO_
}
void ConvolutionParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.ConvolutionParameter)
// optional uint32 num_output = 1;
if (has_num_output()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(1, this->num_output(), output);
}
// optional bool bias_term = 2 [default = true];
if (has_bias_term()) {
::google::protobuf::internal::WireFormatLite::WriteBool(2, this->bias_term(), output);
}
// repeated uint32 pad = 3;
for (int i = 0; i < this->pad_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(
3, this->pad(i), output);
}
// repeated uint32 kernel_size = 4;
for (int i = 0; i < this->kernel_size_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(
4, this->kernel_size(i), output);
}
// optional uint32 group = 5 [default = 1];
if (has_group()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(5, this->group(), output);
}
// repeated uint32 stride = 6;
for (int i = 0; i < this->stride_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(
6, this->stride(i), output);
}
// optional .opencv_caffe.FillerParameter weight_filler = 7;
if (has_weight_filler()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
7, *this->weight_filler_, output);
}
// optional .opencv_caffe.FillerParameter bias_filler = 8;
if (has_bias_filler()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
8, *this->bias_filler_, output);
}
// optional uint32 pad_h = 9 [default = 0];
if (has_pad_h()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(9, this->pad_h(), output);
}
// optional uint32 pad_w = 10 [default = 0];
if (has_pad_w()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(10, this->pad_w(), output);
}
// optional uint32 kernel_h = 11;
if (has_kernel_h()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(11, this->kernel_h(), output);
}
// optional uint32 kernel_w = 12;
if (has_kernel_w()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(12, this->kernel_w(), output);
}
// optional uint32 stride_h = 13;
if (has_stride_h()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(13, this->stride_h(), output);
}
// optional uint32 stride_w = 14;
if (has_stride_w()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(14, this->stride_w(), output);
}
// optional .opencv_caffe.ConvolutionParameter.Engine engine = 15 [default = DEFAULT];
if (has_engine()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
15, this->engine(), output);
}
// optional int32 axis = 16 [default = 1];
if (has_axis()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(16, this->axis(), output);
}
// optional bool force_nd_im2col = 17 [default = false];
if (has_force_nd_im2col()) {
::google::protobuf::internal::WireFormatLite::WriteBool(17, this->force_nd_im2col(), output);
}
// repeated uint32 dilation = 18;
for (int i = 0; i < this->dilation_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(
18, this->dilation(i), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.ConvolutionParameter)
}
::google::protobuf::uint8* ConvolutionParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.ConvolutionParameter)
// optional uint32 num_output = 1;
if (has_num_output()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(1, this->num_output(), target);
}
// optional bool bias_term = 2 [default = true];
if (has_bias_term()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(2, this->bias_term(), target);
}
// repeated uint32 pad = 3;
for (int i = 0; i < this->pad_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteUInt32ToArray(3, this->pad(i), target);
}
// repeated uint32 kernel_size = 4;
for (int i = 0; i < this->kernel_size_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteUInt32ToArray(4, this->kernel_size(i), target);
}
// optional uint32 group = 5 [default = 1];
if (has_group()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(5, this->group(), target);
}
// repeated uint32 stride = 6;
for (int i = 0; i < this->stride_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteUInt32ToArray(6, this->stride(i), target);
}
// optional .opencv_caffe.FillerParameter weight_filler = 7;
if (has_weight_filler()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
7, *this->weight_filler_, false, target);
}
// optional .opencv_caffe.FillerParameter bias_filler = 8;
if (has_bias_filler()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
8, *this->bias_filler_, false, target);
}
// optional uint32 pad_h = 9 [default = 0];
if (has_pad_h()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(9, this->pad_h(), target);
}
// optional uint32 pad_w = 10 [default = 0];
if (has_pad_w()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(10, this->pad_w(), target);
}
// optional uint32 kernel_h = 11;
if (has_kernel_h()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(11, this->kernel_h(), target);
}
// optional uint32 kernel_w = 12;
if (has_kernel_w()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(12, this->kernel_w(), target);
}
// optional uint32 stride_h = 13;
if (has_stride_h()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(13, this->stride_h(), target);
}
// optional uint32 stride_w = 14;
if (has_stride_w()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(14, this->stride_w(), target);
}
// optional .opencv_caffe.ConvolutionParameter.Engine engine = 15 [default = DEFAULT];
if (has_engine()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
15, this->engine(), target);
}
// optional int32 axis = 16 [default = 1];
if (has_axis()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(16, this->axis(), target);
}
// optional bool force_nd_im2col = 17 [default = false];
if (has_force_nd_im2col()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(17, this->force_nd_im2col(), target);
}
// repeated uint32 dilation = 18;
for (int i = 0; i < this->dilation_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteUInt32ToArray(18, this->dilation(i), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.ConvolutionParameter)
return target;
}
size_t ConvolutionParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.ConvolutionParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 195u) {
// optional uint32 num_output = 1;
if (has_num_output()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->num_output());
}
// optional bool bias_term = 2 [default = true];
if (has_bias_term()) {
total_size += 1 + 1;
}
// optional uint32 pad_h = 9 [default = 0];
if (has_pad_h()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->pad_h());
}
// optional uint32 pad_w = 10 [default = 0];
if (has_pad_w()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->pad_w());
}
}
if (_has_bits_[8 / 32] & 65280u) {
// optional uint32 kernel_h = 11;
if (has_kernel_h()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->kernel_h());
}
// optional uint32 kernel_w = 12;
if (has_kernel_w()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->kernel_w());
}
// optional uint32 stride_h = 13;
if (has_stride_h()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->stride_h());
}
// optional uint32 stride_w = 14;
if (has_stride_w()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->stride_w());
}
// optional uint32 group = 5 [default = 1];
if (has_group()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->group());
}
// optional .opencv_caffe.FillerParameter weight_filler = 7;
if (has_weight_filler()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->weight_filler_);
}
// optional .opencv_caffe.FillerParameter bias_filler = 8;
if (has_bias_filler()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->bias_filler_);
}
// optional .opencv_caffe.ConvolutionParameter.Engine engine = 15 [default = DEFAULT];
if (has_engine()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->engine());
}
}
if (_has_bits_[16 / 32] & 196608u) {
// optional int32 axis = 16 [default = 1];
if (has_axis()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->axis());
}
// optional bool force_nd_im2col = 17 [default = false];
if (has_force_nd_im2col()) {
total_size += 2 + 1;
}
}
// repeated uint32 pad = 3;
{
size_t data_size = 0;
unsigned int count = this->pad_size();
for (unsigned int i = 0; i < count; i++) {
data_size += ::google::protobuf::internal::WireFormatLite::
UInt32Size(this->pad(i));
}
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->pad_size());
total_size += data_size;
}
// repeated uint32 kernel_size = 4;
{
size_t data_size = 0;
unsigned int count = this->kernel_size_size();
for (unsigned int i = 0; i < count; i++) {
data_size += ::google::protobuf::internal::WireFormatLite::
UInt32Size(this->kernel_size(i));
}
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->kernel_size_size());
total_size += data_size;
}
// repeated uint32 stride = 6;
{
size_t data_size = 0;
unsigned int count = this->stride_size();
for (unsigned int i = 0; i < count; i++) {
data_size += ::google::protobuf::internal::WireFormatLite::
UInt32Size(this->stride(i));
}
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->stride_size());
total_size += data_size;
}
// repeated uint32 dilation = 18;
{
size_t data_size = 0;
unsigned int count = this->dilation_size();
for (unsigned int i = 0; i < count; i++) {
data_size += ::google::protobuf::internal::WireFormatLite::
UInt32Size(this->dilation(i));
}
total_size += 2 *
::google::protobuf::internal::FromIntSize(this->dilation_size());
total_size += data_size;
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void ConvolutionParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.ConvolutionParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const ConvolutionParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const ConvolutionParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.ConvolutionParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.ConvolutionParameter)
UnsafeMergeFrom(*source);
}
}
void ConvolutionParameter::MergeFrom(const ConvolutionParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.ConvolutionParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void ConvolutionParameter::UnsafeMergeFrom(const ConvolutionParameter& from) {
GOOGLE_DCHECK(&from != this);
pad_.UnsafeMergeFrom(from.pad_);
kernel_size_.UnsafeMergeFrom(from.kernel_size_);
stride_.UnsafeMergeFrom(from.stride_);
dilation_.UnsafeMergeFrom(from.dilation_);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_num_output()) {
set_num_output(from.num_output());
}
if (from.has_bias_term()) {
set_bias_term(from.bias_term());
}
if (from.has_pad_h()) {
set_pad_h(from.pad_h());
}
if (from.has_pad_w()) {
set_pad_w(from.pad_w());
}
}
if (from._has_bits_[8 / 32] & (0xffu << (8 % 32))) {
if (from.has_kernel_h()) {
set_kernel_h(from.kernel_h());
}
if (from.has_kernel_w()) {
set_kernel_w(from.kernel_w());
}
if (from.has_stride_h()) {
set_stride_h(from.stride_h());
}
if (from.has_stride_w()) {
set_stride_w(from.stride_w());
}
if (from.has_group()) {
set_group(from.group());
}
if (from.has_weight_filler()) {
mutable_weight_filler()->::opencv_caffe::FillerParameter::MergeFrom(from.weight_filler());
}
if (from.has_bias_filler()) {
mutable_bias_filler()->::opencv_caffe::FillerParameter::MergeFrom(from.bias_filler());
}
if (from.has_engine()) {
set_engine(from.engine());
}
}
if (from._has_bits_[16 / 32] & (0xffu << (16 % 32))) {
if (from.has_axis()) {
set_axis(from.axis());
}
if (from.has_force_nd_im2col()) {
set_force_nd_im2col(from.force_nd_im2col());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void ConvolutionParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.ConvolutionParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void ConvolutionParameter::CopyFrom(const ConvolutionParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.ConvolutionParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool ConvolutionParameter::IsInitialized() const {
return true;
}
void ConvolutionParameter::Swap(ConvolutionParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void ConvolutionParameter::InternalSwap(ConvolutionParameter* other) {
std::swap(num_output_, other->num_output_);
std::swap(bias_term_, other->bias_term_);
pad_.UnsafeArenaSwap(&other->pad_);
kernel_size_.UnsafeArenaSwap(&other->kernel_size_);
stride_.UnsafeArenaSwap(&other->stride_);
dilation_.UnsafeArenaSwap(&other->dilation_);
std::swap(pad_h_, other->pad_h_);
std::swap(pad_w_, other->pad_w_);
std::swap(kernel_h_, other->kernel_h_);
std::swap(kernel_w_, other->kernel_w_);
std::swap(stride_h_, other->stride_h_);
std::swap(stride_w_, other->stride_w_);
std::swap(group_, other->group_);
std::swap(weight_filler_, other->weight_filler_);
std::swap(bias_filler_, other->bias_filler_);
std::swap(engine_, other->engine_);
std::swap(axis_, other->axis_);
std::swap(force_nd_im2col_, other->force_nd_im2col_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata ConvolutionParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = ConvolutionParameter_descriptor_;
metadata.reflection = ConvolutionParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// ConvolutionParameter
// optional uint32 num_output = 1;
bool ConvolutionParameter::has_num_output() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void ConvolutionParameter::set_has_num_output() {
_has_bits_[0] |= 0x00000001u;
}
void ConvolutionParameter::clear_has_num_output() {
_has_bits_[0] &= ~0x00000001u;
}
void ConvolutionParameter::clear_num_output() {
num_output_ = 0u;
clear_has_num_output();
}
::google::protobuf::uint32 ConvolutionParameter::num_output() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ConvolutionParameter.num_output)
return num_output_;
}
void ConvolutionParameter::set_num_output(::google::protobuf::uint32 value) {
set_has_num_output();
num_output_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ConvolutionParameter.num_output)
}
// optional bool bias_term = 2 [default = true];
bool ConvolutionParameter::has_bias_term() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void ConvolutionParameter::set_has_bias_term() {
_has_bits_[0] |= 0x00000002u;
}
void ConvolutionParameter::clear_has_bias_term() {
_has_bits_[0] &= ~0x00000002u;
}
void ConvolutionParameter::clear_bias_term() {
bias_term_ = true;
clear_has_bias_term();
}
bool ConvolutionParameter::bias_term() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ConvolutionParameter.bias_term)
return bias_term_;
}
void ConvolutionParameter::set_bias_term(bool value) {
set_has_bias_term();
bias_term_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ConvolutionParameter.bias_term)
}
// repeated uint32 pad = 3;
int ConvolutionParameter::pad_size() const {
return pad_.size();
}
void ConvolutionParameter::clear_pad() {
pad_.Clear();
}
::google::protobuf::uint32 ConvolutionParameter::pad(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.ConvolutionParameter.pad)
return pad_.Get(index);
}
void ConvolutionParameter::set_pad(int index, ::google::protobuf::uint32 value) {
pad_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.ConvolutionParameter.pad)
}
void ConvolutionParameter::add_pad(::google::protobuf::uint32 value) {
pad_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.ConvolutionParameter.pad)
}
const ::google::protobuf::RepeatedField< ::google::protobuf::uint32 >&
ConvolutionParameter::pad() const {
// @@protoc_insertion_point(field_list:opencv_caffe.ConvolutionParameter.pad)
return pad_;
}
::google::protobuf::RepeatedField< ::google::protobuf::uint32 >*
ConvolutionParameter::mutable_pad() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.ConvolutionParameter.pad)
return &pad_;
}
// repeated uint32 kernel_size = 4;
int ConvolutionParameter::kernel_size_size() const {
return kernel_size_.size();
}
void ConvolutionParameter::clear_kernel_size() {
kernel_size_.Clear();
}
::google::protobuf::uint32 ConvolutionParameter::kernel_size(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.ConvolutionParameter.kernel_size)
return kernel_size_.Get(index);
}
void ConvolutionParameter::set_kernel_size(int index, ::google::protobuf::uint32 value) {
kernel_size_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.ConvolutionParameter.kernel_size)
}
void ConvolutionParameter::add_kernel_size(::google::protobuf::uint32 value) {
kernel_size_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.ConvolutionParameter.kernel_size)
}
const ::google::protobuf::RepeatedField< ::google::protobuf::uint32 >&
ConvolutionParameter::kernel_size() const {
// @@protoc_insertion_point(field_list:opencv_caffe.ConvolutionParameter.kernel_size)
return kernel_size_;
}
::google::protobuf::RepeatedField< ::google::protobuf::uint32 >*
ConvolutionParameter::mutable_kernel_size() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.ConvolutionParameter.kernel_size)
return &kernel_size_;
}
// repeated uint32 stride = 6;
int ConvolutionParameter::stride_size() const {
return stride_.size();
}
void ConvolutionParameter::clear_stride() {
stride_.Clear();
}
::google::protobuf::uint32 ConvolutionParameter::stride(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.ConvolutionParameter.stride)
return stride_.Get(index);
}
void ConvolutionParameter::set_stride(int index, ::google::protobuf::uint32 value) {
stride_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.ConvolutionParameter.stride)
}
void ConvolutionParameter::add_stride(::google::protobuf::uint32 value) {
stride_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.ConvolutionParameter.stride)
}
const ::google::protobuf::RepeatedField< ::google::protobuf::uint32 >&
ConvolutionParameter::stride() const {
// @@protoc_insertion_point(field_list:opencv_caffe.ConvolutionParameter.stride)
return stride_;
}
::google::protobuf::RepeatedField< ::google::protobuf::uint32 >*
ConvolutionParameter::mutable_stride() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.ConvolutionParameter.stride)
return &stride_;
}
// repeated uint32 dilation = 18;
int ConvolutionParameter::dilation_size() const {
return dilation_.size();
}
void ConvolutionParameter::clear_dilation() {
dilation_.Clear();
}
::google::protobuf::uint32 ConvolutionParameter::dilation(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.ConvolutionParameter.dilation)
return dilation_.Get(index);
}
void ConvolutionParameter::set_dilation(int index, ::google::protobuf::uint32 value) {
dilation_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.ConvolutionParameter.dilation)
}
void ConvolutionParameter::add_dilation(::google::protobuf::uint32 value) {
dilation_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.ConvolutionParameter.dilation)
}
const ::google::protobuf::RepeatedField< ::google::protobuf::uint32 >&
ConvolutionParameter::dilation() const {
// @@protoc_insertion_point(field_list:opencv_caffe.ConvolutionParameter.dilation)
return dilation_;
}
::google::protobuf::RepeatedField< ::google::protobuf::uint32 >*
ConvolutionParameter::mutable_dilation() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.ConvolutionParameter.dilation)
return &dilation_;
}
// optional uint32 pad_h = 9 [default = 0];
bool ConvolutionParameter::has_pad_h() const {
return (_has_bits_[0] & 0x00000040u) != 0;
}
void ConvolutionParameter::set_has_pad_h() {
_has_bits_[0] |= 0x00000040u;
}
void ConvolutionParameter::clear_has_pad_h() {
_has_bits_[0] &= ~0x00000040u;
}
void ConvolutionParameter::clear_pad_h() {
pad_h_ = 0u;
clear_has_pad_h();
}
::google::protobuf::uint32 ConvolutionParameter::pad_h() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ConvolutionParameter.pad_h)
return pad_h_;
}
void ConvolutionParameter::set_pad_h(::google::protobuf::uint32 value) {
set_has_pad_h();
pad_h_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ConvolutionParameter.pad_h)
}
// optional uint32 pad_w = 10 [default = 0];
bool ConvolutionParameter::has_pad_w() const {
return (_has_bits_[0] & 0x00000080u) != 0;
}
void ConvolutionParameter::set_has_pad_w() {
_has_bits_[0] |= 0x00000080u;
}
void ConvolutionParameter::clear_has_pad_w() {
_has_bits_[0] &= ~0x00000080u;
}
void ConvolutionParameter::clear_pad_w() {
pad_w_ = 0u;
clear_has_pad_w();
}
::google::protobuf::uint32 ConvolutionParameter::pad_w() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ConvolutionParameter.pad_w)
return pad_w_;
}
void ConvolutionParameter::set_pad_w(::google::protobuf::uint32 value) {
set_has_pad_w();
pad_w_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ConvolutionParameter.pad_w)
}
// optional uint32 kernel_h = 11;
bool ConvolutionParameter::has_kernel_h() const {
return (_has_bits_[0] & 0x00000100u) != 0;
}
void ConvolutionParameter::set_has_kernel_h() {
_has_bits_[0] |= 0x00000100u;
}
void ConvolutionParameter::clear_has_kernel_h() {
_has_bits_[0] &= ~0x00000100u;
}
void ConvolutionParameter::clear_kernel_h() {
kernel_h_ = 0u;
clear_has_kernel_h();
}
::google::protobuf::uint32 ConvolutionParameter::kernel_h() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ConvolutionParameter.kernel_h)
return kernel_h_;
}
void ConvolutionParameter::set_kernel_h(::google::protobuf::uint32 value) {
set_has_kernel_h();
kernel_h_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ConvolutionParameter.kernel_h)
}
// optional uint32 kernel_w = 12;
bool ConvolutionParameter::has_kernel_w() const {
return (_has_bits_[0] & 0x00000200u) != 0;
}
void ConvolutionParameter::set_has_kernel_w() {
_has_bits_[0] |= 0x00000200u;
}
void ConvolutionParameter::clear_has_kernel_w() {
_has_bits_[0] &= ~0x00000200u;
}
void ConvolutionParameter::clear_kernel_w() {
kernel_w_ = 0u;
clear_has_kernel_w();
}
::google::protobuf::uint32 ConvolutionParameter::kernel_w() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ConvolutionParameter.kernel_w)
return kernel_w_;
}
void ConvolutionParameter::set_kernel_w(::google::protobuf::uint32 value) {
set_has_kernel_w();
kernel_w_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ConvolutionParameter.kernel_w)
}
// optional uint32 stride_h = 13;
bool ConvolutionParameter::has_stride_h() const {
return (_has_bits_[0] & 0x00000400u) != 0;
}
void ConvolutionParameter::set_has_stride_h() {
_has_bits_[0] |= 0x00000400u;
}
void ConvolutionParameter::clear_has_stride_h() {
_has_bits_[0] &= ~0x00000400u;
}
void ConvolutionParameter::clear_stride_h() {
stride_h_ = 0u;
clear_has_stride_h();
}
::google::protobuf::uint32 ConvolutionParameter::stride_h() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ConvolutionParameter.stride_h)
return stride_h_;
}
void ConvolutionParameter::set_stride_h(::google::protobuf::uint32 value) {
set_has_stride_h();
stride_h_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ConvolutionParameter.stride_h)
}
// optional uint32 stride_w = 14;
bool ConvolutionParameter::has_stride_w() const {
return (_has_bits_[0] & 0x00000800u) != 0;
}
void ConvolutionParameter::set_has_stride_w() {
_has_bits_[0] |= 0x00000800u;
}
void ConvolutionParameter::clear_has_stride_w() {
_has_bits_[0] &= ~0x00000800u;
}
void ConvolutionParameter::clear_stride_w() {
stride_w_ = 0u;
clear_has_stride_w();
}
::google::protobuf::uint32 ConvolutionParameter::stride_w() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ConvolutionParameter.stride_w)
return stride_w_;
}
void ConvolutionParameter::set_stride_w(::google::protobuf::uint32 value) {
set_has_stride_w();
stride_w_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ConvolutionParameter.stride_w)
}
// optional uint32 group = 5 [default = 1];
bool ConvolutionParameter::has_group() const {
return (_has_bits_[0] & 0x00001000u) != 0;
}
void ConvolutionParameter::set_has_group() {
_has_bits_[0] |= 0x00001000u;
}
void ConvolutionParameter::clear_has_group() {
_has_bits_[0] &= ~0x00001000u;
}
void ConvolutionParameter::clear_group() {
group_ = 1u;
clear_has_group();
}
::google::protobuf::uint32 ConvolutionParameter::group() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ConvolutionParameter.group)
return group_;
}
void ConvolutionParameter::set_group(::google::protobuf::uint32 value) {
set_has_group();
group_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ConvolutionParameter.group)
}
// optional .opencv_caffe.FillerParameter weight_filler = 7;
bool ConvolutionParameter::has_weight_filler() const {
return (_has_bits_[0] & 0x00002000u) != 0;
}
void ConvolutionParameter::set_has_weight_filler() {
_has_bits_[0] |= 0x00002000u;
}
void ConvolutionParameter::clear_has_weight_filler() {
_has_bits_[0] &= ~0x00002000u;
}
void ConvolutionParameter::clear_weight_filler() {
if (weight_filler_ != NULL) weight_filler_->::opencv_caffe::FillerParameter::Clear();
clear_has_weight_filler();
}
const ::opencv_caffe::FillerParameter& ConvolutionParameter::weight_filler() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ConvolutionParameter.weight_filler)
return weight_filler_ != NULL ? *weight_filler_
: *::opencv_caffe::FillerParameter::internal_default_instance();
}
::opencv_caffe::FillerParameter* ConvolutionParameter::mutable_weight_filler() {
set_has_weight_filler();
if (weight_filler_ == NULL) {
weight_filler_ = new ::opencv_caffe::FillerParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.ConvolutionParameter.weight_filler)
return weight_filler_;
}
::opencv_caffe::FillerParameter* ConvolutionParameter::release_weight_filler() {
// @@protoc_insertion_point(field_release:opencv_caffe.ConvolutionParameter.weight_filler)
clear_has_weight_filler();
::opencv_caffe::FillerParameter* temp = weight_filler_;
weight_filler_ = NULL;
return temp;
}
void ConvolutionParameter::set_allocated_weight_filler(::opencv_caffe::FillerParameter* weight_filler) {
delete weight_filler_;
weight_filler_ = weight_filler;
if (weight_filler) {
set_has_weight_filler();
} else {
clear_has_weight_filler();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.ConvolutionParameter.weight_filler)
}
// optional .opencv_caffe.FillerParameter bias_filler = 8;
bool ConvolutionParameter::has_bias_filler() const {
return (_has_bits_[0] & 0x00004000u) != 0;
}
void ConvolutionParameter::set_has_bias_filler() {
_has_bits_[0] |= 0x00004000u;
}
void ConvolutionParameter::clear_has_bias_filler() {
_has_bits_[0] &= ~0x00004000u;
}
void ConvolutionParameter::clear_bias_filler() {
if (bias_filler_ != NULL) bias_filler_->::opencv_caffe::FillerParameter::Clear();
clear_has_bias_filler();
}
const ::opencv_caffe::FillerParameter& ConvolutionParameter::bias_filler() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ConvolutionParameter.bias_filler)
return bias_filler_ != NULL ? *bias_filler_
: *::opencv_caffe::FillerParameter::internal_default_instance();
}
::opencv_caffe::FillerParameter* ConvolutionParameter::mutable_bias_filler() {
set_has_bias_filler();
if (bias_filler_ == NULL) {
bias_filler_ = new ::opencv_caffe::FillerParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.ConvolutionParameter.bias_filler)
return bias_filler_;
}
::opencv_caffe::FillerParameter* ConvolutionParameter::release_bias_filler() {
// @@protoc_insertion_point(field_release:opencv_caffe.ConvolutionParameter.bias_filler)
clear_has_bias_filler();
::opencv_caffe::FillerParameter* temp = bias_filler_;
bias_filler_ = NULL;
return temp;
}
void ConvolutionParameter::set_allocated_bias_filler(::opencv_caffe::FillerParameter* bias_filler) {
delete bias_filler_;
bias_filler_ = bias_filler;
if (bias_filler) {
set_has_bias_filler();
} else {
clear_has_bias_filler();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.ConvolutionParameter.bias_filler)
}
// optional .opencv_caffe.ConvolutionParameter.Engine engine = 15 [default = DEFAULT];
bool ConvolutionParameter::has_engine() const {
return (_has_bits_[0] & 0x00008000u) != 0;
}
void ConvolutionParameter::set_has_engine() {
_has_bits_[0] |= 0x00008000u;
}
void ConvolutionParameter::clear_has_engine() {
_has_bits_[0] &= ~0x00008000u;
}
void ConvolutionParameter::clear_engine() {
engine_ = 0;
clear_has_engine();
}
::opencv_caffe::ConvolutionParameter_Engine ConvolutionParameter::engine() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ConvolutionParameter.engine)
return static_cast< ::opencv_caffe::ConvolutionParameter_Engine >(engine_);
}
void ConvolutionParameter::set_engine(::opencv_caffe::ConvolutionParameter_Engine value) {
assert(::opencv_caffe::ConvolutionParameter_Engine_IsValid(value));
set_has_engine();
engine_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ConvolutionParameter.engine)
}
// optional int32 axis = 16 [default = 1];
bool ConvolutionParameter::has_axis() const {
return (_has_bits_[0] & 0x00010000u) != 0;
}
void ConvolutionParameter::set_has_axis() {
_has_bits_[0] |= 0x00010000u;
}
void ConvolutionParameter::clear_has_axis() {
_has_bits_[0] &= ~0x00010000u;
}
void ConvolutionParameter::clear_axis() {
axis_ = 1;
clear_has_axis();
}
::google::protobuf::int32 ConvolutionParameter::axis() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ConvolutionParameter.axis)
return axis_;
}
void ConvolutionParameter::set_axis(::google::protobuf::int32 value) {
set_has_axis();
axis_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ConvolutionParameter.axis)
}
// optional bool force_nd_im2col = 17 [default = false];
bool ConvolutionParameter::has_force_nd_im2col() const {
return (_has_bits_[0] & 0x00020000u) != 0;
}
void ConvolutionParameter::set_has_force_nd_im2col() {
_has_bits_[0] |= 0x00020000u;
}
void ConvolutionParameter::clear_has_force_nd_im2col() {
_has_bits_[0] &= ~0x00020000u;
}
void ConvolutionParameter::clear_force_nd_im2col() {
force_nd_im2col_ = false;
clear_has_force_nd_im2col();
}
bool ConvolutionParameter::force_nd_im2col() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ConvolutionParameter.force_nd_im2col)
return force_nd_im2col_;
}
void ConvolutionParameter::set_force_nd_im2col(bool value) {
set_has_force_nd_im2col();
force_nd_im2col_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ConvolutionParameter.force_nd_im2col)
}
inline const ConvolutionParameter* ConvolutionParameter::internal_default_instance() {
return &ConvolutionParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int CropParameter::kAxisFieldNumber;
const int CropParameter::kOffsetFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
CropParameter::CropParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.CropParameter)
}
void CropParameter::InitAsDefaultInstance() {
}
CropParameter::CropParameter(const CropParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.CropParameter)
}
void CropParameter::SharedCtor() {
_cached_size_ = 0;
axis_ = 2;
}
CropParameter::~CropParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.CropParameter)
SharedDtor();
}
void CropParameter::SharedDtor() {
}
void CropParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* CropParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return CropParameter_descriptor_;
}
const CropParameter& CropParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<CropParameter> CropParameter_default_instance_;
CropParameter* CropParameter::New(::google::protobuf::Arena* arena) const {
CropParameter* n = new CropParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void CropParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.CropParameter)
axis_ = 2;
offset_.Clear();
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool CropParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.CropParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional int32 axis = 1 [default = 2];
case 1: {
if (tag == 8) {
set_has_axis();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &axis_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_offset;
break;
}
// repeated uint32 offset = 2;
case 2: {
if (tag == 16) {
parse_offset:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
1, 16, input, this->mutable_offset())));
} else if (tag == 18) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, this->mutable_offset())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_offset;
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.CropParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.CropParameter)
return false;
#undef DO_
}
void CropParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.CropParameter)
// optional int32 axis = 1 [default = 2];
if (has_axis()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(1, this->axis(), output);
}
// repeated uint32 offset = 2;
for (int i = 0; i < this->offset_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(
2, this->offset(i), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.CropParameter)
}
::google::protobuf::uint8* CropParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.CropParameter)
// optional int32 axis = 1 [default = 2];
if (has_axis()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(1, this->axis(), target);
}
// repeated uint32 offset = 2;
for (int i = 0; i < this->offset_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteUInt32ToArray(2, this->offset(i), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.CropParameter)
return target;
}
size_t CropParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.CropParameter)
size_t total_size = 0;
// optional int32 axis = 1 [default = 2];
if (has_axis()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->axis());
}
// repeated uint32 offset = 2;
{
size_t data_size = 0;
unsigned int count = this->offset_size();
for (unsigned int i = 0; i < count; i++) {
data_size += ::google::protobuf::internal::WireFormatLite::
UInt32Size(this->offset(i));
}
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->offset_size());
total_size += data_size;
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void CropParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.CropParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const CropParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const CropParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.CropParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.CropParameter)
UnsafeMergeFrom(*source);
}
}
void CropParameter::MergeFrom(const CropParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.CropParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void CropParameter::UnsafeMergeFrom(const CropParameter& from) {
GOOGLE_DCHECK(&from != this);
offset_.UnsafeMergeFrom(from.offset_);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_axis()) {
set_axis(from.axis());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void CropParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.CropParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void CropParameter::CopyFrom(const CropParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.CropParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool CropParameter::IsInitialized() const {
return true;
}
void CropParameter::Swap(CropParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void CropParameter::InternalSwap(CropParameter* other) {
std::swap(axis_, other->axis_);
offset_.UnsafeArenaSwap(&other->offset_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata CropParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = CropParameter_descriptor_;
metadata.reflection = CropParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// CropParameter
// optional int32 axis = 1 [default = 2];
bool CropParameter::has_axis() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void CropParameter::set_has_axis() {
_has_bits_[0] |= 0x00000001u;
}
void CropParameter::clear_has_axis() {
_has_bits_[0] &= ~0x00000001u;
}
void CropParameter::clear_axis() {
axis_ = 2;
clear_has_axis();
}
::google::protobuf::int32 CropParameter::axis() const {
// @@protoc_insertion_point(field_get:opencv_caffe.CropParameter.axis)
return axis_;
}
void CropParameter::set_axis(::google::protobuf::int32 value) {
set_has_axis();
axis_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.CropParameter.axis)
}
// repeated uint32 offset = 2;
int CropParameter::offset_size() const {
return offset_.size();
}
void CropParameter::clear_offset() {
offset_.Clear();
}
::google::protobuf::uint32 CropParameter::offset(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.CropParameter.offset)
return offset_.Get(index);
}
void CropParameter::set_offset(int index, ::google::protobuf::uint32 value) {
offset_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.CropParameter.offset)
}
void CropParameter::add_offset(::google::protobuf::uint32 value) {
offset_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.CropParameter.offset)
}
const ::google::protobuf::RepeatedField< ::google::protobuf::uint32 >&
CropParameter::offset() const {
// @@protoc_insertion_point(field_list:opencv_caffe.CropParameter.offset)
return offset_;
}
::google::protobuf::RepeatedField< ::google::protobuf::uint32 >*
CropParameter::mutable_offset() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.CropParameter.offset)
return &offset_;
}
inline const CropParameter* CropParameter::internal_default_instance() {
return &CropParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
const ::google::protobuf::EnumDescriptor* DataParameter_DB_descriptor() {
protobuf_AssignDescriptorsOnce();
return DataParameter_DB_descriptor_;
}
bool DataParameter_DB_IsValid(int value) {
switch (value) {
case 0:
case 1:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const DataParameter_DB DataParameter::LEVELDB;
const DataParameter_DB DataParameter::LMDB;
const DataParameter_DB DataParameter::DB_MIN;
const DataParameter_DB DataParameter::DB_MAX;
const int DataParameter::DB_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int DataParameter::kSourceFieldNumber;
const int DataParameter::kBatchSizeFieldNumber;
const int DataParameter::kRandSkipFieldNumber;
const int DataParameter::kBackendFieldNumber;
const int DataParameter::kScaleFieldNumber;
const int DataParameter::kMeanFileFieldNumber;
const int DataParameter::kCropSizeFieldNumber;
const int DataParameter::kMirrorFieldNumber;
const int DataParameter::kForceEncodedColorFieldNumber;
const int DataParameter::kPrefetchFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
DataParameter::DataParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.DataParameter)
}
void DataParameter::InitAsDefaultInstance() {
}
DataParameter::DataParameter(const DataParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.DataParameter)
}
void DataParameter::SharedCtor() {
_cached_size_ = 0;
source_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
mean_file_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
::memset(&batch_size_, 0, reinterpret_cast<char*>(&force_encoded_color_) -
reinterpret_cast<char*>(&batch_size_) + sizeof(force_encoded_color_));
scale_ = 1;
prefetch_ = 4u;
}
DataParameter::~DataParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.DataParameter)
SharedDtor();
}
void DataParameter::SharedDtor() {
source_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
mean_file_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void DataParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* DataParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return DataParameter_descriptor_;
}
const DataParameter& DataParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<DataParameter> DataParameter_default_instance_;
DataParameter* DataParameter::New(::google::protobuf::Arena* arena) const {
DataParameter* n = new DataParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void DataParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.DataParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(DataParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<DataParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
if (_has_bits_[0 / 32] & 255u) {
ZR_(batch_size_, mirror_);
if (has_source()) {
source_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
scale_ = 1;
if (has_mean_file()) {
mean_file_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
}
if (_has_bits_[8 / 32] & 768u) {
force_encoded_color_ = false;
prefetch_ = 4u;
}
#undef ZR_HELPER_
#undef ZR_
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool DataParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.DataParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional string source = 1;
case 1: {
if (tag == 10) {
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_source()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->source().data(), this->source().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.DataParameter.source");
} else {
goto handle_unusual;
}
if (input->ExpectTag(21)) goto parse_scale;
break;
}
// optional float scale = 2 [default = 1];
case 2: {
if (tag == 21) {
parse_scale:
set_has_scale();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &scale_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(26)) goto parse_mean_file;
break;
}
// optional string mean_file = 3;
case 3: {
if (tag == 26) {
parse_mean_file:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_mean_file()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->mean_file().data(), this->mean_file().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.DataParameter.mean_file");
} else {
goto handle_unusual;
}
if (input->ExpectTag(32)) goto parse_batch_size;
break;
}
// optional uint32 batch_size = 4;
case 4: {
if (tag == 32) {
parse_batch_size:
set_has_batch_size();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &batch_size_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(40)) goto parse_crop_size;
break;
}
// optional uint32 crop_size = 5 [default = 0];
case 5: {
if (tag == 40) {
parse_crop_size:
set_has_crop_size();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &crop_size_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(48)) goto parse_mirror;
break;
}
// optional bool mirror = 6 [default = false];
case 6: {
if (tag == 48) {
parse_mirror:
set_has_mirror();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &mirror_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(56)) goto parse_rand_skip;
break;
}
// optional uint32 rand_skip = 7 [default = 0];
case 7: {
if (tag == 56) {
parse_rand_skip:
set_has_rand_skip();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &rand_skip_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(64)) goto parse_backend;
break;
}
// optional .opencv_caffe.DataParameter.DB backend = 8 [default = LEVELDB];
case 8: {
if (tag == 64) {
parse_backend:
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::DataParameter_DB_IsValid(value)) {
set_backend(static_cast< ::opencv_caffe::DataParameter_DB >(value));
} else {
mutable_unknown_fields()->AddVarint(8, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectTag(72)) goto parse_force_encoded_color;
break;
}
// optional bool force_encoded_color = 9 [default = false];
case 9: {
if (tag == 72) {
parse_force_encoded_color:
set_has_force_encoded_color();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &force_encoded_color_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(80)) goto parse_prefetch;
break;
}
// optional uint32 prefetch = 10 [default = 4];
case 10: {
if (tag == 80) {
parse_prefetch:
set_has_prefetch();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &prefetch_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.DataParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.DataParameter)
return false;
#undef DO_
}
void DataParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.DataParameter)
// optional string source = 1;
if (has_source()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->source().data(), this->source().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.DataParameter.source");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
1, this->source(), output);
}
// optional float scale = 2 [default = 1];
if (has_scale()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(2, this->scale(), output);
}
// optional string mean_file = 3;
if (has_mean_file()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->mean_file().data(), this->mean_file().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.DataParameter.mean_file");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
3, this->mean_file(), output);
}
// optional uint32 batch_size = 4;
if (has_batch_size()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(4, this->batch_size(), output);
}
// optional uint32 crop_size = 5 [default = 0];
if (has_crop_size()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(5, this->crop_size(), output);
}
// optional bool mirror = 6 [default = false];
if (has_mirror()) {
::google::protobuf::internal::WireFormatLite::WriteBool(6, this->mirror(), output);
}
// optional uint32 rand_skip = 7 [default = 0];
if (has_rand_skip()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(7, this->rand_skip(), output);
}
// optional .opencv_caffe.DataParameter.DB backend = 8 [default = LEVELDB];
if (has_backend()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
8, this->backend(), output);
}
// optional bool force_encoded_color = 9 [default = false];
if (has_force_encoded_color()) {
::google::protobuf::internal::WireFormatLite::WriteBool(9, this->force_encoded_color(), output);
}
// optional uint32 prefetch = 10 [default = 4];
if (has_prefetch()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(10, this->prefetch(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.DataParameter)
}
::google::protobuf::uint8* DataParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.DataParameter)
// optional string source = 1;
if (has_source()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->source().data(), this->source().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.DataParameter.source");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
1, this->source(), target);
}
// optional float scale = 2 [default = 1];
if (has_scale()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(2, this->scale(), target);
}
// optional string mean_file = 3;
if (has_mean_file()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->mean_file().data(), this->mean_file().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.DataParameter.mean_file");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
3, this->mean_file(), target);
}
// optional uint32 batch_size = 4;
if (has_batch_size()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(4, this->batch_size(), target);
}
// optional uint32 crop_size = 5 [default = 0];
if (has_crop_size()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(5, this->crop_size(), target);
}
// optional bool mirror = 6 [default = false];
if (has_mirror()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(6, this->mirror(), target);
}
// optional uint32 rand_skip = 7 [default = 0];
if (has_rand_skip()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(7, this->rand_skip(), target);
}
// optional .opencv_caffe.DataParameter.DB backend = 8 [default = LEVELDB];
if (has_backend()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
8, this->backend(), target);
}
// optional bool force_encoded_color = 9 [default = false];
if (has_force_encoded_color()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(9, this->force_encoded_color(), target);
}
// optional uint32 prefetch = 10 [default = 4];
if (has_prefetch()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(10, this->prefetch(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.DataParameter)
return target;
}
size_t DataParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.DataParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 255u) {
// optional string source = 1;
if (has_source()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->source());
}
// optional uint32 batch_size = 4;
if (has_batch_size()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->batch_size());
}
// optional uint32 rand_skip = 7 [default = 0];
if (has_rand_skip()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->rand_skip());
}
// optional .opencv_caffe.DataParameter.DB backend = 8 [default = LEVELDB];
if (has_backend()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->backend());
}
// optional float scale = 2 [default = 1];
if (has_scale()) {
total_size += 1 + 4;
}
// optional string mean_file = 3;
if (has_mean_file()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->mean_file());
}
// optional uint32 crop_size = 5 [default = 0];
if (has_crop_size()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->crop_size());
}
// optional bool mirror = 6 [default = false];
if (has_mirror()) {
total_size += 1 + 1;
}
}
if (_has_bits_[8 / 32] & 768u) {
// optional bool force_encoded_color = 9 [default = false];
if (has_force_encoded_color()) {
total_size += 1 + 1;
}
// optional uint32 prefetch = 10 [default = 4];
if (has_prefetch()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->prefetch());
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void DataParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.DataParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const DataParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const DataParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.DataParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.DataParameter)
UnsafeMergeFrom(*source);
}
}
void DataParameter::MergeFrom(const DataParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.DataParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void DataParameter::UnsafeMergeFrom(const DataParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_source()) {
set_has_source();
source_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.source_);
}
if (from.has_batch_size()) {
set_batch_size(from.batch_size());
}
if (from.has_rand_skip()) {
set_rand_skip(from.rand_skip());
}
if (from.has_backend()) {
set_backend(from.backend());
}
if (from.has_scale()) {
set_scale(from.scale());
}
if (from.has_mean_file()) {
set_has_mean_file();
mean_file_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.mean_file_);
}
if (from.has_crop_size()) {
set_crop_size(from.crop_size());
}
if (from.has_mirror()) {
set_mirror(from.mirror());
}
}
if (from._has_bits_[8 / 32] & (0xffu << (8 % 32))) {
if (from.has_force_encoded_color()) {
set_force_encoded_color(from.force_encoded_color());
}
if (from.has_prefetch()) {
set_prefetch(from.prefetch());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void DataParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.DataParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void DataParameter::CopyFrom(const DataParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.DataParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool DataParameter::IsInitialized() const {
return true;
}
void DataParameter::Swap(DataParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void DataParameter::InternalSwap(DataParameter* other) {
source_.Swap(&other->source_);
std::swap(batch_size_, other->batch_size_);
std::swap(rand_skip_, other->rand_skip_);
std::swap(backend_, other->backend_);
std::swap(scale_, other->scale_);
mean_file_.Swap(&other->mean_file_);
std::swap(crop_size_, other->crop_size_);
std::swap(mirror_, other->mirror_);
std::swap(force_encoded_color_, other->force_encoded_color_);
std::swap(prefetch_, other->prefetch_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata DataParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = DataParameter_descriptor_;
metadata.reflection = DataParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// DataParameter
// optional string source = 1;
bool DataParameter::has_source() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void DataParameter::set_has_source() {
_has_bits_[0] |= 0x00000001u;
}
void DataParameter::clear_has_source() {
_has_bits_[0] &= ~0x00000001u;
}
void DataParameter::clear_source() {
source_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_source();
}
const ::std::string& DataParameter::source() const {
// @@protoc_insertion_point(field_get:opencv_caffe.DataParameter.source)
return source_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void DataParameter::set_source(const ::std::string& value) {
set_has_source();
source_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.DataParameter.source)
}
void DataParameter::set_source(const char* value) {
set_has_source();
source_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.DataParameter.source)
}
void DataParameter::set_source(const char* value, size_t size) {
set_has_source();
source_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.DataParameter.source)
}
::std::string* DataParameter::mutable_source() {
set_has_source();
// @@protoc_insertion_point(field_mutable:opencv_caffe.DataParameter.source)
return source_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* DataParameter::release_source() {
// @@protoc_insertion_point(field_release:opencv_caffe.DataParameter.source)
clear_has_source();
return source_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void DataParameter::set_allocated_source(::std::string* source) {
if (source != NULL) {
set_has_source();
} else {
clear_has_source();
}
source_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), source);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.DataParameter.source)
}
// optional uint32 batch_size = 4;
bool DataParameter::has_batch_size() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void DataParameter::set_has_batch_size() {
_has_bits_[0] |= 0x00000002u;
}
void DataParameter::clear_has_batch_size() {
_has_bits_[0] &= ~0x00000002u;
}
void DataParameter::clear_batch_size() {
batch_size_ = 0u;
clear_has_batch_size();
}
::google::protobuf::uint32 DataParameter::batch_size() const {
// @@protoc_insertion_point(field_get:opencv_caffe.DataParameter.batch_size)
return batch_size_;
}
void DataParameter::set_batch_size(::google::protobuf::uint32 value) {
set_has_batch_size();
batch_size_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.DataParameter.batch_size)
}
// optional uint32 rand_skip = 7 [default = 0];
bool DataParameter::has_rand_skip() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void DataParameter::set_has_rand_skip() {
_has_bits_[0] |= 0x00000004u;
}
void DataParameter::clear_has_rand_skip() {
_has_bits_[0] &= ~0x00000004u;
}
void DataParameter::clear_rand_skip() {
rand_skip_ = 0u;
clear_has_rand_skip();
}
::google::protobuf::uint32 DataParameter::rand_skip() const {
// @@protoc_insertion_point(field_get:opencv_caffe.DataParameter.rand_skip)
return rand_skip_;
}
void DataParameter::set_rand_skip(::google::protobuf::uint32 value) {
set_has_rand_skip();
rand_skip_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.DataParameter.rand_skip)
}
// optional .opencv_caffe.DataParameter.DB backend = 8 [default = LEVELDB];
bool DataParameter::has_backend() const {
return (_has_bits_[0] & 0x00000008u) != 0;
}
void DataParameter::set_has_backend() {
_has_bits_[0] |= 0x00000008u;
}
void DataParameter::clear_has_backend() {
_has_bits_[0] &= ~0x00000008u;
}
void DataParameter::clear_backend() {
backend_ = 0;
clear_has_backend();
}
::opencv_caffe::DataParameter_DB DataParameter::backend() const {
// @@protoc_insertion_point(field_get:opencv_caffe.DataParameter.backend)
return static_cast< ::opencv_caffe::DataParameter_DB >(backend_);
}
void DataParameter::set_backend(::opencv_caffe::DataParameter_DB value) {
assert(::opencv_caffe::DataParameter_DB_IsValid(value));
set_has_backend();
backend_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.DataParameter.backend)
}
// optional float scale = 2 [default = 1];
bool DataParameter::has_scale() const {
return (_has_bits_[0] & 0x00000010u) != 0;
}
void DataParameter::set_has_scale() {
_has_bits_[0] |= 0x00000010u;
}
void DataParameter::clear_has_scale() {
_has_bits_[0] &= ~0x00000010u;
}
void DataParameter::clear_scale() {
scale_ = 1;
clear_has_scale();
}
float DataParameter::scale() const {
// @@protoc_insertion_point(field_get:opencv_caffe.DataParameter.scale)
return scale_;
}
void DataParameter::set_scale(float value) {
set_has_scale();
scale_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.DataParameter.scale)
}
// optional string mean_file = 3;
bool DataParameter::has_mean_file() const {
return (_has_bits_[0] & 0x00000020u) != 0;
}
void DataParameter::set_has_mean_file() {
_has_bits_[0] |= 0x00000020u;
}
void DataParameter::clear_has_mean_file() {
_has_bits_[0] &= ~0x00000020u;
}
void DataParameter::clear_mean_file() {
mean_file_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_mean_file();
}
const ::std::string& DataParameter::mean_file() const {
// @@protoc_insertion_point(field_get:opencv_caffe.DataParameter.mean_file)
return mean_file_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void DataParameter::set_mean_file(const ::std::string& value) {
set_has_mean_file();
mean_file_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.DataParameter.mean_file)
}
void DataParameter::set_mean_file(const char* value) {
set_has_mean_file();
mean_file_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.DataParameter.mean_file)
}
void DataParameter::set_mean_file(const char* value, size_t size) {
set_has_mean_file();
mean_file_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.DataParameter.mean_file)
}
::std::string* DataParameter::mutable_mean_file() {
set_has_mean_file();
// @@protoc_insertion_point(field_mutable:opencv_caffe.DataParameter.mean_file)
return mean_file_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* DataParameter::release_mean_file() {
// @@protoc_insertion_point(field_release:opencv_caffe.DataParameter.mean_file)
clear_has_mean_file();
return mean_file_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void DataParameter::set_allocated_mean_file(::std::string* mean_file) {
if (mean_file != NULL) {
set_has_mean_file();
} else {
clear_has_mean_file();
}
mean_file_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), mean_file);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.DataParameter.mean_file)
}
// optional uint32 crop_size = 5 [default = 0];
bool DataParameter::has_crop_size() const {
return (_has_bits_[0] & 0x00000040u) != 0;
}
void DataParameter::set_has_crop_size() {
_has_bits_[0] |= 0x00000040u;
}
void DataParameter::clear_has_crop_size() {
_has_bits_[0] &= ~0x00000040u;
}
void DataParameter::clear_crop_size() {
crop_size_ = 0u;
clear_has_crop_size();
}
::google::protobuf::uint32 DataParameter::crop_size() const {
// @@protoc_insertion_point(field_get:opencv_caffe.DataParameter.crop_size)
return crop_size_;
}
void DataParameter::set_crop_size(::google::protobuf::uint32 value) {
set_has_crop_size();
crop_size_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.DataParameter.crop_size)
}
// optional bool mirror = 6 [default = false];
bool DataParameter::has_mirror() const {
return (_has_bits_[0] & 0x00000080u) != 0;
}
void DataParameter::set_has_mirror() {
_has_bits_[0] |= 0x00000080u;
}
void DataParameter::clear_has_mirror() {
_has_bits_[0] &= ~0x00000080u;
}
void DataParameter::clear_mirror() {
mirror_ = false;
clear_has_mirror();
}
bool DataParameter::mirror() const {
// @@protoc_insertion_point(field_get:opencv_caffe.DataParameter.mirror)
return mirror_;
}
void DataParameter::set_mirror(bool value) {
set_has_mirror();
mirror_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.DataParameter.mirror)
}
// optional bool force_encoded_color = 9 [default = false];
bool DataParameter::has_force_encoded_color() const {
return (_has_bits_[0] & 0x00000100u) != 0;
}
void DataParameter::set_has_force_encoded_color() {
_has_bits_[0] |= 0x00000100u;
}
void DataParameter::clear_has_force_encoded_color() {
_has_bits_[0] &= ~0x00000100u;
}
void DataParameter::clear_force_encoded_color() {
force_encoded_color_ = false;
clear_has_force_encoded_color();
}
bool DataParameter::force_encoded_color() const {
// @@protoc_insertion_point(field_get:opencv_caffe.DataParameter.force_encoded_color)
return force_encoded_color_;
}
void DataParameter::set_force_encoded_color(bool value) {
set_has_force_encoded_color();
force_encoded_color_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.DataParameter.force_encoded_color)
}
// optional uint32 prefetch = 10 [default = 4];
bool DataParameter::has_prefetch() const {
return (_has_bits_[0] & 0x00000200u) != 0;
}
void DataParameter::set_has_prefetch() {
_has_bits_[0] |= 0x00000200u;
}
void DataParameter::clear_has_prefetch() {
_has_bits_[0] &= ~0x00000200u;
}
void DataParameter::clear_prefetch() {
prefetch_ = 4u;
clear_has_prefetch();
}
::google::protobuf::uint32 DataParameter::prefetch() const {
// @@protoc_insertion_point(field_get:opencv_caffe.DataParameter.prefetch)
return prefetch_;
}
void DataParameter::set_prefetch(::google::protobuf::uint32 value) {
set_has_prefetch();
prefetch_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.DataParameter.prefetch)
}
inline const DataParameter* DataParameter::internal_default_instance() {
return &DataParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int NonMaximumSuppressionParameter::kNmsThresholdFieldNumber;
const int NonMaximumSuppressionParameter::kTopKFieldNumber;
const int NonMaximumSuppressionParameter::kEtaFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
NonMaximumSuppressionParameter::NonMaximumSuppressionParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.NonMaximumSuppressionParameter)
}
void NonMaximumSuppressionParameter::InitAsDefaultInstance() {
}
NonMaximumSuppressionParameter::NonMaximumSuppressionParameter(const NonMaximumSuppressionParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.NonMaximumSuppressionParameter)
}
void NonMaximumSuppressionParameter::SharedCtor() {
_cached_size_ = 0;
top_k_ = 0;
nms_threshold_ = 0.3f;
eta_ = 1;
}
NonMaximumSuppressionParameter::~NonMaximumSuppressionParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.NonMaximumSuppressionParameter)
SharedDtor();
}
void NonMaximumSuppressionParameter::SharedDtor() {
}
void NonMaximumSuppressionParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* NonMaximumSuppressionParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return NonMaximumSuppressionParameter_descriptor_;
}
const NonMaximumSuppressionParameter& NonMaximumSuppressionParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<NonMaximumSuppressionParameter> NonMaximumSuppressionParameter_default_instance_;
NonMaximumSuppressionParameter* NonMaximumSuppressionParameter::New(::google::protobuf::Arena* arena) const {
NonMaximumSuppressionParameter* n = new NonMaximumSuppressionParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void NonMaximumSuppressionParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.NonMaximumSuppressionParameter)
if (_has_bits_[0 / 32] & 7u) {
nms_threshold_ = 0.3f;
top_k_ = 0;
eta_ = 1;
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool NonMaximumSuppressionParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.NonMaximumSuppressionParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional float nms_threshold = 1 [default = 0.3];
case 1: {
if (tag == 13) {
set_has_nms_threshold();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &nms_threshold_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_top_k;
break;
}
// optional int32 top_k = 2;
case 2: {
if (tag == 16) {
parse_top_k:
set_has_top_k();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &top_k_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(29)) goto parse_eta;
break;
}
// optional float eta = 3 [default = 1];
case 3: {
if (tag == 29) {
parse_eta:
set_has_eta();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &eta_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.NonMaximumSuppressionParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.NonMaximumSuppressionParameter)
return false;
#undef DO_
}
void NonMaximumSuppressionParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.NonMaximumSuppressionParameter)
// optional float nms_threshold = 1 [default = 0.3];
if (has_nms_threshold()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(1, this->nms_threshold(), output);
}
// optional int32 top_k = 2;
if (has_top_k()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->top_k(), output);
}
// optional float eta = 3 [default = 1];
if (has_eta()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(3, this->eta(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.NonMaximumSuppressionParameter)
}
::google::protobuf::uint8* NonMaximumSuppressionParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.NonMaximumSuppressionParameter)
// optional float nms_threshold = 1 [default = 0.3];
if (has_nms_threshold()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(1, this->nms_threshold(), target);
}
// optional int32 top_k = 2;
if (has_top_k()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(2, this->top_k(), target);
}
// optional float eta = 3 [default = 1];
if (has_eta()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(3, this->eta(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.NonMaximumSuppressionParameter)
return target;
}
size_t NonMaximumSuppressionParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.NonMaximumSuppressionParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 7u) {
// optional float nms_threshold = 1 [default = 0.3];
if (has_nms_threshold()) {
total_size += 1 + 4;
}
// optional int32 top_k = 2;
if (has_top_k()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->top_k());
}
// optional float eta = 3 [default = 1];
if (has_eta()) {
total_size += 1 + 4;
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void NonMaximumSuppressionParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.NonMaximumSuppressionParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const NonMaximumSuppressionParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const NonMaximumSuppressionParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.NonMaximumSuppressionParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.NonMaximumSuppressionParameter)
UnsafeMergeFrom(*source);
}
}
void NonMaximumSuppressionParameter::MergeFrom(const NonMaximumSuppressionParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.NonMaximumSuppressionParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void NonMaximumSuppressionParameter::UnsafeMergeFrom(const NonMaximumSuppressionParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_nms_threshold()) {
set_nms_threshold(from.nms_threshold());
}
if (from.has_top_k()) {
set_top_k(from.top_k());
}
if (from.has_eta()) {
set_eta(from.eta());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void NonMaximumSuppressionParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.NonMaximumSuppressionParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void NonMaximumSuppressionParameter::CopyFrom(const NonMaximumSuppressionParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.NonMaximumSuppressionParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool NonMaximumSuppressionParameter::IsInitialized() const {
return true;
}
void NonMaximumSuppressionParameter::Swap(NonMaximumSuppressionParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void NonMaximumSuppressionParameter::InternalSwap(NonMaximumSuppressionParameter* other) {
std::swap(nms_threshold_, other->nms_threshold_);
std::swap(top_k_, other->top_k_);
std::swap(eta_, other->eta_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata NonMaximumSuppressionParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = NonMaximumSuppressionParameter_descriptor_;
metadata.reflection = NonMaximumSuppressionParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// NonMaximumSuppressionParameter
// optional float nms_threshold = 1 [default = 0.3];
bool NonMaximumSuppressionParameter::has_nms_threshold() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void NonMaximumSuppressionParameter::set_has_nms_threshold() {
_has_bits_[0] |= 0x00000001u;
}
void NonMaximumSuppressionParameter::clear_has_nms_threshold() {
_has_bits_[0] &= ~0x00000001u;
}
void NonMaximumSuppressionParameter::clear_nms_threshold() {
nms_threshold_ = 0.3f;
clear_has_nms_threshold();
}
float NonMaximumSuppressionParameter::nms_threshold() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NonMaximumSuppressionParameter.nms_threshold)
return nms_threshold_;
}
void NonMaximumSuppressionParameter::set_nms_threshold(float value) {
set_has_nms_threshold();
nms_threshold_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.NonMaximumSuppressionParameter.nms_threshold)
}
// optional int32 top_k = 2;
bool NonMaximumSuppressionParameter::has_top_k() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void NonMaximumSuppressionParameter::set_has_top_k() {
_has_bits_[0] |= 0x00000002u;
}
void NonMaximumSuppressionParameter::clear_has_top_k() {
_has_bits_[0] &= ~0x00000002u;
}
void NonMaximumSuppressionParameter::clear_top_k() {
top_k_ = 0;
clear_has_top_k();
}
::google::protobuf::int32 NonMaximumSuppressionParameter::top_k() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NonMaximumSuppressionParameter.top_k)
return top_k_;
}
void NonMaximumSuppressionParameter::set_top_k(::google::protobuf::int32 value) {
set_has_top_k();
top_k_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.NonMaximumSuppressionParameter.top_k)
}
// optional float eta = 3 [default = 1];
bool NonMaximumSuppressionParameter::has_eta() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void NonMaximumSuppressionParameter::set_has_eta() {
_has_bits_[0] |= 0x00000004u;
}
void NonMaximumSuppressionParameter::clear_has_eta() {
_has_bits_[0] &= ~0x00000004u;
}
void NonMaximumSuppressionParameter::clear_eta() {
eta_ = 1;
clear_has_eta();
}
float NonMaximumSuppressionParameter::eta() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NonMaximumSuppressionParameter.eta)
return eta_;
}
void NonMaximumSuppressionParameter::set_eta(float value) {
set_has_eta();
eta_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.NonMaximumSuppressionParameter.eta)
}
inline const NonMaximumSuppressionParameter* NonMaximumSuppressionParameter::internal_default_instance() {
return &NonMaximumSuppressionParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int SaveOutputParameter::kOutputDirectoryFieldNumber;
const int SaveOutputParameter::kOutputNamePrefixFieldNumber;
const int SaveOutputParameter::kOutputFormatFieldNumber;
const int SaveOutputParameter::kLabelMapFileFieldNumber;
const int SaveOutputParameter::kNameSizeFileFieldNumber;
const int SaveOutputParameter::kNumTestImageFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
SaveOutputParameter::SaveOutputParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.SaveOutputParameter)
}
void SaveOutputParameter::InitAsDefaultInstance() {
}
SaveOutputParameter::SaveOutputParameter(const SaveOutputParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.SaveOutputParameter)
}
void SaveOutputParameter::SharedCtor() {
_cached_size_ = 0;
output_directory_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
output_name_prefix_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
output_format_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
label_map_file_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
name_size_file_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
num_test_image_ = 0u;
}
SaveOutputParameter::~SaveOutputParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.SaveOutputParameter)
SharedDtor();
}
void SaveOutputParameter::SharedDtor() {
output_directory_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
output_name_prefix_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
output_format_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
label_map_file_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
name_size_file_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void SaveOutputParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* SaveOutputParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return SaveOutputParameter_descriptor_;
}
const SaveOutputParameter& SaveOutputParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<SaveOutputParameter> SaveOutputParameter_default_instance_;
SaveOutputParameter* SaveOutputParameter::New(::google::protobuf::Arena* arena) const {
SaveOutputParameter* n = new SaveOutputParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void SaveOutputParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.SaveOutputParameter)
if (_has_bits_[0 / 32] & 63u) {
if (has_output_directory()) {
output_directory_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
if (has_output_name_prefix()) {
output_name_prefix_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
if (has_output_format()) {
output_format_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
if (has_label_map_file()) {
label_map_file_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
if (has_name_size_file()) {
name_size_file_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
num_test_image_ = 0u;
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool SaveOutputParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.SaveOutputParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional string output_directory = 1;
case 1: {
if (tag == 10) {
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_output_directory()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->output_directory().data(), this->output_directory().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.SaveOutputParameter.output_directory");
} else {
goto handle_unusual;
}
if (input->ExpectTag(18)) goto parse_output_name_prefix;
break;
}
// optional string output_name_prefix = 2;
case 2: {
if (tag == 18) {
parse_output_name_prefix:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_output_name_prefix()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->output_name_prefix().data(), this->output_name_prefix().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.SaveOutputParameter.output_name_prefix");
} else {
goto handle_unusual;
}
if (input->ExpectTag(26)) goto parse_output_format;
break;
}
// optional string output_format = 3;
case 3: {
if (tag == 26) {
parse_output_format:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_output_format()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->output_format().data(), this->output_format().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.SaveOutputParameter.output_format");
} else {
goto handle_unusual;
}
if (input->ExpectTag(34)) goto parse_label_map_file;
break;
}
// optional string label_map_file = 4;
case 4: {
if (tag == 34) {
parse_label_map_file:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_label_map_file()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->label_map_file().data(), this->label_map_file().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.SaveOutputParameter.label_map_file");
} else {
goto handle_unusual;
}
if (input->ExpectTag(42)) goto parse_name_size_file;
break;
}
// optional string name_size_file = 5;
case 5: {
if (tag == 42) {
parse_name_size_file:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_name_size_file()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->name_size_file().data(), this->name_size_file().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.SaveOutputParameter.name_size_file");
} else {
goto handle_unusual;
}
if (input->ExpectTag(48)) goto parse_num_test_image;
break;
}
// optional uint32 num_test_image = 6;
case 6: {
if (tag == 48) {
parse_num_test_image:
set_has_num_test_image();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &num_test_image_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.SaveOutputParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.SaveOutputParameter)
return false;
#undef DO_
}
void SaveOutputParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.SaveOutputParameter)
// optional string output_directory = 1;
if (has_output_directory()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->output_directory().data(), this->output_directory().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SaveOutputParameter.output_directory");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
1, this->output_directory(), output);
}
// optional string output_name_prefix = 2;
if (has_output_name_prefix()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->output_name_prefix().data(), this->output_name_prefix().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SaveOutputParameter.output_name_prefix");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
2, this->output_name_prefix(), output);
}
// optional string output_format = 3;
if (has_output_format()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->output_format().data(), this->output_format().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SaveOutputParameter.output_format");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
3, this->output_format(), output);
}
// optional string label_map_file = 4;
if (has_label_map_file()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->label_map_file().data(), this->label_map_file().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SaveOutputParameter.label_map_file");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
4, this->label_map_file(), output);
}
// optional string name_size_file = 5;
if (has_name_size_file()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->name_size_file().data(), this->name_size_file().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SaveOutputParameter.name_size_file");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
5, this->name_size_file(), output);
}
// optional uint32 num_test_image = 6;
if (has_num_test_image()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(6, this->num_test_image(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.SaveOutputParameter)
}
::google::protobuf::uint8* SaveOutputParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.SaveOutputParameter)
// optional string output_directory = 1;
if (has_output_directory()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->output_directory().data(), this->output_directory().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SaveOutputParameter.output_directory");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
1, this->output_directory(), target);
}
// optional string output_name_prefix = 2;
if (has_output_name_prefix()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->output_name_prefix().data(), this->output_name_prefix().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SaveOutputParameter.output_name_prefix");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
2, this->output_name_prefix(), target);
}
// optional string output_format = 3;
if (has_output_format()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->output_format().data(), this->output_format().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SaveOutputParameter.output_format");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
3, this->output_format(), target);
}
// optional string label_map_file = 4;
if (has_label_map_file()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->label_map_file().data(), this->label_map_file().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SaveOutputParameter.label_map_file");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
4, this->label_map_file(), target);
}
// optional string name_size_file = 5;
if (has_name_size_file()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->name_size_file().data(), this->name_size_file().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.SaveOutputParameter.name_size_file");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
5, this->name_size_file(), target);
}
// optional uint32 num_test_image = 6;
if (has_num_test_image()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(6, this->num_test_image(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.SaveOutputParameter)
return target;
}
size_t SaveOutputParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.SaveOutputParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 63u) {
// optional string output_directory = 1;
if (has_output_directory()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->output_directory());
}
// optional string output_name_prefix = 2;
if (has_output_name_prefix()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->output_name_prefix());
}
// optional string output_format = 3;
if (has_output_format()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->output_format());
}
// optional string label_map_file = 4;
if (has_label_map_file()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->label_map_file());
}
// optional string name_size_file = 5;
if (has_name_size_file()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->name_size_file());
}
// optional uint32 num_test_image = 6;
if (has_num_test_image()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->num_test_image());
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void SaveOutputParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.SaveOutputParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const SaveOutputParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const SaveOutputParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.SaveOutputParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.SaveOutputParameter)
UnsafeMergeFrom(*source);
}
}
void SaveOutputParameter::MergeFrom(const SaveOutputParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.SaveOutputParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void SaveOutputParameter::UnsafeMergeFrom(const SaveOutputParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_output_directory()) {
set_has_output_directory();
output_directory_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.output_directory_);
}
if (from.has_output_name_prefix()) {
set_has_output_name_prefix();
output_name_prefix_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.output_name_prefix_);
}
if (from.has_output_format()) {
set_has_output_format();
output_format_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.output_format_);
}
if (from.has_label_map_file()) {
set_has_label_map_file();
label_map_file_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.label_map_file_);
}
if (from.has_name_size_file()) {
set_has_name_size_file();
name_size_file_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.name_size_file_);
}
if (from.has_num_test_image()) {
set_num_test_image(from.num_test_image());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void SaveOutputParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.SaveOutputParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void SaveOutputParameter::CopyFrom(const SaveOutputParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.SaveOutputParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool SaveOutputParameter::IsInitialized() const {
return true;
}
void SaveOutputParameter::Swap(SaveOutputParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void SaveOutputParameter::InternalSwap(SaveOutputParameter* other) {
output_directory_.Swap(&other->output_directory_);
output_name_prefix_.Swap(&other->output_name_prefix_);
output_format_.Swap(&other->output_format_);
label_map_file_.Swap(&other->label_map_file_);
name_size_file_.Swap(&other->name_size_file_);
std::swap(num_test_image_, other->num_test_image_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata SaveOutputParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = SaveOutputParameter_descriptor_;
metadata.reflection = SaveOutputParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// SaveOutputParameter
// optional string output_directory = 1;
bool SaveOutputParameter::has_output_directory() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void SaveOutputParameter::set_has_output_directory() {
_has_bits_[0] |= 0x00000001u;
}
void SaveOutputParameter::clear_has_output_directory() {
_has_bits_[0] &= ~0x00000001u;
}
void SaveOutputParameter::clear_output_directory() {
output_directory_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_output_directory();
}
const ::std::string& SaveOutputParameter::output_directory() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SaveOutputParameter.output_directory)
return output_directory_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void SaveOutputParameter::set_output_directory(const ::std::string& value) {
set_has_output_directory();
output_directory_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.SaveOutputParameter.output_directory)
}
void SaveOutputParameter::set_output_directory(const char* value) {
set_has_output_directory();
output_directory_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.SaveOutputParameter.output_directory)
}
void SaveOutputParameter::set_output_directory(const char* value, size_t size) {
set_has_output_directory();
output_directory_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.SaveOutputParameter.output_directory)
}
::std::string* SaveOutputParameter::mutable_output_directory() {
set_has_output_directory();
// @@protoc_insertion_point(field_mutable:opencv_caffe.SaveOutputParameter.output_directory)
return output_directory_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* SaveOutputParameter::release_output_directory() {
// @@protoc_insertion_point(field_release:opencv_caffe.SaveOutputParameter.output_directory)
clear_has_output_directory();
return output_directory_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void SaveOutputParameter::set_allocated_output_directory(::std::string* output_directory) {
if (output_directory != NULL) {
set_has_output_directory();
} else {
clear_has_output_directory();
}
output_directory_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), output_directory);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.SaveOutputParameter.output_directory)
}
// optional string output_name_prefix = 2;
bool SaveOutputParameter::has_output_name_prefix() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void SaveOutputParameter::set_has_output_name_prefix() {
_has_bits_[0] |= 0x00000002u;
}
void SaveOutputParameter::clear_has_output_name_prefix() {
_has_bits_[0] &= ~0x00000002u;
}
void SaveOutputParameter::clear_output_name_prefix() {
output_name_prefix_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_output_name_prefix();
}
const ::std::string& SaveOutputParameter::output_name_prefix() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SaveOutputParameter.output_name_prefix)
return output_name_prefix_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void SaveOutputParameter::set_output_name_prefix(const ::std::string& value) {
set_has_output_name_prefix();
output_name_prefix_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.SaveOutputParameter.output_name_prefix)
}
void SaveOutputParameter::set_output_name_prefix(const char* value) {
set_has_output_name_prefix();
output_name_prefix_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.SaveOutputParameter.output_name_prefix)
}
void SaveOutputParameter::set_output_name_prefix(const char* value, size_t size) {
set_has_output_name_prefix();
output_name_prefix_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.SaveOutputParameter.output_name_prefix)
}
::std::string* SaveOutputParameter::mutable_output_name_prefix() {
set_has_output_name_prefix();
// @@protoc_insertion_point(field_mutable:opencv_caffe.SaveOutputParameter.output_name_prefix)
return output_name_prefix_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* SaveOutputParameter::release_output_name_prefix() {
// @@protoc_insertion_point(field_release:opencv_caffe.SaveOutputParameter.output_name_prefix)
clear_has_output_name_prefix();
return output_name_prefix_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void SaveOutputParameter::set_allocated_output_name_prefix(::std::string* output_name_prefix) {
if (output_name_prefix != NULL) {
set_has_output_name_prefix();
} else {
clear_has_output_name_prefix();
}
output_name_prefix_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), output_name_prefix);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.SaveOutputParameter.output_name_prefix)
}
// optional string output_format = 3;
bool SaveOutputParameter::has_output_format() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void SaveOutputParameter::set_has_output_format() {
_has_bits_[0] |= 0x00000004u;
}
void SaveOutputParameter::clear_has_output_format() {
_has_bits_[0] &= ~0x00000004u;
}
void SaveOutputParameter::clear_output_format() {
output_format_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_output_format();
}
const ::std::string& SaveOutputParameter::output_format() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SaveOutputParameter.output_format)
return output_format_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void SaveOutputParameter::set_output_format(const ::std::string& value) {
set_has_output_format();
output_format_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.SaveOutputParameter.output_format)
}
void SaveOutputParameter::set_output_format(const char* value) {
set_has_output_format();
output_format_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.SaveOutputParameter.output_format)
}
void SaveOutputParameter::set_output_format(const char* value, size_t size) {
set_has_output_format();
output_format_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.SaveOutputParameter.output_format)
}
::std::string* SaveOutputParameter::mutable_output_format() {
set_has_output_format();
// @@protoc_insertion_point(field_mutable:opencv_caffe.SaveOutputParameter.output_format)
return output_format_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* SaveOutputParameter::release_output_format() {
// @@protoc_insertion_point(field_release:opencv_caffe.SaveOutputParameter.output_format)
clear_has_output_format();
return output_format_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void SaveOutputParameter::set_allocated_output_format(::std::string* output_format) {
if (output_format != NULL) {
set_has_output_format();
} else {
clear_has_output_format();
}
output_format_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), output_format);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.SaveOutputParameter.output_format)
}
// optional string label_map_file = 4;
bool SaveOutputParameter::has_label_map_file() const {
return (_has_bits_[0] & 0x00000008u) != 0;
}
void SaveOutputParameter::set_has_label_map_file() {
_has_bits_[0] |= 0x00000008u;
}
void SaveOutputParameter::clear_has_label_map_file() {
_has_bits_[0] &= ~0x00000008u;
}
void SaveOutputParameter::clear_label_map_file() {
label_map_file_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_label_map_file();
}
const ::std::string& SaveOutputParameter::label_map_file() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SaveOutputParameter.label_map_file)
return label_map_file_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void SaveOutputParameter::set_label_map_file(const ::std::string& value) {
set_has_label_map_file();
label_map_file_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.SaveOutputParameter.label_map_file)
}
void SaveOutputParameter::set_label_map_file(const char* value) {
set_has_label_map_file();
label_map_file_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.SaveOutputParameter.label_map_file)
}
void SaveOutputParameter::set_label_map_file(const char* value, size_t size) {
set_has_label_map_file();
label_map_file_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.SaveOutputParameter.label_map_file)
}
::std::string* SaveOutputParameter::mutable_label_map_file() {
set_has_label_map_file();
// @@protoc_insertion_point(field_mutable:opencv_caffe.SaveOutputParameter.label_map_file)
return label_map_file_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* SaveOutputParameter::release_label_map_file() {
// @@protoc_insertion_point(field_release:opencv_caffe.SaveOutputParameter.label_map_file)
clear_has_label_map_file();
return label_map_file_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void SaveOutputParameter::set_allocated_label_map_file(::std::string* label_map_file) {
if (label_map_file != NULL) {
set_has_label_map_file();
} else {
clear_has_label_map_file();
}
label_map_file_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), label_map_file);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.SaveOutputParameter.label_map_file)
}
// optional string name_size_file = 5;
bool SaveOutputParameter::has_name_size_file() const {
return (_has_bits_[0] & 0x00000010u) != 0;
}
void SaveOutputParameter::set_has_name_size_file() {
_has_bits_[0] |= 0x00000010u;
}
void SaveOutputParameter::clear_has_name_size_file() {
_has_bits_[0] &= ~0x00000010u;
}
void SaveOutputParameter::clear_name_size_file() {
name_size_file_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_name_size_file();
}
const ::std::string& SaveOutputParameter::name_size_file() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SaveOutputParameter.name_size_file)
return name_size_file_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void SaveOutputParameter::set_name_size_file(const ::std::string& value) {
set_has_name_size_file();
name_size_file_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.SaveOutputParameter.name_size_file)
}
void SaveOutputParameter::set_name_size_file(const char* value) {
set_has_name_size_file();
name_size_file_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.SaveOutputParameter.name_size_file)
}
void SaveOutputParameter::set_name_size_file(const char* value, size_t size) {
set_has_name_size_file();
name_size_file_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.SaveOutputParameter.name_size_file)
}
::std::string* SaveOutputParameter::mutable_name_size_file() {
set_has_name_size_file();
// @@protoc_insertion_point(field_mutable:opencv_caffe.SaveOutputParameter.name_size_file)
return name_size_file_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* SaveOutputParameter::release_name_size_file() {
// @@protoc_insertion_point(field_release:opencv_caffe.SaveOutputParameter.name_size_file)
clear_has_name_size_file();
return name_size_file_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void SaveOutputParameter::set_allocated_name_size_file(::std::string* name_size_file) {
if (name_size_file != NULL) {
set_has_name_size_file();
} else {
clear_has_name_size_file();
}
name_size_file_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), name_size_file);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.SaveOutputParameter.name_size_file)
}
// optional uint32 num_test_image = 6;
bool SaveOutputParameter::has_num_test_image() const {
return (_has_bits_[0] & 0x00000020u) != 0;
}
void SaveOutputParameter::set_has_num_test_image() {
_has_bits_[0] |= 0x00000020u;
}
void SaveOutputParameter::clear_has_num_test_image() {
_has_bits_[0] &= ~0x00000020u;
}
void SaveOutputParameter::clear_num_test_image() {
num_test_image_ = 0u;
clear_has_num_test_image();
}
::google::protobuf::uint32 SaveOutputParameter::num_test_image() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SaveOutputParameter.num_test_image)
return num_test_image_;
}
void SaveOutputParameter::set_num_test_image(::google::protobuf::uint32 value) {
set_has_num_test_image();
num_test_image_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SaveOutputParameter.num_test_image)
}
inline const SaveOutputParameter* SaveOutputParameter::internal_default_instance() {
return &SaveOutputParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int DropoutParameter::kDropoutRatioFieldNumber;
const int DropoutParameter::kScaleTrainFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
DropoutParameter::DropoutParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.DropoutParameter)
}
void DropoutParameter::InitAsDefaultInstance() {
}
DropoutParameter::DropoutParameter(const DropoutParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.DropoutParameter)
}
void DropoutParameter::SharedCtor() {
_cached_size_ = 0;
dropout_ratio_ = 0.5f;
scale_train_ = true;
}
DropoutParameter::~DropoutParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.DropoutParameter)
SharedDtor();
}
void DropoutParameter::SharedDtor() {
}
void DropoutParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* DropoutParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return DropoutParameter_descriptor_;
}
const DropoutParameter& DropoutParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<DropoutParameter> DropoutParameter_default_instance_;
DropoutParameter* DropoutParameter::New(::google::protobuf::Arena* arena) const {
DropoutParameter* n = new DropoutParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void DropoutParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.DropoutParameter)
if (_has_bits_[0 / 32] & 3u) {
dropout_ratio_ = 0.5f;
scale_train_ = true;
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool DropoutParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.DropoutParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional float dropout_ratio = 1 [default = 0.5];
case 1: {
if (tag == 13) {
set_has_dropout_ratio();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &dropout_ratio_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_scale_train;
break;
}
// optional bool scale_train = 2 [default = true];
case 2: {
if (tag == 16) {
parse_scale_train:
set_has_scale_train();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &scale_train_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.DropoutParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.DropoutParameter)
return false;
#undef DO_
}
void DropoutParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.DropoutParameter)
// optional float dropout_ratio = 1 [default = 0.5];
if (has_dropout_ratio()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(1, this->dropout_ratio(), output);
}
// optional bool scale_train = 2 [default = true];
if (has_scale_train()) {
::google::protobuf::internal::WireFormatLite::WriteBool(2, this->scale_train(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.DropoutParameter)
}
::google::protobuf::uint8* DropoutParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.DropoutParameter)
// optional float dropout_ratio = 1 [default = 0.5];
if (has_dropout_ratio()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(1, this->dropout_ratio(), target);
}
// optional bool scale_train = 2 [default = true];
if (has_scale_train()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(2, this->scale_train(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.DropoutParameter)
return target;
}
size_t DropoutParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.DropoutParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 3u) {
// optional float dropout_ratio = 1 [default = 0.5];
if (has_dropout_ratio()) {
total_size += 1 + 4;
}
// optional bool scale_train = 2 [default = true];
if (has_scale_train()) {
total_size += 1 + 1;
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void DropoutParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.DropoutParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const DropoutParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const DropoutParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.DropoutParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.DropoutParameter)
UnsafeMergeFrom(*source);
}
}
void DropoutParameter::MergeFrom(const DropoutParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.DropoutParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void DropoutParameter::UnsafeMergeFrom(const DropoutParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_dropout_ratio()) {
set_dropout_ratio(from.dropout_ratio());
}
if (from.has_scale_train()) {
set_scale_train(from.scale_train());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void DropoutParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.DropoutParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void DropoutParameter::CopyFrom(const DropoutParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.DropoutParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool DropoutParameter::IsInitialized() const {
return true;
}
void DropoutParameter::Swap(DropoutParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void DropoutParameter::InternalSwap(DropoutParameter* other) {
std::swap(dropout_ratio_, other->dropout_ratio_);
std::swap(scale_train_, other->scale_train_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata DropoutParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = DropoutParameter_descriptor_;
metadata.reflection = DropoutParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// DropoutParameter
// optional float dropout_ratio = 1 [default = 0.5];
bool DropoutParameter::has_dropout_ratio() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void DropoutParameter::set_has_dropout_ratio() {
_has_bits_[0] |= 0x00000001u;
}
void DropoutParameter::clear_has_dropout_ratio() {
_has_bits_[0] &= ~0x00000001u;
}
void DropoutParameter::clear_dropout_ratio() {
dropout_ratio_ = 0.5f;
clear_has_dropout_ratio();
}
float DropoutParameter::dropout_ratio() const {
// @@protoc_insertion_point(field_get:opencv_caffe.DropoutParameter.dropout_ratio)
return dropout_ratio_;
}
void DropoutParameter::set_dropout_ratio(float value) {
set_has_dropout_ratio();
dropout_ratio_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.DropoutParameter.dropout_ratio)
}
// optional bool scale_train = 2 [default = true];
bool DropoutParameter::has_scale_train() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void DropoutParameter::set_has_scale_train() {
_has_bits_[0] |= 0x00000002u;
}
void DropoutParameter::clear_has_scale_train() {
_has_bits_[0] &= ~0x00000002u;
}
void DropoutParameter::clear_scale_train() {
scale_train_ = true;
clear_has_scale_train();
}
bool DropoutParameter::scale_train() const {
// @@protoc_insertion_point(field_get:opencv_caffe.DropoutParameter.scale_train)
return scale_train_;
}
void DropoutParameter::set_scale_train(bool value) {
set_has_scale_train();
scale_train_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.DropoutParameter.scale_train)
}
inline const DropoutParameter* DropoutParameter::internal_default_instance() {
return &DropoutParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int DummyDataParameter::kDataFillerFieldNumber;
const int DummyDataParameter::kShapeFieldNumber;
const int DummyDataParameter::kNumFieldNumber;
const int DummyDataParameter::kChannelsFieldNumber;
const int DummyDataParameter::kHeightFieldNumber;
const int DummyDataParameter::kWidthFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
DummyDataParameter::DummyDataParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.DummyDataParameter)
}
void DummyDataParameter::InitAsDefaultInstance() {
}
DummyDataParameter::DummyDataParameter(const DummyDataParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.DummyDataParameter)
}
void DummyDataParameter::SharedCtor() {
_cached_size_ = 0;
}
DummyDataParameter::~DummyDataParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.DummyDataParameter)
SharedDtor();
}
void DummyDataParameter::SharedDtor() {
}
void DummyDataParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* DummyDataParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return DummyDataParameter_descriptor_;
}
const DummyDataParameter& DummyDataParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<DummyDataParameter> DummyDataParameter_default_instance_;
DummyDataParameter* DummyDataParameter::New(::google::protobuf::Arena* arena) const {
DummyDataParameter* n = new DummyDataParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void DummyDataParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.DummyDataParameter)
data_filler_.Clear();
shape_.Clear();
num_.Clear();
channels_.Clear();
height_.Clear();
width_.Clear();
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool DummyDataParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.DummyDataParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// repeated .opencv_caffe.FillerParameter data_filler = 1;
case 1: {
if (tag == 10) {
DO_(input->IncrementRecursionDepth());
parse_loop_data_filler:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtualNoRecursionDepth(
input, add_data_filler()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(10)) goto parse_loop_data_filler;
input->UnsafeDecrementRecursionDepth();
if (input->ExpectTag(16)) goto parse_num;
break;
}
// repeated uint32 num = 2;
case 2: {
if (tag == 16) {
parse_num:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
1, 16, input, this->mutable_num())));
} else if (tag == 18) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, this->mutable_num())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_num;
if (input->ExpectTag(24)) goto parse_channels;
break;
}
// repeated uint32 channels = 3;
case 3: {
if (tag == 24) {
parse_channels:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
1, 24, input, this->mutable_channels())));
} else if (tag == 26) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, this->mutable_channels())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(24)) goto parse_channels;
if (input->ExpectTag(32)) goto parse_height;
break;
}
// repeated uint32 height = 4;
case 4: {
if (tag == 32) {
parse_height:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
1, 32, input, this->mutable_height())));
} else if (tag == 34) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, this->mutable_height())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(32)) goto parse_height;
if (input->ExpectTag(40)) goto parse_width;
break;
}
// repeated uint32 width = 5;
case 5: {
if (tag == 40) {
parse_width:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
1, 40, input, this->mutable_width())));
} else if (tag == 42) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, this->mutable_width())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(40)) goto parse_width;
if (input->ExpectTag(50)) goto parse_shape;
break;
}
// repeated .opencv_caffe.BlobShape shape = 6;
case 6: {
if (tag == 50) {
parse_shape:
DO_(input->IncrementRecursionDepth());
parse_loop_shape:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtualNoRecursionDepth(
input, add_shape()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(50)) goto parse_loop_shape;
input->UnsafeDecrementRecursionDepth();
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.DummyDataParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.DummyDataParameter)
return false;
#undef DO_
}
void DummyDataParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.DummyDataParameter)
// repeated .opencv_caffe.FillerParameter data_filler = 1;
for (unsigned int i = 0, n = this->data_filler_size(); i < n; i++) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
1, this->data_filler(i), output);
}
// repeated uint32 num = 2;
for (int i = 0; i < this->num_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(
2, this->num(i), output);
}
// repeated uint32 channels = 3;
for (int i = 0; i < this->channels_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(
3, this->channels(i), output);
}
// repeated uint32 height = 4;
for (int i = 0; i < this->height_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(
4, this->height(i), output);
}
// repeated uint32 width = 5;
for (int i = 0; i < this->width_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(
5, this->width(i), output);
}
// repeated .opencv_caffe.BlobShape shape = 6;
for (unsigned int i = 0, n = this->shape_size(); i < n; i++) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
6, this->shape(i), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.DummyDataParameter)
}
::google::protobuf::uint8* DummyDataParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.DummyDataParameter)
// repeated .opencv_caffe.FillerParameter data_filler = 1;
for (unsigned int i = 0, n = this->data_filler_size(); i < n; i++) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
1, this->data_filler(i), false, target);
}
// repeated uint32 num = 2;
for (int i = 0; i < this->num_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteUInt32ToArray(2, this->num(i), target);
}
// repeated uint32 channels = 3;
for (int i = 0; i < this->channels_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteUInt32ToArray(3, this->channels(i), target);
}
// repeated uint32 height = 4;
for (int i = 0; i < this->height_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteUInt32ToArray(4, this->height(i), target);
}
// repeated uint32 width = 5;
for (int i = 0; i < this->width_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteUInt32ToArray(5, this->width(i), target);
}
// repeated .opencv_caffe.BlobShape shape = 6;
for (unsigned int i = 0, n = this->shape_size(); i < n; i++) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
6, this->shape(i), false, target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.DummyDataParameter)
return target;
}
size_t DummyDataParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.DummyDataParameter)
size_t total_size = 0;
// repeated .opencv_caffe.FillerParameter data_filler = 1;
{
unsigned int count = this->data_filler_size();
total_size += 1UL * count;
for (unsigned int i = 0; i < count; i++) {
total_size +=
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
this->data_filler(i));
}
}
// repeated .opencv_caffe.BlobShape shape = 6;
{
unsigned int count = this->shape_size();
total_size += 1UL * count;
for (unsigned int i = 0; i < count; i++) {
total_size +=
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
this->shape(i));
}
}
// repeated uint32 num = 2;
{
size_t data_size = 0;
unsigned int count = this->num_size();
for (unsigned int i = 0; i < count; i++) {
data_size += ::google::protobuf::internal::WireFormatLite::
UInt32Size(this->num(i));
}
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->num_size());
total_size += data_size;
}
// repeated uint32 channels = 3;
{
size_t data_size = 0;
unsigned int count = this->channels_size();
for (unsigned int i = 0; i < count; i++) {
data_size += ::google::protobuf::internal::WireFormatLite::
UInt32Size(this->channels(i));
}
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->channels_size());
total_size += data_size;
}
// repeated uint32 height = 4;
{
size_t data_size = 0;
unsigned int count = this->height_size();
for (unsigned int i = 0; i < count; i++) {
data_size += ::google::protobuf::internal::WireFormatLite::
UInt32Size(this->height(i));
}
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->height_size());
total_size += data_size;
}
// repeated uint32 width = 5;
{
size_t data_size = 0;
unsigned int count = this->width_size();
for (unsigned int i = 0; i < count; i++) {
data_size += ::google::protobuf::internal::WireFormatLite::
UInt32Size(this->width(i));
}
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->width_size());
total_size += data_size;
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void DummyDataParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.DummyDataParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const DummyDataParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const DummyDataParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.DummyDataParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.DummyDataParameter)
UnsafeMergeFrom(*source);
}
}
void DummyDataParameter::MergeFrom(const DummyDataParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.DummyDataParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void DummyDataParameter::UnsafeMergeFrom(const DummyDataParameter& from) {
GOOGLE_DCHECK(&from != this);
data_filler_.MergeFrom(from.data_filler_);
shape_.MergeFrom(from.shape_);
num_.UnsafeMergeFrom(from.num_);
channels_.UnsafeMergeFrom(from.channels_);
height_.UnsafeMergeFrom(from.height_);
width_.UnsafeMergeFrom(from.width_);
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void DummyDataParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.DummyDataParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void DummyDataParameter::CopyFrom(const DummyDataParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.DummyDataParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool DummyDataParameter::IsInitialized() const {
return true;
}
void DummyDataParameter::Swap(DummyDataParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void DummyDataParameter::InternalSwap(DummyDataParameter* other) {
data_filler_.UnsafeArenaSwap(&other->data_filler_);
shape_.UnsafeArenaSwap(&other->shape_);
num_.UnsafeArenaSwap(&other->num_);
channels_.UnsafeArenaSwap(&other->channels_);
height_.UnsafeArenaSwap(&other->height_);
width_.UnsafeArenaSwap(&other->width_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata DummyDataParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = DummyDataParameter_descriptor_;
metadata.reflection = DummyDataParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// DummyDataParameter
// repeated .opencv_caffe.FillerParameter data_filler = 1;
int DummyDataParameter::data_filler_size() const {
return data_filler_.size();
}
void DummyDataParameter::clear_data_filler() {
data_filler_.Clear();
}
const ::opencv_caffe::FillerParameter& DummyDataParameter::data_filler(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.DummyDataParameter.data_filler)
return data_filler_.Get(index);
}
::opencv_caffe::FillerParameter* DummyDataParameter::mutable_data_filler(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.DummyDataParameter.data_filler)
return data_filler_.Mutable(index);
}
::opencv_caffe::FillerParameter* DummyDataParameter::add_data_filler() {
// @@protoc_insertion_point(field_add:opencv_caffe.DummyDataParameter.data_filler)
return data_filler_.Add();
}
::google::protobuf::RepeatedPtrField< ::opencv_caffe::FillerParameter >*
DummyDataParameter::mutable_data_filler() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.DummyDataParameter.data_filler)
return &data_filler_;
}
const ::google::protobuf::RepeatedPtrField< ::opencv_caffe::FillerParameter >&
DummyDataParameter::data_filler() const {
// @@protoc_insertion_point(field_list:opencv_caffe.DummyDataParameter.data_filler)
return data_filler_;
}
// repeated .opencv_caffe.BlobShape shape = 6;
int DummyDataParameter::shape_size() const {
return shape_.size();
}
void DummyDataParameter::clear_shape() {
shape_.Clear();
}
const ::opencv_caffe::BlobShape& DummyDataParameter::shape(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.DummyDataParameter.shape)
return shape_.Get(index);
}
::opencv_caffe::BlobShape* DummyDataParameter::mutable_shape(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.DummyDataParameter.shape)
return shape_.Mutable(index);
}
::opencv_caffe::BlobShape* DummyDataParameter::add_shape() {
// @@protoc_insertion_point(field_add:opencv_caffe.DummyDataParameter.shape)
return shape_.Add();
}
::google::protobuf::RepeatedPtrField< ::opencv_caffe::BlobShape >*
DummyDataParameter::mutable_shape() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.DummyDataParameter.shape)
return &shape_;
}
const ::google::protobuf::RepeatedPtrField< ::opencv_caffe::BlobShape >&
DummyDataParameter::shape() const {
// @@protoc_insertion_point(field_list:opencv_caffe.DummyDataParameter.shape)
return shape_;
}
// repeated uint32 num = 2;
int DummyDataParameter::num_size() const {
return num_.size();
}
void DummyDataParameter::clear_num() {
num_.Clear();
}
::google::protobuf::uint32 DummyDataParameter::num(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.DummyDataParameter.num)
return num_.Get(index);
}
void DummyDataParameter::set_num(int index, ::google::protobuf::uint32 value) {
num_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.DummyDataParameter.num)
}
void DummyDataParameter::add_num(::google::protobuf::uint32 value) {
num_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.DummyDataParameter.num)
}
const ::google::protobuf::RepeatedField< ::google::protobuf::uint32 >&
DummyDataParameter::num() const {
// @@protoc_insertion_point(field_list:opencv_caffe.DummyDataParameter.num)
return num_;
}
::google::protobuf::RepeatedField< ::google::protobuf::uint32 >*
DummyDataParameter::mutable_num() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.DummyDataParameter.num)
return &num_;
}
// repeated uint32 channels = 3;
int DummyDataParameter::channels_size() const {
return channels_.size();
}
void DummyDataParameter::clear_channels() {
channels_.Clear();
}
::google::protobuf::uint32 DummyDataParameter::channels(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.DummyDataParameter.channels)
return channels_.Get(index);
}
void DummyDataParameter::set_channels(int index, ::google::protobuf::uint32 value) {
channels_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.DummyDataParameter.channels)
}
void DummyDataParameter::add_channels(::google::protobuf::uint32 value) {
channels_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.DummyDataParameter.channels)
}
const ::google::protobuf::RepeatedField< ::google::protobuf::uint32 >&
DummyDataParameter::channels() const {
// @@protoc_insertion_point(field_list:opencv_caffe.DummyDataParameter.channels)
return channels_;
}
::google::protobuf::RepeatedField< ::google::protobuf::uint32 >*
DummyDataParameter::mutable_channels() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.DummyDataParameter.channels)
return &channels_;
}
// repeated uint32 height = 4;
int DummyDataParameter::height_size() const {
return height_.size();
}
void DummyDataParameter::clear_height() {
height_.Clear();
}
::google::protobuf::uint32 DummyDataParameter::height(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.DummyDataParameter.height)
return height_.Get(index);
}
void DummyDataParameter::set_height(int index, ::google::protobuf::uint32 value) {
height_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.DummyDataParameter.height)
}
void DummyDataParameter::add_height(::google::protobuf::uint32 value) {
height_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.DummyDataParameter.height)
}
const ::google::protobuf::RepeatedField< ::google::protobuf::uint32 >&
DummyDataParameter::height() const {
// @@protoc_insertion_point(field_list:opencv_caffe.DummyDataParameter.height)
return height_;
}
::google::protobuf::RepeatedField< ::google::protobuf::uint32 >*
DummyDataParameter::mutable_height() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.DummyDataParameter.height)
return &height_;
}
// repeated uint32 width = 5;
int DummyDataParameter::width_size() const {
return width_.size();
}
void DummyDataParameter::clear_width() {
width_.Clear();
}
::google::protobuf::uint32 DummyDataParameter::width(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.DummyDataParameter.width)
return width_.Get(index);
}
void DummyDataParameter::set_width(int index, ::google::protobuf::uint32 value) {
width_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.DummyDataParameter.width)
}
void DummyDataParameter::add_width(::google::protobuf::uint32 value) {
width_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.DummyDataParameter.width)
}
const ::google::protobuf::RepeatedField< ::google::protobuf::uint32 >&
DummyDataParameter::width() const {
// @@protoc_insertion_point(field_list:opencv_caffe.DummyDataParameter.width)
return width_;
}
::google::protobuf::RepeatedField< ::google::protobuf::uint32 >*
DummyDataParameter::mutable_width() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.DummyDataParameter.width)
return &width_;
}
inline const DummyDataParameter* DummyDataParameter::internal_default_instance() {
return &DummyDataParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
const ::google::protobuf::EnumDescriptor* EltwiseParameter_EltwiseOp_descriptor() {
protobuf_AssignDescriptorsOnce();
return EltwiseParameter_EltwiseOp_descriptor_;
}
bool EltwiseParameter_EltwiseOp_IsValid(int value) {
switch (value) {
case 0:
case 1:
case 2:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const EltwiseParameter_EltwiseOp EltwiseParameter::PROD;
const EltwiseParameter_EltwiseOp EltwiseParameter::SUM;
const EltwiseParameter_EltwiseOp EltwiseParameter::MAX;
const EltwiseParameter_EltwiseOp EltwiseParameter::EltwiseOp_MIN;
const EltwiseParameter_EltwiseOp EltwiseParameter::EltwiseOp_MAX;
const int EltwiseParameter::EltwiseOp_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int EltwiseParameter::kOperationFieldNumber;
const int EltwiseParameter::kCoeffFieldNumber;
const int EltwiseParameter::kStableProdGradFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
EltwiseParameter::EltwiseParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.EltwiseParameter)
}
void EltwiseParameter::InitAsDefaultInstance() {
}
EltwiseParameter::EltwiseParameter(const EltwiseParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.EltwiseParameter)
}
void EltwiseParameter::SharedCtor() {
_cached_size_ = 0;
operation_ = 1;
stable_prod_grad_ = true;
}
EltwiseParameter::~EltwiseParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.EltwiseParameter)
SharedDtor();
}
void EltwiseParameter::SharedDtor() {
}
void EltwiseParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* EltwiseParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return EltwiseParameter_descriptor_;
}
const EltwiseParameter& EltwiseParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<EltwiseParameter> EltwiseParameter_default_instance_;
EltwiseParameter* EltwiseParameter::New(::google::protobuf::Arena* arena) const {
EltwiseParameter* n = new EltwiseParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void EltwiseParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.EltwiseParameter)
if (_has_bits_[0 / 32] & 5u) {
operation_ = 1;
stable_prod_grad_ = true;
}
coeff_.Clear();
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool EltwiseParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.EltwiseParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional .opencv_caffe.EltwiseParameter.EltwiseOp operation = 1 [default = SUM];
case 1: {
if (tag == 8) {
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::EltwiseParameter_EltwiseOp_IsValid(value)) {
set_operation(static_cast< ::opencv_caffe::EltwiseParameter_EltwiseOp >(value));
} else {
mutable_unknown_fields()->AddVarint(1, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectTag(21)) goto parse_coeff;
break;
}
// repeated float coeff = 2;
case 2: {
if (tag == 21) {
parse_coeff:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
1, 21, input, this->mutable_coeff())));
} else if (tag == 18) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, this->mutable_coeff())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(21)) goto parse_coeff;
if (input->ExpectTag(24)) goto parse_stable_prod_grad;
break;
}
// optional bool stable_prod_grad = 3 [default = true];
case 3: {
if (tag == 24) {
parse_stable_prod_grad:
set_has_stable_prod_grad();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &stable_prod_grad_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.EltwiseParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.EltwiseParameter)
return false;
#undef DO_
}
void EltwiseParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.EltwiseParameter)
// optional .opencv_caffe.EltwiseParameter.EltwiseOp operation = 1 [default = SUM];
if (has_operation()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
1, this->operation(), output);
}
// repeated float coeff = 2;
for (int i = 0; i < this->coeff_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteFloat(
2, this->coeff(i), output);
}
// optional bool stable_prod_grad = 3 [default = true];
if (has_stable_prod_grad()) {
::google::protobuf::internal::WireFormatLite::WriteBool(3, this->stable_prod_grad(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.EltwiseParameter)
}
::google::protobuf::uint8* EltwiseParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.EltwiseParameter)
// optional .opencv_caffe.EltwiseParameter.EltwiseOp operation = 1 [default = SUM];
if (has_operation()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
1, this->operation(), target);
}
// repeated float coeff = 2;
for (int i = 0; i < this->coeff_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteFloatToArray(2, this->coeff(i), target);
}
// optional bool stable_prod_grad = 3 [default = true];
if (has_stable_prod_grad()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(3, this->stable_prod_grad(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.EltwiseParameter)
return target;
}
size_t EltwiseParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.EltwiseParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 5u) {
// optional .opencv_caffe.EltwiseParameter.EltwiseOp operation = 1 [default = SUM];
if (has_operation()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->operation());
}
// optional bool stable_prod_grad = 3 [default = true];
if (has_stable_prod_grad()) {
total_size += 1 + 1;
}
}
// repeated float coeff = 2;
{
size_t data_size = 0;
unsigned int count = this->coeff_size();
data_size = 4UL * count;
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->coeff_size());
total_size += data_size;
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void EltwiseParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.EltwiseParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const EltwiseParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const EltwiseParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.EltwiseParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.EltwiseParameter)
UnsafeMergeFrom(*source);
}
}
void EltwiseParameter::MergeFrom(const EltwiseParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.EltwiseParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void EltwiseParameter::UnsafeMergeFrom(const EltwiseParameter& from) {
GOOGLE_DCHECK(&from != this);
coeff_.UnsafeMergeFrom(from.coeff_);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_operation()) {
set_operation(from.operation());
}
if (from.has_stable_prod_grad()) {
set_stable_prod_grad(from.stable_prod_grad());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void EltwiseParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.EltwiseParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void EltwiseParameter::CopyFrom(const EltwiseParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.EltwiseParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool EltwiseParameter::IsInitialized() const {
return true;
}
void EltwiseParameter::Swap(EltwiseParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void EltwiseParameter::InternalSwap(EltwiseParameter* other) {
std::swap(operation_, other->operation_);
coeff_.UnsafeArenaSwap(&other->coeff_);
std::swap(stable_prod_grad_, other->stable_prod_grad_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata EltwiseParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = EltwiseParameter_descriptor_;
metadata.reflection = EltwiseParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// EltwiseParameter
// optional .opencv_caffe.EltwiseParameter.EltwiseOp operation = 1 [default = SUM];
bool EltwiseParameter::has_operation() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void EltwiseParameter::set_has_operation() {
_has_bits_[0] |= 0x00000001u;
}
void EltwiseParameter::clear_has_operation() {
_has_bits_[0] &= ~0x00000001u;
}
void EltwiseParameter::clear_operation() {
operation_ = 1;
clear_has_operation();
}
::opencv_caffe::EltwiseParameter_EltwiseOp EltwiseParameter::operation() const {
// @@protoc_insertion_point(field_get:opencv_caffe.EltwiseParameter.operation)
return static_cast< ::opencv_caffe::EltwiseParameter_EltwiseOp >(operation_);
}
void EltwiseParameter::set_operation(::opencv_caffe::EltwiseParameter_EltwiseOp value) {
assert(::opencv_caffe::EltwiseParameter_EltwiseOp_IsValid(value));
set_has_operation();
operation_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.EltwiseParameter.operation)
}
// repeated float coeff = 2;
int EltwiseParameter::coeff_size() const {
return coeff_.size();
}
void EltwiseParameter::clear_coeff() {
coeff_.Clear();
}
float EltwiseParameter::coeff(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.EltwiseParameter.coeff)
return coeff_.Get(index);
}
void EltwiseParameter::set_coeff(int index, float value) {
coeff_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.EltwiseParameter.coeff)
}
void EltwiseParameter::add_coeff(float value) {
coeff_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.EltwiseParameter.coeff)
}
const ::google::protobuf::RepeatedField< float >&
EltwiseParameter::coeff() const {
// @@protoc_insertion_point(field_list:opencv_caffe.EltwiseParameter.coeff)
return coeff_;
}
::google::protobuf::RepeatedField< float >*
EltwiseParameter::mutable_coeff() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.EltwiseParameter.coeff)
return &coeff_;
}
// optional bool stable_prod_grad = 3 [default = true];
bool EltwiseParameter::has_stable_prod_grad() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void EltwiseParameter::set_has_stable_prod_grad() {
_has_bits_[0] |= 0x00000004u;
}
void EltwiseParameter::clear_has_stable_prod_grad() {
_has_bits_[0] &= ~0x00000004u;
}
void EltwiseParameter::clear_stable_prod_grad() {
stable_prod_grad_ = true;
clear_has_stable_prod_grad();
}
bool EltwiseParameter::stable_prod_grad() const {
// @@protoc_insertion_point(field_get:opencv_caffe.EltwiseParameter.stable_prod_grad)
return stable_prod_grad_;
}
void EltwiseParameter::set_stable_prod_grad(bool value) {
set_has_stable_prod_grad();
stable_prod_grad_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.EltwiseParameter.stable_prod_grad)
}
inline const EltwiseParameter* EltwiseParameter::internal_default_instance() {
return &EltwiseParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int ELUParameter::kAlphaFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
ELUParameter::ELUParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.ELUParameter)
}
void ELUParameter::InitAsDefaultInstance() {
}
ELUParameter::ELUParameter(const ELUParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.ELUParameter)
}
void ELUParameter::SharedCtor() {
_cached_size_ = 0;
alpha_ = 1;
}
ELUParameter::~ELUParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.ELUParameter)
SharedDtor();
}
void ELUParameter::SharedDtor() {
}
void ELUParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* ELUParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return ELUParameter_descriptor_;
}
const ELUParameter& ELUParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<ELUParameter> ELUParameter_default_instance_;
ELUParameter* ELUParameter::New(::google::protobuf::Arena* arena) const {
ELUParameter* n = new ELUParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void ELUParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.ELUParameter)
alpha_ = 1;
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool ELUParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.ELUParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional float alpha = 1 [default = 1];
case 1: {
if (tag == 13) {
set_has_alpha();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &alpha_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.ELUParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.ELUParameter)
return false;
#undef DO_
}
void ELUParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.ELUParameter)
// optional float alpha = 1 [default = 1];
if (has_alpha()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(1, this->alpha(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.ELUParameter)
}
::google::protobuf::uint8* ELUParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.ELUParameter)
// optional float alpha = 1 [default = 1];
if (has_alpha()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(1, this->alpha(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.ELUParameter)
return target;
}
size_t ELUParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.ELUParameter)
size_t total_size = 0;
// optional float alpha = 1 [default = 1];
if (has_alpha()) {
total_size += 1 + 4;
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void ELUParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.ELUParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const ELUParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const ELUParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.ELUParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.ELUParameter)
UnsafeMergeFrom(*source);
}
}
void ELUParameter::MergeFrom(const ELUParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.ELUParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void ELUParameter::UnsafeMergeFrom(const ELUParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_alpha()) {
set_alpha(from.alpha());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void ELUParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.ELUParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void ELUParameter::CopyFrom(const ELUParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.ELUParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool ELUParameter::IsInitialized() const {
return true;
}
void ELUParameter::Swap(ELUParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void ELUParameter::InternalSwap(ELUParameter* other) {
std::swap(alpha_, other->alpha_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata ELUParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = ELUParameter_descriptor_;
metadata.reflection = ELUParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// ELUParameter
// optional float alpha = 1 [default = 1];
bool ELUParameter::has_alpha() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void ELUParameter::set_has_alpha() {
_has_bits_[0] |= 0x00000001u;
}
void ELUParameter::clear_has_alpha() {
_has_bits_[0] &= ~0x00000001u;
}
void ELUParameter::clear_alpha() {
alpha_ = 1;
clear_has_alpha();
}
float ELUParameter::alpha() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ELUParameter.alpha)
return alpha_;
}
void ELUParameter::set_alpha(float value) {
set_has_alpha();
alpha_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ELUParameter.alpha)
}
inline const ELUParameter* ELUParameter::internal_default_instance() {
return &ELUParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int EmbedParameter::kNumOutputFieldNumber;
const int EmbedParameter::kInputDimFieldNumber;
const int EmbedParameter::kBiasTermFieldNumber;
const int EmbedParameter::kWeightFillerFieldNumber;
const int EmbedParameter::kBiasFillerFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
EmbedParameter::EmbedParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.EmbedParameter)
}
void EmbedParameter::InitAsDefaultInstance() {
weight_filler_ = const_cast< ::opencv_caffe::FillerParameter*>(
::opencv_caffe::FillerParameter::internal_default_instance());
bias_filler_ = const_cast< ::opencv_caffe::FillerParameter*>(
::opencv_caffe::FillerParameter::internal_default_instance());
}
EmbedParameter::EmbedParameter(const EmbedParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.EmbedParameter)
}
void EmbedParameter::SharedCtor() {
_cached_size_ = 0;
weight_filler_ = NULL;
bias_filler_ = NULL;
::memset(&num_output_, 0, reinterpret_cast<char*>(&input_dim_) -
reinterpret_cast<char*>(&num_output_) + sizeof(input_dim_));
bias_term_ = true;
}
EmbedParameter::~EmbedParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.EmbedParameter)
SharedDtor();
}
void EmbedParameter::SharedDtor() {
if (this != &EmbedParameter_default_instance_.get()) {
delete weight_filler_;
delete bias_filler_;
}
}
void EmbedParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* EmbedParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return EmbedParameter_descriptor_;
}
const EmbedParameter& EmbedParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<EmbedParameter> EmbedParameter_default_instance_;
EmbedParameter* EmbedParameter::New(::google::protobuf::Arena* arena) const {
EmbedParameter* n = new EmbedParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void EmbedParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.EmbedParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(EmbedParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<EmbedParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
if (_has_bits_[0 / 32] & 31u) {
ZR_(num_output_, input_dim_);
bias_term_ = true;
if (has_weight_filler()) {
if (weight_filler_ != NULL) weight_filler_->::opencv_caffe::FillerParameter::Clear();
}
if (has_bias_filler()) {
if (bias_filler_ != NULL) bias_filler_->::opencv_caffe::FillerParameter::Clear();
}
}
#undef ZR_HELPER_
#undef ZR_
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool EmbedParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.EmbedParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional uint32 num_output = 1;
case 1: {
if (tag == 8) {
set_has_num_output();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &num_output_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_input_dim;
break;
}
// optional uint32 input_dim = 2;
case 2: {
if (tag == 16) {
parse_input_dim:
set_has_input_dim();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &input_dim_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(24)) goto parse_bias_term;
break;
}
// optional bool bias_term = 3 [default = true];
case 3: {
if (tag == 24) {
parse_bias_term:
set_has_bias_term();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &bias_term_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(34)) goto parse_weight_filler;
break;
}
// optional .opencv_caffe.FillerParameter weight_filler = 4;
case 4: {
if (tag == 34) {
parse_weight_filler:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_weight_filler()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(42)) goto parse_bias_filler;
break;
}
// optional .opencv_caffe.FillerParameter bias_filler = 5;
case 5: {
if (tag == 42) {
parse_bias_filler:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_bias_filler()));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.EmbedParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.EmbedParameter)
return false;
#undef DO_
}
void EmbedParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.EmbedParameter)
// optional uint32 num_output = 1;
if (has_num_output()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(1, this->num_output(), output);
}
// optional uint32 input_dim = 2;
if (has_input_dim()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(2, this->input_dim(), output);
}
// optional bool bias_term = 3 [default = true];
if (has_bias_term()) {
::google::protobuf::internal::WireFormatLite::WriteBool(3, this->bias_term(), output);
}
// optional .opencv_caffe.FillerParameter weight_filler = 4;
if (has_weight_filler()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
4, *this->weight_filler_, output);
}
// optional .opencv_caffe.FillerParameter bias_filler = 5;
if (has_bias_filler()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
5, *this->bias_filler_, output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.EmbedParameter)
}
::google::protobuf::uint8* EmbedParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.EmbedParameter)
// optional uint32 num_output = 1;
if (has_num_output()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(1, this->num_output(), target);
}
// optional uint32 input_dim = 2;
if (has_input_dim()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(2, this->input_dim(), target);
}
// optional bool bias_term = 3 [default = true];
if (has_bias_term()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(3, this->bias_term(), target);
}
// optional .opencv_caffe.FillerParameter weight_filler = 4;
if (has_weight_filler()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
4, *this->weight_filler_, false, target);
}
// optional .opencv_caffe.FillerParameter bias_filler = 5;
if (has_bias_filler()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
5, *this->bias_filler_, false, target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.EmbedParameter)
return target;
}
size_t EmbedParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.EmbedParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 31u) {
// optional uint32 num_output = 1;
if (has_num_output()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->num_output());
}
// optional uint32 input_dim = 2;
if (has_input_dim()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->input_dim());
}
// optional bool bias_term = 3 [default = true];
if (has_bias_term()) {
total_size += 1 + 1;
}
// optional .opencv_caffe.FillerParameter weight_filler = 4;
if (has_weight_filler()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->weight_filler_);
}
// optional .opencv_caffe.FillerParameter bias_filler = 5;
if (has_bias_filler()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->bias_filler_);
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void EmbedParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.EmbedParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const EmbedParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const EmbedParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.EmbedParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.EmbedParameter)
UnsafeMergeFrom(*source);
}
}
void EmbedParameter::MergeFrom(const EmbedParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.EmbedParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void EmbedParameter::UnsafeMergeFrom(const EmbedParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_num_output()) {
set_num_output(from.num_output());
}
if (from.has_input_dim()) {
set_input_dim(from.input_dim());
}
if (from.has_bias_term()) {
set_bias_term(from.bias_term());
}
if (from.has_weight_filler()) {
mutable_weight_filler()->::opencv_caffe::FillerParameter::MergeFrom(from.weight_filler());
}
if (from.has_bias_filler()) {
mutable_bias_filler()->::opencv_caffe::FillerParameter::MergeFrom(from.bias_filler());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void EmbedParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.EmbedParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void EmbedParameter::CopyFrom(const EmbedParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.EmbedParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool EmbedParameter::IsInitialized() const {
return true;
}
void EmbedParameter::Swap(EmbedParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void EmbedParameter::InternalSwap(EmbedParameter* other) {
std::swap(num_output_, other->num_output_);
std::swap(input_dim_, other->input_dim_);
std::swap(bias_term_, other->bias_term_);
std::swap(weight_filler_, other->weight_filler_);
std::swap(bias_filler_, other->bias_filler_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata EmbedParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = EmbedParameter_descriptor_;
metadata.reflection = EmbedParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// EmbedParameter
// optional uint32 num_output = 1;
bool EmbedParameter::has_num_output() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void EmbedParameter::set_has_num_output() {
_has_bits_[0] |= 0x00000001u;
}
void EmbedParameter::clear_has_num_output() {
_has_bits_[0] &= ~0x00000001u;
}
void EmbedParameter::clear_num_output() {
num_output_ = 0u;
clear_has_num_output();
}
::google::protobuf::uint32 EmbedParameter::num_output() const {
// @@protoc_insertion_point(field_get:opencv_caffe.EmbedParameter.num_output)
return num_output_;
}
void EmbedParameter::set_num_output(::google::protobuf::uint32 value) {
set_has_num_output();
num_output_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.EmbedParameter.num_output)
}
// optional uint32 input_dim = 2;
bool EmbedParameter::has_input_dim() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void EmbedParameter::set_has_input_dim() {
_has_bits_[0] |= 0x00000002u;
}
void EmbedParameter::clear_has_input_dim() {
_has_bits_[0] &= ~0x00000002u;
}
void EmbedParameter::clear_input_dim() {
input_dim_ = 0u;
clear_has_input_dim();
}
::google::protobuf::uint32 EmbedParameter::input_dim() const {
// @@protoc_insertion_point(field_get:opencv_caffe.EmbedParameter.input_dim)
return input_dim_;
}
void EmbedParameter::set_input_dim(::google::protobuf::uint32 value) {
set_has_input_dim();
input_dim_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.EmbedParameter.input_dim)
}
// optional bool bias_term = 3 [default = true];
bool EmbedParameter::has_bias_term() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void EmbedParameter::set_has_bias_term() {
_has_bits_[0] |= 0x00000004u;
}
void EmbedParameter::clear_has_bias_term() {
_has_bits_[0] &= ~0x00000004u;
}
void EmbedParameter::clear_bias_term() {
bias_term_ = true;
clear_has_bias_term();
}
bool EmbedParameter::bias_term() const {
// @@protoc_insertion_point(field_get:opencv_caffe.EmbedParameter.bias_term)
return bias_term_;
}
void EmbedParameter::set_bias_term(bool value) {
set_has_bias_term();
bias_term_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.EmbedParameter.bias_term)
}
// optional .opencv_caffe.FillerParameter weight_filler = 4;
bool EmbedParameter::has_weight_filler() const {
return (_has_bits_[0] & 0x00000008u) != 0;
}
void EmbedParameter::set_has_weight_filler() {
_has_bits_[0] |= 0x00000008u;
}
void EmbedParameter::clear_has_weight_filler() {
_has_bits_[0] &= ~0x00000008u;
}
void EmbedParameter::clear_weight_filler() {
if (weight_filler_ != NULL) weight_filler_->::opencv_caffe::FillerParameter::Clear();
clear_has_weight_filler();
}
const ::opencv_caffe::FillerParameter& EmbedParameter::weight_filler() const {
// @@protoc_insertion_point(field_get:opencv_caffe.EmbedParameter.weight_filler)
return weight_filler_ != NULL ? *weight_filler_
: *::opencv_caffe::FillerParameter::internal_default_instance();
}
::opencv_caffe::FillerParameter* EmbedParameter::mutable_weight_filler() {
set_has_weight_filler();
if (weight_filler_ == NULL) {
weight_filler_ = new ::opencv_caffe::FillerParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.EmbedParameter.weight_filler)
return weight_filler_;
}
::opencv_caffe::FillerParameter* EmbedParameter::release_weight_filler() {
// @@protoc_insertion_point(field_release:opencv_caffe.EmbedParameter.weight_filler)
clear_has_weight_filler();
::opencv_caffe::FillerParameter* temp = weight_filler_;
weight_filler_ = NULL;
return temp;
}
void EmbedParameter::set_allocated_weight_filler(::opencv_caffe::FillerParameter* weight_filler) {
delete weight_filler_;
weight_filler_ = weight_filler;
if (weight_filler) {
set_has_weight_filler();
} else {
clear_has_weight_filler();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.EmbedParameter.weight_filler)
}
// optional .opencv_caffe.FillerParameter bias_filler = 5;
bool EmbedParameter::has_bias_filler() const {
return (_has_bits_[0] & 0x00000010u) != 0;
}
void EmbedParameter::set_has_bias_filler() {
_has_bits_[0] |= 0x00000010u;
}
void EmbedParameter::clear_has_bias_filler() {
_has_bits_[0] &= ~0x00000010u;
}
void EmbedParameter::clear_bias_filler() {
if (bias_filler_ != NULL) bias_filler_->::opencv_caffe::FillerParameter::Clear();
clear_has_bias_filler();
}
const ::opencv_caffe::FillerParameter& EmbedParameter::bias_filler() const {
// @@protoc_insertion_point(field_get:opencv_caffe.EmbedParameter.bias_filler)
return bias_filler_ != NULL ? *bias_filler_
: *::opencv_caffe::FillerParameter::internal_default_instance();
}
::opencv_caffe::FillerParameter* EmbedParameter::mutable_bias_filler() {
set_has_bias_filler();
if (bias_filler_ == NULL) {
bias_filler_ = new ::opencv_caffe::FillerParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.EmbedParameter.bias_filler)
return bias_filler_;
}
::opencv_caffe::FillerParameter* EmbedParameter::release_bias_filler() {
// @@protoc_insertion_point(field_release:opencv_caffe.EmbedParameter.bias_filler)
clear_has_bias_filler();
::opencv_caffe::FillerParameter* temp = bias_filler_;
bias_filler_ = NULL;
return temp;
}
void EmbedParameter::set_allocated_bias_filler(::opencv_caffe::FillerParameter* bias_filler) {
delete bias_filler_;
bias_filler_ = bias_filler;
if (bias_filler) {
set_has_bias_filler();
} else {
clear_has_bias_filler();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.EmbedParameter.bias_filler)
}
inline const EmbedParameter* EmbedParameter::internal_default_instance() {
return &EmbedParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int ExpParameter::kBaseFieldNumber;
const int ExpParameter::kScaleFieldNumber;
const int ExpParameter::kShiftFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
ExpParameter::ExpParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.ExpParameter)
}
void ExpParameter::InitAsDefaultInstance() {
}
ExpParameter::ExpParameter(const ExpParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.ExpParameter)
}
void ExpParameter::SharedCtor() {
_cached_size_ = 0;
shift_ = 0;
base_ = -1;
scale_ = 1;
}
ExpParameter::~ExpParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.ExpParameter)
SharedDtor();
}
void ExpParameter::SharedDtor() {
}
void ExpParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* ExpParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return ExpParameter_descriptor_;
}
const ExpParameter& ExpParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<ExpParameter> ExpParameter_default_instance_;
ExpParameter* ExpParameter::New(::google::protobuf::Arena* arena) const {
ExpParameter* n = new ExpParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void ExpParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.ExpParameter)
if (_has_bits_[0 / 32] & 7u) {
base_ = -1;
scale_ = 1;
shift_ = 0;
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool ExpParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.ExpParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional float base = 1 [default = -1];
case 1: {
if (tag == 13) {
set_has_base();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &base_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(21)) goto parse_scale;
break;
}
// optional float scale = 2 [default = 1];
case 2: {
if (tag == 21) {
parse_scale:
set_has_scale();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &scale_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(29)) goto parse_shift;
break;
}
// optional float shift = 3 [default = 0];
case 3: {
if (tag == 29) {
parse_shift:
set_has_shift();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &shift_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.ExpParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.ExpParameter)
return false;
#undef DO_
}
void ExpParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.ExpParameter)
// optional float base = 1 [default = -1];
if (has_base()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(1, this->base(), output);
}
// optional float scale = 2 [default = 1];
if (has_scale()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(2, this->scale(), output);
}
// optional float shift = 3 [default = 0];
if (has_shift()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(3, this->shift(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.ExpParameter)
}
::google::protobuf::uint8* ExpParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.ExpParameter)
// optional float base = 1 [default = -1];
if (has_base()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(1, this->base(), target);
}
// optional float scale = 2 [default = 1];
if (has_scale()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(2, this->scale(), target);
}
// optional float shift = 3 [default = 0];
if (has_shift()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(3, this->shift(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.ExpParameter)
return target;
}
size_t ExpParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.ExpParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 7u) {
// optional float base = 1 [default = -1];
if (has_base()) {
total_size += 1 + 4;
}
// optional float scale = 2 [default = 1];
if (has_scale()) {
total_size += 1 + 4;
}
// optional float shift = 3 [default = 0];
if (has_shift()) {
total_size += 1 + 4;
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void ExpParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.ExpParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const ExpParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const ExpParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.ExpParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.ExpParameter)
UnsafeMergeFrom(*source);
}
}
void ExpParameter::MergeFrom(const ExpParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.ExpParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void ExpParameter::UnsafeMergeFrom(const ExpParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_base()) {
set_base(from.base());
}
if (from.has_scale()) {
set_scale(from.scale());
}
if (from.has_shift()) {
set_shift(from.shift());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void ExpParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.ExpParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void ExpParameter::CopyFrom(const ExpParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.ExpParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool ExpParameter::IsInitialized() const {
return true;
}
void ExpParameter::Swap(ExpParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void ExpParameter::InternalSwap(ExpParameter* other) {
std::swap(base_, other->base_);
std::swap(scale_, other->scale_);
std::swap(shift_, other->shift_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata ExpParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = ExpParameter_descriptor_;
metadata.reflection = ExpParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// ExpParameter
// optional float base = 1 [default = -1];
bool ExpParameter::has_base() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void ExpParameter::set_has_base() {
_has_bits_[0] |= 0x00000001u;
}
void ExpParameter::clear_has_base() {
_has_bits_[0] &= ~0x00000001u;
}
void ExpParameter::clear_base() {
base_ = -1;
clear_has_base();
}
float ExpParameter::base() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ExpParameter.base)
return base_;
}
void ExpParameter::set_base(float value) {
set_has_base();
base_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ExpParameter.base)
}
// optional float scale = 2 [default = 1];
bool ExpParameter::has_scale() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void ExpParameter::set_has_scale() {
_has_bits_[0] |= 0x00000002u;
}
void ExpParameter::clear_has_scale() {
_has_bits_[0] &= ~0x00000002u;
}
void ExpParameter::clear_scale() {
scale_ = 1;
clear_has_scale();
}
float ExpParameter::scale() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ExpParameter.scale)
return scale_;
}
void ExpParameter::set_scale(float value) {
set_has_scale();
scale_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ExpParameter.scale)
}
// optional float shift = 3 [default = 0];
bool ExpParameter::has_shift() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void ExpParameter::set_has_shift() {
_has_bits_[0] |= 0x00000004u;
}
void ExpParameter::clear_has_shift() {
_has_bits_[0] &= ~0x00000004u;
}
void ExpParameter::clear_shift() {
shift_ = 0;
clear_has_shift();
}
float ExpParameter::shift() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ExpParameter.shift)
return shift_;
}
void ExpParameter::set_shift(float value) {
set_has_shift();
shift_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ExpParameter.shift)
}
inline const ExpParameter* ExpParameter::internal_default_instance() {
return &ExpParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int FlattenParameter::kAxisFieldNumber;
const int FlattenParameter::kEndAxisFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
FlattenParameter::FlattenParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.FlattenParameter)
}
void FlattenParameter::InitAsDefaultInstance() {
}
FlattenParameter::FlattenParameter(const FlattenParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.FlattenParameter)
}
void FlattenParameter::SharedCtor() {
_cached_size_ = 0;
axis_ = 1;
end_axis_ = -1;
}
FlattenParameter::~FlattenParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.FlattenParameter)
SharedDtor();
}
void FlattenParameter::SharedDtor() {
}
void FlattenParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* FlattenParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return FlattenParameter_descriptor_;
}
const FlattenParameter& FlattenParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<FlattenParameter> FlattenParameter_default_instance_;
FlattenParameter* FlattenParameter::New(::google::protobuf::Arena* arena) const {
FlattenParameter* n = new FlattenParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void FlattenParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.FlattenParameter)
if (_has_bits_[0 / 32] & 3u) {
axis_ = 1;
end_axis_ = -1;
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool FlattenParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.FlattenParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional int32 axis = 1 [default = 1];
case 1: {
if (tag == 8) {
set_has_axis();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &axis_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_end_axis;
break;
}
// optional int32 end_axis = 2 [default = -1];
case 2: {
if (tag == 16) {
parse_end_axis:
set_has_end_axis();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &end_axis_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.FlattenParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.FlattenParameter)
return false;
#undef DO_
}
void FlattenParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.FlattenParameter)
// optional int32 axis = 1 [default = 1];
if (has_axis()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(1, this->axis(), output);
}
// optional int32 end_axis = 2 [default = -1];
if (has_end_axis()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->end_axis(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.FlattenParameter)
}
::google::protobuf::uint8* FlattenParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.FlattenParameter)
// optional int32 axis = 1 [default = 1];
if (has_axis()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(1, this->axis(), target);
}
// optional int32 end_axis = 2 [default = -1];
if (has_end_axis()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(2, this->end_axis(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.FlattenParameter)
return target;
}
size_t FlattenParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.FlattenParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 3u) {
// optional int32 axis = 1 [default = 1];
if (has_axis()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->axis());
}
// optional int32 end_axis = 2 [default = -1];
if (has_end_axis()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->end_axis());
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void FlattenParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.FlattenParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const FlattenParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const FlattenParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.FlattenParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.FlattenParameter)
UnsafeMergeFrom(*source);
}
}
void FlattenParameter::MergeFrom(const FlattenParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.FlattenParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void FlattenParameter::UnsafeMergeFrom(const FlattenParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_axis()) {
set_axis(from.axis());
}
if (from.has_end_axis()) {
set_end_axis(from.end_axis());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void FlattenParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.FlattenParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void FlattenParameter::CopyFrom(const FlattenParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.FlattenParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool FlattenParameter::IsInitialized() const {
return true;
}
void FlattenParameter::Swap(FlattenParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void FlattenParameter::InternalSwap(FlattenParameter* other) {
std::swap(axis_, other->axis_);
std::swap(end_axis_, other->end_axis_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata FlattenParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = FlattenParameter_descriptor_;
metadata.reflection = FlattenParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// FlattenParameter
// optional int32 axis = 1 [default = 1];
bool FlattenParameter::has_axis() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void FlattenParameter::set_has_axis() {
_has_bits_[0] |= 0x00000001u;
}
void FlattenParameter::clear_has_axis() {
_has_bits_[0] &= ~0x00000001u;
}
void FlattenParameter::clear_axis() {
axis_ = 1;
clear_has_axis();
}
::google::protobuf::int32 FlattenParameter::axis() const {
// @@protoc_insertion_point(field_get:opencv_caffe.FlattenParameter.axis)
return axis_;
}
void FlattenParameter::set_axis(::google::protobuf::int32 value) {
set_has_axis();
axis_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.FlattenParameter.axis)
}
// optional int32 end_axis = 2 [default = -1];
bool FlattenParameter::has_end_axis() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void FlattenParameter::set_has_end_axis() {
_has_bits_[0] |= 0x00000002u;
}
void FlattenParameter::clear_has_end_axis() {
_has_bits_[0] &= ~0x00000002u;
}
void FlattenParameter::clear_end_axis() {
end_axis_ = -1;
clear_has_end_axis();
}
::google::protobuf::int32 FlattenParameter::end_axis() const {
// @@protoc_insertion_point(field_get:opencv_caffe.FlattenParameter.end_axis)
return end_axis_;
}
void FlattenParameter::set_end_axis(::google::protobuf::int32 value) {
set_has_end_axis();
end_axis_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.FlattenParameter.end_axis)
}
inline const FlattenParameter* FlattenParameter::internal_default_instance() {
return &FlattenParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int HDF5DataParameter::kSourceFieldNumber;
const int HDF5DataParameter::kBatchSizeFieldNumber;
const int HDF5DataParameter::kShuffleFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
HDF5DataParameter::HDF5DataParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.HDF5DataParameter)
}
void HDF5DataParameter::InitAsDefaultInstance() {
}
HDF5DataParameter::HDF5DataParameter(const HDF5DataParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.HDF5DataParameter)
}
void HDF5DataParameter::SharedCtor() {
_cached_size_ = 0;
source_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
::memset(&batch_size_, 0, reinterpret_cast<char*>(&shuffle_) -
reinterpret_cast<char*>(&batch_size_) + sizeof(shuffle_));
}
HDF5DataParameter::~HDF5DataParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.HDF5DataParameter)
SharedDtor();
}
void HDF5DataParameter::SharedDtor() {
source_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void HDF5DataParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* HDF5DataParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return HDF5DataParameter_descriptor_;
}
const HDF5DataParameter& HDF5DataParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<HDF5DataParameter> HDF5DataParameter_default_instance_;
HDF5DataParameter* HDF5DataParameter::New(::google::protobuf::Arena* arena) const {
HDF5DataParameter* n = new HDF5DataParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void HDF5DataParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.HDF5DataParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(HDF5DataParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<HDF5DataParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
if (_has_bits_[0 / 32] & 7u) {
ZR_(batch_size_, shuffle_);
if (has_source()) {
source_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
}
#undef ZR_HELPER_
#undef ZR_
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool HDF5DataParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.HDF5DataParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional string source = 1;
case 1: {
if (tag == 10) {
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_source()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->source().data(), this->source().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.HDF5DataParameter.source");
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_batch_size;
break;
}
// optional uint32 batch_size = 2;
case 2: {
if (tag == 16) {
parse_batch_size:
set_has_batch_size();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &batch_size_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(24)) goto parse_shuffle;
break;
}
// optional bool shuffle = 3 [default = false];
case 3: {
if (tag == 24) {
parse_shuffle:
set_has_shuffle();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &shuffle_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.HDF5DataParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.HDF5DataParameter)
return false;
#undef DO_
}
void HDF5DataParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.HDF5DataParameter)
// optional string source = 1;
if (has_source()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->source().data(), this->source().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.HDF5DataParameter.source");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
1, this->source(), output);
}
// optional uint32 batch_size = 2;
if (has_batch_size()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(2, this->batch_size(), output);
}
// optional bool shuffle = 3 [default = false];
if (has_shuffle()) {
::google::protobuf::internal::WireFormatLite::WriteBool(3, this->shuffle(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.HDF5DataParameter)
}
::google::protobuf::uint8* HDF5DataParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.HDF5DataParameter)
// optional string source = 1;
if (has_source()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->source().data(), this->source().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.HDF5DataParameter.source");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
1, this->source(), target);
}
// optional uint32 batch_size = 2;
if (has_batch_size()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(2, this->batch_size(), target);
}
// optional bool shuffle = 3 [default = false];
if (has_shuffle()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(3, this->shuffle(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.HDF5DataParameter)
return target;
}
size_t HDF5DataParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.HDF5DataParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 7u) {
// optional string source = 1;
if (has_source()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->source());
}
// optional uint32 batch_size = 2;
if (has_batch_size()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->batch_size());
}
// optional bool shuffle = 3 [default = false];
if (has_shuffle()) {
total_size += 1 + 1;
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void HDF5DataParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.HDF5DataParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const HDF5DataParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const HDF5DataParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.HDF5DataParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.HDF5DataParameter)
UnsafeMergeFrom(*source);
}
}
void HDF5DataParameter::MergeFrom(const HDF5DataParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.HDF5DataParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void HDF5DataParameter::UnsafeMergeFrom(const HDF5DataParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_source()) {
set_has_source();
source_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.source_);
}
if (from.has_batch_size()) {
set_batch_size(from.batch_size());
}
if (from.has_shuffle()) {
set_shuffle(from.shuffle());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void HDF5DataParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.HDF5DataParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void HDF5DataParameter::CopyFrom(const HDF5DataParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.HDF5DataParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool HDF5DataParameter::IsInitialized() const {
return true;
}
void HDF5DataParameter::Swap(HDF5DataParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void HDF5DataParameter::InternalSwap(HDF5DataParameter* other) {
source_.Swap(&other->source_);
std::swap(batch_size_, other->batch_size_);
std::swap(shuffle_, other->shuffle_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata HDF5DataParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = HDF5DataParameter_descriptor_;
metadata.reflection = HDF5DataParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// HDF5DataParameter
// optional string source = 1;
bool HDF5DataParameter::has_source() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void HDF5DataParameter::set_has_source() {
_has_bits_[0] |= 0x00000001u;
}
void HDF5DataParameter::clear_has_source() {
_has_bits_[0] &= ~0x00000001u;
}
void HDF5DataParameter::clear_source() {
source_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_source();
}
const ::std::string& HDF5DataParameter::source() const {
// @@protoc_insertion_point(field_get:opencv_caffe.HDF5DataParameter.source)
return source_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void HDF5DataParameter::set_source(const ::std::string& value) {
set_has_source();
source_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.HDF5DataParameter.source)
}
void HDF5DataParameter::set_source(const char* value) {
set_has_source();
source_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.HDF5DataParameter.source)
}
void HDF5DataParameter::set_source(const char* value, size_t size) {
set_has_source();
source_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.HDF5DataParameter.source)
}
::std::string* HDF5DataParameter::mutable_source() {
set_has_source();
// @@protoc_insertion_point(field_mutable:opencv_caffe.HDF5DataParameter.source)
return source_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* HDF5DataParameter::release_source() {
// @@protoc_insertion_point(field_release:opencv_caffe.HDF5DataParameter.source)
clear_has_source();
return source_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void HDF5DataParameter::set_allocated_source(::std::string* source) {
if (source != NULL) {
set_has_source();
} else {
clear_has_source();
}
source_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), source);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.HDF5DataParameter.source)
}
// optional uint32 batch_size = 2;
bool HDF5DataParameter::has_batch_size() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void HDF5DataParameter::set_has_batch_size() {
_has_bits_[0] |= 0x00000002u;
}
void HDF5DataParameter::clear_has_batch_size() {
_has_bits_[0] &= ~0x00000002u;
}
void HDF5DataParameter::clear_batch_size() {
batch_size_ = 0u;
clear_has_batch_size();
}
::google::protobuf::uint32 HDF5DataParameter::batch_size() const {
// @@protoc_insertion_point(field_get:opencv_caffe.HDF5DataParameter.batch_size)
return batch_size_;
}
void HDF5DataParameter::set_batch_size(::google::protobuf::uint32 value) {
set_has_batch_size();
batch_size_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.HDF5DataParameter.batch_size)
}
// optional bool shuffle = 3 [default = false];
bool HDF5DataParameter::has_shuffle() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void HDF5DataParameter::set_has_shuffle() {
_has_bits_[0] |= 0x00000004u;
}
void HDF5DataParameter::clear_has_shuffle() {
_has_bits_[0] &= ~0x00000004u;
}
void HDF5DataParameter::clear_shuffle() {
shuffle_ = false;
clear_has_shuffle();
}
bool HDF5DataParameter::shuffle() const {
// @@protoc_insertion_point(field_get:opencv_caffe.HDF5DataParameter.shuffle)
return shuffle_;
}
void HDF5DataParameter::set_shuffle(bool value) {
set_has_shuffle();
shuffle_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.HDF5DataParameter.shuffle)
}
inline const HDF5DataParameter* HDF5DataParameter::internal_default_instance() {
return &HDF5DataParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int HDF5OutputParameter::kFileNameFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
HDF5OutputParameter::HDF5OutputParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.HDF5OutputParameter)
}
void HDF5OutputParameter::InitAsDefaultInstance() {
}
HDF5OutputParameter::HDF5OutputParameter(const HDF5OutputParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.HDF5OutputParameter)
}
void HDF5OutputParameter::SharedCtor() {
_cached_size_ = 0;
file_name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
HDF5OutputParameter::~HDF5OutputParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.HDF5OutputParameter)
SharedDtor();
}
void HDF5OutputParameter::SharedDtor() {
file_name_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void HDF5OutputParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* HDF5OutputParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return HDF5OutputParameter_descriptor_;
}
const HDF5OutputParameter& HDF5OutputParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<HDF5OutputParameter> HDF5OutputParameter_default_instance_;
HDF5OutputParameter* HDF5OutputParameter::New(::google::protobuf::Arena* arena) const {
HDF5OutputParameter* n = new HDF5OutputParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void HDF5OutputParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.HDF5OutputParameter)
if (has_file_name()) {
file_name_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool HDF5OutputParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.HDF5OutputParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional string file_name = 1;
case 1: {
if (tag == 10) {
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_file_name()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->file_name().data(), this->file_name().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.HDF5OutputParameter.file_name");
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.HDF5OutputParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.HDF5OutputParameter)
return false;
#undef DO_
}
void HDF5OutputParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.HDF5OutputParameter)
// optional string file_name = 1;
if (has_file_name()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->file_name().data(), this->file_name().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.HDF5OutputParameter.file_name");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
1, this->file_name(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.HDF5OutputParameter)
}
::google::protobuf::uint8* HDF5OutputParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.HDF5OutputParameter)
// optional string file_name = 1;
if (has_file_name()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->file_name().data(), this->file_name().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.HDF5OutputParameter.file_name");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
1, this->file_name(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.HDF5OutputParameter)
return target;
}
size_t HDF5OutputParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.HDF5OutputParameter)
size_t total_size = 0;
// optional string file_name = 1;
if (has_file_name()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->file_name());
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void HDF5OutputParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.HDF5OutputParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const HDF5OutputParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const HDF5OutputParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.HDF5OutputParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.HDF5OutputParameter)
UnsafeMergeFrom(*source);
}
}
void HDF5OutputParameter::MergeFrom(const HDF5OutputParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.HDF5OutputParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void HDF5OutputParameter::UnsafeMergeFrom(const HDF5OutputParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_file_name()) {
set_has_file_name();
file_name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.file_name_);
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void HDF5OutputParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.HDF5OutputParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void HDF5OutputParameter::CopyFrom(const HDF5OutputParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.HDF5OutputParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool HDF5OutputParameter::IsInitialized() const {
return true;
}
void HDF5OutputParameter::Swap(HDF5OutputParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void HDF5OutputParameter::InternalSwap(HDF5OutputParameter* other) {
file_name_.Swap(&other->file_name_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata HDF5OutputParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = HDF5OutputParameter_descriptor_;
metadata.reflection = HDF5OutputParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// HDF5OutputParameter
// optional string file_name = 1;
bool HDF5OutputParameter::has_file_name() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void HDF5OutputParameter::set_has_file_name() {
_has_bits_[0] |= 0x00000001u;
}
void HDF5OutputParameter::clear_has_file_name() {
_has_bits_[0] &= ~0x00000001u;
}
void HDF5OutputParameter::clear_file_name() {
file_name_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_file_name();
}
const ::std::string& HDF5OutputParameter::file_name() const {
// @@protoc_insertion_point(field_get:opencv_caffe.HDF5OutputParameter.file_name)
return file_name_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void HDF5OutputParameter::set_file_name(const ::std::string& value) {
set_has_file_name();
file_name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.HDF5OutputParameter.file_name)
}
void HDF5OutputParameter::set_file_name(const char* value) {
set_has_file_name();
file_name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.HDF5OutputParameter.file_name)
}
void HDF5OutputParameter::set_file_name(const char* value, size_t size) {
set_has_file_name();
file_name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.HDF5OutputParameter.file_name)
}
::std::string* HDF5OutputParameter::mutable_file_name() {
set_has_file_name();
// @@protoc_insertion_point(field_mutable:opencv_caffe.HDF5OutputParameter.file_name)
return file_name_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* HDF5OutputParameter::release_file_name() {
// @@protoc_insertion_point(field_release:opencv_caffe.HDF5OutputParameter.file_name)
clear_has_file_name();
return file_name_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void HDF5OutputParameter::set_allocated_file_name(::std::string* file_name) {
if (file_name != NULL) {
set_has_file_name();
} else {
clear_has_file_name();
}
file_name_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), file_name);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.HDF5OutputParameter.file_name)
}
inline const HDF5OutputParameter* HDF5OutputParameter::internal_default_instance() {
return &HDF5OutputParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
const ::google::protobuf::EnumDescriptor* HingeLossParameter_Norm_descriptor() {
protobuf_AssignDescriptorsOnce();
return HingeLossParameter_Norm_descriptor_;
}
bool HingeLossParameter_Norm_IsValid(int value) {
switch (value) {
case 1:
case 2:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const HingeLossParameter_Norm HingeLossParameter::L1;
const HingeLossParameter_Norm HingeLossParameter::L2;
const HingeLossParameter_Norm HingeLossParameter::Norm_MIN;
const HingeLossParameter_Norm HingeLossParameter::Norm_MAX;
const int HingeLossParameter::Norm_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int HingeLossParameter::kNormFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
HingeLossParameter::HingeLossParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.HingeLossParameter)
}
void HingeLossParameter::InitAsDefaultInstance() {
}
HingeLossParameter::HingeLossParameter(const HingeLossParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.HingeLossParameter)
}
void HingeLossParameter::SharedCtor() {
_cached_size_ = 0;
norm_ = 1;
}
HingeLossParameter::~HingeLossParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.HingeLossParameter)
SharedDtor();
}
void HingeLossParameter::SharedDtor() {
}
void HingeLossParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* HingeLossParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return HingeLossParameter_descriptor_;
}
const HingeLossParameter& HingeLossParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<HingeLossParameter> HingeLossParameter_default_instance_;
HingeLossParameter* HingeLossParameter::New(::google::protobuf::Arena* arena) const {
HingeLossParameter* n = new HingeLossParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void HingeLossParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.HingeLossParameter)
norm_ = 1;
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool HingeLossParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.HingeLossParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional .opencv_caffe.HingeLossParameter.Norm norm = 1 [default = L1];
case 1: {
if (tag == 8) {
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::HingeLossParameter_Norm_IsValid(value)) {
set_norm(static_cast< ::opencv_caffe::HingeLossParameter_Norm >(value));
} else {
mutable_unknown_fields()->AddVarint(1, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.HingeLossParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.HingeLossParameter)
return false;
#undef DO_
}
void HingeLossParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.HingeLossParameter)
// optional .opencv_caffe.HingeLossParameter.Norm norm = 1 [default = L1];
if (has_norm()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
1, this->norm(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.HingeLossParameter)
}
::google::protobuf::uint8* HingeLossParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.HingeLossParameter)
// optional .opencv_caffe.HingeLossParameter.Norm norm = 1 [default = L1];
if (has_norm()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
1, this->norm(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.HingeLossParameter)
return target;
}
size_t HingeLossParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.HingeLossParameter)
size_t total_size = 0;
// optional .opencv_caffe.HingeLossParameter.Norm norm = 1 [default = L1];
if (has_norm()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->norm());
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void HingeLossParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.HingeLossParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const HingeLossParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const HingeLossParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.HingeLossParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.HingeLossParameter)
UnsafeMergeFrom(*source);
}
}
void HingeLossParameter::MergeFrom(const HingeLossParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.HingeLossParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void HingeLossParameter::UnsafeMergeFrom(const HingeLossParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_norm()) {
set_norm(from.norm());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void HingeLossParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.HingeLossParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void HingeLossParameter::CopyFrom(const HingeLossParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.HingeLossParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool HingeLossParameter::IsInitialized() const {
return true;
}
void HingeLossParameter::Swap(HingeLossParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void HingeLossParameter::InternalSwap(HingeLossParameter* other) {
std::swap(norm_, other->norm_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata HingeLossParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = HingeLossParameter_descriptor_;
metadata.reflection = HingeLossParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// HingeLossParameter
// optional .opencv_caffe.HingeLossParameter.Norm norm = 1 [default = L1];
bool HingeLossParameter::has_norm() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void HingeLossParameter::set_has_norm() {
_has_bits_[0] |= 0x00000001u;
}
void HingeLossParameter::clear_has_norm() {
_has_bits_[0] &= ~0x00000001u;
}
void HingeLossParameter::clear_norm() {
norm_ = 1;
clear_has_norm();
}
::opencv_caffe::HingeLossParameter_Norm HingeLossParameter::norm() const {
// @@protoc_insertion_point(field_get:opencv_caffe.HingeLossParameter.norm)
return static_cast< ::opencv_caffe::HingeLossParameter_Norm >(norm_);
}
void HingeLossParameter::set_norm(::opencv_caffe::HingeLossParameter_Norm value) {
assert(::opencv_caffe::HingeLossParameter_Norm_IsValid(value));
set_has_norm();
norm_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.HingeLossParameter.norm)
}
inline const HingeLossParameter* HingeLossParameter::internal_default_instance() {
return &HingeLossParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int ImageDataParameter::kSourceFieldNumber;
const int ImageDataParameter::kBatchSizeFieldNumber;
const int ImageDataParameter::kRandSkipFieldNumber;
const int ImageDataParameter::kShuffleFieldNumber;
const int ImageDataParameter::kNewHeightFieldNumber;
const int ImageDataParameter::kNewWidthFieldNumber;
const int ImageDataParameter::kIsColorFieldNumber;
const int ImageDataParameter::kScaleFieldNumber;
const int ImageDataParameter::kMeanFileFieldNumber;
const int ImageDataParameter::kCropSizeFieldNumber;
const int ImageDataParameter::kMirrorFieldNumber;
const int ImageDataParameter::kRootFolderFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
ImageDataParameter::ImageDataParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.ImageDataParameter)
}
void ImageDataParameter::InitAsDefaultInstance() {
}
ImageDataParameter::ImageDataParameter(const ImageDataParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.ImageDataParameter)
}
void ImageDataParameter::SharedCtor() {
_cached_size_ = 0;
source_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
mean_file_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
root_folder_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
::memset(&rand_skip_, 0, reinterpret_cast<char*>(&crop_size_) -
reinterpret_cast<char*>(&rand_skip_) + sizeof(crop_size_));
scale_ = 1;
batch_size_ = 1u;
is_color_ = true;
}
ImageDataParameter::~ImageDataParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.ImageDataParameter)
SharedDtor();
}
void ImageDataParameter::SharedDtor() {
source_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
mean_file_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
root_folder_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void ImageDataParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* ImageDataParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return ImageDataParameter_descriptor_;
}
const ImageDataParameter& ImageDataParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<ImageDataParameter> ImageDataParameter_default_instance_;
ImageDataParameter* ImageDataParameter::New(::google::protobuf::Arena* arena) const {
ImageDataParameter* n = new ImageDataParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void ImageDataParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.ImageDataParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(ImageDataParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<ImageDataParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
if (_has_bits_[0 / 32] & 255u) {
ZR_(rand_skip_, shuffle_);
if (has_source()) {
source_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
batch_size_ = 1u;
is_color_ = true;
scale_ = 1;
}
if (_has_bits_[8 / 32] & 3840u) {
ZR_(mirror_, crop_size_);
if (has_mean_file()) {
mean_file_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
if (has_root_folder()) {
root_folder_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
}
#undef ZR_HELPER_
#undef ZR_
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool ImageDataParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.ImageDataParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional string source = 1;
case 1: {
if (tag == 10) {
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_source()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->source().data(), this->source().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.ImageDataParameter.source");
} else {
goto handle_unusual;
}
if (input->ExpectTag(21)) goto parse_scale;
break;
}
// optional float scale = 2 [default = 1];
case 2: {
if (tag == 21) {
parse_scale:
set_has_scale();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &scale_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(26)) goto parse_mean_file;
break;
}
// optional string mean_file = 3;
case 3: {
if (tag == 26) {
parse_mean_file:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_mean_file()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->mean_file().data(), this->mean_file().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.ImageDataParameter.mean_file");
} else {
goto handle_unusual;
}
if (input->ExpectTag(32)) goto parse_batch_size;
break;
}
// optional uint32 batch_size = 4 [default = 1];
case 4: {
if (tag == 32) {
parse_batch_size:
set_has_batch_size();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &batch_size_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(40)) goto parse_crop_size;
break;
}
// optional uint32 crop_size = 5 [default = 0];
case 5: {
if (tag == 40) {
parse_crop_size:
set_has_crop_size();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &crop_size_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(48)) goto parse_mirror;
break;
}
// optional bool mirror = 6 [default = false];
case 6: {
if (tag == 48) {
parse_mirror:
set_has_mirror();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &mirror_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(56)) goto parse_rand_skip;
break;
}
// optional uint32 rand_skip = 7 [default = 0];
case 7: {
if (tag == 56) {
parse_rand_skip:
set_has_rand_skip();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &rand_skip_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(64)) goto parse_shuffle;
break;
}
// optional bool shuffle = 8 [default = false];
case 8: {
if (tag == 64) {
parse_shuffle:
set_has_shuffle();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &shuffle_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(72)) goto parse_new_height;
break;
}
// optional uint32 new_height = 9 [default = 0];
case 9: {
if (tag == 72) {
parse_new_height:
set_has_new_height();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &new_height_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(80)) goto parse_new_width;
break;
}
// optional uint32 new_width = 10 [default = 0];
case 10: {
if (tag == 80) {
parse_new_width:
set_has_new_width();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &new_width_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(88)) goto parse_is_color;
break;
}
// optional bool is_color = 11 [default = true];
case 11: {
if (tag == 88) {
parse_is_color:
set_has_is_color();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &is_color_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(98)) goto parse_root_folder;
break;
}
// optional string root_folder = 12 [default = ""];
case 12: {
if (tag == 98) {
parse_root_folder:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_root_folder()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->root_folder().data(), this->root_folder().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.ImageDataParameter.root_folder");
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.ImageDataParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.ImageDataParameter)
return false;
#undef DO_
}
void ImageDataParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.ImageDataParameter)
// optional string source = 1;
if (has_source()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->source().data(), this->source().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.ImageDataParameter.source");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
1, this->source(), output);
}
// optional float scale = 2 [default = 1];
if (has_scale()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(2, this->scale(), output);
}
// optional string mean_file = 3;
if (has_mean_file()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->mean_file().data(), this->mean_file().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.ImageDataParameter.mean_file");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
3, this->mean_file(), output);
}
// optional uint32 batch_size = 4 [default = 1];
if (has_batch_size()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(4, this->batch_size(), output);
}
// optional uint32 crop_size = 5 [default = 0];
if (has_crop_size()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(5, this->crop_size(), output);
}
// optional bool mirror = 6 [default = false];
if (has_mirror()) {
::google::protobuf::internal::WireFormatLite::WriteBool(6, this->mirror(), output);
}
// optional uint32 rand_skip = 7 [default = 0];
if (has_rand_skip()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(7, this->rand_skip(), output);
}
// optional bool shuffle = 8 [default = false];
if (has_shuffle()) {
::google::protobuf::internal::WireFormatLite::WriteBool(8, this->shuffle(), output);
}
// optional uint32 new_height = 9 [default = 0];
if (has_new_height()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(9, this->new_height(), output);
}
// optional uint32 new_width = 10 [default = 0];
if (has_new_width()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(10, this->new_width(), output);
}
// optional bool is_color = 11 [default = true];
if (has_is_color()) {
::google::protobuf::internal::WireFormatLite::WriteBool(11, this->is_color(), output);
}
// optional string root_folder = 12 [default = ""];
if (has_root_folder()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->root_folder().data(), this->root_folder().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.ImageDataParameter.root_folder");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
12, this->root_folder(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.ImageDataParameter)
}
::google::protobuf::uint8* ImageDataParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.ImageDataParameter)
// optional string source = 1;
if (has_source()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->source().data(), this->source().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.ImageDataParameter.source");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
1, this->source(), target);
}
// optional float scale = 2 [default = 1];
if (has_scale()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(2, this->scale(), target);
}
// optional string mean_file = 3;
if (has_mean_file()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->mean_file().data(), this->mean_file().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.ImageDataParameter.mean_file");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
3, this->mean_file(), target);
}
// optional uint32 batch_size = 4 [default = 1];
if (has_batch_size()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(4, this->batch_size(), target);
}
// optional uint32 crop_size = 5 [default = 0];
if (has_crop_size()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(5, this->crop_size(), target);
}
// optional bool mirror = 6 [default = false];
if (has_mirror()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(6, this->mirror(), target);
}
// optional uint32 rand_skip = 7 [default = 0];
if (has_rand_skip()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(7, this->rand_skip(), target);
}
// optional bool shuffle = 8 [default = false];
if (has_shuffle()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(8, this->shuffle(), target);
}
// optional uint32 new_height = 9 [default = 0];
if (has_new_height()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(9, this->new_height(), target);
}
// optional uint32 new_width = 10 [default = 0];
if (has_new_width()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(10, this->new_width(), target);
}
// optional bool is_color = 11 [default = true];
if (has_is_color()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(11, this->is_color(), target);
}
// optional string root_folder = 12 [default = ""];
if (has_root_folder()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->root_folder().data(), this->root_folder().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.ImageDataParameter.root_folder");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
12, this->root_folder(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.ImageDataParameter)
return target;
}
size_t ImageDataParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.ImageDataParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 255u) {
// optional string source = 1;
if (has_source()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->source());
}
// optional uint32 batch_size = 4 [default = 1];
if (has_batch_size()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->batch_size());
}
// optional uint32 rand_skip = 7 [default = 0];
if (has_rand_skip()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->rand_skip());
}
// optional bool shuffle = 8 [default = false];
if (has_shuffle()) {
total_size += 1 + 1;
}
// optional uint32 new_height = 9 [default = 0];
if (has_new_height()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->new_height());
}
// optional uint32 new_width = 10 [default = 0];
if (has_new_width()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->new_width());
}
// optional bool is_color = 11 [default = true];
if (has_is_color()) {
total_size += 1 + 1;
}
// optional float scale = 2 [default = 1];
if (has_scale()) {
total_size += 1 + 4;
}
}
if (_has_bits_[8 / 32] & 3840u) {
// optional string mean_file = 3;
if (has_mean_file()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->mean_file());
}
// optional uint32 crop_size = 5 [default = 0];
if (has_crop_size()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->crop_size());
}
// optional bool mirror = 6 [default = false];
if (has_mirror()) {
total_size += 1 + 1;
}
// optional string root_folder = 12 [default = ""];
if (has_root_folder()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->root_folder());
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void ImageDataParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.ImageDataParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const ImageDataParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const ImageDataParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.ImageDataParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.ImageDataParameter)
UnsafeMergeFrom(*source);
}
}
void ImageDataParameter::MergeFrom(const ImageDataParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.ImageDataParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void ImageDataParameter::UnsafeMergeFrom(const ImageDataParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_source()) {
set_has_source();
source_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.source_);
}
if (from.has_batch_size()) {
set_batch_size(from.batch_size());
}
if (from.has_rand_skip()) {
set_rand_skip(from.rand_skip());
}
if (from.has_shuffle()) {
set_shuffle(from.shuffle());
}
if (from.has_new_height()) {
set_new_height(from.new_height());
}
if (from.has_new_width()) {
set_new_width(from.new_width());
}
if (from.has_is_color()) {
set_is_color(from.is_color());
}
if (from.has_scale()) {
set_scale(from.scale());
}
}
if (from._has_bits_[8 / 32] & (0xffu << (8 % 32))) {
if (from.has_mean_file()) {
set_has_mean_file();
mean_file_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.mean_file_);
}
if (from.has_crop_size()) {
set_crop_size(from.crop_size());
}
if (from.has_mirror()) {
set_mirror(from.mirror());
}
if (from.has_root_folder()) {
set_has_root_folder();
root_folder_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.root_folder_);
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void ImageDataParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.ImageDataParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void ImageDataParameter::CopyFrom(const ImageDataParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.ImageDataParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool ImageDataParameter::IsInitialized() const {
return true;
}
void ImageDataParameter::Swap(ImageDataParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void ImageDataParameter::InternalSwap(ImageDataParameter* other) {
source_.Swap(&other->source_);
std::swap(batch_size_, other->batch_size_);
std::swap(rand_skip_, other->rand_skip_);
std::swap(shuffle_, other->shuffle_);
std::swap(new_height_, other->new_height_);
std::swap(new_width_, other->new_width_);
std::swap(is_color_, other->is_color_);
std::swap(scale_, other->scale_);
mean_file_.Swap(&other->mean_file_);
std::swap(crop_size_, other->crop_size_);
std::swap(mirror_, other->mirror_);
root_folder_.Swap(&other->root_folder_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata ImageDataParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = ImageDataParameter_descriptor_;
metadata.reflection = ImageDataParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// ImageDataParameter
// optional string source = 1;
bool ImageDataParameter::has_source() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void ImageDataParameter::set_has_source() {
_has_bits_[0] |= 0x00000001u;
}
void ImageDataParameter::clear_has_source() {
_has_bits_[0] &= ~0x00000001u;
}
void ImageDataParameter::clear_source() {
source_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_source();
}
const ::std::string& ImageDataParameter::source() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ImageDataParameter.source)
return source_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void ImageDataParameter::set_source(const ::std::string& value) {
set_has_source();
source_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.ImageDataParameter.source)
}
void ImageDataParameter::set_source(const char* value) {
set_has_source();
source_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.ImageDataParameter.source)
}
void ImageDataParameter::set_source(const char* value, size_t size) {
set_has_source();
source_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.ImageDataParameter.source)
}
::std::string* ImageDataParameter::mutable_source() {
set_has_source();
// @@protoc_insertion_point(field_mutable:opencv_caffe.ImageDataParameter.source)
return source_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* ImageDataParameter::release_source() {
// @@protoc_insertion_point(field_release:opencv_caffe.ImageDataParameter.source)
clear_has_source();
return source_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void ImageDataParameter::set_allocated_source(::std::string* source) {
if (source != NULL) {
set_has_source();
} else {
clear_has_source();
}
source_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), source);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.ImageDataParameter.source)
}
// optional uint32 batch_size = 4 [default = 1];
bool ImageDataParameter::has_batch_size() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void ImageDataParameter::set_has_batch_size() {
_has_bits_[0] |= 0x00000002u;
}
void ImageDataParameter::clear_has_batch_size() {
_has_bits_[0] &= ~0x00000002u;
}
void ImageDataParameter::clear_batch_size() {
batch_size_ = 1u;
clear_has_batch_size();
}
::google::protobuf::uint32 ImageDataParameter::batch_size() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ImageDataParameter.batch_size)
return batch_size_;
}
void ImageDataParameter::set_batch_size(::google::protobuf::uint32 value) {
set_has_batch_size();
batch_size_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ImageDataParameter.batch_size)
}
// optional uint32 rand_skip = 7 [default = 0];
bool ImageDataParameter::has_rand_skip() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void ImageDataParameter::set_has_rand_skip() {
_has_bits_[0] |= 0x00000004u;
}
void ImageDataParameter::clear_has_rand_skip() {
_has_bits_[0] &= ~0x00000004u;
}
void ImageDataParameter::clear_rand_skip() {
rand_skip_ = 0u;
clear_has_rand_skip();
}
::google::protobuf::uint32 ImageDataParameter::rand_skip() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ImageDataParameter.rand_skip)
return rand_skip_;
}
void ImageDataParameter::set_rand_skip(::google::protobuf::uint32 value) {
set_has_rand_skip();
rand_skip_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ImageDataParameter.rand_skip)
}
// optional bool shuffle = 8 [default = false];
bool ImageDataParameter::has_shuffle() const {
return (_has_bits_[0] & 0x00000008u) != 0;
}
void ImageDataParameter::set_has_shuffle() {
_has_bits_[0] |= 0x00000008u;
}
void ImageDataParameter::clear_has_shuffle() {
_has_bits_[0] &= ~0x00000008u;
}
void ImageDataParameter::clear_shuffle() {
shuffle_ = false;
clear_has_shuffle();
}
bool ImageDataParameter::shuffle() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ImageDataParameter.shuffle)
return shuffle_;
}
void ImageDataParameter::set_shuffle(bool value) {
set_has_shuffle();
shuffle_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ImageDataParameter.shuffle)
}
// optional uint32 new_height = 9 [default = 0];
bool ImageDataParameter::has_new_height() const {
return (_has_bits_[0] & 0x00000010u) != 0;
}
void ImageDataParameter::set_has_new_height() {
_has_bits_[0] |= 0x00000010u;
}
void ImageDataParameter::clear_has_new_height() {
_has_bits_[0] &= ~0x00000010u;
}
void ImageDataParameter::clear_new_height() {
new_height_ = 0u;
clear_has_new_height();
}
::google::protobuf::uint32 ImageDataParameter::new_height() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ImageDataParameter.new_height)
return new_height_;
}
void ImageDataParameter::set_new_height(::google::protobuf::uint32 value) {
set_has_new_height();
new_height_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ImageDataParameter.new_height)
}
// optional uint32 new_width = 10 [default = 0];
bool ImageDataParameter::has_new_width() const {
return (_has_bits_[0] & 0x00000020u) != 0;
}
void ImageDataParameter::set_has_new_width() {
_has_bits_[0] |= 0x00000020u;
}
void ImageDataParameter::clear_has_new_width() {
_has_bits_[0] &= ~0x00000020u;
}
void ImageDataParameter::clear_new_width() {
new_width_ = 0u;
clear_has_new_width();
}
::google::protobuf::uint32 ImageDataParameter::new_width() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ImageDataParameter.new_width)
return new_width_;
}
void ImageDataParameter::set_new_width(::google::protobuf::uint32 value) {
set_has_new_width();
new_width_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ImageDataParameter.new_width)
}
// optional bool is_color = 11 [default = true];
bool ImageDataParameter::has_is_color() const {
return (_has_bits_[0] & 0x00000040u) != 0;
}
void ImageDataParameter::set_has_is_color() {
_has_bits_[0] |= 0x00000040u;
}
void ImageDataParameter::clear_has_is_color() {
_has_bits_[0] &= ~0x00000040u;
}
void ImageDataParameter::clear_is_color() {
is_color_ = true;
clear_has_is_color();
}
bool ImageDataParameter::is_color() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ImageDataParameter.is_color)
return is_color_;
}
void ImageDataParameter::set_is_color(bool value) {
set_has_is_color();
is_color_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ImageDataParameter.is_color)
}
// optional float scale = 2 [default = 1];
bool ImageDataParameter::has_scale() const {
return (_has_bits_[0] & 0x00000080u) != 0;
}
void ImageDataParameter::set_has_scale() {
_has_bits_[0] |= 0x00000080u;
}
void ImageDataParameter::clear_has_scale() {
_has_bits_[0] &= ~0x00000080u;
}
void ImageDataParameter::clear_scale() {
scale_ = 1;
clear_has_scale();
}
float ImageDataParameter::scale() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ImageDataParameter.scale)
return scale_;
}
void ImageDataParameter::set_scale(float value) {
set_has_scale();
scale_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ImageDataParameter.scale)
}
// optional string mean_file = 3;
bool ImageDataParameter::has_mean_file() const {
return (_has_bits_[0] & 0x00000100u) != 0;
}
void ImageDataParameter::set_has_mean_file() {
_has_bits_[0] |= 0x00000100u;
}
void ImageDataParameter::clear_has_mean_file() {
_has_bits_[0] &= ~0x00000100u;
}
void ImageDataParameter::clear_mean_file() {
mean_file_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_mean_file();
}
const ::std::string& ImageDataParameter::mean_file() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ImageDataParameter.mean_file)
return mean_file_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void ImageDataParameter::set_mean_file(const ::std::string& value) {
set_has_mean_file();
mean_file_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.ImageDataParameter.mean_file)
}
void ImageDataParameter::set_mean_file(const char* value) {
set_has_mean_file();
mean_file_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.ImageDataParameter.mean_file)
}
void ImageDataParameter::set_mean_file(const char* value, size_t size) {
set_has_mean_file();
mean_file_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.ImageDataParameter.mean_file)
}
::std::string* ImageDataParameter::mutable_mean_file() {
set_has_mean_file();
// @@protoc_insertion_point(field_mutable:opencv_caffe.ImageDataParameter.mean_file)
return mean_file_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* ImageDataParameter::release_mean_file() {
// @@protoc_insertion_point(field_release:opencv_caffe.ImageDataParameter.mean_file)
clear_has_mean_file();
return mean_file_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void ImageDataParameter::set_allocated_mean_file(::std::string* mean_file) {
if (mean_file != NULL) {
set_has_mean_file();
} else {
clear_has_mean_file();
}
mean_file_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), mean_file);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.ImageDataParameter.mean_file)
}
// optional uint32 crop_size = 5 [default = 0];
bool ImageDataParameter::has_crop_size() const {
return (_has_bits_[0] & 0x00000200u) != 0;
}
void ImageDataParameter::set_has_crop_size() {
_has_bits_[0] |= 0x00000200u;
}
void ImageDataParameter::clear_has_crop_size() {
_has_bits_[0] &= ~0x00000200u;
}
void ImageDataParameter::clear_crop_size() {
crop_size_ = 0u;
clear_has_crop_size();
}
::google::protobuf::uint32 ImageDataParameter::crop_size() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ImageDataParameter.crop_size)
return crop_size_;
}
void ImageDataParameter::set_crop_size(::google::protobuf::uint32 value) {
set_has_crop_size();
crop_size_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ImageDataParameter.crop_size)
}
// optional bool mirror = 6 [default = false];
bool ImageDataParameter::has_mirror() const {
return (_has_bits_[0] & 0x00000400u) != 0;
}
void ImageDataParameter::set_has_mirror() {
_has_bits_[0] |= 0x00000400u;
}
void ImageDataParameter::clear_has_mirror() {
_has_bits_[0] &= ~0x00000400u;
}
void ImageDataParameter::clear_mirror() {
mirror_ = false;
clear_has_mirror();
}
bool ImageDataParameter::mirror() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ImageDataParameter.mirror)
return mirror_;
}
void ImageDataParameter::set_mirror(bool value) {
set_has_mirror();
mirror_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ImageDataParameter.mirror)
}
// optional string root_folder = 12 [default = ""];
bool ImageDataParameter::has_root_folder() const {
return (_has_bits_[0] & 0x00000800u) != 0;
}
void ImageDataParameter::set_has_root_folder() {
_has_bits_[0] |= 0x00000800u;
}
void ImageDataParameter::clear_has_root_folder() {
_has_bits_[0] &= ~0x00000800u;
}
void ImageDataParameter::clear_root_folder() {
root_folder_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_root_folder();
}
const ::std::string& ImageDataParameter::root_folder() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ImageDataParameter.root_folder)
return root_folder_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void ImageDataParameter::set_root_folder(const ::std::string& value) {
set_has_root_folder();
root_folder_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.ImageDataParameter.root_folder)
}
void ImageDataParameter::set_root_folder(const char* value) {
set_has_root_folder();
root_folder_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.ImageDataParameter.root_folder)
}
void ImageDataParameter::set_root_folder(const char* value, size_t size) {
set_has_root_folder();
root_folder_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.ImageDataParameter.root_folder)
}
::std::string* ImageDataParameter::mutable_root_folder() {
set_has_root_folder();
// @@protoc_insertion_point(field_mutable:opencv_caffe.ImageDataParameter.root_folder)
return root_folder_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* ImageDataParameter::release_root_folder() {
// @@protoc_insertion_point(field_release:opencv_caffe.ImageDataParameter.root_folder)
clear_has_root_folder();
return root_folder_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void ImageDataParameter::set_allocated_root_folder(::std::string* root_folder) {
if (root_folder != NULL) {
set_has_root_folder();
} else {
clear_has_root_folder();
}
root_folder_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), root_folder);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.ImageDataParameter.root_folder)
}
inline const ImageDataParameter* ImageDataParameter::internal_default_instance() {
return &ImageDataParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int InfogainLossParameter::kSourceFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
InfogainLossParameter::InfogainLossParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.InfogainLossParameter)
}
void InfogainLossParameter::InitAsDefaultInstance() {
}
InfogainLossParameter::InfogainLossParameter(const InfogainLossParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.InfogainLossParameter)
}
void InfogainLossParameter::SharedCtor() {
_cached_size_ = 0;
source_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
InfogainLossParameter::~InfogainLossParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.InfogainLossParameter)
SharedDtor();
}
void InfogainLossParameter::SharedDtor() {
source_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void InfogainLossParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* InfogainLossParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return InfogainLossParameter_descriptor_;
}
const InfogainLossParameter& InfogainLossParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<InfogainLossParameter> InfogainLossParameter_default_instance_;
InfogainLossParameter* InfogainLossParameter::New(::google::protobuf::Arena* arena) const {
InfogainLossParameter* n = new InfogainLossParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void InfogainLossParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.InfogainLossParameter)
if (has_source()) {
source_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool InfogainLossParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.InfogainLossParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional string source = 1;
case 1: {
if (tag == 10) {
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_source()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->source().data(), this->source().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.InfogainLossParameter.source");
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.InfogainLossParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.InfogainLossParameter)
return false;
#undef DO_
}
void InfogainLossParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.InfogainLossParameter)
// optional string source = 1;
if (has_source()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->source().data(), this->source().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.InfogainLossParameter.source");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
1, this->source(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.InfogainLossParameter)
}
::google::protobuf::uint8* InfogainLossParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.InfogainLossParameter)
// optional string source = 1;
if (has_source()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->source().data(), this->source().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.InfogainLossParameter.source");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
1, this->source(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.InfogainLossParameter)
return target;
}
size_t InfogainLossParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.InfogainLossParameter)
size_t total_size = 0;
// optional string source = 1;
if (has_source()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->source());
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void InfogainLossParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.InfogainLossParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const InfogainLossParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const InfogainLossParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.InfogainLossParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.InfogainLossParameter)
UnsafeMergeFrom(*source);
}
}
void InfogainLossParameter::MergeFrom(const InfogainLossParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.InfogainLossParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void InfogainLossParameter::UnsafeMergeFrom(const InfogainLossParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_source()) {
set_has_source();
source_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.source_);
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void InfogainLossParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.InfogainLossParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void InfogainLossParameter::CopyFrom(const InfogainLossParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.InfogainLossParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool InfogainLossParameter::IsInitialized() const {
return true;
}
void InfogainLossParameter::Swap(InfogainLossParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void InfogainLossParameter::InternalSwap(InfogainLossParameter* other) {
source_.Swap(&other->source_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata InfogainLossParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = InfogainLossParameter_descriptor_;
metadata.reflection = InfogainLossParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// InfogainLossParameter
// optional string source = 1;
bool InfogainLossParameter::has_source() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void InfogainLossParameter::set_has_source() {
_has_bits_[0] |= 0x00000001u;
}
void InfogainLossParameter::clear_has_source() {
_has_bits_[0] &= ~0x00000001u;
}
void InfogainLossParameter::clear_source() {
source_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_source();
}
const ::std::string& InfogainLossParameter::source() const {
// @@protoc_insertion_point(field_get:opencv_caffe.InfogainLossParameter.source)
return source_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void InfogainLossParameter::set_source(const ::std::string& value) {
set_has_source();
source_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.InfogainLossParameter.source)
}
void InfogainLossParameter::set_source(const char* value) {
set_has_source();
source_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.InfogainLossParameter.source)
}
void InfogainLossParameter::set_source(const char* value, size_t size) {
set_has_source();
source_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.InfogainLossParameter.source)
}
::std::string* InfogainLossParameter::mutable_source() {
set_has_source();
// @@protoc_insertion_point(field_mutable:opencv_caffe.InfogainLossParameter.source)
return source_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* InfogainLossParameter::release_source() {
// @@protoc_insertion_point(field_release:opencv_caffe.InfogainLossParameter.source)
clear_has_source();
return source_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void InfogainLossParameter::set_allocated_source(::std::string* source) {
if (source != NULL) {
set_has_source();
} else {
clear_has_source();
}
source_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), source);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.InfogainLossParameter.source)
}
inline const InfogainLossParameter* InfogainLossParameter::internal_default_instance() {
return &InfogainLossParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int InnerProductParameter::kNumOutputFieldNumber;
const int InnerProductParameter::kBiasTermFieldNumber;
const int InnerProductParameter::kWeightFillerFieldNumber;
const int InnerProductParameter::kBiasFillerFieldNumber;
const int InnerProductParameter::kAxisFieldNumber;
const int InnerProductParameter::kTransposeFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
InnerProductParameter::InnerProductParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.InnerProductParameter)
}
void InnerProductParameter::InitAsDefaultInstance() {
weight_filler_ = const_cast< ::opencv_caffe::FillerParameter*>(
::opencv_caffe::FillerParameter::internal_default_instance());
bias_filler_ = const_cast< ::opencv_caffe::FillerParameter*>(
::opencv_caffe::FillerParameter::internal_default_instance());
}
InnerProductParameter::InnerProductParameter(const InnerProductParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.InnerProductParameter)
}
void InnerProductParameter::SharedCtor() {
_cached_size_ = 0;
weight_filler_ = NULL;
bias_filler_ = NULL;
::memset(&num_output_, 0, reinterpret_cast<char*>(&transpose_) -
reinterpret_cast<char*>(&num_output_) + sizeof(transpose_));
bias_term_ = true;
axis_ = 1;
}
InnerProductParameter::~InnerProductParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.InnerProductParameter)
SharedDtor();
}
void InnerProductParameter::SharedDtor() {
if (this != &InnerProductParameter_default_instance_.get()) {
delete weight_filler_;
delete bias_filler_;
}
}
void InnerProductParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* InnerProductParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return InnerProductParameter_descriptor_;
}
const InnerProductParameter& InnerProductParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<InnerProductParameter> InnerProductParameter_default_instance_;
InnerProductParameter* InnerProductParameter::New(::google::protobuf::Arena* arena) const {
InnerProductParameter* n = new InnerProductParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void InnerProductParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.InnerProductParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(InnerProductParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<InnerProductParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
if (_has_bits_[0 / 32] & 63u) {
ZR_(num_output_, transpose_);
bias_term_ = true;
if (has_weight_filler()) {
if (weight_filler_ != NULL) weight_filler_->::opencv_caffe::FillerParameter::Clear();
}
if (has_bias_filler()) {
if (bias_filler_ != NULL) bias_filler_->::opencv_caffe::FillerParameter::Clear();
}
axis_ = 1;
}
#undef ZR_HELPER_
#undef ZR_
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool InnerProductParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.InnerProductParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional uint32 num_output = 1;
case 1: {
if (tag == 8) {
set_has_num_output();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &num_output_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_bias_term;
break;
}
// optional bool bias_term = 2 [default = true];
case 2: {
if (tag == 16) {
parse_bias_term:
set_has_bias_term();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &bias_term_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(26)) goto parse_weight_filler;
break;
}
// optional .opencv_caffe.FillerParameter weight_filler = 3;
case 3: {
if (tag == 26) {
parse_weight_filler:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_weight_filler()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(34)) goto parse_bias_filler;
break;
}
// optional .opencv_caffe.FillerParameter bias_filler = 4;
case 4: {
if (tag == 34) {
parse_bias_filler:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_bias_filler()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(40)) goto parse_axis;
break;
}
// optional int32 axis = 5 [default = 1];
case 5: {
if (tag == 40) {
parse_axis:
set_has_axis();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &axis_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(48)) goto parse_transpose;
break;
}
// optional bool transpose = 6 [default = false];
case 6: {
if (tag == 48) {
parse_transpose:
set_has_transpose();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &transpose_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.InnerProductParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.InnerProductParameter)
return false;
#undef DO_
}
void InnerProductParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.InnerProductParameter)
// optional uint32 num_output = 1;
if (has_num_output()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(1, this->num_output(), output);
}
// optional bool bias_term = 2 [default = true];
if (has_bias_term()) {
::google::protobuf::internal::WireFormatLite::WriteBool(2, this->bias_term(), output);
}
// optional .opencv_caffe.FillerParameter weight_filler = 3;
if (has_weight_filler()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
3, *this->weight_filler_, output);
}
// optional .opencv_caffe.FillerParameter bias_filler = 4;
if (has_bias_filler()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
4, *this->bias_filler_, output);
}
// optional int32 axis = 5 [default = 1];
if (has_axis()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(5, this->axis(), output);
}
// optional bool transpose = 6 [default = false];
if (has_transpose()) {
::google::protobuf::internal::WireFormatLite::WriteBool(6, this->transpose(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.InnerProductParameter)
}
::google::protobuf::uint8* InnerProductParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.InnerProductParameter)
// optional uint32 num_output = 1;
if (has_num_output()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(1, this->num_output(), target);
}
// optional bool bias_term = 2 [default = true];
if (has_bias_term()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(2, this->bias_term(), target);
}
// optional .opencv_caffe.FillerParameter weight_filler = 3;
if (has_weight_filler()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
3, *this->weight_filler_, false, target);
}
// optional .opencv_caffe.FillerParameter bias_filler = 4;
if (has_bias_filler()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
4, *this->bias_filler_, false, target);
}
// optional int32 axis = 5 [default = 1];
if (has_axis()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(5, this->axis(), target);
}
// optional bool transpose = 6 [default = false];
if (has_transpose()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(6, this->transpose(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.InnerProductParameter)
return target;
}
size_t InnerProductParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.InnerProductParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 63u) {
// optional uint32 num_output = 1;
if (has_num_output()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->num_output());
}
// optional bool bias_term = 2 [default = true];
if (has_bias_term()) {
total_size += 1 + 1;
}
// optional .opencv_caffe.FillerParameter weight_filler = 3;
if (has_weight_filler()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->weight_filler_);
}
// optional .opencv_caffe.FillerParameter bias_filler = 4;
if (has_bias_filler()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->bias_filler_);
}
// optional int32 axis = 5 [default = 1];
if (has_axis()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->axis());
}
// optional bool transpose = 6 [default = false];
if (has_transpose()) {
total_size += 1 + 1;
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void InnerProductParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.InnerProductParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const InnerProductParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const InnerProductParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.InnerProductParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.InnerProductParameter)
UnsafeMergeFrom(*source);
}
}
void InnerProductParameter::MergeFrom(const InnerProductParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.InnerProductParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void InnerProductParameter::UnsafeMergeFrom(const InnerProductParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_num_output()) {
set_num_output(from.num_output());
}
if (from.has_bias_term()) {
set_bias_term(from.bias_term());
}
if (from.has_weight_filler()) {
mutable_weight_filler()->::opencv_caffe::FillerParameter::MergeFrom(from.weight_filler());
}
if (from.has_bias_filler()) {
mutable_bias_filler()->::opencv_caffe::FillerParameter::MergeFrom(from.bias_filler());
}
if (from.has_axis()) {
set_axis(from.axis());
}
if (from.has_transpose()) {
set_transpose(from.transpose());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void InnerProductParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.InnerProductParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void InnerProductParameter::CopyFrom(const InnerProductParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.InnerProductParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool InnerProductParameter::IsInitialized() const {
return true;
}
void InnerProductParameter::Swap(InnerProductParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void InnerProductParameter::InternalSwap(InnerProductParameter* other) {
std::swap(num_output_, other->num_output_);
std::swap(bias_term_, other->bias_term_);
std::swap(weight_filler_, other->weight_filler_);
std::swap(bias_filler_, other->bias_filler_);
std::swap(axis_, other->axis_);
std::swap(transpose_, other->transpose_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata InnerProductParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = InnerProductParameter_descriptor_;
metadata.reflection = InnerProductParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// InnerProductParameter
// optional uint32 num_output = 1;
bool InnerProductParameter::has_num_output() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void InnerProductParameter::set_has_num_output() {
_has_bits_[0] |= 0x00000001u;
}
void InnerProductParameter::clear_has_num_output() {
_has_bits_[0] &= ~0x00000001u;
}
void InnerProductParameter::clear_num_output() {
num_output_ = 0u;
clear_has_num_output();
}
::google::protobuf::uint32 InnerProductParameter::num_output() const {
// @@protoc_insertion_point(field_get:opencv_caffe.InnerProductParameter.num_output)
return num_output_;
}
void InnerProductParameter::set_num_output(::google::protobuf::uint32 value) {
set_has_num_output();
num_output_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.InnerProductParameter.num_output)
}
// optional bool bias_term = 2 [default = true];
bool InnerProductParameter::has_bias_term() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void InnerProductParameter::set_has_bias_term() {
_has_bits_[0] |= 0x00000002u;
}
void InnerProductParameter::clear_has_bias_term() {
_has_bits_[0] &= ~0x00000002u;
}
void InnerProductParameter::clear_bias_term() {
bias_term_ = true;
clear_has_bias_term();
}
bool InnerProductParameter::bias_term() const {
// @@protoc_insertion_point(field_get:opencv_caffe.InnerProductParameter.bias_term)
return bias_term_;
}
void InnerProductParameter::set_bias_term(bool value) {
set_has_bias_term();
bias_term_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.InnerProductParameter.bias_term)
}
// optional .opencv_caffe.FillerParameter weight_filler = 3;
bool InnerProductParameter::has_weight_filler() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void InnerProductParameter::set_has_weight_filler() {
_has_bits_[0] |= 0x00000004u;
}
void InnerProductParameter::clear_has_weight_filler() {
_has_bits_[0] &= ~0x00000004u;
}
void InnerProductParameter::clear_weight_filler() {
if (weight_filler_ != NULL) weight_filler_->::opencv_caffe::FillerParameter::Clear();
clear_has_weight_filler();
}
const ::opencv_caffe::FillerParameter& InnerProductParameter::weight_filler() const {
// @@protoc_insertion_point(field_get:opencv_caffe.InnerProductParameter.weight_filler)
return weight_filler_ != NULL ? *weight_filler_
: *::opencv_caffe::FillerParameter::internal_default_instance();
}
::opencv_caffe::FillerParameter* InnerProductParameter::mutable_weight_filler() {
set_has_weight_filler();
if (weight_filler_ == NULL) {
weight_filler_ = new ::opencv_caffe::FillerParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.InnerProductParameter.weight_filler)
return weight_filler_;
}
::opencv_caffe::FillerParameter* InnerProductParameter::release_weight_filler() {
// @@protoc_insertion_point(field_release:opencv_caffe.InnerProductParameter.weight_filler)
clear_has_weight_filler();
::opencv_caffe::FillerParameter* temp = weight_filler_;
weight_filler_ = NULL;
return temp;
}
void InnerProductParameter::set_allocated_weight_filler(::opencv_caffe::FillerParameter* weight_filler) {
delete weight_filler_;
weight_filler_ = weight_filler;
if (weight_filler) {
set_has_weight_filler();
} else {
clear_has_weight_filler();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.InnerProductParameter.weight_filler)
}
// optional .opencv_caffe.FillerParameter bias_filler = 4;
bool InnerProductParameter::has_bias_filler() const {
return (_has_bits_[0] & 0x00000008u) != 0;
}
void InnerProductParameter::set_has_bias_filler() {
_has_bits_[0] |= 0x00000008u;
}
void InnerProductParameter::clear_has_bias_filler() {
_has_bits_[0] &= ~0x00000008u;
}
void InnerProductParameter::clear_bias_filler() {
if (bias_filler_ != NULL) bias_filler_->::opencv_caffe::FillerParameter::Clear();
clear_has_bias_filler();
}
const ::opencv_caffe::FillerParameter& InnerProductParameter::bias_filler() const {
// @@protoc_insertion_point(field_get:opencv_caffe.InnerProductParameter.bias_filler)
return bias_filler_ != NULL ? *bias_filler_
: *::opencv_caffe::FillerParameter::internal_default_instance();
}
::opencv_caffe::FillerParameter* InnerProductParameter::mutable_bias_filler() {
set_has_bias_filler();
if (bias_filler_ == NULL) {
bias_filler_ = new ::opencv_caffe::FillerParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.InnerProductParameter.bias_filler)
return bias_filler_;
}
::opencv_caffe::FillerParameter* InnerProductParameter::release_bias_filler() {
// @@protoc_insertion_point(field_release:opencv_caffe.InnerProductParameter.bias_filler)
clear_has_bias_filler();
::opencv_caffe::FillerParameter* temp = bias_filler_;
bias_filler_ = NULL;
return temp;
}
void InnerProductParameter::set_allocated_bias_filler(::opencv_caffe::FillerParameter* bias_filler) {
delete bias_filler_;
bias_filler_ = bias_filler;
if (bias_filler) {
set_has_bias_filler();
} else {
clear_has_bias_filler();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.InnerProductParameter.bias_filler)
}
// optional int32 axis = 5 [default = 1];
bool InnerProductParameter::has_axis() const {
return (_has_bits_[0] & 0x00000010u) != 0;
}
void InnerProductParameter::set_has_axis() {
_has_bits_[0] |= 0x00000010u;
}
void InnerProductParameter::clear_has_axis() {
_has_bits_[0] &= ~0x00000010u;
}
void InnerProductParameter::clear_axis() {
axis_ = 1;
clear_has_axis();
}
::google::protobuf::int32 InnerProductParameter::axis() const {
// @@protoc_insertion_point(field_get:opencv_caffe.InnerProductParameter.axis)
return axis_;
}
void InnerProductParameter::set_axis(::google::protobuf::int32 value) {
set_has_axis();
axis_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.InnerProductParameter.axis)
}
// optional bool transpose = 6 [default = false];
bool InnerProductParameter::has_transpose() const {
return (_has_bits_[0] & 0x00000020u) != 0;
}
void InnerProductParameter::set_has_transpose() {
_has_bits_[0] |= 0x00000020u;
}
void InnerProductParameter::clear_has_transpose() {
_has_bits_[0] &= ~0x00000020u;
}
void InnerProductParameter::clear_transpose() {
transpose_ = false;
clear_has_transpose();
}
bool InnerProductParameter::transpose() const {
// @@protoc_insertion_point(field_get:opencv_caffe.InnerProductParameter.transpose)
return transpose_;
}
void InnerProductParameter::set_transpose(bool value) {
set_has_transpose();
transpose_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.InnerProductParameter.transpose)
}
inline const InnerProductParameter* InnerProductParameter::internal_default_instance() {
return &InnerProductParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int InputParameter::kShapeFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
InputParameter::InputParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.InputParameter)
}
void InputParameter::InitAsDefaultInstance() {
}
InputParameter::InputParameter(const InputParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.InputParameter)
}
void InputParameter::SharedCtor() {
_cached_size_ = 0;
}
InputParameter::~InputParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.InputParameter)
SharedDtor();
}
void InputParameter::SharedDtor() {
}
void InputParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* InputParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return InputParameter_descriptor_;
}
const InputParameter& InputParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<InputParameter> InputParameter_default_instance_;
InputParameter* InputParameter::New(::google::protobuf::Arena* arena) const {
InputParameter* n = new InputParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void InputParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.InputParameter)
shape_.Clear();
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool InputParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.InputParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// repeated .opencv_caffe.BlobShape shape = 1;
case 1: {
if (tag == 10) {
DO_(input->IncrementRecursionDepth());
parse_loop_shape:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtualNoRecursionDepth(
input, add_shape()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(10)) goto parse_loop_shape;
input->UnsafeDecrementRecursionDepth();
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.InputParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.InputParameter)
return false;
#undef DO_
}
void InputParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.InputParameter)
// repeated .opencv_caffe.BlobShape shape = 1;
for (unsigned int i = 0, n = this->shape_size(); i < n; i++) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
1, this->shape(i), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.InputParameter)
}
::google::protobuf::uint8* InputParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.InputParameter)
// repeated .opencv_caffe.BlobShape shape = 1;
for (unsigned int i = 0, n = this->shape_size(); i < n; i++) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
1, this->shape(i), false, target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.InputParameter)
return target;
}
size_t InputParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.InputParameter)
size_t total_size = 0;
// repeated .opencv_caffe.BlobShape shape = 1;
{
unsigned int count = this->shape_size();
total_size += 1UL * count;
for (unsigned int i = 0; i < count; i++) {
total_size +=
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
this->shape(i));
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void InputParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.InputParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const InputParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const InputParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.InputParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.InputParameter)
UnsafeMergeFrom(*source);
}
}
void InputParameter::MergeFrom(const InputParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.InputParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void InputParameter::UnsafeMergeFrom(const InputParameter& from) {
GOOGLE_DCHECK(&from != this);
shape_.MergeFrom(from.shape_);
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void InputParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.InputParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void InputParameter::CopyFrom(const InputParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.InputParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool InputParameter::IsInitialized() const {
return true;
}
void InputParameter::Swap(InputParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void InputParameter::InternalSwap(InputParameter* other) {
shape_.UnsafeArenaSwap(&other->shape_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata InputParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = InputParameter_descriptor_;
metadata.reflection = InputParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// InputParameter
// repeated .opencv_caffe.BlobShape shape = 1;
int InputParameter::shape_size() const {
return shape_.size();
}
void InputParameter::clear_shape() {
shape_.Clear();
}
const ::opencv_caffe::BlobShape& InputParameter::shape(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.InputParameter.shape)
return shape_.Get(index);
}
::opencv_caffe::BlobShape* InputParameter::mutable_shape(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.InputParameter.shape)
return shape_.Mutable(index);
}
::opencv_caffe::BlobShape* InputParameter::add_shape() {
// @@protoc_insertion_point(field_add:opencv_caffe.InputParameter.shape)
return shape_.Add();
}
::google::protobuf::RepeatedPtrField< ::opencv_caffe::BlobShape >*
InputParameter::mutable_shape() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.InputParameter.shape)
return &shape_;
}
const ::google::protobuf::RepeatedPtrField< ::opencv_caffe::BlobShape >&
InputParameter::shape() const {
// @@protoc_insertion_point(field_list:opencv_caffe.InputParameter.shape)
return shape_;
}
inline const InputParameter* InputParameter::internal_default_instance() {
return &InputParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int LogParameter::kBaseFieldNumber;
const int LogParameter::kScaleFieldNumber;
const int LogParameter::kShiftFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
LogParameter::LogParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.LogParameter)
}
void LogParameter::InitAsDefaultInstance() {
}
LogParameter::LogParameter(const LogParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.LogParameter)
}
void LogParameter::SharedCtor() {
_cached_size_ = 0;
shift_ = 0;
base_ = -1;
scale_ = 1;
}
LogParameter::~LogParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.LogParameter)
SharedDtor();
}
void LogParameter::SharedDtor() {
}
void LogParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* LogParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return LogParameter_descriptor_;
}
const LogParameter& LogParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<LogParameter> LogParameter_default_instance_;
LogParameter* LogParameter::New(::google::protobuf::Arena* arena) const {
LogParameter* n = new LogParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void LogParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.LogParameter)
if (_has_bits_[0 / 32] & 7u) {
base_ = -1;
scale_ = 1;
shift_ = 0;
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool LogParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.LogParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional float base = 1 [default = -1];
case 1: {
if (tag == 13) {
set_has_base();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &base_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(21)) goto parse_scale;
break;
}
// optional float scale = 2 [default = 1];
case 2: {
if (tag == 21) {
parse_scale:
set_has_scale();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &scale_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(29)) goto parse_shift;
break;
}
// optional float shift = 3 [default = 0];
case 3: {
if (tag == 29) {
parse_shift:
set_has_shift();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &shift_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.LogParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.LogParameter)
return false;
#undef DO_
}
void LogParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.LogParameter)
// optional float base = 1 [default = -1];
if (has_base()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(1, this->base(), output);
}
// optional float scale = 2 [default = 1];
if (has_scale()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(2, this->scale(), output);
}
// optional float shift = 3 [default = 0];
if (has_shift()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(3, this->shift(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.LogParameter)
}
::google::protobuf::uint8* LogParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.LogParameter)
// optional float base = 1 [default = -1];
if (has_base()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(1, this->base(), target);
}
// optional float scale = 2 [default = 1];
if (has_scale()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(2, this->scale(), target);
}
// optional float shift = 3 [default = 0];
if (has_shift()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(3, this->shift(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.LogParameter)
return target;
}
size_t LogParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.LogParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 7u) {
// optional float base = 1 [default = -1];
if (has_base()) {
total_size += 1 + 4;
}
// optional float scale = 2 [default = 1];
if (has_scale()) {
total_size += 1 + 4;
}
// optional float shift = 3 [default = 0];
if (has_shift()) {
total_size += 1 + 4;
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void LogParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.LogParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const LogParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const LogParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.LogParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.LogParameter)
UnsafeMergeFrom(*source);
}
}
void LogParameter::MergeFrom(const LogParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.LogParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void LogParameter::UnsafeMergeFrom(const LogParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_base()) {
set_base(from.base());
}
if (from.has_scale()) {
set_scale(from.scale());
}
if (from.has_shift()) {
set_shift(from.shift());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void LogParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.LogParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void LogParameter::CopyFrom(const LogParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.LogParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool LogParameter::IsInitialized() const {
return true;
}
void LogParameter::Swap(LogParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void LogParameter::InternalSwap(LogParameter* other) {
std::swap(base_, other->base_);
std::swap(scale_, other->scale_);
std::swap(shift_, other->shift_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata LogParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = LogParameter_descriptor_;
metadata.reflection = LogParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// LogParameter
// optional float base = 1 [default = -1];
bool LogParameter::has_base() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void LogParameter::set_has_base() {
_has_bits_[0] |= 0x00000001u;
}
void LogParameter::clear_has_base() {
_has_bits_[0] &= ~0x00000001u;
}
void LogParameter::clear_base() {
base_ = -1;
clear_has_base();
}
float LogParameter::base() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LogParameter.base)
return base_;
}
void LogParameter::set_base(float value) {
set_has_base();
base_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.LogParameter.base)
}
// optional float scale = 2 [default = 1];
bool LogParameter::has_scale() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void LogParameter::set_has_scale() {
_has_bits_[0] |= 0x00000002u;
}
void LogParameter::clear_has_scale() {
_has_bits_[0] &= ~0x00000002u;
}
void LogParameter::clear_scale() {
scale_ = 1;
clear_has_scale();
}
float LogParameter::scale() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LogParameter.scale)
return scale_;
}
void LogParameter::set_scale(float value) {
set_has_scale();
scale_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.LogParameter.scale)
}
// optional float shift = 3 [default = 0];
bool LogParameter::has_shift() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void LogParameter::set_has_shift() {
_has_bits_[0] |= 0x00000004u;
}
void LogParameter::clear_has_shift() {
_has_bits_[0] &= ~0x00000004u;
}
void LogParameter::clear_shift() {
shift_ = 0;
clear_has_shift();
}
float LogParameter::shift() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LogParameter.shift)
return shift_;
}
void LogParameter::set_shift(float value) {
set_has_shift();
shift_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.LogParameter.shift)
}
inline const LogParameter* LogParameter::internal_default_instance() {
return &LogParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
const ::google::protobuf::EnumDescriptor* LRNParameter_NormRegion_descriptor() {
protobuf_AssignDescriptorsOnce();
return LRNParameter_NormRegion_descriptor_;
}
bool LRNParameter_NormRegion_IsValid(int value) {
switch (value) {
case 0:
case 1:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const LRNParameter_NormRegion LRNParameter::ACROSS_CHANNELS;
const LRNParameter_NormRegion LRNParameter::WITHIN_CHANNEL;
const LRNParameter_NormRegion LRNParameter::NormRegion_MIN;
const LRNParameter_NormRegion LRNParameter::NormRegion_MAX;
const int LRNParameter::NormRegion_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
const ::google::protobuf::EnumDescriptor* LRNParameter_Engine_descriptor() {
protobuf_AssignDescriptorsOnce();
return LRNParameter_Engine_descriptor_;
}
bool LRNParameter_Engine_IsValid(int value) {
switch (value) {
case 0:
case 1:
case 2:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const LRNParameter_Engine LRNParameter::DEFAULT;
const LRNParameter_Engine LRNParameter::CAFFE;
const LRNParameter_Engine LRNParameter::CUDNN;
const LRNParameter_Engine LRNParameter::Engine_MIN;
const LRNParameter_Engine LRNParameter::Engine_MAX;
const int LRNParameter::Engine_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int LRNParameter::kLocalSizeFieldNumber;
const int LRNParameter::kAlphaFieldNumber;
const int LRNParameter::kBetaFieldNumber;
const int LRNParameter::kNormRegionFieldNumber;
const int LRNParameter::kKFieldNumber;
const int LRNParameter::kEngineFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
LRNParameter::LRNParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.LRNParameter)
}
void LRNParameter::InitAsDefaultInstance() {
}
LRNParameter::LRNParameter(const LRNParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.LRNParameter)
}
void LRNParameter::SharedCtor() {
_cached_size_ = 0;
::memset(&norm_region_, 0, reinterpret_cast<char*>(&engine_) -
reinterpret_cast<char*>(&norm_region_) + sizeof(engine_));
local_size_ = 5u;
alpha_ = 1;
beta_ = 0.75f;
k_ = 1;
}
LRNParameter::~LRNParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.LRNParameter)
SharedDtor();
}
void LRNParameter::SharedDtor() {
}
void LRNParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* LRNParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return LRNParameter_descriptor_;
}
const LRNParameter& LRNParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<LRNParameter> LRNParameter_default_instance_;
LRNParameter* LRNParameter::New(::google::protobuf::Arena* arena) const {
LRNParameter* n = new LRNParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void LRNParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.LRNParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(LRNParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<LRNParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
if (_has_bits_[0 / 32] & 63u) {
ZR_(norm_region_, engine_);
local_size_ = 5u;
alpha_ = 1;
beta_ = 0.75f;
k_ = 1;
}
#undef ZR_HELPER_
#undef ZR_
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool LRNParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.LRNParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional uint32 local_size = 1 [default = 5];
case 1: {
if (tag == 8) {
set_has_local_size();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &local_size_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(21)) goto parse_alpha;
break;
}
// optional float alpha = 2 [default = 1];
case 2: {
if (tag == 21) {
parse_alpha:
set_has_alpha();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &alpha_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(29)) goto parse_beta;
break;
}
// optional float beta = 3 [default = 0.75];
case 3: {
if (tag == 29) {
parse_beta:
set_has_beta();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &beta_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(32)) goto parse_norm_region;
break;
}
// optional .opencv_caffe.LRNParameter.NormRegion norm_region = 4 [default = ACROSS_CHANNELS];
case 4: {
if (tag == 32) {
parse_norm_region:
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::LRNParameter_NormRegion_IsValid(value)) {
set_norm_region(static_cast< ::opencv_caffe::LRNParameter_NormRegion >(value));
} else {
mutable_unknown_fields()->AddVarint(4, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectTag(45)) goto parse_k;
break;
}
// optional float k = 5 [default = 1];
case 5: {
if (tag == 45) {
parse_k:
set_has_k();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &k_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(48)) goto parse_engine;
break;
}
// optional .opencv_caffe.LRNParameter.Engine engine = 6 [default = DEFAULT];
case 6: {
if (tag == 48) {
parse_engine:
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::LRNParameter_Engine_IsValid(value)) {
set_engine(static_cast< ::opencv_caffe::LRNParameter_Engine >(value));
} else {
mutable_unknown_fields()->AddVarint(6, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.LRNParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.LRNParameter)
return false;
#undef DO_
}
void LRNParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.LRNParameter)
// optional uint32 local_size = 1 [default = 5];
if (has_local_size()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(1, this->local_size(), output);
}
// optional float alpha = 2 [default = 1];
if (has_alpha()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(2, this->alpha(), output);
}
// optional float beta = 3 [default = 0.75];
if (has_beta()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(3, this->beta(), output);
}
// optional .opencv_caffe.LRNParameter.NormRegion norm_region = 4 [default = ACROSS_CHANNELS];
if (has_norm_region()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
4, this->norm_region(), output);
}
// optional float k = 5 [default = 1];
if (has_k()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(5, this->k(), output);
}
// optional .opencv_caffe.LRNParameter.Engine engine = 6 [default = DEFAULT];
if (has_engine()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
6, this->engine(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.LRNParameter)
}
::google::protobuf::uint8* LRNParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.LRNParameter)
// optional uint32 local_size = 1 [default = 5];
if (has_local_size()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(1, this->local_size(), target);
}
// optional float alpha = 2 [default = 1];
if (has_alpha()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(2, this->alpha(), target);
}
// optional float beta = 3 [default = 0.75];
if (has_beta()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(3, this->beta(), target);
}
// optional .opencv_caffe.LRNParameter.NormRegion norm_region = 4 [default = ACROSS_CHANNELS];
if (has_norm_region()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
4, this->norm_region(), target);
}
// optional float k = 5 [default = 1];
if (has_k()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(5, this->k(), target);
}
// optional .opencv_caffe.LRNParameter.Engine engine = 6 [default = DEFAULT];
if (has_engine()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
6, this->engine(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.LRNParameter)
return target;
}
size_t LRNParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.LRNParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 63u) {
// optional uint32 local_size = 1 [default = 5];
if (has_local_size()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->local_size());
}
// optional float alpha = 2 [default = 1];
if (has_alpha()) {
total_size += 1 + 4;
}
// optional float beta = 3 [default = 0.75];
if (has_beta()) {
total_size += 1 + 4;
}
// optional .opencv_caffe.LRNParameter.NormRegion norm_region = 4 [default = ACROSS_CHANNELS];
if (has_norm_region()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->norm_region());
}
// optional float k = 5 [default = 1];
if (has_k()) {
total_size += 1 + 4;
}
// optional .opencv_caffe.LRNParameter.Engine engine = 6 [default = DEFAULT];
if (has_engine()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->engine());
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void LRNParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.LRNParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const LRNParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const LRNParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.LRNParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.LRNParameter)
UnsafeMergeFrom(*source);
}
}
void LRNParameter::MergeFrom(const LRNParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.LRNParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void LRNParameter::UnsafeMergeFrom(const LRNParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_local_size()) {
set_local_size(from.local_size());
}
if (from.has_alpha()) {
set_alpha(from.alpha());
}
if (from.has_beta()) {
set_beta(from.beta());
}
if (from.has_norm_region()) {
set_norm_region(from.norm_region());
}
if (from.has_k()) {
set_k(from.k());
}
if (from.has_engine()) {
set_engine(from.engine());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void LRNParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.LRNParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void LRNParameter::CopyFrom(const LRNParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.LRNParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool LRNParameter::IsInitialized() const {
return true;
}
void LRNParameter::Swap(LRNParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void LRNParameter::InternalSwap(LRNParameter* other) {
std::swap(local_size_, other->local_size_);
std::swap(alpha_, other->alpha_);
std::swap(beta_, other->beta_);
std::swap(norm_region_, other->norm_region_);
std::swap(k_, other->k_);
std::swap(engine_, other->engine_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata LRNParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = LRNParameter_descriptor_;
metadata.reflection = LRNParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// LRNParameter
// optional uint32 local_size = 1 [default = 5];
bool LRNParameter::has_local_size() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void LRNParameter::set_has_local_size() {
_has_bits_[0] |= 0x00000001u;
}
void LRNParameter::clear_has_local_size() {
_has_bits_[0] &= ~0x00000001u;
}
void LRNParameter::clear_local_size() {
local_size_ = 5u;
clear_has_local_size();
}
::google::protobuf::uint32 LRNParameter::local_size() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LRNParameter.local_size)
return local_size_;
}
void LRNParameter::set_local_size(::google::protobuf::uint32 value) {
set_has_local_size();
local_size_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.LRNParameter.local_size)
}
// optional float alpha = 2 [default = 1];
bool LRNParameter::has_alpha() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void LRNParameter::set_has_alpha() {
_has_bits_[0] |= 0x00000002u;
}
void LRNParameter::clear_has_alpha() {
_has_bits_[0] &= ~0x00000002u;
}
void LRNParameter::clear_alpha() {
alpha_ = 1;
clear_has_alpha();
}
float LRNParameter::alpha() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LRNParameter.alpha)
return alpha_;
}
void LRNParameter::set_alpha(float value) {
set_has_alpha();
alpha_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.LRNParameter.alpha)
}
// optional float beta = 3 [default = 0.75];
bool LRNParameter::has_beta() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void LRNParameter::set_has_beta() {
_has_bits_[0] |= 0x00000004u;
}
void LRNParameter::clear_has_beta() {
_has_bits_[0] &= ~0x00000004u;
}
void LRNParameter::clear_beta() {
beta_ = 0.75f;
clear_has_beta();
}
float LRNParameter::beta() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LRNParameter.beta)
return beta_;
}
void LRNParameter::set_beta(float value) {
set_has_beta();
beta_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.LRNParameter.beta)
}
// optional .opencv_caffe.LRNParameter.NormRegion norm_region = 4 [default = ACROSS_CHANNELS];
bool LRNParameter::has_norm_region() const {
return (_has_bits_[0] & 0x00000008u) != 0;
}
void LRNParameter::set_has_norm_region() {
_has_bits_[0] |= 0x00000008u;
}
void LRNParameter::clear_has_norm_region() {
_has_bits_[0] &= ~0x00000008u;
}
void LRNParameter::clear_norm_region() {
norm_region_ = 0;
clear_has_norm_region();
}
::opencv_caffe::LRNParameter_NormRegion LRNParameter::norm_region() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LRNParameter.norm_region)
return static_cast< ::opencv_caffe::LRNParameter_NormRegion >(norm_region_);
}
void LRNParameter::set_norm_region(::opencv_caffe::LRNParameter_NormRegion value) {
assert(::opencv_caffe::LRNParameter_NormRegion_IsValid(value));
set_has_norm_region();
norm_region_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.LRNParameter.norm_region)
}
// optional float k = 5 [default = 1];
bool LRNParameter::has_k() const {
return (_has_bits_[0] & 0x00000010u) != 0;
}
void LRNParameter::set_has_k() {
_has_bits_[0] |= 0x00000010u;
}
void LRNParameter::clear_has_k() {
_has_bits_[0] &= ~0x00000010u;
}
void LRNParameter::clear_k() {
k_ = 1;
clear_has_k();
}
float LRNParameter::k() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LRNParameter.k)
return k_;
}
void LRNParameter::set_k(float value) {
set_has_k();
k_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.LRNParameter.k)
}
// optional .opencv_caffe.LRNParameter.Engine engine = 6 [default = DEFAULT];
bool LRNParameter::has_engine() const {
return (_has_bits_[0] & 0x00000020u) != 0;
}
void LRNParameter::set_has_engine() {
_has_bits_[0] |= 0x00000020u;
}
void LRNParameter::clear_has_engine() {
_has_bits_[0] &= ~0x00000020u;
}
void LRNParameter::clear_engine() {
engine_ = 0;
clear_has_engine();
}
::opencv_caffe::LRNParameter_Engine LRNParameter::engine() const {
// @@protoc_insertion_point(field_get:opencv_caffe.LRNParameter.engine)
return static_cast< ::opencv_caffe::LRNParameter_Engine >(engine_);
}
void LRNParameter::set_engine(::opencv_caffe::LRNParameter_Engine value) {
assert(::opencv_caffe::LRNParameter_Engine_IsValid(value));
set_has_engine();
engine_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.LRNParameter.engine)
}
inline const LRNParameter* LRNParameter::internal_default_instance() {
return &LRNParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int MemoryDataParameter::kBatchSizeFieldNumber;
const int MemoryDataParameter::kChannelsFieldNumber;
const int MemoryDataParameter::kHeightFieldNumber;
const int MemoryDataParameter::kWidthFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
MemoryDataParameter::MemoryDataParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.MemoryDataParameter)
}
void MemoryDataParameter::InitAsDefaultInstance() {
}
MemoryDataParameter::MemoryDataParameter(const MemoryDataParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.MemoryDataParameter)
}
void MemoryDataParameter::SharedCtor() {
_cached_size_ = 0;
::memset(&batch_size_, 0, reinterpret_cast<char*>(&width_) -
reinterpret_cast<char*>(&batch_size_) + sizeof(width_));
}
MemoryDataParameter::~MemoryDataParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.MemoryDataParameter)
SharedDtor();
}
void MemoryDataParameter::SharedDtor() {
}
void MemoryDataParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* MemoryDataParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return MemoryDataParameter_descriptor_;
}
const MemoryDataParameter& MemoryDataParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<MemoryDataParameter> MemoryDataParameter_default_instance_;
MemoryDataParameter* MemoryDataParameter::New(::google::protobuf::Arena* arena) const {
MemoryDataParameter* n = new MemoryDataParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void MemoryDataParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.MemoryDataParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(MemoryDataParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<MemoryDataParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
ZR_(batch_size_, width_);
#undef ZR_HELPER_
#undef ZR_
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool MemoryDataParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.MemoryDataParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional uint32 batch_size = 1;
case 1: {
if (tag == 8) {
set_has_batch_size();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &batch_size_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_channels;
break;
}
// optional uint32 channels = 2;
case 2: {
if (tag == 16) {
parse_channels:
set_has_channels();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &channels_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(24)) goto parse_height;
break;
}
// optional uint32 height = 3;
case 3: {
if (tag == 24) {
parse_height:
set_has_height();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &height_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(32)) goto parse_width;
break;
}
// optional uint32 width = 4;
case 4: {
if (tag == 32) {
parse_width:
set_has_width();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &width_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.MemoryDataParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.MemoryDataParameter)
return false;
#undef DO_
}
void MemoryDataParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.MemoryDataParameter)
// optional uint32 batch_size = 1;
if (has_batch_size()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(1, this->batch_size(), output);
}
// optional uint32 channels = 2;
if (has_channels()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(2, this->channels(), output);
}
// optional uint32 height = 3;
if (has_height()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(3, this->height(), output);
}
// optional uint32 width = 4;
if (has_width()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(4, this->width(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.MemoryDataParameter)
}
::google::protobuf::uint8* MemoryDataParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.MemoryDataParameter)
// optional uint32 batch_size = 1;
if (has_batch_size()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(1, this->batch_size(), target);
}
// optional uint32 channels = 2;
if (has_channels()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(2, this->channels(), target);
}
// optional uint32 height = 3;
if (has_height()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(3, this->height(), target);
}
// optional uint32 width = 4;
if (has_width()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(4, this->width(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.MemoryDataParameter)
return target;
}
size_t MemoryDataParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.MemoryDataParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 15u) {
// optional uint32 batch_size = 1;
if (has_batch_size()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->batch_size());
}
// optional uint32 channels = 2;
if (has_channels()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->channels());
}
// optional uint32 height = 3;
if (has_height()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->height());
}
// optional uint32 width = 4;
if (has_width()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->width());
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void MemoryDataParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.MemoryDataParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const MemoryDataParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const MemoryDataParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.MemoryDataParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.MemoryDataParameter)
UnsafeMergeFrom(*source);
}
}
void MemoryDataParameter::MergeFrom(const MemoryDataParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.MemoryDataParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void MemoryDataParameter::UnsafeMergeFrom(const MemoryDataParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_batch_size()) {
set_batch_size(from.batch_size());
}
if (from.has_channels()) {
set_channels(from.channels());
}
if (from.has_height()) {
set_height(from.height());
}
if (from.has_width()) {
set_width(from.width());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void MemoryDataParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.MemoryDataParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void MemoryDataParameter::CopyFrom(const MemoryDataParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.MemoryDataParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool MemoryDataParameter::IsInitialized() const {
return true;
}
void MemoryDataParameter::Swap(MemoryDataParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void MemoryDataParameter::InternalSwap(MemoryDataParameter* other) {
std::swap(batch_size_, other->batch_size_);
std::swap(channels_, other->channels_);
std::swap(height_, other->height_);
std::swap(width_, other->width_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata MemoryDataParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = MemoryDataParameter_descriptor_;
metadata.reflection = MemoryDataParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// MemoryDataParameter
// optional uint32 batch_size = 1;
bool MemoryDataParameter::has_batch_size() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void MemoryDataParameter::set_has_batch_size() {
_has_bits_[0] |= 0x00000001u;
}
void MemoryDataParameter::clear_has_batch_size() {
_has_bits_[0] &= ~0x00000001u;
}
void MemoryDataParameter::clear_batch_size() {
batch_size_ = 0u;
clear_has_batch_size();
}
::google::protobuf::uint32 MemoryDataParameter::batch_size() const {
// @@protoc_insertion_point(field_get:opencv_caffe.MemoryDataParameter.batch_size)
return batch_size_;
}
void MemoryDataParameter::set_batch_size(::google::protobuf::uint32 value) {
set_has_batch_size();
batch_size_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.MemoryDataParameter.batch_size)
}
// optional uint32 channels = 2;
bool MemoryDataParameter::has_channels() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void MemoryDataParameter::set_has_channels() {
_has_bits_[0] |= 0x00000002u;
}
void MemoryDataParameter::clear_has_channels() {
_has_bits_[0] &= ~0x00000002u;
}
void MemoryDataParameter::clear_channels() {
channels_ = 0u;
clear_has_channels();
}
::google::protobuf::uint32 MemoryDataParameter::channels() const {
// @@protoc_insertion_point(field_get:opencv_caffe.MemoryDataParameter.channels)
return channels_;
}
void MemoryDataParameter::set_channels(::google::protobuf::uint32 value) {
set_has_channels();
channels_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.MemoryDataParameter.channels)
}
// optional uint32 height = 3;
bool MemoryDataParameter::has_height() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void MemoryDataParameter::set_has_height() {
_has_bits_[0] |= 0x00000004u;
}
void MemoryDataParameter::clear_has_height() {
_has_bits_[0] &= ~0x00000004u;
}
void MemoryDataParameter::clear_height() {
height_ = 0u;
clear_has_height();
}
::google::protobuf::uint32 MemoryDataParameter::height() const {
// @@protoc_insertion_point(field_get:opencv_caffe.MemoryDataParameter.height)
return height_;
}
void MemoryDataParameter::set_height(::google::protobuf::uint32 value) {
set_has_height();
height_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.MemoryDataParameter.height)
}
// optional uint32 width = 4;
bool MemoryDataParameter::has_width() const {
return (_has_bits_[0] & 0x00000008u) != 0;
}
void MemoryDataParameter::set_has_width() {
_has_bits_[0] |= 0x00000008u;
}
void MemoryDataParameter::clear_has_width() {
_has_bits_[0] &= ~0x00000008u;
}
void MemoryDataParameter::clear_width() {
width_ = 0u;
clear_has_width();
}
::google::protobuf::uint32 MemoryDataParameter::width() const {
// @@protoc_insertion_point(field_get:opencv_caffe.MemoryDataParameter.width)
return width_;
}
void MemoryDataParameter::set_width(::google::protobuf::uint32 value) {
set_has_width();
width_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.MemoryDataParameter.width)
}
inline const MemoryDataParameter* MemoryDataParameter::internal_default_instance() {
return &MemoryDataParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int MVNParameter::kNormalizeVarianceFieldNumber;
const int MVNParameter::kAcrossChannelsFieldNumber;
const int MVNParameter::kEpsFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
MVNParameter::MVNParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.MVNParameter)
}
void MVNParameter::InitAsDefaultInstance() {
}
MVNParameter::MVNParameter(const MVNParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.MVNParameter)
}
void MVNParameter::SharedCtor() {
_cached_size_ = 0;
across_channels_ = false;
normalize_variance_ = true;
eps_ = 1e-09f;
}
MVNParameter::~MVNParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.MVNParameter)
SharedDtor();
}
void MVNParameter::SharedDtor() {
}
void MVNParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* MVNParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return MVNParameter_descriptor_;
}
const MVNParameter& MVNParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<MVNParameter> MVNParameter_default_instance_;
MVNParameter* MVNParameter::New(::google::protobuf::Arena* arena) const {
MVNParameter* n = new MVNParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void MVNParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.MVNParameter)
if (_has_bits_[0 / 32] & 7u) {
normalize_variance_ = true;
across_channels_ = false;
eps_ = 1e-09f;
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool MVNParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.MVNParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional bool normalize_variance = 1 [default = true];
case 1: {
if (tag == 8) {
set_has_normalize_variance();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &normalize_variance_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_across_channels;
break;
}
// optional bool across_channels = 2 [default = false];
case 2: {
if (tag == 16) {
parse_across_channels:
set_has_across_channels();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &across_channels_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(29)) goto parse_eps;
break;
}
// optional float eps = 3 [default = 1e-09];
case 3: {
if (tag == 29) {
parse_eps:
set_has_eps();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &eps_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.MVNParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.MVNParameter)
return false;
#undef DO_
}
void MVNParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.MVNParameter)
// optional bool normalize_variance = 1 [default = true];
if (has_normalize_variance()) {
::google::protobuf::internal::WireFormatLite::WriteBool(1, this->normalize_variance(), output);
}
// optional bool across_channels = 2 [default = false];
if (has_across_channels()) {
::google::protobuf::internal::WireFormatLite::WriteBool(2, this->across_channels(), output);
}
// optional float eps = 3 [default = 1e-09];
if (has_eps()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(3, this->eps(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.MVNParameter)
}
::google::protobuf::uint8* MVNParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.MVNParameter)
// optional bool normalize_variance = 1 [default = true];
if (has_normalize_variance()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(1, this->normalize_variance(), target);
}
// optional bool across_channels = 2 [default = false];
if (has_across_channels()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(2, this->across_channels(), target);
}
// optional float eps = 3 [default = 1e-09];
if (has_eps()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(3, this->eps(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.MVNParameter)
return target;
}
size_t MVNParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.MVNParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 7u) {
// optional bool normalize_variance = 1 [default = true];
if (has_normalize_variance()) {
total_size += 1 + 1;
}
// optional bool across_channels = 2 [default = false];
if (has_across_channels()) {
total_size += 1 + 1;
}
// optional float eps = 3 [default = 1e-09];
if (has_eps()) {
total_size += 1 + 4;
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void MVNParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.MVNParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const MVNParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const MVNParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.MVNParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.MVNParameter)
UnsafeMergeFrom(*source);
}
}
void MVNParameter::MergeFrom(const MVNParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.MVNParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void MVNParameter::UnsafeMergeFrom(const MVNParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_normalize_variance()) {
set_normalize_variance(from.normalize_variance());
}
if (from.has_across_channels()) {
set_across_channels(from.across_channels());
}
if (from.has_eps()) {
set_eps(from.eps());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void MVNParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.MVNParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void MVNParameter::CopyFrom(const MVNParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.MVNParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool MVNParameter::IsInitialized() const {
return true;
}
void MVNParameter::Swap(MVNParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void MVNParameter::InternalSwap(MVNParameter* other) {
std::swap(normalize_variance_, other->normalize_variance_);
std::swap(across_channels_, other->across_channels_);
std::swap(eps_, other->eps_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata MVNParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = MVNParameter_descriptor_;
metadata.reflection = MVNParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// MVNParameter
// optional bool normalize_variance = 1 [default = true];
bool MVNParameter::has_normalize_variance() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void MVNParameter::set_has_normalize_variance() {
_has_bits_[0] |= 0x00000001u;
}
void MVNParameter::clear_has_normalize_variance() {
_has_bits_[0] &= ~0x00000001u;
}
void MVNParameter::clear_normalize_variance() {
normalize_variance_ = true;
clear_has_normalize_variance();
}
bool MVNParameter::normalize_variance() const {
// @@protoc_insertion_point(field_get:opencv_caffe.MVNParameter.normalize_variance)
return normalize_variance_;
}
void MVNParameter::set_normalize_variance(bool value) {
set_has_normalize_variance();
normalize_variance_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.MVNParameter.normalize_variance)
}
// optional bool across_channels = 2 [default = false];
bool MVNParameter::has_across_channels() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void MVNParameter::set_has_across_channels() {
_has_bits_[0] |= 0x00000002u;
}
void MVNParameter::clear_has_across_channels() {
_has_bits_[0] &= ~0x00000002u;
}
void MVNParameter::clear_across_channels() {
across_channels_ = false;
clear_has_across_channels();
}
bool MVNParameter::across_channels() const {
// @@protoc_insertion_point(field_get:opencv_caffe.MVNParameter.across_channels)
return across_channels_;
}
void MVNParameter::set_across_channels(bool value) {
set_has_across_channels();
across_channels_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.MVNParameter.across_channels)
}
// optional float eps = 3 [default = 1e-09];
bool MVNParameter::has_eps() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void MVNParameter::set_has_eps() {
_has_bits_[0] |= 0x00000004u;
}
void MVNParameter::clear_has_eps() {
_has_bits_[0] &= ~0x00000004u;
}
void MVNParameter::clear_eps() {
eps_ = 1e-09f;
clear_has_eps();
}
float MVNParameter::eps() const {
// @@protoc_insertion_point(field_get:opencv_caffe.MVNParameter.eps)
return eps_;
}
void MVNParameter::set_eps(float value) {
set_has_eps();
eps_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.MVNParameter.eps)
}
inline const MVNParameter* MVNParameter::internal_default_instance() {
return &MVNParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int ParameterParameter::kShapeFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
ParameterParameter::ParameterParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.ParameterParameter)
}
void ParameterParameter::InitAsDefaultInstance() {
shape_ = const_cast< ::opencv_caffe::BlobShape*>(
::opencv_caffe::BlobShape::internal_default_instance());
}
ParameterParameter::ParameterParameter(const ParameterParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.ParameterParameter)
}
void ParameterParameter::SharedCtor() {
_cached_size_ = 0;
shape_ = NULL;
}
ParameterParameter::~ParameterParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.ParameterParameter)
SharedDtor();
}
void ParameterParameter::SharedDtor() {
if (this != &ParameterParameter_default_instance_.get()) {
delete shape_;
}
}
void ParameterParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* ParameterParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return ParameterParameter_descriptor_;
}
const ParameterParameter& ParameterParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<ParameterParameter> ParameterParameter_default_instance_;
ParameterParameter* ParameterParameter::New(::google::protobuf::Arena* arena) const {
ParameterParameter* n = new ParameterParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void ParameterParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.ParameterParameter)
if (has_shape()) {
if (shape_ != NULL) shape_->::opencv_caffe::BlobShape::Clear();
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool ParameterParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.ParameterParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional .opencv_caffe.BlobShape shape = 1;
case 1: {
if (tag == 10) {
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_shape()));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.ParameterParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.ParameterParameter)
return false;
#undef DO_
}
void ParameterParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.ParameterParameter)
// optional .opencv_caffe.BlobShape shape = 1;
if (has_shape()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
1, *this->shape_, output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.ParameterParameter)
}
::google::protobuf::uint8* ParameterParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.ParameterParameter)
// optional .opencv_caffe.BlobShape shape = 1;
if (has_shape()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
1, *this->shape_, false, target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.ParameterParameter)
return target;
}
size_t ParameterParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.ParameterParameter)
size_t total_size = 0;
// optional .opencv_caffe.BlobShape shape = 1;
if (has_shape()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->shape_);
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void ParameterParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.ParameterParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const ParameterParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const ParameterParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.ParameterParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.ParameterParameter)
UnsafeMergeFrom(*source);
}
}
void ParameterParameter::MergeFrom(const ParameterParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.ParameterParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void ParameterParameter::UnsafeMergeFrom(const ParameterParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_shape()) {
mutable_shape()->::opencv_caffe::BlobShape::MergeFrom(from.shape());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void ParameterParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.ParameterParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void ParameterParameter::CopyFrom(const ParameterParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.ParameterParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool ParameterParameter::IsInitialized() const {
return true;
}
void ParameterParameter::Swap(ParameterParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void ParameterParameter::InternalSwap(ParameterParameter* other) {
std::swap(shape_, other->shape_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata ParameterParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = ParameterParameter_descriptor_;
metadata.reflection = ParameterParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// ParameterParameter
// optional .opencv_caffe.BlobShape shape = 1;
bool ParameterParameter::has_shape() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void ParameterParameter::set_has_shape() {
_has_bits_[0] |= 0x00000001u;
}
void ParameterParameter::clear_has_shape() {
_has_bits_[0] &= ~0x00000001u;
}
void ParameterParameter::clear_shape() {
if (shape_ != NULL) shape_->::opencv_caffe::BlobShape::Clear();
clear_has_shape();
}
const ::opencv_caffe::BlobShape& ParameterParameter::shape() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ParameterParameter.shape)
return shape_ != NULL ? *shape_
: *::opencv_caffe::BlobShape::internal_default_instance();
}
::opencv_caffe::BlobShape* ParameterParameter::mutable_shape() {
set_has_shape();
if (shape_ == NULL) {
shape_ = new ::opencv_caffe::BlobShape;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.ParameterParameter.shape)
return shape_;
}
::opencv_caffe::BlobShape* ParameterParameter::release_shape() {
// @@protoc_insertion_point(field_release:opencv_caffe.ParameterParameter.shape)
clear_has_shape();
::opencv_caffe::BlobShape* temp = shape_;
shape_ = NULL;
return temp;
}
void ParameterParameter::set_allocated_shape(::opencv_caffe::BlobShape* shape) {
delete shape_;
shape_ = shape;
if (shape) {
set_has_shape();
} else {
clear_has_shape();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.ParameterParameter.shape)
}
inline const ParameterParameter* ParameterParameter::internal_default_instance() {
return &ParameterParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
const ::google::protobuf::EnumDescriptor* PoolingParameter_PoolMethod_descriptor() {
protobuf_AssignDescriptorsOnce();
return PoolingParameter_PoolMethod_descriptor_;
}
bool PoolingParameter_PoolMethod_IsValid(int value) {
switch (value) {
case 0:
case 1:
case 2:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const PoolingParameter_PoolMethod PoolingParameter::MAX;
const PoolingParameter_PoolMethod PoolingParameter::AVE;
const PoolingParameter_PoolMethod PoolingParameter::STOCHASTIC;
const PoolingParameter_PoolMethod PoolingParameter::PoolMethod_MIN;
const PoolingParameter_PoolMethod PoolingParameter::PoolMethod_MAX;
const int PoolingParameter::PoolMethod_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
const ::google::protobuf::EnumDescriptor* PoolingParameter_Engine_descriptor() {
protobuf_AssignDescriptorsOnce();
return PoolingParameter_Engine_descriptor_;
}
bool PoolingParameter_Engine_IsValid(int value) {
switch (value) {
case 0:
case 1:
case 2:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const PoolingParameter_Engine PoolingParameter::DEFAULT;
const PoolingParameter_Engine PoolingParameter::CAFFE;
const PoolingParameter_Engine PoolingParameter::CUDNN;
const PoolingParameter_Engine PoolingParameter::Engine_MIN;
const PoolingParameter_Engine PoolingParameter::Engine_MAX;
const int PoolingParameter::Engine_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int PoolingParameter::kPoolFieldNumber;
const int PoolingParameter::kPadFieldNumber;
const int PoolingParameter::kPadHFieldNumber;
const int PoolingParameter::kPadWFieldNumber;
const int PoolingParameter::kKernelSizeFieldNumber;
const int PoolingParameter::kKernelHFieldNumber;
const int PoolingParameter::kKernelWFieldNumber;
const int PoolingParameter::kStrideFieldNumber;
const int PoolingParameter::kStrideHFieldNumber;
const int PoolingParameter::kStrideWFieldNumber;
const int PoolingParameter::kEngineFieldNumber;
const int PoolingParameter::kGlobalPoolingFieldNumber;
const int PoolingParameter::kCeilModeFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
PoolingParameter::PoolingParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.PoolingParameter)
}
void PoolingParameter::InitAsDefaultInstance() {
}
PoolingParameter::PoolingParameter(const PoolingParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.PoolingParameter)
}
void PoolingParameter::SharedCtor() {
_cached_size_ = 0;
::memset(&pool_, 0, reinterpret_cast<char*>(&global_pooling_) -
reinterpret_cast<char*>(&pool_) + sizeof(global_pooling_));
stride_ = 1u;
ceil_mode_ = true;
}
PoolingParameter::~PoolingParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.PoolingParameter)
SharedDtor();
}
void PoolingParameter::SharedDtor() {
}
void PoolingParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* PoolingParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return PoolingParameter_descriptor_;
}
const PoolingParameter& PoolingParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<PoolingParameter> PoolingParameter_default_instance_;
PoolingParameter* PoolingParameter::New(::google::protobuf::Arena* arena) const {
PoolingParameter* n = new PoolingParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void PoolingParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.PoolingParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(PoolingParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<PoolingParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
if (_has_bits_[0 / 32] & 255u) {
ZR_(pool_, kernel_w_);
stride_ = 1u;
}
if (_has_bits_[8 / 32] & 7936u) {
ZR_(stride_h_, global_pooling_);
ceil_mode_ = true;
}
#undef ZR_HELPER_
#undef ZR_
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool PoolingParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.PoolingParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional .opencv_caffe.PoolingParameter.PoolMethod pool = 1 [default = MAX];
case 1: {
if (tag == 8) {
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::PoolingParameter_PoolMethod_IsValid(value)) {
set_pool(static_cast< ::opencv_caffe::PoolingParameter_PoolMethod >(value));
} else {
mutable_unknown_fields()->AddVarint(1, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_kernel_size;
break;
}
// optional uint32 kernel_size = 2;
case 2: {
if (tag == 16) {
parse_kernel_size:
set_has_kernel_size();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &kernel_size_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(24)) goto parse_stride;
break;
}
// optional uint32 stride = 3 [default = 1];
case 3: {
if (tag == 24) {
parse_stride:
set_has_stride();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &stride_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(32)) goto parse_pad;
break;
}
// optional uint32 pad = 4 [default = 0];
case 4: {
if (tag == 32) {
parse_pad:
set_has_pad();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &pad_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(40)) goto parse_kernel_h;
break;
}
// optional uint32 kernel_h = 5;
case 5: {
if (tag == 40) {
parse_kernel_h:
set_has_kernel_h();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &kernel_h_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(48)) goto parse_kernel_w;
break;
}
// optional uint32 kernel_w = 6;
case 6: {
if (tag == 48) {
parse_kernel_w:
set_has_kernel_w();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &kernel_w_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(56)) goto parse_stride_h;
break;
}
// optional uint32 stride_h = 7;
case 7: {
if (tag == 56) {
parse_stride_h:
set_has_stride_h();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &stride_h_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(64)) goto parse_stride_w;
break;
}
// optional uint32 stride_w = 8;
case 8: {
if (tag == 64) {
parse_stride_w:
set_has_stride_w();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &stride_w_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(72)) goto parse_pad_h;
break;
}
// optional uint32 pad_h = 9 [default = 0];
case 9: {
if (tag == 72) {
parse_pad_h:
set_has_pad_h();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &pad_h_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(80)) goto parse_pad_w;
break;
}
// optional uint32 pad_w = 10 [default = 0];
case 10: {
if (tag == 80) {
parse_pad_w:
set_has_pad_w();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &pad_w_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(88)) goto parse_engine;
break;
}
// optional .opencv_caffe.PoolingParameter.Engine engine = 11 [default = DEFAULT];
case 11: {
if (tag == 88) {
parse_engine:
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::PoolingParameter_Engine_IsValid(value)) {
set_engine(static_cast< ::opencv_caffe::PoolingParameter_Engine >(value));
} else {
mutable_unknown_fields()->AddVarint(11, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectTag(96)) goto parse_global_pooling;
break;
}
// optional bool global_pooling = 12 [default = false];
case 12: {
if (tag == 96) {
parse_global_pooling:
set_has_global_pooling();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &global_pooling_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(104)) goto parse_ceil_mode;
break;
}
// optional bool ceil_mode = 13 [default = true];
case 13: {
if (tag == 104) {
parse_ceil_mode:
set_has_ceil_mode();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &ceil_mode_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.PoolingParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.PoolingParameter)
return false;
#undef DO_
}
void PoolingParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.PoolingParameter)
// optional .opencv_caffe.PoolingParameter.PoolMethod pool = 1 [default = MAX];
if (has_pool()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
1, this->pool(), output);
}
// optional uint32 kernel_size = 2;
if (has_kernel_size()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(2, this->kernel_size(), output);
}
// optional uint32 stride = 3 [default = 1];
if (has_stride()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(3, this->stride(), output);
}
// optional uint32 pad = 4 [default = 0];
if (has_pad()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(4, this->pad(), output);
}
// optional uint32 kernel_h = 5;
if (has_kernel_h()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(5, this->kernel_h(), output);
}
// optional uint32 kernel_w = 6;
if (has_kernel_w()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(6, this->kernel_w(), output);
}
// optional uint32 stride_h = 7;
if (has_stride_h()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(7, this->stride_h(), output);
}
// optional uint32 stride_w = 8;
if (has_stride_w()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(8, this->stride_w(), output);
}
// optional uint32 pad_h = 9 [default = 0];
if (has_pad_h()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(9, this->pad_h(), output);
}
// optional uint32 pad_w = 10 [default = 0];
if (has_pad_w()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(10, this->pad_w(), output);
}
// optional .opencv_caffe.PoolingParameter.Engine engine = 11 [default = DEFAULT];
if (has_engine()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
11, this->engine(), output);
}
// optional bool global_pooling = 12 [default = false];
if (has_global_pooling()) {
::google::protobuf::internal::WireFormatLite::WriteBool(12, this->global_pooling(), output);
}
// optional bool ceil_mode = 13 [default = true];
if (has_ceil_mode()) {
::google::protobuf::internal::WireFormatLite::WriteBool(13, this->ceil_mode(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.PoolingParameter)
}
::google::protobuf::uint8* PoolingParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.PoolingParameter)
// optional .opencv_caffe.PoolingParameter.PoolMethod pool = 1 [default = MAX];
if (has_pool()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
1, this->pool(), target);
}
// optional uint32 kernel_size = 2;
if (has_kernel_size()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(2, this->kernel_size(), target);
}
// optional uint32 stride = 3 [default = 1];
if (has_stride()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(3, this->stride(), target);
}
// optional uint32 pad = 4 [default = 0];
if (has_pad()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(4, this->pad(), target);
}
// optional uint32 kernel_h = 5;
if (has_kernel_h()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(5, this->kernel_h(), target);
}
// optional uint32 kernel_w = 6;
if (has_kernel_w()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(6, this->kernel_w(), target);
}
// optional uint32 stride_h = 7;
if (has_stride_h()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(7, this->stride_h(), target);
}
// optional uint32 stride_w = 8;
if (has_stride_w()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(8, this->stride_w(), target);
}
// optional uint32 pad_h = 9 [default = 0];
if (has_pad_h()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(9, this->pad_h(), target);
}
// optional uint32 pad_w = 10 [default = 0];
if (has_pad_w()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(10, this->pad_w(), target);
}
// optional .opencv_caffe.PoolingParameter.Engine engine = 11 [default = DEFAULT];
if (has_engine()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
11, this->engine(), target);
}
// optional bool global_pooling = 12 [default = false];
if (has_global_pooling()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(12, this->global_pooling(), target);
}
// optional bool ceil_mode = 13 [default = true];
if (has_ceil_mode()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(13, this->ceil_mode(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.PoolingParameter)
return target;
}
size_t PoolingParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.PoolingParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 255u) {
// optional .opencv_caffe.PoolingParameter.PoolMethod pool = 1 [default = MAX];
if (has_pool()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->pool());
}
// optional uint32 pad = 4 [default = 0];
if (has_pad()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->pad());
}
// optional uint32 pad_h = 9 [default = 0];
if (has_pad_h()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->pad_h());
}
// optional uint32 pad_w = 10 [default = 0];
if (has_pad_w()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->pad_w());
}
// optional uint32 kernel_size = 2;
if (has_kernel_size()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->kernel_size());
}
// optional uint32 kernel_h = 5;
if (has_kernel_h()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->kernel_h());
}
// optional uint32 kernel_w = 6;
if (has_kernel_w()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->kernel_w());
}
// optional uint32 stride = 3 [default = 1];
if (has_stride()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->stride());
}
}
if (_has_bits_[8 / 32] & 7936u) {
// optional uint32 stride_h = 7;
if (has_stride_h()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->stride_h());
}
// optional uint32 stride_w = 8;
if (has_stride_w()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->stride_w());
}
// optional .opencv_caffe.PoolingParameter.Engine engine = 11 [default = DEFAULT];
if (has_engine()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->engine());
}
// optional bool global_pooling = 12 [default = false];
if (has_global_pooling()) {
total_size += 1 + 1;
}
// optional bool ceil_mode = 13 [default = true];
if (has_ceil_mode()) {
total_size += 1 + 1;
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void PoolingParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.PoolingParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const PoolingParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const PoolingParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.PoolingParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.PoolingParameter)
UnsafeMergeFrom(*source);
}
}
void PoolingParameter::MergeFrom(const PoolingParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.PoolingParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void PoolingParameter::UnsafeMergeFrom(const PoolingParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_pool()) {
set_pool(from.pool());
}
if (from.has_pad()) {
set_pad(from.pad());
}
if (from.has_pad_h()) {
set_pad_h(from.pad_h());
}
if (from.has_pad_w()) {
set_pad_w(from.pad_w());
}
if (from.has_kernel_size()) {
set_kernel_size(from.kernel_size());
}
if (from.has_kernel_h()) {
set_kernel_h(from.kernel_h());
}
if (from.has_kernel_w()) {
set_kernel_w(from.kernel_w());
}
if (from.has_stride()) {
set_stride(from.stride());
}
}
if (from._has_bits_[8 / 32] & (0xffu << (8 % 32))) {
if (from.has_stride_h()) {
set_stride_h(from.stride_h());
}
if (from.has_stride_w()) {
set_stride_w(from.stride_w());
}
if (from.has_engine()) {
set_engine(from.engine());
}
if (from.has_global_pooling()) {
set_global_pooling(from.global_pooling());
}
if (from.has_ceil_mode()) {
set_ceil_mode(from.ceil_mode());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void PoolingParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.PoolingParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void PoolingParameter::CopyFrom(const PoolingParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.PoolingParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool PoolingParameter::IsInitialized() const {
return true;
}
void PoolingParameter::Swap(PoolingParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void PoolingParameter::InternalSwap(PoolingParameter* other) {
std::swap(pool_, other->pool_);
std::swap(pad_, other->pad_);
std::swap(pad_h_, other->pad_h_);
std::swap(pad_w_, other->pad_w_);
std::swap(kernel_size_, other->kernel_size_);
std::swap(kernel_h_, other->kernel_h_);
std::swap(kernel_w_, other->kernel_w_);
std::swap(stride_, other->stride_);
std::swap(stride_h_, other->stride_h_);
std::swap(stride_w_, other->stride_w_);
std::swap(engine_, other->engine_);
std::swap(global_pooling_, other->global_pooling_);
std::swap(ceil_mode_, other->ceil_mode_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata PoolingParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = PoolingParameter_descriptor_;
metadata.reflection = PoolingParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// PoolingParameter
// optional .opencv_caffe.PoolingParameter.PoolMethod pool = 1 [default = MAX];
bool PoolingParameter::has_pool() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void PoolingParameter::set_has_pool() {
_has_bits_[0] |= 0x00000001u;
}
void PoolingParameter::clear_has_pool() {
_has_bits_[0] &= ~0x00000001u;
}
void PoolingParameter::clear_pool() {
pool_ = 0;
clear_has_pool();
}
::opencv_caffe::PoolingParameter_PoolMethod PoolingParameter::pool() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PoolingParameter.pool)
return static_cast< ::opencv_caffe::PoolingParameter_PoolMethod >(pool_);
}
void PoolingParameter::set_pool(::opencv_caffe::PoolingParameter_PoolMethod value) {
assert(::opencv_caffe::PoolingParameter_PoolMethod_IsValid(value));
set_has_pool();
pool_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PoolingParameter.pool)
}
// optional uint32 pad = 4 [default = 0];
bool PoolingParameter::has_pad() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void PoolingParameter::set_has_pad() {
_has_bits_[0] |= 0x00000002u;
}
void PoolingParameter::clear_has_pad() {
_has_bits_[0] &= ~0x00000002u;
}
void PoolingParameter::clear_pad() {
pad_ = 0u;
clear_has_pad();
}
::google::protobuf::uint32 PoolingParameter::pad() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PoolingParameter.pad)
return pad_;
}
void PoolingParameter::set_pad(::google::protobuf::uint32 value) {
set_has_pad();
pad_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PoolingParameter.pad)
}
// optional uint32 pad_h = 9 [default = 0];
bool PoolingParameter::has_pad_h() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void PoolingParameter::set_has_pad_h() {
_has_bits_[0] |= 0x00000004u;
}
void PoolingParameter::clear_has_pad_h() {
_has_bits_[0] &= ~0x00000004u;
}
void PoolingParameter::clear_pad_h() {
pad_h_ = 0u;
clear_has_pad_h();
}
::google::protobuf::uint32 PoolingParameter::pad_h() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PoolingParameter.pad_h)
return pad_h_;
}
void PoolingParameter::set_pad_h(::google::protobuf::uint32 value) {
set_has_pad_h();
pad_h_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PoolingParameter.pad_h)
}
// optional uint32 pad_w = 10 [default = 0];
bool PoolingParameter::has_pad_w() const {
return (_has_bits_[0] & 0x00000008u) != 0;
}
void PoolingParameter::set_has_pad_w() {
_has_bits_[0] |= 0x00000008u;
}
void PoolingParameter::clear_has_pad_w() {
_has_bits_[0] &= ~0x00000008u;
}
void PoolingParameter::clear_pad_w() {
pad_w_ = 0u;
clear_has_pad_w();
}
::google::protobuf::uint32 PoolingParameter::pad_w() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PoolingParameter.pad_w)
return pad_w_;
}
void PoolingParameter::set_pad_w(::google::protobuf::uint32 value) {
set_has_pad_w();
pad_w_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PoolingParameter.pad_w)
}
// optional uint32 kernel_size = 2;
bool PoolingParameter::has_kernel_size() const {
return (_has_bits_[0] & 0x00000010u) != 0;
}
void PoolingParameter::set_has_kernel_size() {
_has_bits_[0] |= 0x00000010u;
}
void PoolingParameter::clear_has_kernel_size() {
_has_bits_[0] &= ~0x00000010u;
}
void PoolingParameter::clear_kernel_size() {
kernel_size_ = 0u;
clear_has_kernel_size();
}
::google::protobuf::uint32 PoolingParameter::kernel_size() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PoolingParameter.kernel_size)
return kernel_size_;
}
void PoolingParameter::set_kernel_size(::google::protobuf::uint32 value) {
set_has_kernel_size();
kernel_size_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PoolingParameter.kernel_size)
}
// optional uint32 kernel_h = 5;
bool PoolingParameter::has_kernel_h() const {
return (_has_bits_[0] & 0x00000020u) != 0;
}
void PoolingParameter::set_has_kernel_h() {
_has_bits_[0] |= 0x00000020u;
}
void PoolingParameter::clear_has_kernel_h() {
_has_bits_[0] &= ~0x00000020u;
}
void PoolingParameter::clear_kernel_h() {
kernel_h_ = 0u;
clear_has_kernel_h();
}
::google::protobuf::uint32 PoolingParameter::kernel_h() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PoolingParameter.kernel_h)
return kernel_h_;
}
void PoolingParameter::set_kernel_h(::google::protobuf::uint32 value) {
set_has_kernel_h();
kernel_h_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PoolingParameter.kernel_h)
}
// optional uint32 kernel_w = 6;
bool PoolingParameter::has_kernel_w() const {
return (_has_bits_[0] & 0x00000040u) != 0;
}
void PoolingParameter::set_has_kernel_w() {
_has_bits_[0] |= 0x00000040u;
}
void PoolingParameter::clear_has_kernel_w() {
_has_bits_[0] &= ~0x00000040u;
}
void PoolingParameter::clear_kernel_w() {
kernel_w_ = 0u;
clear_has_kernel_w();
}
::google::protobuf::uint32 PoolingParameter::kernel_w() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PoolingParameter.kernel_w)
return kernel_w_;
}
void PoolingParameter::set_kernel_w(::google::protobuf::uint32 value) {
set_has_kernel_w();
kernel_w_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PoolingParameter.kernel_w)
}
// optional uint32 stride = 3 [default = 1];
bool PoolingParameter::has_stride() const {
return (_has_bits_[0] & 0x00000080u) != 0;
}
void PoolingParameter::set_has_stride() {
_has_bits_[0] |= 0x00000080u;
}
void PoolingParameter::clear_has_stride() {
_has_bits_[0] &= ~0x00000080u;
}
void PoolingParameter::clear_stride() {
stride_ = 1u;
clear_has_stride();
}
::google::protobuf::uint32 PoolingParameter::stride() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PoolingParameter.stride)
return stride_;
}
void PoolingParameter::set_stride(::google::protobuf::uint32 value) {
set_has_stride();
stride_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PoolingParameter.stride)
}
// optional uint32 stride_h = 7;
bool PoolingParameter::has_stride_h() const {
return (_has_bits_[0] & 0x00000100u) != 0;
}
void PoolingParameter::set_has_stride_h() {
_has_bits_[0] |= 0x00000100u;
}
void PoolingParameter::clear_has_stride_h() {
_has_bits_[0] &= ~0x00000100u;
}
void PoolingParameter::clear_stride_h() {
stride_h_ = 0u;
clear_has_stride_h();
}
::google::protobuf::uint32 PoolingParameter::stride_h() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PoolingParameter.stride_h)
return stride_h_;
}
void PoolingParameter::set_stride_h(::google::protobuf::uint32 value) {
set_has_stride_h();
stride_h_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PoolingParameter.stride_h)
}
// optional uint32 stride_w = 8;
bool PoolingParameter::has_stride_w() const {
return (_has_bits_[0] & 0x00000200u) != 0;
}
void PoolingParameter::set_has_stride_w() {
_has_bits_[0] |= 0x00000200u;
}
void PoolingParameter::clear_has_stride_w() {
_has_bits_[0] &= ~0x00000200u;
}
void PoolingParameter::clear_stride_w() {
stride_w_ = 0u;
clear_has_stride_w();
}
::google::protobuf::uint32 PoolingParameter::stride_w() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PoolingParameter.stride_w)
return stride_w_;
}
void PoolingParameter::set_stride_w(::google::protobuf::uint32 value) {
set_has_stride_w();
stride_w_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PoolingParameter.stride_w)
}
// optional .opencv_caffe.PoolingParameter.Engine engine = 11 [default = DEFAULT];
bool PoolingParameter::has_engine() const {
return (_has_bits_[0] & 0x00000400u) != 0;
}
void PoolingParameter::set_has_engine() {
_has_bits_[0] |= 0x00000400u;
}
void PoolingParameter::clear_has_engine() {
_has_bits_[0] &= ~0x00000400u;
}
void PoolingParameter::clear_engine() {
engine_ = 0;
clear_has_engine();
}
::opencv_caffe::PoolingParameter_Engine PoolingParameter::engine() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PoolingParameter.engine)
return static_cast< ::opencv_caffe::PoolingParameter_Engine >(engine_);
}
void PoolingParameter::set_engine(::opencv_caffe::PoolingParameter_Engine value) {
assert(::opencv_caffe::PoolingParameter_Engine_IsValid(value));
set_has_engine();
engine_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PoolingParameter.engine)
}
// optional bool global_pooling = 12 [default = false];
bool PoolingParameter::has_global_pooling() const {
return (_has_bits_[0] & 0x00000800u) != 0;
}
void PoolingParameter::set_has_global_pooling() {
_has_bits_[0] |= 0x00000800u;
}
void PoolingParameter::clear_has_global_pooling() {
_has_bits_[0] &= ~0x00000800u;
}
void PoolingParameter::clear_global_pooling() {
global_pooling_ = false;
clear_has_global_pooling();
}
bool PoolingParameter::global_pooling() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PoolingParameter.global_pooling)
return global_pooling_;
}
void PoolingParameter::set_global_pooling(bool value) {
set_has_global_pooling();
global_pooling_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PoolingParameter.global_pooling)
}
// optional bool ceil_mode = 13 [default = true];
bool PoolingParameter::has_ceil_mode() const {
return (_has_bits_[0] & 0x00001000u) != 0;
}
void PoolingParameter::set_has_ceil_mode() {
_has_bits_[0] |= 0x00001000u;
}
void PoolingParameter::clear_has_ceil_mode() {
_has_bits_[0] &= ~0x00001000u;
}
void PoolingParameter::clear_ceil_mode() {
ceil_mode_ = true;
clear_has_ceil_mode();
}
bool PoolingParameter::ceil_mode() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PoolingParameter.ceil_mode)
return ceil_mode_;
}
void PoolingParameter::set_ceil_mode(bool value) {
set_has_ceil_mode();
ceil_mode_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PoolingParameter.ceil_mode)
}
inline const PoolingParameter* PoolingParameter::internal_default_instance() {
return &PoolingParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int PowerParameter::kPowerFieldNumber;
const int PowerParameter::kScaleFieldNumber;
const int PowerParameter::kShiftFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
PowerParameter::PowerParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.PowerParameter)
}
void PowerParameter::InitAsDefaultInstance() {
}
PowerParameter::PowerParameter(const PowerParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.PowerParameter)
}
void PowerParameter::SharedCtor() {
_cached_size_ = 0;
shift_ = 0;
power_ = 1;
scale_ = 1;
}
PowerParameter::~PowerParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.PowerParameter)
SharedDtor();
}
void PowerParameter::SharedDtor() {
}
void PowerParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* PowerParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return PowerParameter_descriptor_;
}
const PowerParameter& PowerParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<PowerParameter> PowerParameter_default_instance_;
PowerParameter* PowerParameter::New(::google::protobuf::Arena* arena) const {
PowerParameter* n = new PowerParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void PowerParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.PowerParameter)
if (_has_bits_[0 / 32] & 7u) {
power_ = 1;
scale_ = 1;
shift_ = 0;
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool PowerParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.PowerParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional float power = 1 [default = 1];
case 1: {
if (tag == 13) {
set_has_power();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &power_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(21)) goto parse_scale;
break;
}
// optional float scale = 2 [default = 1];
case 2: {
if (tag == 21) {
parse_scale:
set_has_scale();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &scale_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(29)) goto parse_shift;
break;
}
// optional float shift = 3 [default = 0];
case 3: {
if (tag == 29) {
parse_shift:
set_has_shift();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &shift_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.PowerParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.PowerParameter)
return false;
#undef DO_
}
void PowerParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.PowerParameter)
// optional float power = 1 [default = 1];
if (has_power()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(1, this->power(), output);
}
// optional float scale = 2 [default = 1];
if (has_scale()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(2, this->scale(), output);
}
// optional float shift = 3 [default = 0];
if (has_shift()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(3, this->shift(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.PowerParameter)
}
::google::protobuf::uint8* PowerParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.PowerParameter)
// optional float power = 1 [default = 1];
if (has_power()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(1, this->power(), target);
}
// optional float scale = 2 [default = 1];
if (has_scale()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(2, this->scale(), target);
}
// optional float shift = 3 [default = 0];
if (has_shift()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(3, this->shift(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.PowerParameter)
return target;
}
size_t PowerParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.PowerParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 7u) {
// optional float power = 1 [default = 1];
if (has_power()) {
total_size += 1 + 4;
}
// optional float scale = 2 [default = 1];
if (has_scale()) {
total_size += 1 + 4;
}
// optional float shift = 3 [default = 0];
if (has_shift()) {
total_size += 1 + 4;
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void PowerParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.PowerParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const PowerParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const PowerParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.PowerParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.PowerParameter)
UnsafeMergeFrom(*source);
}
}
void PowerParameter::MergeFrom(const PowerParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.PowerParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void PowerParameter::UnsafeMergeFrom(const PowerParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_power()) {
set_power(from.power());
}
if (from.has_scale()) {
set_scale(from.scale());
}
if (from.has_shift()) {
set_shift(from.shift());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void PowerParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.PowerParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void PowerParameter::CopyFrom(const PowerParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.PowerParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool PowerParameter::IsInitialized() const {
return true;
}
void PowerParameter::Swap(PowerParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void PowerParameter::InternalSwap(PowerParameter* other) {
std::swap(power_, other->power_);
std::swap(scale_, other->scale_);
std::swap(shift_, other->shift_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata PowerParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = PowerParameter_descriptor_;
metadata.reflection = PowerParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// PowerParameter
// optional float power = 1 [default = 1];
bool PowerParameter::has_power() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void PowerParameter::set_has_power() {
_has_bits_[0] |= 0x00000001u;
}
void PowerParameter::clear_has_power() {
_has_bits_[0] &= ~0x00000001u;
}
void PowerParameter::clear_power() {
power_ = 1;
clear_has_power();
}
float PowerParameter::power() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PowerParameter.power)
return power_;
}
void PowerParameter::set_power(float value) {
set_has_power();
power_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PowerParameter.power)
}
// optional float scale = 2 [default = 1];
bool PowerParameter::has_scale() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void PowerParameter::set_has_scale() {
_has_bits_[0] |= 0x00000002u;
}
void PowerParameter::clear_has_scale() {
_has_bits_[0] &= ~0x00000002u;
}
void PowerParameter::clear_scale() {
scale_ = 1;
clear_has_scale();
}
float PowerParameter::scale() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PowerParameter.scale)
return scale_;
}
void PowerParameter::set_scale(float value) {
set_has_scale();
scale_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PowerParameter.scale)
}
// optional float shift = 3 [default = 0];
bool PowerParameter::has_shift() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void PowerParameter::set_has_shift() {
_has_bits_[0] |= 0x00000004u;
}
void PowerParameter::clear_has_shift() {
_has_bits_[0] &= ~0x00000004u;
}
void PowerParameter::clear_shift() {
shift_ = 0;
clear_has_shift();
}
float PowerParameter::shift() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PowerParameter.shift)
return shift_;
}
void PowerParameter::set_shift(float value) {
set_has_shift();
shift_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PowerParameter.shift)
}
inline const PowerParameter* PowerParameter::internal_default_instance() {
return &PowerParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int PythonParameter::kModuleFieldNumber;
const int PythonParameter::kLayerFieldNumber;
const int PythonParameter::kParamStrFieldNumber;
const int PythonParameter::kShareInParallelFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
PythonParameter::PythonParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.PythonParameter)
}
void PythonParameter::InitAsDefaultInstance() {
}
PythonParameter::PythonParameter(const PythonParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.PythonParameter)
}
void PythonParameter::SharedCtor() {
_cached_size_ = 0;
module_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
layer_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
param_str_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
share_in_parallel_ = false;
}
PythonParameter::~PythonParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.PythonParameter)
SharedDtor();
}
void PythonParameter::SharedDtor() {
module_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
layer_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
param_str_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void PythonParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* PythonParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return PythonParameter_descriptor_;
}
const PythonParameter& PythonParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<PythonParameter> PythonParameter_default_instance_;
PythonParameter* PythonParameter::New(::google::protobuf::Arena* arena) const {
PythonParameter* n = new PythonParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void PythonParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.PythonParameter)
if (_has_bits_[0 / 32] & 15u) {
if (has_module()) {
module_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
if (has_layer()) {
layer_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
if (has_param_str()) {
param_str_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
share_in_parallel_ = false;
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool PythonParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.PythonParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional string module = 1;
case 1: {
if (tag == 10) {
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_module()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->module().data(), this->module().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.PythonParameter.module");
} else {
goto handle_unusual;
}
if (input->ExpectTag(18)) goto parse_layer;
break;
}
// optional string layer = 2;
case 2: {
if (tag == 18) {
parse_layer:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_layer()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->layer().data(), this->layer().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.PythonParameter.layer");
} else {
goto handle_unusual;
}
if (input->ExpectTag(26)) goto parse_param_str;
break;
}
// optional string param_str = 3 [default = ""];
case 3: {
if (tag == 26) {
parse_param_str:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_param_str()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->param_str().data(), this->param_str().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.PythonParameter.param_str");
} else {
goto handle_unusual;
}
if (input->ExpectTag(32)) goto parse_share_in_parallel;
break;
}
// optional bool share_in_parallel = 4 [default = false];
case 4: {
if (tag == 32) {
parse_share_in_parallel:
set_has_share_in_parallel();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &share_in_parallel_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.PythonParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.PythonParameter)
return false;
#undef DO_
}
void PythonParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.PythonParameter)
// optional string module = 1;
if (has_module()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->module().data(), this->module().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.PythonParameter.module");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
1, this->module(), output);
}
// optional string layer = 2;
if (has_layer()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->layer().data(), this->layer().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.PythonParameter.layer");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
2, this->layer(), output);
}
// optional string param_str = 3 [default = ""];
if (has_param_str()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->param_str().data(), this->param_str().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.PythonParameter.param_str");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
3, this->param_str(), output);
}
// optional bool share_in_parallel = 4 [default = false];
if (has_share_in_parallel()) {
::google::protobuf::internal::WireFormatLite::WriteBool(4, this->share_in_parallel(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.PythonParameter)
}
::google::protobuf::uint8* PythonParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.PythonParameter)
// optional string module = 1;
if (has_module()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->module().data(), this->module().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.PythonParameter.module");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
1, this->module(), target);
}
// optional string layer = 2;
if (has_layer()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->layer().data(), this->layer().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.PythonParameter.layer");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
2, this->layer(), target);
}
// optional string param_str = 3 [default = ""];
if (has_param_str()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->param_str().data(), this->param_str().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.PythonParameter.param_str");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
3, this->param_str(), target);
}
// optional bool share_in_parallel = 4 [default = false];
if (has_share_in_parallel()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(4, this->share_in_parallel(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.PythonParameter)
return target;
}
size_t PythonParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.PythonParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 15u) {
// optional string module = 1;
if (has_module()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->module());
}
// optional string layer = 2;
if (has_layer()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->layer());
}
// optional string param_str = 3 [default = ""];
if (has_param_str()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->param_str());
}
// optional bool share_in_parallel = 4 [default = false];
if (has_share_in_parallel()) {
total_size += 1 + 1;
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void PythonParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.PythonParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const PythonParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const PythonParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.PythonParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.PythonParameter)
UnsafeMergeFrom(*source);
}
}
void PythonParameter::MergeFrom(const PythonParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.PythonParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void PythonParameter::UnsafeMergeFrom(const PythonParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_module()) {
set_has_module();
module_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.module_);
}
if (from.has_layer()) {
set_has_layer();
layer_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.layer_);
}
if (from.has_param_str()) {
set_has_param_str();
param_str_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.param_str_);
}
if (from.has_share_in_parallel()) {
set_share_in_parallel(from.share_in_parallel());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void PythonParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.PythonParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void PythonParameter::CopyFrom(const PythonParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.PythonParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool PythonParameter::IsInitialized() const {
return true;
}
void PythonParameter::Swap(PythonParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void PythonParameter::InternalSwap(PythonParameter* other) {
module_.Swap(&other->module_);
layer_.Swap(&other->layer_);
param_str_.Swap(&other->param_str_);
std::swap(share_in_parallel_, other->share_in_parallel_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata PythonParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = PythonParameter_descriptor_;
metadata.reflection = PythonParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// PythonParameter
// optional string module = 1;
bool PythonParameter::has_module() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void PythonParameter::set_has_module() {
_has_bits_[0] |= 0x00000001u;
}
void PythonParameter::clear_has_module() {
_has_bits_[0] &= ~0x00000001u;
}
void PythonParameter::clear_module() {
module_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_module();
}
const ::std::string& PythonParameter::module() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PythonParameter.module)
return module_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void PythonParameter::set_module(const ::std::string& value) {
set_has_module();
module_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.PythonParameter.module)
}
void PythonParameter::set_module(const char* value) {
set_has_module();
module_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.PythonParameter.module)
}
void PythonParameter::set_module(const char* value, size_t size) {
set_has_module();
module_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.PythonParameter.module)
}
::std::string* PythonParameter::mutable_module() {
set_has_module();
// @@protoc_insertion_point(field_mutable:opencv_caffe.PythonParameter.module)
return module_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* PythonParameter::release_module() {
// @@protoc_insertion_point(field_release:opencv_caffe.PythonParameter.module)
clear_has_module();
return module_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void PythonParameter::set_allocated_module(::std::string* module) {
if (module != NULL) {
set_has_module();
} else {
clear_has_module();
}
module_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), module);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.PythonParameter.module)
}
// optional string layer = 2;
bool PythonParameter::has_layer() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void PythonParameter::set_has_layer() {
_has_bits_[0] |= 0x00000002u;
}
void PythonParameter::clear_has_layer() {
_has_bits_[0] &= ~0x00000002u;
}
void PythonParameter::clear_layer() {
layer_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_layer();
}
const ::std::string& PythonParameter::layer() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PythonParameter.layer)
return layer_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void PythonParameter::set_layer(const ::std::string& value) {
set_has_layer();
layer_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.PythonParameter.layer)
}
void PythonParameter::set_layer(const char* value) {
set_has_layer();
layer_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.PythonParameter.layer)
}
void PythonParameter::set_layer(const char* value, size_t size) {
set_has_layer();
layer_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.PythonParameter.layer)
}
::std::string* PythonParameter::mutable_layer() {
set_has_layer();
// @@protoc_insertion_point(field_mutable:opencv_caffe.PythonParameter.layer)
return layer_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* PythonParameter::release_layer() {
// @@protoc_insertion_point(field_release:opencv_caffe.PythonParameter.layer)
clear_has_layer();
return layer_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void PythonParameter::set_allocated_layer(::std::string* layer) {
if (layer != NULL) {
set_has_layer();
} else {
clear_has_layer();
}
layer_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), layer);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.PythonParameter.layer)
}
// optional string param_str = 3 [default = ""];
bool PythonParameter::has_param_str() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void PythonParameter::set_has_param_str() {
_has_bits_[0] |= 0x00000004u;
}
void PythonParameter::clear_has_param_str() {
_has_bits_[0] &= ~0x00000004u;
}
void PythonParameter::clear_param_str() {
param_str_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_param_str();
}
const ::std::string& PythonParameter::param_str() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PythonParameter.param_str)
return param_str_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void PythonParameter::set_param_str(const ::std::string& value) {
set_has_param_str();
param_str_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.PythonParameter.param_str)
}
void PythonParameter::set_param_str(const char* value) {
set_has_param_str();
param_str_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.PythonParameter.param_str)
}
void PythonParameter::set_param_str(const char* value, size_t size) {
set_has_param_str();
param_str_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.PythonParameter.param_str)
}
::std::string* PythonParameter::mutable_param_str() {
set_has_param_str();
// @@protoc_insertion_point(field_mutable:opencv_caffe.PythonParameter.param_str)
return param_str_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* PythonParameter::release_param_str() {
// @@protoc_insertion_point(field_release:opencv_caffe.PythonParameter.param_str)
clear_has_param_str();
return param_str_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void PythonParameter::set_allocated_param_str(::std::string* param_str) {
if (param_str != NULL) {
set_has_param_str();
} else {
clear_has_param_str();
}
param_str_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), param_str);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.PythonParameter.param_str)
}
// optional bool share_in_parallel = 4 [default = false];
bool PythonParameter::has_share_in_parallel() const {
return (_has_bits_[0] & 0x00000008u) != 0;
}
void PythonParameter::set_has_share_in_parallel() {
_has_bits_[0] |= 0x00000008u;
}
void PythonParameter::clear_has_share_in_parallel() {
_has_bits_[0] &= ~0x00000008u;
}
void PythonParameter::clear_share_in_parallel() {
share_in_parallel_ = false;
clear_has_share_in_parallel();
}
bool PythonParameter::share_in_parallel() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PythonParameter.share_in_parallel)
return share_in_parallel_;
}
void PythonParameter::set_share_in_parallel(bool value) {
set_has_share_in_parallel();
share_in_parallel_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PythonParameter.share_in_parallel)
}
inline const PythonParameter* PythonParameter::internal_default_instance() {
return &PythonParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int RecurrentParameter::kNumOutputFieldNumber;
const int RecurrentParameter::kWeightFillerFieldNumber;
const int RecurrentParameter::kBiasFillerFieldNumber;
const int RecurrentParameter::kDebugInfoFieldNumber;
const int RecurrentParameter::kExposeHiddenFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
RecurrentParameter::RecurrentParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.RecurrentParameter)
}
void RecurrentParameter::InitAsDefaultInstance() {
weight_filler_ = const_cast< ::opencv_caffe::FillerParameter*>(
::opencv_caffe::FillerParameter::internal_default_instance());
bias_filler_ = const_cast< ::opencv_caffe::FillerParameter*>(
::opencv_caffe::FillerParameter::internal_default_instance());
}
RecurrentParameter::RecurrentParameter(const RecurrentParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.RecurrentParameter)
}
void RecurrentParameter::SharedCtor() {
_cached_size_ = 0;
weight_filler_ = NULL;
bias_filler_ = NULL;
::memset(&num_output_, 0, reinterpret_cast<char*>(&expose_hidden_) -
reinterpret_cast<char*>(&num_output_) + sizeof(expose_hidden_));
}
RecurrentParameter::~RecurrentParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.RecurrentParameter)
SharedDtor();
}
void RecurrentParameter::SharedDtor() {
if (this != &RecurrentParameter_default_instance_.get()) {
delete weight_filler_;
delete bias_filler_;
}
}
void RecurrentParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* RecurrentParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return RecurrentParameter_descriptor_;
}
const RecurrentParameter& RecurrentParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<RecurrentParameter> RecurrentParameter_default_instance_;
RecurrentParameter* RecurrentParameter::New(::google::protobuf::Arena* arena) const {
RecurrentParameter* n = new RecurrentParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void RecurrentParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.RecurrentParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(RecurrentParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<RecurrentParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
if (_has_bits_[0 / 32] & 31u) {
ZR_(num_output_, expose_hidden_);
if (has_weight_filler()) {
if (weight_filler_ != NULL) weight_filler_->::opencv_caffe::FillerParameter::Clear();
}
if (has_bias_filler()) {
if (bias_filler_ != NULL) bias_filler_->::opencv_caffe::FillerParameter::Clear();
}
}
#undef ZR_HELPER_
#undef ZR_
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool RecurrentParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.RecurrentParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional uint32 num_output = 1 [default = 0];
case 1: {
if (tag == 8) {
set_has_num_output();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &num_output_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(18)) goto parse_weight_filler;
break;
}
// optional .opencv_caffe.FillerParameter weight_filler = 2;
case 2: {
if (tag == 18) {
parse_weight_filler:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_weight_filler()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(26)) goto parse_bias_filler;
break;
}
// optional .opencv_caffe.FillerParameter bias_filler = 3;
case 3: {
if (tag == 26) {
parse_bias_filler:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_bias_filler()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(32)) goto parse_debug_info;
break;
}
// optional bool debug_info = 4 [default = false];
case 4: {
if (tag == 32) {
parse_debug_info:
set_has_debug_info();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &debug_info_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(40)) goto parse_expose_hidden;
break;
}
// optional bool expose_hidden = 5 [default = false];
case 5: {
if (tag == 40) {
parse_expose_hidden:
set_has_expose_hidden();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &expose_hidden_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.RecurrentParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.RecurrentParameter)
return false;
#undef DO_
}
void RecurrentParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.RecurrentParameter)
// optional uint32 num_output = 1 [default = 0];
if (has_num_output()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(1, this->num_output(), output);
}
// optional .opencv_caffe.FillerParameter weight_filler = 2;
if (has_weight_filler()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
2, *this->weight_filler_, output);
}
// optional .opencv_caffe.FillerParameter bias_filler = 3;
if (has_bias_filler()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
3, *this->bias_filler_, output);
}
// optional bool debug_info = 4 [default = false];
if (has_debug_info()) {
::google::protobuf::internal::WireFormatLite::WriteBool(4, this->debug_info(), output);
}
// optional bool expose_hidden = 5 [default = false];
if (has_expose_hidden()) {
::google::protobuf::internal::WireFormatLite::WriteBool(5, this->expose_hidden(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.RecurrentParameter)
}
::google::protobuf::uint8* RecurrentParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.RecurrentParameter)
// optional uint32 num_output = 1 [default = 0];
if (has_num_output()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(1, this->num_output(), target);
}
// optional .opencv_caffe.FillerParameter weight_filler = 2;
if (has_weight_filler()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
2, *this->weight_filler_, false, target);
}
// optional .opencv_caffe.FillerParameter bias_filler = 3;
if (has_bias_filler()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
3, *this->bias_filler_, false, target);
}
// optional bool debug_info = 4 [default = false];
if (has_debug_info()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(4, this->debug_info(), target);
}
// optional bool expose_hidden = 5 [default = false];
if (has_expose_hidden()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(5, this->expose_hidden(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.RecurrentParameter)
return target;
}
size_t RecurrentParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.RecurrentParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 31u) {
// optional uint32 num_output = 1 [default = 0];
if (has_num_output()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->num_output());
}
// optional .opencv_caffe.FillerParameter weight_filler = 2;
if (has_weight_filler()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->weight_filler_);
}
// optional .opencv_caffe.FillerParameter bias_filler = 3;
if (has_bias_filler()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->bias_filler_);
}
// optional bool debug_info = 4 [default = false];
if (has_debug_info()) {
total_size += 1 + 1;
}
// optional bool expose_hidden = 5 [default = false];
if (has_expose_hidden()) {
total_size += 1 + 1;
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void RecurrentParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.RecurrentParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const RecurrentParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const RecurrentParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.RecurrentParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.RecurrentParameter)
UnsafeMergeFrom(*source);
}
}
void RecurrentParameter::MergeFrom(const RecurrentParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.RecurrentParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void RecurrentParameter::UnsafeMergeFrom(const RecurrentParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_num_output()) {
set_num_output(from.num_output());
}
if (from.has_weight_filler()) {
mutable_weight_filler()->::opencv_caffe::FillerParameter::MergeFrom(from.weight_filler());
}
if (from.has_bias_filler()) {
mutable_bias_filler()->::opencv_caffe::FillerParameter::MergeFrom(from.bias_filler());
}
if (from.has_debug_info()) {
set_debug_info(from.debug_info());
}
if (from.has_expose_hidden()) {
set_expose_hidden(from.expose_hidden());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void RecurrentParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.RecurrentParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void RecurrentParameter::CopyFrom(const RecurrentParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.RecurrentParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool RecurrentParameter::IsInitialized() const {
return true;
}
void RecurrentParameter::Swap(RecurrentParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void RecurrentParameter::InternalSwap(RecurrentParameter* other) {
std::swap(num_output_, other->num_output_);
std::swap(weight_filler_, other->weight_filler_);
std::swap(bias_filler_, other->bias_filler_);
std::swap(debug_info_, other->debug_info_);
std::swap(expose_hidden_, other->expose_hidden_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata RecurrentParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = RecurrentParameter_descriptor_;
metadata.reflection = RecurrentParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// RecurrentParameter
// optional uint32 num_output = 1 [default = 0];
bool RecurrentParameter::has_num_output() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void RecurrentParameter::set_has_num_output() {
_has_bits_[0] |= 0x00000001u;
}
void RecurrentParameter::clear_has_num_output() {
_has_bits_[0] &= ~0x00000001u;
}
void RecurrentParameter::clear_num_output() {
num_output_ = 0u;
clear_has_num_output();
}
::google::protobuf::uint32 RecurrentParameter::num_output() const {
// @@protoc_insertion_point(field_get:opencv_caffe.RecurrentParameter.num_output)
return num_output_;
}
void RecurrentParameter::set_num_output(::google::protobuf::uint32 value) {
set_has_num_output();
num_output_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.RecurrentParameter.num_output)
}
// optional .opencv_caffe.FillerParameter weight_filler = 2;
bool RecurrentParameter::has_weight_filler() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void RecurrentParameter::set_has_weight_filler() {
_has_bits_[0] |= 0x00000002u;
}
void RecurrentParameter::clear_has_weight_filler() {
_has_bits_[0] &= ~0x00000002u;
}
void RecurrentParameter::clear_weight_filler() {
if (weight_filler_ != NULL) weight_filler_->::opencv_caffe::FillerParameter::Clear();
clear_has_weight_filler();
}
const ::opencv_caffe::FillerParameter& RecurrentParameter::weight_filler() const {
// @@protoc_insertion_point(field_get:opencv_caffe.RecurrentParameter.weight_filler)
return weight_filler_ != NULL ? *weight_filler_
: *::opencv_caffe::FillerParameter::internal_default_instance();
}
::opencv_caffe::FillerParameter* RecurrentParameter::mutable_weight_filler() {
set_has_weight_filler();
if (weight_filler_ == NULL) {
weight_filler_ = new ::opencv_caffe::FillerParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.RecurrentParameter.weight_filler)
return weight_filler_;
}
::opencv_caffe::FillerParameter* RecurrentParameter::release_weight_filler() {
// @@protoc_insertion_point(field_release:opencv_caffe.RecurrentParameter.weight_filler)
clear_has_weight_filler();
::opencv_caffe::FillerParameter* temp = weight_filler_;
weight_filler_ = NULL;
return temp;
}
void RecurrentParameter::set_allocated_weight_filler(::opencv_caffe::FillerParameter* weight_filler) {
delete weight_filler_;
weight_filler_ = weight_filler;
if (weight_filler) {
set_has_weight_filler();
} else {
clear_has_weight_filler();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.RecurrentParameter.weight_filler)
}
// optional .opencv_caffe.FillerParameter bias_filler = 3;
bool RecurrentParameter::has_bias_filler() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void RecurrentParameter::set_has_bias_filler() {
_has_bits_[0] |= 0x00000004u;
}
void RecurrentParameter::clear_has_bias_filler() {
_has_bits_[0] &= ~0x00000004u;
}
void RecurrentParameter::clear_bias_filler() {
if (bias_filler_ != NULL) bias_filler_->::opencv_caffe::FillerParameter::Clear();
clear_has_bias_filler();
}
const ::opencv_caffe::FillerParameter& RecurrentParameter::bias_filler() const {
// @@protoc_insertion_point(field_get:opencv_caffe.RecurrentParameter.bias_filler)
return bias_filler_ != NULL ? *bias_filler_
: *::opencv_caffe::FillerParameter::internal_default_instance();
}
::opencv_caffe::FillerParameter* RecurrentParameter::mutable_bias_filler() {
set_has_bias_filler();
if (bias_filler_ == NULL) {
bias_filler_ = new ::opencv_caffe::FillerParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.RecurrentParameter.bias_filler)
return bias_filler_;
}
::opencv_caffe::FillerParameter* RecurrentParameter::release_bias_filler() {
// @@protoc_insertion_point(field_release:opencv_caffe.RecurrentParameter.bias_filler)
clear_has_bias_filler();
::opencv_caffe::FillerParameter* temp = bias_filler_;
bias_filler_ = NULL;
return temp;
}
void RecurrentParameter::set_allocated_bias_filler(::opencv_caffe::FillerParameter* bias_filler) {
delete bias_filler_;
bias_filler_ = bias_filler;
if (bias_filler) {
set_has_bias_filler();
} else {
clear_has_bias_filler();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.RecurrentParameter.bias_filler)
}
// optional bool debug_info = 4 [default = false];
bool RecurrentParameter::has_debug_info() const {
return (_has_bits_[0] & 0x00000008u) != 0;
}
void RecurrentParameter::set_has_debug_info() {
_has_bits_[0] |= 0x00000008u;
}
void RecurrentParameter::clear_has_debug_info() {
_has_bits_[0] &= ~0x00000008u;
}
void RecurrentParameter::clear_debug_info() {
debug_info_ = false;
clear_has_debug_info();
}
bool RecurrentParameter::debug_info() const {
// @@protoc_insertion_point(field_get:opencv_caffe.RecurrentParameter.debug_info)
return debug_info_;
}
void RecurrentParameter::set_debug_info(bool value) {
set_has_debug_info();
debug_info_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.RecurrentParameter.debug_info)
}
// optional bool expose_hidden = 5 [default = false];
bool RecurrentParameter::has_expose_hidden() const {
return (_has_bits_[0] & 0x00000010u) != 0;
}
void RecurrentParameter::set_has_expose_hidden() {
_has_bits_[0] |= 0x00000010u;
}
void RecurrentParameter::clear_has_expose_hidden() {
_has_bits_[0] &= ~0x00000010u;
}
void RecurrentParameter::clear_expose_hidden() {
expose_hidden_ = false;
clear_has_expose_hidden();
}
bool RecurrentParameter::expose_hidden() const {
// @@protoc_insertion_point(field_get:opencv_caffe.RecurrentParameter.expose_hidden)
return expose_hidden_;
}
void RecurrentParameter::set_expose_hidden(bool value) {
set_has_expose_hidden();
expose_hidden_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.RecurrentParameter.expose_hidden)
}
inline const RecurrentParameter* RecurrentParameter::internal_default_instance() {
return &RecurrentParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
const ::google::protobuf::EnumDescriptor* ReductionParameter_ReductionOp_descriptor() {
protobuf_AssignDescriptorsOnce();
return ReductionParameter_ReductionOp_descriptor_;
}
bool ReductionParameter_ReductionOp_IsValid(int value) {
switch (value) {
case 1:
case 2:
case 3:
case 4:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const ReductionParameter_ReductionOp ReductionParameter::SUM;
const ReductionParameter_ReductionOp ReductionParameter::ASUM;
const ReductionParameter_ReductionOp ReductionParameter::SUMSQ;
const ReductionParameter_ReductionOp ReductionParameter::MEAN;
const ReductionParameter_ReductionOp ReductionParameter::ReductionOp_MIN;
const ReductionParameter_ReductionOp ReductionParameter::ReductionOp_MAX;
const int ReductionParameter::ReductionOp_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int ReductionParameter::kOperationFieldNumber;
const int ReductionParameter::kAxisFieldNumber;
const int ReductionParameter::kCoeffFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
ReductionParameter::ReductionParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.ReductionParameter)
}
void ReductionParameter::InitAsDefaultInstance() {
}
ReductionParameter::ReductionParameter(const ReductionParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.ReductionParameter)
}
void ReductionParameter::SharedCtor() {
_cached_size_ = 0;
axis_ = 0;
operation_ = 1;
coeff_ = 1;
}
ReductionParameter::~ReductionParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.ReductionParameter)
SharedDtor();
}
void ReductionParameter::SharedDtor() {
}
void ReductionParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* ReductionParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return ReductionParameter_descriptor_;
}
const ReductionParameter& ReductionParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<ReductionParameter> ReductionParameter_default_instance_;
ReductionParameter* ReductionParameter::New(::google::protobuf::Arena* arena) const {
ReductionParameter* n = new ReductionParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void ReductionParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.ReductionParameter)
if (_has_bits_[0 / 32] & 7u) {
operation_ = 1;
axis_ = 0;
coeff_ = 1;
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool ReductionParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.ReductionParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional .opencv_caffe.ReductionParameter.ReductionOp operation = 1 [default = SUM];
case 1: {
if (tag == 8) {
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::ReductionParameter_ReductionOp_IsValid(value)) {
set_operation(static_cast< ::opencv_caffe::ReductionParameter_ReductionOp >(value));
} else {
mutable_unknown_fields()->AddVarint(1, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_axis;
break;
}
// optional int32 axis = 2 [default = 0];
case 2: {
if (tag == 16) {
parse_axis:
set_has_axis();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &axis_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(29)) goto parse_coeff;
break;
}
// optional float coeff = 3 [default = 1];
case 3: {
if (tag == 29) {
parse_coeff:
set_has_coeff();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &coeff_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.ReductionParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.ReductionParameter)
return false;
#undef DO_
}
void ReductionParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.ReductionParameter)
// optional .opencv_caffe.ReductionParameter.ReductionOp operation = 1 [default = SUM];
if (has_operation()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
1, this->operation(), output);
}
// optional int32 axis = 2 [default = 0];
if (has_axis()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->axis(), output);
}
// optional float coeff = 3 [default = 1];
if (has_coeff()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(3, this->coeff(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.ReductionParameter)
}
::google::protobuf::uint8* ReductionParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.ReductionParameter)
// optional .opencv_caffe.ReductionParameter.ReductionOp operation = 1 [default = SUM];
if (has_operation()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
1, this->operation(), target);
}
// optional int32 axis = 2 [default = 0];
if (has_axis()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(2, this->axis(), target);
}
// optional float coeff = 3 [default = 1];
if (has_coeff()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(3, this->coeff(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.ReductionParameter)
return target;
}
size_t ReductionParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.ReductionParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 7u) {
// optional .opencv_caffe.ReductionParameter.ReductionOp operation = 1 [default = SUM];
if (has_operation()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->operation());
}
// optional int32 axis = 2 [default = 0];
if (has_axis()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->axis());
}
// optional float coeff = 3 [default = 1];
if (has_coeff()) {
total_size += 1 + 4;
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void ReductionParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.ReductionParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const ReductionParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const ReductionParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.ReductionParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.ReductionParameter)
UnsafeMergeFrom(*source);
}
}
void ReductionParameter::MergeFrom(const ReductionParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.ReductionParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void ReductionParameter::UnsafeMergeFrom(const ReductionParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_operation()) {
set_operation(from.operation());
}
if (from.has_axis()) {
set_axis(from.axis());
}
if (from.has_coeff()) {
set_coeff(from.coeff());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void ReductionParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.ReductionParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void ReductionParameter::CopyFrom(const ReductionParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.ReductionParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool ReductionParameter::IsInitialized() const {
return true;
}
void ReductionParameter::Swap(ReductionParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void ReductionParameter::InternalSwap(ReductionParameter* other) {
std::swap(operation_, other->operation_);
std::swap(axis_, other->axis_);
std::swap(coeff_, other->coeff_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata ReductionParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = ReductionParameter_descriptor_;
metadata.reflection = ReductionParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// ReductionParameter
// optional .opencv_caffe.ReductionParameter.ReductionOp operation = 1 [default = SUM];
bool ReductionParameter::has_operation() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void ReductionParameter::set_has_operation() {
_has_bits_[0] |= 0x00000001u;
}
void ReductionParameter::clear_has_operation() {
_has_bits_[0] &= ~0x00000001u;
}
void ReductionParameter::clear_operation() {
operation_ = 1;
clear_has_operation();
}
::opencv_caffe::ReductionParameter_ReductionOp ReductionParameter::operation() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ReductionParameter.operation)
return static_cast< ::opencv_caffe::ReductionParameter_ReductionOp >(operation_);
}
void ReductionParameter::set_operation(::opencv_caffe::ReductionParameter_ReductionOp value) {
assert(::opencv_caffe::ReductionParameter_ReductionOp_IsValid(value));
set_has_operation();
operation_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ReductionParameter.operation)
}
// optional int32 axis = 2 [default = 0];
bool ReductionParameter::has_axis() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void ReductionParameter::set_has_axis() {
_has_bits_[0] |= 0x00000002u;
}
void ReductionParameter::clear_has_axis() {
_has_bits_[0] &= ~0x00000002u;
}
void ReductionParameter::clear_axis() {
axis_ = 0;
clear_has_axis();
}
::google::protobuf::int32 ReductionParameter::axis() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ReductionParameter.axis)
return axis_;
}
void ReductionParameter::set_axis(::google::protobuf::int32 value) {
set_has_axis();
axis_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ReductionParameter.axis)
}
// optional float coeff = 3 [default = 1];
bool ReductionParameter::has_coeff() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void ReductionParameter::set_has_coeff() {
_has_bits_[0] |= 0x00000004u;
}
void ReductionParameter::clear_has_coeff() {
_has_bits_[0] &= ~0x00000004u;
}
void ReductionParameter::clear_coeff() {
coeff_ = 1;
clear_has_coeff();
}
float ReductionParameter::coeff() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ReductionParameter.coeff)
return coeff_;
}
void ReductionParameter::set_coeff(float value) {
set_has_coeff();
coeff_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ReductionParameter.coeff)
}
inline const ReductionParameter* ReductionParameter::internal_default_instance() {
return &ReductionParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
const ::google::protobuf::EnumDescriptor* ReLUParameter_Engine_descriptor() {
protobuf_AssignDescriptorsOnce();
return ReLUParameter_Engine_descriptor_;
}
bool ReLUParameter_Engine_IsValid(int value) {
switch (value) {
case 0:
case 1:
case 2:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const ReLUParameter_Engine ReLUParameter::DEFAULT;
const ReLUParameter_Engine ReLUParameter::CAFFE;
const ReLUParameter_Engine ReLUParameter::CUDNN;
const ReLUParameter_Engine ReLUParameter::Engine_MIN;
const ReLUParameter_Engine ReLUParameter::Engine_MAX;
const int ReLUParameter::Engine_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int ReLUParameter::kNegativeSlopeFieldNumber;
const int ReLUParameter::kEngineFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
ReLUParameter::ReLUParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.ReLUParameter)
}
void ReLUParameter::InitAsDefaultInstance() {
}
ReLUParameter::ReLUParameter(const ReLUParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.ReLUParameter)
}
void ReLUParameter::SharedCtor() {
_cached_size_ = 0;
::memset(&negative_slope_, 0, reinterpret_cast<char*>(&engine_) -
reinterpret_cast<char*>(&negative_slope_) + sizeof(engine_));
}
ReLUParameter::~ReLUParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.ReLUParameter)
SharedDtor();
}
void ReLUParameter::SharedDtor() {
}
void ReLUParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* ReLUParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return ReLUParameter_descriptor_;
}
const ReLUParameter& ReLUParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<ReLUParameter> ReLUParameter_default_instance_;
ReLUParameter* ReLUParameter::New(::google::protobuf::Arena* arena) const {
ReLUParameter* n = new ReLUParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void ReLUParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.ReLUParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(ReLUParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<ReLUParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
ZR_(negative_slope_, engine_);
#undef ZR_HELPER_
#undef ZR_
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool ReLUParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.ReLUParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional float negative_slope = 1 [default = 0];
case 1: {
if (tag == 13) {
set_has_negative_slope();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &negative_slope_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_engine;
break;
}
// optional .opencv_caffe.ReLUParameter.Engine engine = 2 [default = DEFAULT];
case 2: {
if (tag == 16) {
parse_engine:
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::ReLUParameter_Engine_IsValid(value)) {
set_engine(static_cast< ::opencv_caffe::ReLUParameter_Engine >(value));
} else {
mutable_unknown_fields()->AddVarint(2, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.ReLUParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.ReLUParameter)
return false;
#undef DO_
}
void ReLUParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.ReLUParameter)
// optional float negative_slope = 1 [default = 0];
if (has_negative_slope()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(1, this->negative_slope(), output);
}
// optional .opencv_caffe.ReLUParameter.Engine engine = 2 [default = DEFAULT];
if (has_engine()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
2, this->engine(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.ReLUParameter)
}
::google::protobuf::uint8* ReLUParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.ReLUParameter)
// optional float negative_slope = 1 [default = 0];
if (has_negative_slope()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(1, this->negative_slope(), target);
}
// optional .opencv_caffe.ReLUParameter.Engine engine = 2 [default = DEFAULT];
if (has_engine()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
2, this->engine(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.ReLUParameter)
return target;
}
size_t ReLUParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.ReLUParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 3u) {
// optional float negative_slope = 1 [default = 0];
if (has_negative_slope()) {
total_size += 1 + 4;
}
// optional .opencv_caffe.ReLUParameter.Engine engine = 2 [default = DEFAULT];
if (has_engine()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->engine());
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void ReLUParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.ReLUParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const ReLUParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const ReLUParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.ReLUParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.ReLUParameter)
UnsafeMergeFrom(*source);
}
}
void ReLUParameter::MergeFrom(const ReLUParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.ReLUParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void ReLUParameter::UnsafeMergeFrom(const ReLUParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_negative_slope()) {
set_negative_slope(from.negative_slope());
}
if (from.has_engine()) {
set_engine(from.engine());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void ReLUParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.ReLUParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void ReLUParameter::CopyFrom(const ReLUParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.ReLUParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool ReLUParameter::IsInitialized() const {
return true;
}
void ReLUParameter::Swap(ReLUParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void ReLUParameter::InternalSwap(ReLUParameter* other) {
std::swap(negative_slope_, other->negative_slope_);
std::swap(engine_, other->engine_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata ReLUParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = ReLUParameter_descriptor_;
metadata.reflection = ReLUParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// ReLUParameter
// optional float negative_slope = 1 [default = 0];
bool ReLUParameter::has_negative_slope() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void ReLUParameter::set_has_negative_slope() {
_has_bits_[0] |= 0x00000001u;
}
void ReLUParameter::clear_has_negative_slope() {
_has_bits_[0] &= ~0x00000001u;
}
void ReLUParameter::clear_negative_slope() {
negative_slope_ = 0;
clear_has_negative_slope();
}
float ReLUParameter::negative_slope() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ReLUParameter.negative_slope)
return negative_slope_;
}
void ReLUParameter::set_negative_slope(float value) {
set_has_negative_slope();
negative_slope_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ReLUParameter.negative_slope)
}
// optional .opencv_caffe.ReLUParameter.Engine engine = 2 [default = DEFAULT];
bool ReLUParameter::has_engine() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void ReLUParameter::set_has_engine() {
_has_bits_[0] |= 0x00000002u;
}
void ReLUParameter::clear_has_engine() {
_has_bits_[0] &= ~0x00000002u;
}
void ReLUParameter::clear_engine() {
engine_ = 0;
clear_has_engine();
}
::opencv_caffe::ReLUParameter_Engine ReLUParameter::engine() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ReLUParameter.engine)
return static_cast< ::opencv_caffe::ReLUParameter_Engine >(engine_);
}
void ReLUParameter::set_engine(::opencv_caffe::ReLUParameter_Engine value) {
assert(::opencv_caffe::ReLUParameter_Engine_IsValid(value));
set_has_engine();
engine_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ReLUParameter.engine)
}
inline const ReLUParameter* ReLUParameter::internal_default_instance() {
return &ReLUParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int ReshapeParameter::kShapeFieldNumber;
const int ReshapeParameter::kAxisFieldNumber;
const int ReshapeParameter::kNumAxesFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
ReshapeParameter::ReshapeParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.ReshapeParameter)
}
void ReshapeParameter::InitAsDefaultInstance() {
shape_ = const_cast< ::opencv_caffe::BlobShape*>(
::opencv_caffe::BlobShape::internal_default_instance());
}
ReshapeParameter::ReshapeParameter(const ReshapeParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.ReshapeParameter)
}
void ReshapeParameter::SharedCtor() {
_cached_size_ = 0;
shape_ = NULL;
axis_ = 0;
num_axes_ = -1;
}
ReshapeParameter::~ReshapeParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.ReshapeParameter)
SharedDtor();
}
void ReshapeParameter::SharedDtor() {
if (this != &ReshapeParameter_default_instance_.get()) {
delete shape_;
}
}
void ReshapeParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* ReshapeParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return ReshapeParameter_descriptor_;
}
const ReshapeParameter& ReshapeParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<ReshapeParameter> ReshapeParameter_default_instance_;
ReshapeParameter* ReshapeParameter::New(::google::protobuf::Arena* arena) const {
ReshapeParameter* n = new ReshapeParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void ReshapeParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.ReshapeParameter)
if (_has_bits_[0 / 32] & 7u) {
if (has_shape()) {
if (shape_ != NULL) shape_->::opencv_caffe::BlobShape::Clear();
}
axis_ = 0;
num_axes_ = -1;
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool ReshapeParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.ReshapeParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional .opencv_caffe.BlobShape shape = 1;
case 1: {
if (tag == 10) {
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_shape()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_axis;
break;
}
// optional int32 axis = 2 [default = 0];
case 2: {
if (tag == 16) {
parse_axis:
set_has_axis();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &axis_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(24)) goto parse_num_axes;
break;
}
// optional int32 num_axes = 3 [default = -1];
case 3: {
if (tag == 24) {
parse_num_axes:
set_has_num_axes();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &num_axes_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.ReshapeParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.ReshapeParameter)
return false;
#undef DO_
}
void ReshapeParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.ReshapeParameter)
// optional .opencv_caffe.BlobShape shape = 1;
if (has_shape()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
1, *this->shape_, output);
}
// optional int32 axis = 2 [default = 0];
if (has_axis()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->axis(), output);
}
// optional int32 num_axes = 3 [default = -1];
if (has_num_axes()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(3, this->num_axes(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.ReshapeParameter)
}
::google::protobuf::uint8* ReshapeParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.ReshapeParameter)
// optional .opencv_caffe.BlobShape shape = 1;
if (has_shape()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
1, *this->shape_, false, target);
}
// optional int32 axis = 2 [default = 0];
if (has_axis()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(2, this->axis(), target);
}
// optional int32 num_axes = 3 [default = -1];
if (has_num_axes()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(3, this->num_axes(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.ReshapeParameter)
return target;
}
size_t ReshapeParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.ReshapeParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 7u) {
// optional .opencv_caffe.BlobShape shape = 1;
if (has_shape()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->shape_);
}
// optional int32 axis = 2 [default = 0];
if (has_axis()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->axis());
}
// optional int32 num_axes = 3 [default = -1];
if (has_num_axes()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->num_axes());
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void ReshapeParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.ReshapeParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const ReshapeParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const ReshapeParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.ReshapeParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.ReshapeParameter)
UnsafeMergeFrom(*source);
}
}
void ReshapeParameter::MergeFrom(const ReshapeParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.ReshapeParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void ReshapeParameter::UnsafeMergeFrom(const ReshapeParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_shape()) {
mutable_shape()->::opencv_caffe::BlobShape::MergeFrom(from.shape());
}
if (from.has_axis()) {
set_axis(from.axis());
}
if (from.has_num_axes()) {
set_num_axes(from.num_axes());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void ReshapeParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.ReshapeParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void ReshapeParameter::CopyFrom(const ReshapeParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.ReshapeParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool ReshapeParameter::IsInitialized() const {
return true;
}
void ReshapeParameter::Swap(ReshapeParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void ReshapeParameter::InternalSwap(ReshapeParameter* other) {
std::swap(shape_, other->shape_);
std::swap(axis_, other->axis_);
std::swap(num_axes_, other->num_axes_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata ReshapeParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = ReshapeParameter_descriptor_;
metadata.reflection = ReshapeParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// ReshapeParameter
// optional .opencv_caffe.BlobShape shape = 1;
bool ReshapeParameter::has_shape() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void ReshapeParameter::set_has_shape() {
_has_bits_[0] |= 0x00000001u;
}
void ReshapeParameter::clear_has_shape() {
_has_bits_[0] &= ~0x00000001u;
}
void ReshapeParameter::clear_shape() {
if (shape_ != NULL) shape_->::opencv_caffe::BlobShape::Clear();
clear_has_shape();
}
const ::opencv_caffe::BlobShape& ReshapeParameter::shape() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ReshapeParameter.shape)
return shape_ != NULL ? *shape_
: *::opencv_caffe::BlobShape::internal_default_instance();
}
::opencv_caffe::BlobShape* ReshapeParameter::mutable_shape() {
set_has_shape();
if (shape_ == NULL) {
shape_ = new ::opencv_caffe::BlobShape;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.ReshapeParameter.shape)
return shape_;
}
::opencv_caffe::BlobShape* ReshapeParameter::release_shape() {
// @@protoc_insertion_point(field_release:opencv_caffe.ReshapeParameter.shape)
clear_has_shape();
::opencv_caffe::BlobShape* temp = shape_;
shape_ = NULL;
return temp;
}
void ReshapeParameter::set_allocated_shape(::opencv_caffe::BlobShape* shape) {
delete shape_;
shape_ = shape;
if (shape) {
set_has_shape();
} else {
clear_has_shape();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.ReshapeParameter.shape)
}
// optional int32 axis = 2 [default = 0];
bool ReshapeParameter::has_axis() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void ReshapeParameter::set_has_axis() {
_has_bits_[0] |= 0x00000002u;
}
void ReshapeParameter::clear_has_axis() {
_has_bits_[0] &= ~0x00000002u;
}
void ReshapeParameter::clear_axis() {
axis_ = 0;
clear_has_axis();
}
::google::protobuf::int32 ReshapeParameter::axis() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ReshapeParameter.axis)
return axis_;
}
void ReshapeParameter::set_axis(::google::protobuf::int32 value) {
set_has_axis();
axis_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ReshapeParameter.axis)
}
// optional int32 num_axes = 3 [default = -1];
bool ReshapeParameter::has_num_axes() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void ReshapeParameter::set_has_num_axes() {
_has_bits_[0] |= 0x00000004u;
}
void ReshapeParameter::clear_has_num_axes() {
_has_bits_[0] &= ~0x00000004u;
}
void ReshapeParameter::clear_num_axes() {
num_axes_ = -1;
clear_has_num_axes();
}
::google::protobuf::int32 ReshapeParameter::num_axes() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ReshapeParameter.num_axes)
return num_axes_;
}
void ReshapeParameter::set_num_axes(::google::protobuf::int32 value) {
set_has_num_axes();
num_axes_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ReshapeParameter.num_axes)
}
inline const ReshapeParameter* ReshapeParameter::internal_default_instance() {
return &ReshapeParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int ScaleParameter::kAxisFieldNumber;
const int ScaleParameter::kNumAxesFieldNumber;
const int ScaleParameter::kFillerFieldNumber;
const int ScaleParameter::kBiasTermFieldNumber;
const int ScaleParameter::kBiasFillerFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
ScaleParameter::ScaleParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.ScaleParameter)
}
void ScaleParameter::InitAsDefaultInstance() {
filler_ = const_cast< ::opencv_caffe::FillerParameter*>(
::opencv_caffe::FillerParameter::internal_default_instance());
bias_filler_ = const_cast< ::opencv_caffe::FillerParameter*>(
::opencv_caffe::FillerParameter::internal_default_instance());
}
ScaleParameter::ScaleParameter(const ScaleParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.ScaleParameter)
}
void ScaleParameter::SharedCtor() {
_cached_size_ = 0;
filler_ = NULL;
bias_filler_ = NULL;
bias_term_ = false;
axis_ = 1;
num_axes_ = 1;
}
ScaleParameter::~ScaleParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.ScaleParameter)
SharedDtor();
}
void ScaleParameter::SharedDtor() {
if (this != &ScaleParameter_default_instance_.get()) {
delete filler_;
delete bias_filler_;
}
}
void ScaleParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* ScaleParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return ScaleParameter_descriptor_;
}
const ScaleParameter& ScaleParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<ScaleParameter> ScaleParameter_default_instance_;
ScaleParameter* ScaleParameter::New(::google::protobuf::Arena* arena) const {
ScaleParameter* n = new ScaleParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void ScaleParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.ScaleParameter)
if (_has_bits_[0 / 32] & 31u) {
axis_ = 1;
num_axes_ = 1;
if (has_filler()) {
if (filler_ != NULL) filler_->::opencv_caffe::FillerParameter::Clear();
}
bias_term_ = false;
if (has_bias_filler()) {
if (bias_filler_ != NULL) bias_filler_->::opencv_caffe::FillerParameter::Clear();
}
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool ScaleParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.ScaleParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional int32 axis = 1 [default = 1];
case 1: {
if (tag == 8) {
set_has_axis();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &axis_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_num_axes;
break;
}
// optional int32 num_axes = 2 [default = 1];
case 2: {
if (tag == 16) {
parse_num_axes:
set_has_num_axes();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &num_axes_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(26)) goto parse_filler;
break;
}
// optional .opencv_caffe.FillerParameter filler = 3;
case 3: {
if (tag == 26) {
parse_filler:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_filler()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(32)) goto parse_bias_term;
break;
}
// optional bool bias_term = 4 [default = false];
case 4: {
if (tag == 32) {
parse_bias_term:
set_has_bias_term();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &bias_term_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(42)) goto parse_bias_filler;
break;
}
// optional .opencv_caffe.FillerParameter bias_filler = 5;
case 5: {
if (tag == 42) {
parse_bias_filler:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_bias_filler()));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.ScaleParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.ScaleParameter)
return false;
#undef DO_
}
void ScaleParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.ScaleParameter)
// optional int32 axis = 1 [default = 1];
if (has_axis()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(1, this->axis(), output);
}
// optional int32 num_axes = 2 [default = 1];
if (has_num_axes()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->num_axes(), output);
}
// optional .opencv_caffe.FillerParameter filler = 3;
if (has_filler()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
3, *this->filler_, output);
}
// optional bool bias_term = 4 [default = false];
if (has_bias_term()) {
::google::protobuf::internal::WireFormatLite::WriteBool(4, this->bias_term(), output);
}
// optional .opencv_caffe.FillerParameter bias_filler = 5;
if (has_bias_filler()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
5, *this->bias_filler_, output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.ScaleParameter)
}
::google::protobuf::uint8* ScaleParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.ScaleParameter)
// optional int32 axis = 1 [default = 1];
if (has_axis()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(1, this->axis(), target);
}
// optional int32 num_axes = 2 [default = 1];
if (has_num_axes()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(2, this->num_axes(), target);
}
// optional .opencv_caffe.FillerParameter filler = 3;
if (has_filler()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
3, *this->filler_, false, target);
}
// optional bool bias_term = 4 [default = false];
if (has_bias_term()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(4, this->bias_term(), target);
}
// optional .opencv_caffe.FillerParameter bias_filler = 5;
if (has_bias_filler()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
5, *this->bias_filler_, false, target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.ScaleParameter)
return target;
}
size_t ScaleParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.ScaleParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 31u) {
// optional int32 axis = 1 [default = 1];
if (has_axis()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->axis());
}
// optional int32 num_axes = 2 [default = 1];
if (has_num_axes()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->num_axes());
}
// optional .opencv_caffe.FillerParameter filler = 3;
if (has_filler()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->filler_);
}
// optional bool bias_term = 4 [default = false];
if (has_bias_term()) {
total_size += 1 + 1;
}
// optional .opencv_caffe.FillerParameter bias_filler = 5;
if (has_bias_filler()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->bias_filler_);
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void ScaleParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.ScaleParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const ScaleParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const ScaleParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.ScaleParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.ScaleParameter)
UnsafeMergeFrom(*source);
}
}
void ScaleParameter::MergeFrom(const ScaleParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.ScaleParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void ScaleParameter::UnsafeMergeFrom(const ScaleParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_axis()) {
set_axis(from.axis());
}
if (from.has_num_axes()) {
set_num_axes(from.num_axes());
}
if (from.has_filler()) {
mutable_filler()->::opencv_caffe::FillerParameter::MergeFrom(from.filler());
}
if (from.has_bias_term()) {
set_bias_term(from.bias_term());
}
if (from.has_bias_filler()) {
mutable_bias_filler()->::opencv_caffe::FillerParameter::MergeFrom(from.bias_filler());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void ScaleParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.ScaleParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void ScaleParameter::CopyFrom(const ScaleParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.ScaleParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool ScaleParameter::IsInitialized() const {
return true;
}
void ScaleParameter::Swap(ScaleParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void ScaleParameter::InternalSwap(ScaleParameter* other) {
std::swap(axis_, other->axis_);
std::swap(num_axes_, other->num_axes_);
std::swap(filler_, other->filler_);
std::swap(bias_term_, other->bias_term_);
std::swap(bias_filler_, other->bias_filler_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata ScaleParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = ScaleParameter_descriptor_;
metadata.reflection = ScaleParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// ScaleParameter
// optional int32 axis = 1 [default = 1];
bool ScaleParameter::has_axis() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void ScaleParameter::set_has_axis() {
_has_bits_[0] |= 0x00000001u;
}
void ScaleParameter::clear_has_axis() {
_has_bits_[0] &= ~0x00000001u;
}
void ScaleParameter::clear_axis() {
axis_ = 1;
clear_has_axis();
}
::google::protobuf::int32 ScaleParameter::axis() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ScaleParameter.axis)
return axis_;
}
void ScaleParameter::set_axis(::google::protobuf::int32 value) {
set_has_axis();
axis_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ScaleParameter.axis)
}
// optional int32 num_axes = 2 [default = 1];
bool ScaleParameter::has_num_axes() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void ScaleParameter::set_has_num_axes() {
_has_bits_[0] |= 0x00000002u;
}
void ScaleParameter::clear_has_num_axes() {
_has_bits_[0] &= ~0x00000002u;
}
void ScaleParameter::clear_num_axes() {
num_axes_ = 1;
clear_has_num_axes();
}
::google::protobuf::int32 ScaleParameter::num_axes() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ScaleParameter.num_axes)
return num_axes_;
}
void ScaleParameter::set_num_axes(::google::protobuf::int32 value) {
set_has_num_axes();
num_axes_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ScaleParameter.num_axes)
}
// optional .opencv_caffe.FillerParameter filler = 3;
bool ScaleParameter::has_filler() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void ScaleParameter::set_has_filler() {
_has_bits_[0] |= 0x00000004u;
}
void ScaleParameter::clear_has_filler() {
_has_bits_[0] &= ~0x00000004u;
}
void ScaleParameter::clear_filler() {
if (filler_ != NULL) filler_->::opencv_caffe::FillerParameter::Clear();
clear_has_filler();
}
const ::opencv_caffe::FillerParameter& ScaleParameter::filler() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ScaleParameter.filler)
return filler_ != NULL ? *filler_
: *::opencv_caffe::FillerParameter::internal_default_instance();
}
::opencv_caffe::FillerParameter* ScaleParameter::mutable_filler() {
set_has_filler();
if (filler_ == NULL) {
filler_ = new ::opencv_caffe::FillerParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.ScaleParameter.filler)
return filler_;
}
::opencv_caffe::FillerParameter* ScaleParameter::release_filler() {
// @@protoc_insertion_point(field_release:opencv_caffe.ScaleParameter.filler)
clear_has_filler();
::opencv_caffe::FillerParameter* temp = filler_;
filler_ = NULL;
return temp;
}
void ScaleParameter::set_allocated_filler(::opencv_caffe::FillerParameter* filler) {
delete filler_;
filler_ = filler;
if (filler) {
set_has_filler();
} else {
clear_has_filler();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.ScaleParameter.filler)
}
// optional bool bias_term = 4 [default = false];
bool ScaleParameter::has_bias_term() const {
return (_has_bits_[0] & 0x00000008u) != 0;
}
void ScaleParameter::set_has_bias_term() {
_has_bits_[0] |= 0x00000008u;
}
void ScaleParameter::clear_has_bias_term() {
_has_bits_[0] &= ~0x00000008u;
}
void ScaleParameter::clear_bias_term() {
bias_term_ = false;
clear_has_bias_term();
}
bool ScaleParameter::bias_term() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ScaleParameter.bias_term)
return bias_term_;
}
void ScaleParameter::set_bias_term(bool value) {
set_has_bias_term();
bias_term_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ScaleParameter.bias_term)
}
// optional .opencv_caffe.FillerParameter bias_filler = 5;
bool ScaleParameter::has_bias_filler() const {
return (_has_bits_[0] & 0x00000010u) != 0;
}
void ScaleParameter::set_has_bias_filler() {
_has_bits_[0] |= 0x00000010u;
}
void ScaleParameter::clear_has_bias_filler() {
_has_bits_[0] &= ~0x00000010u;
}
void ScaleParameter::clear_bias_filler() {
if (bias_filler_ != NULL) bias_filler_->::opencv_caffe::FillerParameter::Clear();
clear_has_bias_filler();
}
const ::opencv_caffe::FillerParameter& ScaleParameter::bias_filler() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ScaleParameter.bias_filler)
return bias_filler_ != NULL ? *bias_filler_
: *::opencv_caffe::FillerParameter::internal_default_instance();
}
::opencv_caffe::FillerParameter* ScaleParameter::mutable_bias_filler() {
set_has_bias_filler();
if (bias_filler_ == NULL) {
bias_filler_ = new ::opencv_caffe::FillerParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.ScaleParameter.bias_filler)
return bias_filler_;
}
::opencv_caffe::FillerParameter* ScaleParameter::release_bias_filler() {
// @@protoc_insertion_point(field_release:opencv_caffe.ScaleParameter.bias_filler)
clear_has_bias_filler();
::opencv_caffe::FillerParameter* temp = bias_filler_;
bias_filler_ = NULL;
return temp;
}
void ScaleParameter::set_allocated_bias_filler(::opencv_caffe::FillerParameter* bias_filler) {
delete bias_filler_;
bias_filler_ = bias_filler;
if (bias_filler) {
set_has_bias_filler();
} else {
clear_has_bias_filler();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.ScaleParameter.bias_filler)
}
inline const ScaleParameter* ScaleParameter::internal_default_instance() {
return &ScaleParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
const ::google::protobuf::EnumDescriptor* SigmoidParameter_Engine_descriptor() {
protobuf_AssignDescriptorsOnce();
return SigmoidParameter_Engine_descriptor_;
}
bool SigmoidParameter_Engine_IsValid(int value) {
switch (value) {
case 0:
case 1:
case 2:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const SigmoidParameter_Engine SigmoidParameter::DEFAULT;
const SigmoidParameter_Engine SigmoidParameter::CAFFE;
const SigmoidParameter_Engine SigmoidParameter::CUDNN;
const SigmoidParameter_Engine SigmoidParameter::Engine_MIN;
const SigmoidParameter_Engine SigmoidParameter::Engine_MAX;
const int SigmoidParameter::Engine_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int SigmoidParameter::kEngineFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
SigmoidParameter::SigmoidParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.SigmoidParameter)
}
void SigmoidParameter::InitAsDefaultInstance() {
}
SigmoidParameter::SigmoidParameter(const SigmoidParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.SigmoidParameter)
}
void SigmoidParameter::SharedCtor() {
_cached_size_ = 0;
engine_ = 0;
}
SigmoidParameter::~SigmoidParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.SigmoidParameter)
SharedDtor();
}
void SigmoidParameter::SharedDtor() {
}
void SigmoidParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* SigmoidParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return SigmoidParameter_descriptor_;
}
const SigmoidParameter& SigmoidParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<SigmoidParameter> SigmoidParameter_default_instance_;
SigmoidParameter* SigmoidParameter::New(::google::protobuf::Arena* arena) const {
SigmoidParameter* n = new SigmoidParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void SigmoidParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.SigmoidParameter)
engine_ = 0;
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool SigmoidParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.SigmoidParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional .opencv_caffe.SigmoidParameter.Engine engine = 1 [default = DEFAULT];
case 1: {
if (tag == 8) {
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::SigmoidParameter_Engine_IsValid(value)) {
set_engine(static_cast< ::opencv_caffe::SigmoidParameter_Engine >(value));
} else {
mutable_unknown_fields()->AddVarint(1, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.SigmoidParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.SigmoidParameter)
return false;
#undef DO_
}
void SigmoidParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.SigmoidParameter)
// optional .opencv_caffe.SigmoidParameter.Engine engine = 1 [default = DEFAULT];
if (has_engine()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
1, this->engine(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.SigmoidParameter)
}
::google::protobuf::uint8* SigmoidParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.SigmoidParameter)
// optional .opencv_caffe.SigmoidParameter.Engine engine = 1 [default = DEFAULT];
if (has_engine()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
1, this->engine(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.SigmoidParameter)
return target;
}
size_t SigmoidParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.SigmoidParameter)
size_t total_size = 0;
// optional .opencv_caffe.SigmoidParameter.Engine engine = 1 [default = DEFAULT];
if (has_engine()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->engine());
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void SigmoidParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.SigmoidParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const SigmoidParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const SigmoidParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.SigmoidParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.SigmoidParameter)
UnsafeMergeFrom(*source);
}
}
void SigmoidParameter::MergeFrom(const SigmoidParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.SigmoidParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void SigmoidParameter::UnsafeMergeFrom(const SigmoidParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_engine()) {
set_engine(from.engine());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void SigmoidParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.SigmoidParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void SigmoidParameter::CopyFrom(const SigmoidParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.SigmoidParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool SigmoidParameter::IsInitialized() const {
return true;
}
void SigmoidParameter::Swap(SigmoidParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void SigmoidParameter::InternalSwap(SigmoidParameter* other) {
std::swap(engine_, other->engine_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata SigmoidParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = SigmoidParameter_descriptor_;
metadata.reflection = SigmoidParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// SigmoidParameter
// optional .opencv_caffe.SigmoidParameter.Engine engine = 1 [default = DEFAULT];
bool SigmoidParameter::has_engine() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void SigmoidParameter::set_has_engine() {
_has_bits_[0] |= 0x00000001u;
}
void SigmoidParameter::clear_has_engine() {
_has_bits_[0] &= ~0x00000001u;
}
void SigmoidParameter::clear_engine() {
engine_ = 0;
clear_has_engine();
}
::opencv_caffe::SigmoidParameter_Engine SigmoidParameter::engine() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SigmoidParameter.engine)
return static_cast< ::opencv_caffe::SigmoidParameter_Engine >(engine_);
}
void SigmoidParameter::set_engine(::opencv_caffe::SigmoidParameter_Engine value) {
assert(::opencv_caffe::SigmoidParameter_Engine_IsValid(value));
set_has_engine();
engine_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SigmoidParameter.engine)
}
inline const SigmoidParameter* SigmoidParameter::internal_default_instance() {
return &SigmoidParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int SliceParameter::kAxisFieldNumber;
const int SliceParameter::kSlicePointFieldNumber;
const int SliceParameter::kSliceDimFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
SliceParameter::SliceParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.SliceParameter)
}
void SliceParameter::InitAsDefaultInstance() {
}
SliceParameter::SliceParameter(const SliceParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.SliceParameter)
}
void SliceParameter::SharedCtor() {
_cached_size_ = 0;
axis_ = 1;
slice_dim_ = 1u;
}
SliceParameter::~SliceParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.SliceParameter)
SharedDtor();
}
void SliceParameter::SharedDtor() {
}
void SliceParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* SliceParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return SliceParameter_descriptor_;
}
const SliceParameter& SliceParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<SliceParameter> SliceParameter_default_instance_;
SliceParameter* SliceParameter::New(::google::protobuf::Arena* arena) const {
SliceParameter* n = new SliceParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void SliceParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.SliceParameter)
if (_has_bits_[0 / 32] & 5u) {
axis_ = 1;
slice_dim_ = 1u;
}
slice_point_.Clear();
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool SliceParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.SliceParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional uint32 slice_dim = 1 [default = 1];
case 1: {
if (tag == 8) {
set_has_slice_dim();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &slice_dim_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_slice_point;
break;
}
// repeated uint32 slice_point = 2;
case 2: {
if (tag == 16) {
parse_slice_point:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
1, 16, input, this->mutable_slice_point())));
} else if (tag == 18) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, this->mutable_slice_point())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_slice_point;
if (input->ExpectTag(24)) goto parse_axis;
break;
}
// optional int32 axis = 3 [default = 1];
case 3: {
if (tag == 24) {
parse_axis:
set_has_axis();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &axis_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.SliceParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.SliceParameter)
return false;
#undef DO_
}
void SliceParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.SliceParameter)
// optional uint32 slice_dim = 1 [default = 1];
if (has_slice_dim()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(1, this->slice_dim(), output);
}
// repeated uint32 slice_point = 2;
for (int i = 0; i < this->slice_point_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(
2, this->slice_point(i), output);
}
// optional int32 axis = 3 [default = 1];
if (has_axis()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(3, this->axis(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.SliceParameter)
}
::google::protobuf::uint8* SliceParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.SliceParameter)
// optional uint32 slice_dim = 1 [default = 1];
if (has_slice_dim()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(1, this->slice_dim(), target);
}
// repeated uint32 slice_point = 2;
for (int i = 0; i < this->slice_point_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteUInt32ToArray(2, this->slice_point(i), target);
}
// optional int32 axis = 3 [default = 1];
if (has_axis()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(3, this->axis(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.SliceParameter)
return target;
}
size_t SliceParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.SliceParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 5u) {
// optional int32 axis = 3 [default = 1];
if (has_axis()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->axis());
}
// optional uint32 slice_dim = 1 [default = 1];
if (has_slice_dim()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->slice_dim());
}
}
// repeated uint32 slice_point = 2;
{
size_t data_size = 0;
unsigned int count = this->slice_point_size();
for (unsigned int i = 0; i < count; i++) {
data_size += ::google::protobuf::internal::WireFormatLite::
UInt32Size(this->slice_point(i));
}
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->slice_point_size());
total_size += data_size;
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void SliceParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.SliceParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const SliceParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const SliceParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.SliceParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.SliceParameter)
UnsafeMergeFrom(*source);
}
}
void SliceParameter::MergeFrom(const SliceParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.SliceParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void SliceParameter::UnsafeMergeFrom(const SliceParameter& from) {
GOOGLE_DCHECK(&from != this);
slice_point_.UnsafeMergeFrom(from.slice_point_);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_axis()) {
set_axis(from.axis());
}
if (from.has_slice_dim()) {
set_slice_dim(from.slice_dim());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void SliceParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.SliceParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void SliceParameter::CopyFrom(const SliceParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.SliceParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool SliceParameter::IsInitialized() const {
return true;
}
void SliceParameter::Swap(SliceParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void SliceParameter::InternalSwap(SliceParameter* other) {
std::swap(axis_, other->axis_);
slice_point_.UnsafeArenaSwap(&other->slice_point_);
std::swap(slice_dim_, other->slice_dim_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata SliceParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = SliceParameter_descriptor_;
metadata.reflection = SliceParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// SliceParameter
// optional int32 axis = 3 [default = 1];
bool SliceParameter::has_axis() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void SliceParameter::set_has_axis() {
_has_bits_[0] |= 0x00000001u;
}
void SliceParameter::clear_has_axis() {
_has_bits_[0] &= ~0x00000001u;
}
void SliceParameter::clear_axis() {
axis_ = 1;
clear_has_axis();
}
::google::protobuf::int32 SliceParameter::axis() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SliceParameter.axis)
return axis_;
}
void SliceParameter::set_axis(::google::protobuf::int32 value) {
set_has_axis();
axis_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SliceParameter.axis)
}
// repeated uint32 slice_point = 2;
int SliceParameter::slice_point_size() const {
return slice_point_.size();
}
void SliceParameter::clear_slice_point() {
slice_point_.Clear();
}
::google::protobuf::uint32 SliceParameter::slice_point(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.SliceParameter.slice_point)
return slice_point_.Get(index);
}
void SliceParameter::set_slice_point(int index, ::google::protobuf::uint32 value) {
slice_point_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.SliceParameter.slice_point)
}
void SliceParameter::add_slice_point(::google::protobuf::uint32 value) {
slice_point_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.SliceParameter.slice_point)
}
const ::google::protobuf::RepeatedField< ::google::protobuf::uint32 >&
SliceParameter::slice_point() const {
// @@protoc_insertion_point(field_list:opencv_caffe.SliceParameter.slice_point)
return slice_point_;
}
::google::protobuf::RepeatedField< ::google::protobuf::uint32 >*
SliceParameter::mutable_slice_point() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.SliceParameter.slice_point)
return &slice_point_;
}
// optional uint32 slice_dim = 1 [default = 1];
bool SliceParameter::has_slice_dim() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void SliceParameter::set_has_slice_dim() {
_has_bits_[0] |= 0x00000004u;
}
void SliceParameter::clear_has_slice_dim() {
_has_bits_[0] &= ~0x00000004u;
}
void SliceParameter::clear_slice_dim() {
slice_dim_ = 1u;
clear_has_slice_dim();
}
::google::protobuf::uint32 SliceParameter::slice_dim() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SliceParameter.slice_dim)
return slice_dim_;
}
void SliceParameter::set_slice_dim(::google::protobuf::uint32 value) {
set_has_slice_dim();
slice_dim_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SliceParameter.slice_dim)
}
inline const SliceParameter* SliceParameter::internal_default_instance() {
return &SliceParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
const ::google::protobuf::EnumDescriptor* SoftmaxParameter_Engine_descriptor() {
protobuf_AssignDescriptorsOnce();
return SoftmaxParameter_Engine_descriptor_;
}
bool SoftmaxParameter_Engine_IsValid(int value) {
switch (value) {
case 0:
case 1:
case 2:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const SoftmaxParameter_Engine SoftmaxParameter::DEFAULT;
const SoftmaxParameter_Engine SoftmaxParameter::CAFFE;
const SoftmaxParameter_Engine SoftmaxParameter::CUDNN;
const SoftmaxParameter_Engine SoftmaxParameter::Engine_MIN;
const SoftmaxParameter_Engine SoftmaxParameter::Engine_MAX;
const int SoftmaxParameter::Engine_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int SoftmaxParameter::kEngineFieldNumber;
const int SoftmaxParameter::kAxisFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
SoftmaxParameter::SoftmaxParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.SoftmaxParameter)
}
void SoftmaxParameter::InitAsDefaultInstance() {
}
SoftmaxParameter::SoftmaxParameter(const SoftmaxParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.SoftmaxParameter)
}
void SoftmaxParameter::SharedCtor() {
_cached_size_ = 0;
engine_ = 0;
axis_ = 1;
}
SoftmaxParameter::~SoftmaxParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.SoftmaxParameter)
SharedDtor();
}
void SoftmaxParameter::SharedDtor() {
}
void SoftmaxParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* SoftmaxParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return SoftmaxParameter_descriptor_;
}
const SoftmaxParameter& SoftmaxParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<SoftmaxParameter> SoftmaxParameter_default_instance_;
SoftmaxParameter* SoftmaxParameter::New(::google::protobuf::Arena* arena) const {
SoftmaxParameter* n = new SoftmaxParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void SoftmaxParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.SoftmaxParameter)
if (_has_bits_[0 / 32] & 3u) {
engine_ = 0;
axis_ = 1;
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool SoftmaxParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.SoftmaxParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional .opencv_caffe.SoftmaxParameter.Engine engine = 1 [default = DEFAULT];
case 1: {
if (tag == 8) {
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::SoftmaxParameter_Engine_IsValid(value)) {
set_engine(static_cast< ::opencv_caffe::SoftmaxParameter_Engine >(value));
} else {
mutable_unknown_fields()->AddVarint(1, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_axis;
break;
}
// optional int32 axis = 2 [default = 1];
case 2: {
if (tag == 16) {
parse_axis:
set_has_axis();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &axis_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.SoftmaxParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.SoftmaxParameter)
return false;
#undef DO_
}
void SoftmaxParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.SoftmaxParameter)
// optional .opencv_caffe.SoftmaxParameter.Engine engine = 1 [default = DEFAULT];
if (has_engine()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
1, this->engine(), output);
}
// optional int32 axis = 2 [default = 1];
if (has_axis()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->axis(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.SoftmaxParameter)
}
::google::protobuf::uint8* SoftmaxParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.SoftmaxParameter)
// optional .opencv_caffe.SoftmaxParameter.Engine engine = 1 [default = DEFAULT];
if (has_engine()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
1, this->engine(), target);
}
// optional int32 axis = 2 [default = 1];
if (has_axis()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(2, this->axis(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.SoftmaxParameter)
return target;
}
size_t SoftmaxParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.SoftmaxParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 3u) {
// optional .opencv_caffe.SoftmaxParameter.Engine engine = 1 [default = DEFAULT];
if (has_engine()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->engine());
}
// optional int32 axis = 2 [default = 1];
if (has_axis()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->axis());
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void SoftmaxParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.SoftmaxParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const SoftmaxParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const SoftmaxParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.SoftmaxParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.SoftmaxParameter)
UnsafeMergeFrom(*source);
}
}
void SoftmaxParameter::MergeFrom(const SoftmaxParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.SoftmaxParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void SoftmaxParameter::UnsafeMergeFrom(const SoftmaxParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_engine()) {
set_engine(from.engine());
}
if (from.has_axis()) {
set_axis(from.axis());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void SoftmaxParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.SoftmaxParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void SoftmaxParameter::CopyFrom(const SoftmaxParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.SoftmaxParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool SoftmaxParameter::IsInitialized() const {
return true;
}
void SoftmaxParameter::Swap(SoftmaxParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void SoftmaxParameter::InternalSwap(SoftmaxParameter* other) {
std::swap(engine_, other->engine_);
std::swap(axis_, other->axis_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata SoftmaxParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = SoftmaxParameter_descriptor_;
metadata.reflection = SoftmaxParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// SoftmaxParameter
// optional .opencv_caffe.SoftmaxParameter.Engine engine = 1 [default = DEFAULT];
bool SoftmaxParameter::has_engine() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void SoftmaxParameter::set_has_engine() {
_has_bits_[0] |= 0x00000001u;
}
void SoftmaxParameter::clear_has_engine() {
_has_bits_[0] &= ~0x00000001u;
}
void SoftmaxParameter::clear_engine() {
engine_ = 0;
clear_has_engine();
}
::opencv_caffe::SoftmaxParameter_Engine SoftmaxParameter::engine() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SoftmaxParameter.engine)
return static_cast< ::opencv_caffe::SoftmaxParameter_Engine >(engine_);
}
void SoftmaxParameter::set_engine(::opencv_caffe::SoftmaxParameter_Engine value) {
assert(::opencv_caffe::SoftmaxParameter_Engine_IsValid(value));
set_has_engine();
engine_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SoftmaxParameter.engine)
}
// optional int32 axis = 2 [default = 1];
bool SoftmaxParameter::has_axis() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void SoftmaxParameter::set_has_axis() {
_has_bits_[0] |= 0x00000002u;
}
void SoftmaxParameter::clear_has_axis() {
_has_bits_[0] &= ~0x00000002u;
}
void SoftmaxParameter::clear_axis() {
axis_ = 1;
clear_has_axis();
}
::google::protobuf::int32 SoftmaxParameter::axis() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SoftmaxParameter.axis)
return axis_;
}
void SoftmaxParameter::set_axis(::google::protobuf::int32 value) {
set_has_axis();
axis_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SoftmaxParameter.axis)
}
inline const SoftmaxParameter* SoftmaxParameter::internal_default_instance() {
return &SoftmaxParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
const ::google::protobuf::EnumDescriptor* TanHParameter_Engine_descriptor() {
protobuf_AssignDescriptorsOnce();
return TanHParameter_Engine_descriptor_;
}
bool TanHParameter_Engine_IsValid(int value) {
switch (value) {
case 0:
case 1:
case 2:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const TanHParameter_Engine TanHParameter::DEFAULT;
const TanHParameter_Engine TanHParameter::CAFFE;
const TanHParameter_Engine TanHParameter::CUDNN;
const TanHParameter_Engine TanHParameter::Engine_MIN;
const TanHParameter_Engine TanHParameter::Engine_MAX;
const int TanHParameter::Engine_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int TanHParameter::kEngineFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
TanHParameter::TanHParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.TanHParameter)
}
void TanHParameter::InitAsDefaultInstance() {
}
TanHParameter::TanHParameter(const TanHParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.TanHParameter)
}
void TanHParameter::SharedCtor() {
_cached_size_ = 0;
engine_ = 0;
}
TanHParameter::~TanHParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.TanHParameter)
SharedDtor();
}
void TanHParameter::SharedDtor() {
}
void TanHParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* TanHParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return TanHParameter_descriptor_;
}
const TanHParameter& TanHParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<TanHParameter> TanHParameter_default_instance_;
TanHParameter* TanHParameter::New(::google::protobuf::Arena* arena) const {
TanHParameter* n = new TanHParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void TanHParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.TanHParameter)
engine_ = 0;
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool TanHParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.TanHParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional .opencv_caffe.TanHParameter.Engine engine = 1 [default = DEFAULT];
case 1: {
if (tag == 8) {
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::TanHParameter_Engine_IsValid(value)) {
set_engine(static_cast< ::opencv_caffe::TanHParameter_Engine >(value));
} else {
mutable_unknown_fields()->AddVarint(1, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.TanHParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.TanHParameter)
return false;
#undef DO_
}
void TanHParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.TanHParameter)
// optional .opencv_caffe.TanHParameter.Engine engine = 1 [default = DEFAULT];
if (has_engine()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
1, this->engine(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.TanHParameter)
}
::google::protobuf::uint8* TanHParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.TanHParameter)
// optional .opencv_caffe.TanHParameter.Engine engine = 1 [default = DEFAULT];
if (has_engine()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
1, this->engine(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.TanHParameter)
return target;
}
size_t TanHParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.TanHParameter)
size_t total_size = 0;
// optional .opencv_caffe.TanHParameter.Engine engine = 1 [default = DEFAULT];
if (has_engine()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->engine());
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void TanHParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.TanHParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const TanHParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const TanHParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.TanHParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.TanHParameter)
UnsafeMergeFrom(*source);
}
}
void TanHParameter::MergeFrom(const TanHParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.TanHParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void TanHParameter::UnsafeMergeFrom(const TanHParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_engine()) {
set_engine(from.engine());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void TanHParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.TanHParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void TanHParameter::CopyFrom(const TanHParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.TanHParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool TanHParameter::IsInitialized() const {
return true;
}
void TanHParameter::Swap(TanHParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void TanHParameter::InternalSwap(TanHParameter* other) {
std::swap(engine_, other->engine_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata TanHParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = TanHParameter_descriptor_;
metadata.reflection = TanHParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// TanHParameter
// optional .opencv_caffe.TanHParameter.Engine engine = 1 [default = DEFAULT];
bool TanHParameter::has_engine() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void TanHParameter::set_has_engine() {
_has_bits_[0] |= 0x00000001u;
}
void TanHParameter::clear_has_engine() {
_has_bits_[0] &= ~0x00000001u;
}
void TanHParameter::clear_engine() {
engine_ = 0;
clear_has_engine();
}
::opencv_caffe::TanHParameter_Engine TanHParameter::engine() const {
// @@protoc_insertion_point(field_get:opencv_caffe.TanHParameter.engine)
return static_cast< ::opencv_caffe::TanHParameter_Engine >(engine_);
}
void TanHParameter::set_engine(::opencv_caffe::TanHParameter_Engine value) {
assert(::opencv_caffe::TanHParameter_Engine_IsValid(value));
set_has_engine();
engine_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.TanHParameter.engine)
}
inline const TanHParameter* TanHParameter::internal_default_instance() {
return &TanHParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int TileParameter::kAxisFieldNumber;
const int TileParameter::kTilesFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
TileParameter::TileParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.TileParameter)
}
void TileParameter::InitAsDefaultInstance() {
}
TileParameter::TileParameter(const TileParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.TileParameter)
}
void TileParameter::SharedCtor() {
_cached_size_ = 0;
tiles_ = 0;
axis_ = 1;
}
TileParameter::~TileParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.TileParameter)
SharedDtor();
}
void TileParameter::SharedDtor() {
}
void TileParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* TileParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return TileParameter_descriptor_;
}
const TileParameter& TileParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<TileParameter> TileParameter_default_instance_;
TileParameter* TileParameter::New(::google::protobuf::Arena* arena) const {
TileParameter* n = new TileParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void TileParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.TileParameter)
if (_has_bits_[0 / 32] & 3u) {
axis_ = 1;
tiles_ = 0;
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool TileParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.TileParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional int32 axis = 1 [default = 1];
case 1: {
if (tag == 8) {
set_has_axis();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &axis_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_tiles;
break;
}
// optional int32 tiles = 2;
case 2: {
if (tag == 16) {
parse_tiles:
set_has_tiles();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &tiles_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.TileParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.TileParameter)
return false;
#undef DO_
}
void TileParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.TileParameter)
// optional int32 axis = 1 [default = 1];
if (has_axis()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(1, this->axis(), output);
}
// optional int32 tiles = 2;
if (has_tiles()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->tiles(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.TileParameter)
}
::google::protobuf::uint8* TileParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.TileParameter)
// optional int32 axis = 1 [default = 1];
if (has_axis()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(1, this->axis(), target);
}
// optional int32 tiles = 2;
if (has_tiles()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(2, this->tiles(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.TileParameter)
return target;
}
size_t TileParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.TileParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 3u) {
// optional int32 axis = 1 [default = 1];
if (has_axis()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->axis());
}
// optional int32 tiles = 2;
if (has_tiles()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->tiles());
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void TileParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.TileParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const TileParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const TileParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.TileParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.TileParameter)
UnsafeMergeFrom(*source);
}
}
void TileParameter::MergeFrom(const TileParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.TileParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void TileParameter::UnsafeMergeFrom(const TileParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_axis()) {
set_axis(from.axis());
}
if (from.has_tiles()) {
set_tiles(from.tiles());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void TileParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.TileParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void TileParameter::CopyFrom(const TileParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.TileParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool TileParameter::IsInitialized() const {
return true;
}
void TileParameter::Swap(TileParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void TileParameter::InternalSwap(TileParameter* other) {
std::swap(axis_, other->axis_);
std::swap(tiles_, other->tiles_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata TileParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = TileParameter_descriptor_;
metadata.reflection = TileParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// TileParameter
// optional int32 axis = 1 [default = 1];
bool TileParameter::has_axis() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void TileParameter::set_has_axis() {
_has_bits_[0] |= 0x00000001u;
}
void TileParameter::clear_has_axis() {
_has_bits_[0] &= ~0x00000001u;
}
void TileParameter::clear_axis() {
axis_ = 1;
clear_has_axis();
}
::google::protobuf::int32 TileParameter::axis() const {
// @@protoc_insertion_point(field_get:opencv_caffe.TileParameter.axis)
return axis_;
}
void TileParameter::set_axis(::google::protobuf::int32 value) {
set_has_axis();
axis_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.TileParameter.axis)
}
// optional int32 tiles = 2;
bool TileParameter::has_tiles() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void TileParameter::set_has_tiles() {
_has_bits_[0] |= 0x00000002u;
}
void TileParameter::clear_has_tiles() {
_has_bits_[0] &= ~0x00000002u;
}
void TileParameter::clear_tiles() {
tiles_ = 0;
clear_has_tiles();
}
::google::protobuf::int32 TileParameter::tiles() const {
// @@protoc_insertion_point(field_get:opencv_caffe.TileParameter.tiles)
return tiles_;
}
void TileParameter::set_tiles(::google::protobuf::int32 value) {
set_has_tiles();
tiles_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.TileParameter.tiles)
}
inline const TileParameter* TileParameter::internal_default_instance() {
return &TileParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int ThresholdParameter::kThresholdFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
ThresholdParameter::ThresholdParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.ThresholdParameter)
}
void ThresholdParameter::InitAsDefaultInstance() {
}
ThresholdParameter::ThresholdParameter(const ThresholdParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.ThresholdParameter)
}
void ThresholdParameter::SharedCtor() {
_cached_size_ = 0;
threshold_ = 0;
}
ThresholdParameter::~ThresholdParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.ThresholdParameter)
SharedDtor();
}
void ThresholdParameter::SharedDtor() {
}
void ThresholdParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* ThresholdParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return ThresholdParameter_descriptor_;
}
const ThresholdParameter& ThresholdParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<ThresholdParameter> ThresholdParameter_default_instance_;
ThresholdParameter* ThresholdParameter::New(::google::protobuf::Arena* arena) const {
ThresholdParameter* n = new ThresholdParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void ThresholdParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.ThresholdParameter)
threshold_ = 0;
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool ThresholdParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.ThresholdParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional float threshold = 1 [default = 0];
case 1: {
if (tag == 13) {
set_has_threshold();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &threshold_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.ThresholdParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.ThresholdParameter)
return false;
#undef DO_
}
void ThresholdParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.ThresholdParameter)
// optional float threshold = 1 [default = 0];
if (has_threshold()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(1, this->threshold(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.ThresholdParameter)
}
::google::protobuf::uint8* ThresholdParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.ThresholdParameter)
// optional float threshold = 1 [default = 0];
if (has_threshold()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(1, this->threshold(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.ThresholdParameter)
return target;
}
size_t ThresholdParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.ThresholdParameter)
size_t total_size = 0;
// optional float threshold = 1 [default = 0];
if (has_threshold()) {
total_size += 1 + 4;
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void ThresholdParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.ThresholdParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const ThresholdParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const ThresholdParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.ThresholdParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.ThresholdParameter)
UnsafeMergeFrom(*source);
}
}
void ThresholdParameter::MergeFrom(const ThresholdParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.ThresholdParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void ThresholdParameter::UnsafeMergeFrom(const ThresholdParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_threshold()) {
set_threshold(from.threshold());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void ThresholdParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.ThresholdParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void ThresholdParameter::CopyFrom(const ThresholdParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.ThresholdParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool ThresholdParameter::IsInitialized() const {
return true;
}
void ThresholdParameter::Swap(ThresholdParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void ThresholdParameter::InternalSwap(ThresholdParameter* other) {
std::swap(threshold_, other->threshold_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata ThresholdParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = ThresholdParameter_descriptor_;
metadata.reflection = ThresholdParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// ThresholdParameter
// optional float threshold = 1 [default = 0];
bool ThresholdParameter::has_threshold() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void ThresholdParameter::set_has_threshold() {
_has_bits_[0] |= 0x00000001u;
}
void ThresholdParameter::clear_has_threshold() {
_has_bits_[0] &= ~0x00000001u;
}
void ThresholdParameter::clear_threshold() {
threshold_ = 0;
clear_has_threshold();
}
float ThresholdParameter::threshold() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ThresholdParameter.threshold)
return threshold_;
}
void ThresholdParameter::set_threshold(float value) {
set_has_threshold();
threshold_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ThresholdParameter.threshold)
}
inline const ThresholdParameter* ThresholdParameter::internal_default_instance() {
return &ThresholdParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
::std::string* WindowDataParameter::_default_crop_mode_ = NULL;
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int WindowDataParameter::kSourceFieldNumber;
const int WindowDataParameter::kScaleFieldNumber;
const int WindowDataParameter::kMeanFileFieldNumber;
const int WindowDataParameter::kBatchSizeFieldNumber;
const int WindowDataParameter::kCropSizeFieldNumber;
const int WindowDataParameter::kMirrorFieldNumber;
const int WindowDataParameter::kFgThresholdFieldNumber;
const int WindowDataParameter::kBgThresholdFieldNumber;
const int WindowDataParameter::kFgFractionFieldNumber;
const int WindowDataParameter::kContextPadFieldNumber;
const int WindowDataParameter::kCropModeFieldNumber;
const int WindowDataParameter::kCacheImagesFieldNumber;
const int WindowDataParameter::kRootFolderFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
WindowDataParameter::WindowDataParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.WindowDataParameter)
}
void WindowDataParameter::InitAsDefaultInstance() {
}
WindowDataParameter::WindowDataParameter(const WindowDataParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.WindowDataParameter)
}
void WindowDataParameter::SharedCtor() {
_cached_size_ = 0;
source_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
mean_file_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
crop_mode_.UnsafeSetDefault(_default_crop_mode_);
root_folder_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
::memset(&batch_size_, 0, reinterpret_cast<char*>(&context_pad_) -
reinterpret_cast<char*>(&batch_size_) + sizeof(context_pad_));
scale_ = 1;
fg_threshold_ = 0.5f;
bg_threshold_ = 0.5f;
fg_fraction_ = 0.25f;
}
WindowDataParameter::~WindowDataParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.WindowDataParameter)
SharedDtor();
}
void WindowDataParameter::SharedDtor() {
source_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
mean_file_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
crop_mode_.DestroyNoArena(_default_crop_mode_);
root_folder_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void WindowDataParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* WindowDataParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return WindowDataParameter_descriptor_;
}
const WindowDataParameter& WindowDataParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<WindowDataParameter> WindowDataParameter_default_instance_;
WindowDataParameter* WindowDataParameter::New(::google::protobuf::Arena* arena) const {
WindowDataParameter* n = new WindowDataParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void WindowDataParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.WindowDataParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(WindowDataParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<WindowDataParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
if (_has_bits_[0 / 32] & 255u) {
ZR_(batch_size_, mirror_);
if (has_source()) {
source_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
scale_ = 1;
if (has_mean_file()) {
mean_file_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
fg_threshold_ = 0.5f;
bg_threshold_ = 0.5f;
}
if (_has_bits_[8 / 32] & 7936u) {
ZR_(cache_images_, context_pad_);
fg_fraction_ = 0.25f;
if (has_crop_mode()) {
crop_mode_.ClearToDefaultNoArena(_default_crop_mode_);
}
if (has_root_folder()) {
root_folder_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
}
#undef ZR_HELPER_
#undef ZR_
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool WindowDataParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.WindowDataParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional string source = 1;
case 1: {
if (tag == 10) {
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_source()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->source().data(), this->source().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.WindowDataParameter.source");
} else {
goto handle_unusual;
}
if (input->ExpectTag(21)) goto parse_scale;
break;
}
// optional float scale = 2 [default = 1];
case 2: {
if (tag == 21) {
parse_scale:
set_has_scale();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &scale_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(26)) goto parse_mean_file;
break;
}
// optional string mean_file = 3;
case 3: {
if (tag == 26) {
parse_mean_file:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_mean_file()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->mean_file().data(), this->mean_file().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.WindowDataParameter.mean_file");
} else {
goto handle_unusual;
}
if (input->ExpectTag(32)) goto parse_batch_size;
break;
}
// optional uint32 batch_size = 4;
case 4: {
if (tag == 32) {
parse_batch_size:
set_has_batch_size();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &batch_size_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(40)) goto parse_crop_size;
break;
}
// optional uint32 crop_size = 5 [default = 0];
case 5: {
if (tag == 40) {
parse_crop_size:
set_has_crop_size();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &crop_size_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(48)) goto parse_mirror;
break;
}
// optional bool mirror = 6 [default = false];
case 6: {
if (tag == 48) {
parse_mirror:
set_has_mirror();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &mirror_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(61)) goto parse_fg_threshold;
break;
}
// optional float fg_threshold = 7 [default = 0.5];
case 7: {
if (tag == 61) {
parse_fg_threshold:
set_has_fg_threshold();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &fg_threshold_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(69)) goto parse_bg_threshold;
break;
}
// optional float bg_threshold = 8 [default = 0.5];
case 8: {
if (tag == 69) {
parse_bg_threshold:
set_has_bg_threshold();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &bg_threshold_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(77)) goto parse_fg_fraction;
break;
}
// optional float fg_fraction = 9 [default = 0.25];
case 9: {
if (tag == 77) {
parse_fg_fraction:
set_has_fg_fraction();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &fg_fraction_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(80)) goto parse_context_pad;
break;
}
// optional uint32 context_pad = 10 [default = 0];
case 10: {
if (tag == 80) {
parse_context_pad:
set_has_context_pad();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &context_pad_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(90)) goto parse_crop_mode;
break;
}
// optional string crop_mode = 11 [default = "warp"];
case 11: {
if (tag == 90) {
parse_crop_mode:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_crop_mode()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->crop_mode().data(), this->crop_mode().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.WindowDataParameter.crop_mode");
} else {
goto handle_unusual;
}
if (input->ExpectTag(96)) goto parse_cache_images;
break;
}
// optional bool cache_images = 12 [default = false];
case 12: {
if (tag == 96) {
parse_cache_images:
set_has_cache_images();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &cache_images_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(106)) goto parse_root_folder;
break;
}
// optional string root_folder = 13 [default = ""];
case 13: {
if (tag == 106) {
parse_root_folder:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_root_folder()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->root_folder().data(), this->root_folder().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.WindowDataParameter.root_folder");
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.WindowDataParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.WindowDataParameter)
return false;
#undef DO_
}
void WindowDataParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.WindowDataParameter)
// optional string source = 1;
if (has_source()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->source().data(), this->source().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.WindowDataParameter.source");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
1, this->source(), output);
}
// optional float scale = 2 [default = 1];
if (has_scale()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(2, this->scale(), output);
}
// optional string mean_file = 3;
if (has_mean_file()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->mean_file().data(), this->mean_file().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.WindowDataParameter.mean_file");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
3, this->mean_file(), output);
}
// optional uint32 batch_size = 4;
if (has_batch_size()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(4, this->batch_size(), output);
}
// optional uint32 crop_size = 5 [default = 0];
if (has_crop_size()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(5, this->crop_size(), output);
}
// optional bool mirror = 6 [default = false];
if (has_mirror()) {
::google::protobuf::internal::WireFormatLite::WriteBool(6, this->mirror(), output);
}
// optional float fg_threshold = 7 [default = 0.5];
if (has_fg_threshold()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(7, this->fg_threshold(), output);
}
// optional float bg_threshold = 8 [default = 0.5];
if (has_bg_threshold()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(8, this->bg_threshold(), output);
}
// optional float fg_fraction = 9 [default = 0.25];
if (has_fg_fraction()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(9, this->fg_fraction(), output);
}
// optional uint32 context_pad = 10 [default = 0];
if (has_context_pad()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(10, this->context_pad(), output);
}
// optional string crop_mode = 11 [default = "warp"];
if (has_crop_mode()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->crop_mode().data(), this->crop_mode().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.WindowDataParameter.crop_mode");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
11, this->crop_mode(), output);
}
// optional bool cache_images = 12 [default = false];
if (has_cache_images()) {
::google::protobuf::internal::WireFormatLite::WriteBool(12, this->cache_images(), output);
}
// optional string root_folder = 13 [default = ""];
if (has_root_folder()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->root_folder().data(), this->root_folder().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.WindowDataParameter.root_folder");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
13, this->root_folder(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.WindowDataParameter)
}
::google::protobuf::uint8* WindowDataParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.WindowDataParameter)
// optional string source = 1;
if (has_source()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->source().data(), this->source().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.WindowDataParameter.source");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
1, this->source(), target);
}
// optional float scale = 2 [default = 1];
if (has_scale()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(2, this->scale(), target);
}
// optional string mean_file = 3;
if (has_mean_file()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->mean_file().data(), this->mean_file().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.WindowDataParameter.mean_file");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
3, this->mean_file(), target);
}
// optional uint32 batch_size = 4;
if (has_batch_size()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(4, this->batch_size(), target);
}
// optional uint32 crop_size = 5 [default = 0];
if (has_crop_size()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(5, this->crop_size(), target);
}
// optional bool mirror = 6 [default = false];
if (has_mirror()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(6, this->mirror(), target);
}
// optional float fg_threshold = 7 [default = 0.5];
if (has_fg_threshold()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(7, this->fg_threshold(), target);
}
// optional float bg_threshold = 8 [default = 0.5];
if (has_bg_threshold()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(8, this->bg_threshold(), target);
}
// optional float fg_fraction = 9 [default = 0.25];
if (has_fg_fraction()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(9, this->fg_fraction(), target);
}
// optional uint32 context_pad = 10 [default = 0];
if (has_context_pad()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(10, this->context_pad(), target);
}
// optional string crop_mode = 11 [default = "warp"];
if (has_crop_mode()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->crop_mode().data(), this->crop_mode().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.WindowDataParameter.crop_mode");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
11, this->crop_mode(), target);
}
// optional bool cache_images = 12 [default = false];
if (has_cache_images()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(12, this->cache_images(), target);
}
// optional string root_folder = 13 [default = ""];
if (has_root_folder()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->root_folder().data(), this->root_folder().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.WindowDataParameter.root_folder");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
13, this->root_folder(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.WindowDataParameter)
return target;
}
size_t WindowDataParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.WindowDataParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 255u) {
// optional string source = 1;
if (has_source()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->source());
}
// optional float scale = 2 [default = 1];
if (has_scale()) {
total_size += 1 + 4;
}
// optional string mean_file = 3;
if (has_mean_file()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->mean_file());
}
// optional uint32 batch_size = 4;
if (has_batch_size()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->batch_size());
}
// optional uint32 crop_size = 5 [default = 0];
if (has_crop_size()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->crop_size());
}
// optional bool mirror = 6 [default = false];
if (has_mirror()) {
total_size += 1 + 1;
}
// optional float fg_threshold = 7 [default = 0.5];
if (has_fg_threshold()) {
total_size += 1 + 4;
}
// optional float bg_threshold = 8 [default = 0.5];
if (has_bg_threshold()) {
total_size += 1 + 4;
}
}
if (_has_bits_[8 / 32] & 7936u) {
// optional float fg_fraction = 9 [default = 0.25];
if (has_fg_fraction()) {
total_size += 1 + 4;
}
// optional uint32 context_pad = 10 [default = 0];
if (has_context_pad()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->context_pad());
}
// optional string crop_mode = 11 [default = "warp"];
if (has_crop_mode()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->crop_mode());
}
// optional bool cache_images = 12 [default = false];
if (has_cache_images()) {
total_size += 1 + 1;
}
// optional string root_folder = 13 [default = ""];
if (has_root_folder()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->root_folder());
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void WindowDataParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.WindowDataParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const WindowDataParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const WindowDataParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.WindowDataParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.WindowDataParameter)
UnsafeMergeFrom(*source);
}
}
void WindowDataParameter::MergeFrom(const WindowDataParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.WindowDataParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void WindowDataParameter::UnsafeMergeFrom(const WindowDataParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_source()) {
set_has_source();
source_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.source_);
}
if (from.has_scale()) {
set_scale(from.scale());
}
if (from.has_mean_file()) {
set_has_mean_file();
mean_file_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.mean_file_);
}
if (from.has_batch_size()) {
set_batch_size(from.batch_size());
}
if (from.has_crop_size()) {
set_crop_size(from.crop_size());
}
if (from.has_mirror()) {
set_mirror(from.mirror());
}
if (from.has_fg_threshold()) {
set_fg_threshold(from.fg_threshold());
}
if (from.has_bg_threshold()) {
set_bg_threshold(from.bg_threshold());
}
}
if (from._has_bits_[8 / 32] & (0xffu << (8 % 32))) {
if (from.has_fg_fraction()) {
set_fg_fraction(from.fg_fraction());
}
if (from.has_context_pad()) {
set_context_pad(from.context_pad());
}
if (from.has_crop_mode()) {
set_has_crop_mode();
crop_mode_.AssignWithDefault(_default_crop_mode_, from.crop_mode_);
}
if (from.has_cache_images()) {
set_cache_images(from.cache_images());
}
if (from.has_root_folder()) {
set_has_root_folder();
root_folder_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.root_folder_);
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void WindowDataParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.WindowDataParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void WindowDataParameter::CopyFrom(const WindowDataParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.WindowDataParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool WindowDataParameter::IsInitialized() const {
return true;
}
void WindowDataParameter::Swap(WindowDataParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void WindowDataParameter::InternalSwap(WindowDataParameter* other) {
source_.Swap(&other->source_);
std::swap(scale_, other->scale_);
mean_file_.Swap(&other->mean_file_);
std::swap(batch_size_, other->batch_size_);
std::swap(crop_size_, other->crop_size_);
std::swap(mirror_, other->mirror_);
std::swap(fg_threshold_, other->fg_threshold_);
std::swap(bg_threshold_, other->bg_threshold_);
std::swap(fg_fraction_, other->fg_fraction_);
std::swap(context_pad_, other->context_pad_);
crop_mode_.Swap(&other->crop_mode_);
std::swap(cache_images_, other->cache_images_);
root_folder_.Swap(&other->root_folder_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata WindowDataParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = WindowDataParameter_descriptor_;
metadata.reflection = WindowDataParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// WindowDataParameter
// optional string source = 1;
bool WindowDataParameter::has_source() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void WindowDataParameter::set_has_source() {
_has_bits_[0] |= 0x00000001u;
}
void WindowDataParameter::clear_has_source() {
_has_bits_[0] &= ~0x00000001u;
}
void WindowDataParameter::clear_source() {
source_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_source();
}
const ::std::string& WindowDataParameter::source() const {
// @@protoc_insertion_point(field_get:opencv_caffe.WindowDataParameter.source)
return source_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void WindowDataParameter::set_source(const ::std::string& value) {
set_has_source();
source_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.WindowDataParameter.source)
}
void WindowDataParameter::set_source(const char* value) {
set_has_source();
source_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.WindowDataParameter.source)
}
void WindowDataParameter::set_source(const char* value, size_t size) {
set_has_source();
source_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.WindowDataParameter.source)
}
::std::string* WindowDataParameter::mutable_source() {
set_has_source();
// @@protoc_insertion_point(field_mutable:opencv_caffe.WindowDataParameter.source)
return source_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* WindowDataParameter::release_source() {
// @@protoc_insertion_point(field_release:opencv_caffe.WindowDataParameter.source)
clear_has_source();
return source_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void WindowDataParameter::set_allocated_source(::std::string* source) {
if (source != NULL) {
set_has_source();
} else {
clear_has_source();
}
source_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), source);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.WindowDataParameter.source)
}
// optional float scale = 2 [default = 1];
bool WindowDataParameter::has_scale() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void WindowDataParameter::set_has_scale() {
_has_bits_[0] |= 0x00000002u;
}
void WindowDataParameter::clear_has_scale() {
_has_bits_[0] &= ~0x00000002u;
}
void WindowDataParameter::clear_scale() {
scale_ = 1;
clear_has_scale();
}
float WindowDataParameter::scale() const {
// @@protoc_insertion_point(field_get:opencv_caffe.WindowDataParameter.scale)
return scale_;
}
void WindowDataParameter::set_scale(float value) {
set_has_scale();
scale_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.WindowDataParameter.scale)
}
// optional string mean_file = 3;
bool WindowDataParameter::has_mean_file() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void WindowDataParameter::set_has_mean_file() {
_has_bits_[0] |= 0x00000004u;
}
void WindowDataParameter::clear_has_mean_file() {
_has_bits_[0] &= ~0x00000004u;
}
void WindowDataParameter::clear_mean_file() {
mean_file_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_mean_file();
}
const ::std::string& WindowDataParameter::mean_file() const {
// @@protoc_insertion_point(field_get:opencv_caffe.WindowDataParameter.mean_file)
return mean_file_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void WindowDataParameter::set_mean_file(const ::std::string& value) {
set_has_mean_file();
mean_file_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.WindowDataParameter.mean_file)
}
void WindowDataParameter::set_mean_file(const char* value) {
set_has_mean_file();
mean_file_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.WindowDataParameter.mean_file)
}
void WindowDataParameter::set_mean_file(const char* value, size_t size) {
set_has_mean_file();
mean_file_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.WindowDataParameter.mean_file)
}
::std::string* WindowDataParameter::mutable_mean_file() {
set_has_mean_file();
// @@protoc_insertion_point(field_mutable:opencv_caffe.WindowDataParameter.mean_file)
return mean_file_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* WindowDataParameter::release_mean_file() {
// @@protoc_insertion_point(field_release:opencv_caffe.WindowDataParameter.mean_file)
clear_has_mean_file();
return mean_file_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void WindowDataParameter::set_allocated_mean_file(::std::string* mean_file) {
if (mean_file != NULL) {
set_has_mean_file();
} else {
clear_has_mean_file();
}
mean_file_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), mean_file);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.WindowDataParameter.mean_file)
}
// optional uint32 batch_size = 4;
bool WindowDataParameter::has_batch_size() const {
return (_has_bits_[0] & 0x00000008u) != 0;
}
void WindowDataParameter::set_has_batch_size() {
_has_bits_[0] |= 0x00000008u;
}
void WindowDataParameter::clear_has_batch_size() {
_has_bits_[0] &= ~0x00000008u;
}
void WindowDataParameter::clear_batch_size() {
batch_size_ = 0u;
clear_has_batch_size();
}
::google::protobuf::uint32 WindowDataParameter::batch_size() const {
// @@protoc_insertion_point(field_get:opencv_caffe.WindowDataParameter.batch_size)
return batch_size_;
}
void WindowDataParameter::set_batch_size(::google::protobuf::uint32 value) {
set_has_batch_size();
batch_size_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.WindowDataParameter.batch_size)
}
// optional uint32 crop_size = 5 [default = 0];
bool WindowDataParameter::has_crop_size() const {
return (_has_bits_[0] & 0x00000010u) != 0;
}
void WindowDataParameter::set_has_crop_size() {
_has_bits_[0] |= 0x00000010u;
}
void WindowDataParameter::clear_has_crop_size() {
_has_bits_[0] &= ~0x00000010u;
}
void WindowDataParameter::clear_crop_size() {
crop_size_ = 0u;
clear_has_crop_size();
}
::google::protobuf::uint32 WindowDataParameter::crop_size() const {
// @@protoc_insertion_point(field_get:opencv_caffe.WindowDataParameter.crop_size)
return crop_size_;
}
void WindowDataParameter::set_crop_size(::google::protobuf::uint32 value) {
set_has_crop_size();
crop_size_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.WindowDataParameter.crop_size)
}
// optional bool mirror = 6 [default = false];
bool WindowDataParameter::has_mirror() const {
return (_has_bits_[0] & 0x00000020u) != 0;
}
void WindowDataParameter::set_has_mirror() {
_has_bits_[0] |= 0x00000020u;
}
void WindowDataParameter::clear_has_mirror() {
_has_bits_[0] &= ~0x00000020u;
}
void WindowDataParameter::clear_mirror() {
mirror_ = false;
clear_has_mirror();
}
bool WindowDataParameter::mirror() const {
// @@protoc_insertion_point(field_get:opencv_caffe.WindowDataParameter.mirror)
return mirror_;
}
void WindowDataParameter::set_mirror(bool value) {
set_has_mirror();
mirror_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.WindowDataParameter.mirror)
}
// optional float fg_threshold = 7 [default = 0.5];
bool WindowDataParameter::has_fg_threshold() const {
return (_has_bits_[0] & 0x00000040u) != 0;
}
void WindowDataParameter::set_has_fg_threshold() {
_has_bits_[0] |= 0x00000040u;
}
void WindowDataParameter::clear_has_fg_threshold() {
_has_bits_[0] &= ~0x00000040u;
}
void WindowDataParameter::clear_fg_threshold() {
fg_threshold_ = 0.5f;
clear_has_fg_threshold();
}
float WindowDataParameter::fg_threshold() const {
// @@protoc_insertion_point(field_get:opencv_caffe.WindowDataParameter.fg_threshold)
return fg_threshold_;
}
void WindowDataParameter::set_fg_threshold(float value) {
set_has_fg_threshold();
fg_threshold_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.WindowDataParameter.fg_threshold)
}
// optional float bg_threshold = 8 [default = 0.5];
bool WindowDataParameter::has_bg_threshold() const {
return (_has_bits_[0] & 0x00000080u) != 0;
}
void WindowDataParameter::set_has_bg_threshold() {
_has_bits_[0] |= 0x00000080u;
}
void WindowDataParameter::clear_has_bg_threshold() {
_has_bits_[0] &= ~0x00000080u;
}
void WindowDataParameter::clear_bg_threshold() {
bg_threshold_ = 0.5f;
clear_has_bg_threshold();
}
float WindowDataParameter::bg_threshold() const {
// @@protoc_insertion_point(field_get:opencv_caffe.WindowDataParameter.bg_threshold)
return bg_threshold_;
}
void WindowDataParameter::set_bg_threshold(float value) {
set_has_bg_threshold();
bg_threshold_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.WindowDataParameter.bg_threshold)
}
// optional float fg_fraction = 9 [default = 0.25];
bool WindowDataParameter::has_fg_fraction() const {
return (_has_bits_[0] & 0x00000100u) != 0;
}
void WindowDataParameter::set_has_fg_fraction() {
_has_bits_[0] |= 0x00000100u;
}
void WindowDataParameter::clear_has_fg_fraction() {
_has_bits_[0] &= ~0x00000100u;
}
void WindowDataParameter::clear_fg_fraction() {
fg_fraction_ = 0.25f;
clear_has_fg_fraction();
}
float WindowDataParameter::fg_fraction() const {
// @@protoc_insertion_point(field_get:opencv_caffe.WindowDataParameter.fg_fraction)
return fg_fraction_;
}
void WindowDataParameter::set_fg_fraction(float value) {
set_has_fg_fraction();
fg_fraction_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.WindowDataParameter.fg_fraction)
}
// optional uint32 context_pad = 10 [default = 0];
bool WindowDataParameter::has_context_pad() const {
return (_has_bits_[0] & 0x00000200u) != 0;
}
void WindowDataParameter::set_has_context_pad() {
_has_bits_[0] |= 0x00000200u;
}
void WindowDataParameter::clear_has_context_pad() {
_has_bits_[0] &= ~0x00000200u;
}
void WindowDataParameter::clear_context_pad() {
context_pad_ = 0u;
clear_has_context_pad();
}
::google::protobuf::uint32 WindowDataParameter::context_pad() const {
// @@protoc_insertion_point(field_get:opencv_caffe.WindowDataParameter.context_pad)
return context_pad_;
}
void WindowDataParameter::set_context_pad(::google::protobuf::uint32 value) {
set_has_context_pad();
context_pad_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.WindowDataParameter.context_pad)
}
// optional string crop_mode = 11 [default = "warp"];
bool WindowDataParameter::has_crop_mode() const {
return (_has_bits_[0] & 0x00000400u) != 0;
}
void WindowDataParameter::set_has_crop_mode() {
_has_bits_[0] |= 0x00000400u;
}
void WindowDataParameter::clear_has_crop_mode() {
_has_bits_[0] &= ~0x00000400u;
}
void WindowDataParameter::clear_crop_mode() {
crop_mode_.ClearToDefaultNoArena(_default_crop_mode_);
clear_has_crop_mode();
}
const ::std::string& WindowDataParameter::crop_mode() const {
// @@protoc_insertion_point(field_get:opencv_caffe.WindowDataParameter.crop_mode)
return crop_mode_.GetNoArena(_default_crop_mode_);
}
void WindowDataParameter::set_crop_mode(const ::std::string& value) {
set_has_crop_mode();
crop_mode_.SetNoArena(_default_crop_mode_, value);
// @@protoc_insertion_point(field_set:opencv_caffe.WindowDataParameter.crop_mode)
}
void WindowDataParameter::set_crop_mode(const char* value) {
set_has_crop_mode();
crop_mode_.SetNoArena(_default_crop_mode_, ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.WindowDataParameter.crop_mode)
}
void WindowDataParameter::set_crop_mode(const char* value, size_t size) {
set_has_crop_mode();
crop_mode_.SetNoArena(_default_crop_mode_,
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.WindowDataParameter.crop_mode)
}
::std::string* WindowDataParameter::mutable_crop_mode() {
set_has_crop_mode();
// @@protoc_insertion_point(field_mutable:opencv_caffe.WindowDataParameter.crop_mode)
return crop_mode_.MutableNoArena(_default_crop_mode_);
}
::std::string* WindowDataParameter::release_crop_mode() {
// @@protoc_insertion_point(field_release:opencv_caffe.WindowDataParameter.crop_mode)
clear_has_crop_mode();
return crop_mode_.ReleaseNoArena(_default_crop_mode_);
}
void WindowDataParameter::set_allocated_crop_mode(::std::string* crop_mode) {
if (crop_mode != NULL) {
set_has_crop_mode();
} else {
clear_has_crop_mode();
}
crop_mode_.SetAllocatedNoArena(_default_crop_mode_, crop_mode);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.WindowDataParameter.crop_mode)
}
// optional bool cache_images = 12 [default = false];
bool WindowDataParameter::has_cache_images() const {
return (_has_bits_[0] & 0x00000800u) != 0;
}
void WindowDataParameter::set_has_cache_images() {
_has_bits_[0] |= 0x00000800u;
}
void WindowDataParameter::clear_has_cache_images() {
_has_bits_[0] &= ~0x00000800u;
}
void WindowDataParameter::clear_cache_images() {
cache_images_ = false;
clear_has_cache_images();
}
bool WindowDataParameter::cache_images() const {
// @@protoc_insertion_point(field_get:opencv_caffe.WindowDataParameter.cache_images)
return cache_images_;
}
void WindowDataParameter::set_cache_images(bool value) {
set_has_cache_images();
cache_images_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.WindowDataParameter.cache_images)
}
// optional string root_folder = 13 [default = ""];
bool WindowDataParameter::has_root_folder() const {
return (_has_bits_[0] & 0x00001000u) != 0;
}
void WindowDataParameter::set_has_root_folder() {
_has_bits_[0] |= 0x00001000u;
}
void WindowDataParameter::clear_has_root_folder() {
_has_bits_[0] &= ~0x00001000u;
}
void WindowDataParameter::clear_root_folder() {
root_folder_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_root_folder();
}
const ::std::string& WindowDataParameter::root_folder() const {
// @@protoc_insertion_point(field_get:opencv_caffe.WindowDataParameter.root_folder)
return root_folder_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void WindowDataParameter::set_root_folder(const ::std::string& value) {
set_has_root_folder();
root_folder_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.WindowDataParameter.root_folder)
}
void WindowDataParameter::set_root_folder(const char* value) {
set_has_root_folder();
root_folder_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.WindowDataParameter.root_folder)
}
void WindowDataParameter::set_root_folder(const char* value, size_t size) {
set_has_root_folder();
root_folder_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.WindowDataParameter.root_folder)
}
::std::string* WindowDataParameter::mutable_root_folder() {
set_has_root_folder();
// @@protoc_insertion_point(field_mutable:opencv_caffe.WindowDataParameter.root_folder)
return root_folder_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* WindowDataParameter::release_root_folder() {
// @@protoc_insertion_point(field_release:opencv_caffe.WindowDataParameter.root_folder)
clear_has_root_folder();
return root_folder_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void WindowDataParameter::set_allocated_root_folder(::std::string* root_folder) {
if (root_folder != NULL) {
set_has_root_folder();
} else {
clear_has_root_folder();
}
root_folder_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), root_folder);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.WindowDataParameter.root_folder)
}
inline const WindowDataParameter* WindowDataParameter::internal_default_instance() {
return &WindowDataParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
const ::google::protobuf::EnumDescriptor* SPPParameter_PoolMethod_descriptor() {
protobuf_AssignDescriptorsOnce();
return SPPParameter_PoolMethod_descriptor_;
}
bool SPPParameter_PoolMethod_IsValid(int value) {
switch (value) {
case 0:
case 1:
case 2:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const SPPParameter_PoolMethod SPPParameter::MAX;
const SPPParameter_PoolMethod SPPParameter::AVE;
const SPPParameter_PoolMethod SPPParameter::STOCHASTIC;
const SPPParameter_PoolMethod SPPParameter::PoolMethod_MIN;
const SPPParameter_PoolMethod SPPParameter::PoolMethod_MAX;
const int SPPParameter::PoolMethod_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
const ::google::protobuf::EnumDescriptor* SPPParameter_Engine_descriptor() {
protobuf_AssignDescriptorsOnce();
return SPPParameter_Engine_descriptor_;
}
bool SPPParameter_Engine_IsValid(int value) {
switch (value) {
case 0:
case 1:
case 2:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const SPPParameter_Engine SPPParameter::DEFAULT;
const SPPParameter_Engine SPPParameter::CAFFE;
const SPPParameter_Engine SPPParameter::CUDNN;
const SPPParameter_Engine SPPParameter::Engine_MIN;
const SPPParameter_Engine SPPParameter::Engine_MAX;
const int SPPParameter::Engine_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int SPPParameter::kPyramidHeightFieldNumber;
const int SPPParameter::kPoolFieldNumber;
const int SPPParameter::kEngineFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
SPPParameter::SPPParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.SPPParameter)
}
void SPPParameter::InitAsDefaultInstance() {
}
SPPParameter::SPPParameter(const SPPParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.SPPParameter)
}
void SPPParameter::SharedCtor() {
_cached_size_ = 0;
::memset(&pyramid_height_, 0, reinterpret_cast<char*>(&engine_) -
reinterpret_cast<char*>(&pyramid_height_) + sizeof(engine_));
}
SPPParameter::~SPPParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.SPPParameter)
SharedDtor();
}
void SPPParameter::SharedDtor() {
}
void SPPParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* SPPParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return SPPParameter_descriptor_;
}
const SPPParameter& SPPParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<SPPParameter> SPPParameter_default_instance_;
SPPParameter* SPPParameter::New(::google::protobuf::Arena* arena) const {
SPPParameter* n = new SPPParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void SPPParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.SPPParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(SPPParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<SPPParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
ZR_(pyramid_height_, engine_);
#undef ZR_HELPER_
#undef ZR_
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool SPPParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.SPPParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional uint32 pyramid_height = 1;
case 1: {
if (tag == 8) {
set_has_pyramid_height();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &pyramid_height_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_pool;
break;
}
// optional .opencv_caffe.SPPParameter.PoolMethod pool = 2 [default = MAX];
case 2: {
if (tag == 16) {
parse_pool:
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::SPPParameter_PoolMethod_IsValid(value)) {
set_pool(static_cast< ::opencv_caffe::SPPParameter_PoolMethod >(value));
} else {
mutable_unknown_fields()->AddVarint(2, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectTag(48)) goto parse_engine;
break;
}
// optional .opencv_caffe.SPPParameter.Engine engine = 6 [default = DEFAULT];
case 6: {
if (tag == 48) {
parse_engine:
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::SPPParameter_Engine_IsValid(value)) {
set_engine(static_cast< ::opencv_caffe::SPPParameter_Engine >(value));
} else {
mutable_unknown_fields()->AddVarint(6, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.SPPParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.SPPParameter)
return false;
#undef DO_
}
void SPPParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.SPPParameter)
// optional uint32 pyramid_height = 1;
if (has_pyramid_height()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(1, this->pyramid_height(), output);
}
// optional .opencv_caffe.SPPParameter.PoolMethod pool = 2 [default = MAX];
if (has_pool()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
2, this->pool(), output);
}
// optional .opencv_caffe.SPPParameter.Engine engine = 6 [default = DEFAULT];
if (has_engine()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
6, this->engine(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.SPPParameter)
}
::google::protobuf::uint8* SPPParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.SPPParameter)
// optional uint32 pyramid_height = 1;
if (has_pyramid_height()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(1, this->pyramid_height(), target);
}
// optional .opencv_caffe.SPPParameter.PoolMethod pool = 2 [default = MAX];
if (has_pool()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
2, this->pool(), target);
}
// optional .opencv_caffe.SPPParameter.Engine engine = 6 [default = DEFAULT];
if (has_engine()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
6, this->engine(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.SPPParameter)
return target;
}
size_t SPPParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.SPPParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 7u) {
// optional uint32 pyramid_height = 1;
if (has_pyramid_height()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->pyramid_height());
}
// optional .opencv_caffe.SPPParameter.PoolMethod pool = 2 [default = MAX];
if (has_pool()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->pool());
}
// optional .opencv_caffe.SPPParameter.Engine engine = 6 [default = DEFAULT];
if (has_engine()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->engine());
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void SPPParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.SPPParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const SPPParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const SPPParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.SPPParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.SPPParameter)
UnsafeMergeFrom(*source);
}
}
void SPPParameter::MergeFrom(const SPPParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.SPPParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void SPPParameter::UnsafeMergeFrom(const SPPParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_pyramid_height()) {
set_pyramid_height(from.pyramid_height());
}
if (from.has_pool()) {
set_pool(from.pool());
}
if (from.has_engine()) {
set_engine(from.engine());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void SPPParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.SPPParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void SPPParameter::CopyFrom(const SPPParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.SPPParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool SPPParameter::IsInitialized() const {
return true;
}
void SPPParameter::Swap(SPPParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void SPPParameter::InternalSwap(SPPParameter* other) {
std::swap(pyramid_height_, other->pyramid_height_);
std::swap(pool_, other->pool_);
std::swap(engine_, other->engine_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata SPPParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = SPPParameter_descriptor_;
metadata.reflection = SPPParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// SPPParameter
// optional uint32 pyramid_height = 1;
bool SPPParameter::has_pyramid_height() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void SPPParameter::set_has_pyramid_height() {
_has_bits_[0] |= 0x00000001u;
}
void SPPParameter::clear_has_pyramid_height() {
_has_bits_[0] &= ~0x00000001u;
}
void SPPParameter::clear_pyramid_height() {
pyramid_height_ = 0u;
clear_has_pyramid_height();
}
::google::protobuf::uint32 SPPParameter::pyramid_height() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SPPParameter.pyramid_height)
return pyramid_height_;
}
void SPPParameter::set_pyramid_height(::google::protobuf::uint32 value) {
set_has_pyramid_height();
pyramid_height_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SPPParameter.pyramid_height)
}
// optional .opencv_caffe.SPPParameter.PoolMethod pool = 2 [default = MAX];
bool SPPParameter::has_pool() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void SPPParameter::set_has_pool() {
_has_bits_[0] |= 0x00000002u;
}
void SPPParameter::clear_has_pool() {
_has_bits_[0] &= ~0x00000002u;
}
void SPPParameter::clear_pool() {
pool_ = 0;
clear_has_pool();
}
::opencv_caffe::SPPParameter_PoolMethod SPPParameter::pool() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SPPParameter.pool)
return static_cast< ::opencv_caffe::SPPParameter_PoolMethod >(pool_);
}
void SPPParameter::set_pool(::opencv_caffe::SPPParameter_PoolMethod value) {
assert(::opencv_caffe::SPPParameter_PoolMethod_IsValid(value));
set_has_pool();
pool_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SPPParameter.pool)
}
// optional .opencv_caffe.SPPParameter.Engine engine = 6 [default = DEFAULT];
bool SPPParameter::has_engine() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void SPPParameter::set_has_engine() {
_has_bits_[0] |= 0x00000004u;
}
void SPPParameter::clear_has_engine() {
_has_bits_[0] &= ~0x00000004u;
}
void SPPParameter::clear_engine() {
engine_ = 0;
clear_has_engine();
}
::opencv_caffe::SPPParameter_Engine SPPParameter::engine() const {
// @@protoc_insertion_point(field_get:opencv_caffe.SPPParameter.engine)
return static_cast< ::opencv_caffe::SPPParameter_Engine >(engine_);
}
void SPPParameter::set_engine(::opencv_caffe::SPPParameter_Engine value) {
assert(::opencv_caffe::SPPParameter_Engine_IsValid(value));
set_has_engine();
engine_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.SPPParameter.engine)
}
inline const SPPParameter* SPPParameter::internal_default_instance() {
return &SPPParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
const ::google::protobuf::EnumDescriptor* V1LayerParameter_LayerType_descriptor() {
protobuf_AssignDescriptorsOnce();
return V1LayerParameter_LayerType_descriptor_;
}
bool V1LayerParameter_LayerType_IsValid(int value) {
switch (value) {
case 0:
case 1:
case 2:
case 3:
case 4:
case 5:
case 6:
case 7:
case 8:
case 9:
case 10:
case 11:
case 12:
case 13:
case 14:
case 15:
case 16:
case 17:
case 18:
case 19:
case 20:
case 21:
case 22:
case 23:
case 24:
case 25:
case 26:
case 27:
case 28:
case 29:
case 30:
case 31:
case 32:
case 33:
case 34:
case 35:
case 36:
case 37:
case 38:
case 39:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const V1LayerParameter_LayerType V1LayerParameter::NONE;
const V1LayerParameter_LayerType V1LayerParameter::ABSVAL;
const V1LayerParameter_LayerType V1LayerParameter::ACCURACY;
const V1LayerParameter_LayerType V1LayerParameter::ARGMAX;
const V1LayerParameter_LayerType V1LayerParameter::BNLL;
const V1LayerParameter_LayerType V1LayerParameter::CONCAT;
const V1LayerParameter_LayerType V1LayerParameter::CONTRASTIVE_LOSS;
const V1LayerParameter_LayerType V1LayerParameter::CONVOLUTION;
const V1LayerParameter_LayerType V1LayerParameter::DATA;
const V1LayerParameter_LayerType V1LayerParameter::DECONVOLUTION;
const V1LayerParameter_LayerType V1LayerParameter::DROPOUT;
const V1LayerParameter_LayerType V1LayerParameter::DUMMY_DATA;
const V1LayerParameter_LayerType V1LayerParameter::EUCLIDEAN_LOSS;
const V1LayerParameter_LayerType V1LayerParameter::ELTWISE;
const V1LayerParameter_LayerType V1LayerParameter::EXP;
const V1LayerParameter_LayerType V1LayerParameter::FLATTEN;
const V1LayerParameter_LayerType V1LayerParameter::HDF5_DATA;
const V1LayerParameter_LayerType V1LayerParameter::HDF5_OUTPUT;
const V1LayerParameter_LayerType V1LayerParameter::HINGE_LOSS;
const V1LayerParameter_LayerType V1LayerParameter::IM2COL;
const V1LayerParameter_LayerType V1LayerParameter::IMAGE_DATA;
const V1LayerParameter_LayerType V1LayerParameter::INFOGAIN_LOSS;
const V1LayerParameter_LayerType V1LayerParameter::INNER_PRODUCT;
const V1LayerParameter_LayerType V1LayerParameter::LRN;
const V1LayerParameter_LayerType V1LayerParameter::MEMORY_DATA;
const V1LayerParameter_LayerType V1LayerParameter::MULTINOMIAL_LOGISTIC_LOSS;
const V1LayerParameter_LayerType V1LayerParameter::MVN;
const V1LayerParameter_LayerType V1LayerParameter::POOLING;
const V1LayerParameter_LayerType V1LayerParameter::POWER;
const V1LayerParameter_LayerType V1LayerParameter::RELU;
const V1LayerParameter_LayerType V1LayerParameter::SIGMOID;
const V1LayerParameter_LayerType V1LayerParameter::SIGMOID_CROSS_ENTROPY_LOSS;
const V1LayerParameter_LayerType V1LayerParameter::SILENCE;
const V1LayerParameter_LayerType V1LayerParameter::SOFTMAX;
const V1LayerParameter_LayerType V1LayerParameter::SOFTMAX_LOSS;
const V1LayerParameter_LayerType V1LayerParameter::SPLIT;
const V1LayerParameter_LayerType V1LayerParameter::SLICE;
const V1LayerParameter_LayerType V1LayerParameter::TANH;
const V1LayerParameter_LayerType V1LayerParameter::WINDOW_DATA;
const V1LayerParameter_LayerType V1LayerParameter::THRESHOLD;
const V1LayerParameter_LayerType V1LayerParameter::LayerType_MIN;
const V1LayerParameter_LayerType V1LayerParameter::LayerType_MAX;
const int V1LayerParameter::LayerType_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
const ::google::protobuf::EnumDescriptor* V1LayerParameter_DimCheckMode_descriptor() {
protobuf_AssignDescriptorsOnce();
return V1LayerParameter_DimCheckMode_descriptor_;
}
bool V1LayerParameter_DimCheckMode_IsValid(int value) {
switch (value) {
case 0:
case 1:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const V1LayerParameter_DimCheckMode V1LayerParameter::STRICT;
const V1LayerParameter_DimCheckMode V1LayerParameter::PERMISSIVE;
const V1LayerParameter_DimCheckMode V1LayerParameter::DimCheckMode_MIN;
const V1LayerParameter_DimCheckMode V1LayerParameter::DimCheckMode_MAX;
const int V1LayerParameter::DimCheckMode_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int V1LayerParameter::kBottomFieldNumber;
const int V1LayerParameter::kTopFieldNumber;
const int V1LayerParameter::kNameFieldNumber;
const int V1LayerParameter::kIncludeFieldNumber;
const int V1LayerParameter::kExcludeFieldNumber;
const int V1LayerParameter::kTypeFieldNumber;
const int V1LayerParameter::kBlobsFieldNumber;
const int V1LayerParameter::kParamFieldNumber;
const int V1LayerParameter::kBlobShareModeFieldNumber;
const int V1LayerParameter::kBlobsLrFieldNumber;
const int V1LayerParameter::kWeightDecayFieldNumber;
const int V1LayerParameter::kLossWeightFieldNumber;
const int V1LayerParameter::kAccuracyParamFieldNumber;
const int V1LayerParameter::kArgmaxParamFieldNumber;
const int V1LayerParameter::kConcatParamFieldNumber;
const int V1LayerParameter::kContrastiveLossParamFieldNumber;
const int V1LayerParameter::kConvolutionParamFieldNumber;
const int V1LayerParameter::kDataParamFieldNumber;
const int V1LayerParameter::kDropoutParamFieldNumber;
const int V1LayerParameter::kDummyDataParamFieldNumber;
const int V1LayerParameter::kEltwiseParamFieldNumber;
const int V1LayerParameter::kExpParamFieldNumber;
const int V1LayerParameter::kHdf5DataParamFieldNumber;
const int V1LayerParameter::kHdf5OutputParamFieldNumber;
const int V1LayerParameter::kHingeLossParamFieldNumber;
const int V1LayerParameter::kImageDataParamFieldNumber;
const int V1LayerParameter::kInfogainLossParamFieldNumber;
const int V1LayerParameter::kInnerProductParamFieldNumber;
const int V1LayerParameter::kLrnParamFieldNumber;
const int V1LayerParameter::kMemoryDataParamFieldNumber;
const int V1LayerParameter::kMvnParamFieldNumber;
const int V1LayerParameter::kPoolingParamFieldNumber;
const int V1LayerParameter::kPowerParamFieldNumber;
const int V1LayerParameter::kReluParamFieldNumber;
const int V1LayerParameter::kSigmoidParamFieldNumber;
const int V1LayerParameter::kSoftmaxParamFieldNumber;
const int V1LayerParameter::kSliceParamFieldNumber;
const int V1LayerParameter::kTanhParamFieldNumber;
const int V1LayerParameter::kThresholdParamFieldNumber;
const int V1LayerParameter::kWindowDataParamFieldNumber;
const int V1LayerParameter::kTransformParamFieldNumber;
const int V1LayerParameter::kLossParamFieldNumber;
const int V1LayerParameter::kLayerFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
V1LayerParameter::V1LayerParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.V1LayerParameter)
}
void V1LayerParameter::InitAsDefaultInstance() {
accuracy_param_ = const_cast< ::opencv_caffe::AccuracyParameter*>(
::opencv_caffe::AccuracyParameter::internal_default_instance());
argmax_param_ = const_cast< ::opencv_caffe::ArgMaxParameter*>(
::opencv_caffe::ArgMaxParameter::internal_default_instance());
concat_param_ = const_cast< ::opencv_caffe::ConcatParameter*>(
::opencv_caffe::ConcatParameter::internal_default_instance());
contrastive_loss_param_ = const_cast< ::opencv_caffe::ContrastiveLossParameter*>(
::opencv_caffe::ContrastiveLossParameter::internal_default_instance());
convolution_param_ = const_cast< ::opencv_caffe::ConvolutionParameter*>(
::opencv_caffe::ConvolutionParameter::internal_default_instance());
data_param_ = const_cast< ::opencv_caffe::DataParameter*>(
::opencv_caffe::DataParameter::internal_default_instance());
dropout_param_ = const_cast< ::opencv_caffe::DropoutParameter*>(
::opencv_caffe::DropoutParameter::internal_default_instance());
dummy_data_param_ = const_cast< ::opencv_caffe::DummyDataParameter*>(
::opencv_caffe::DummyDataParameter::internal_default_instance());
eltwise_param_ = const_cast< ::opencv_caffe::EltwiseParameter*>(
::opencv_caffe::EltwiseParameter::internal_default_instance());
exp_param_ = const_cast< ::opencv_caffe::ExpParameter*>(
::opencv_caffe::ExpParameter::internal_default_instance());
hdf5_data_param_ = const_cast< ::opencv_caffe::HDF5DataParameter*>(
::opencv_caffe::HDF5DataParameter::internal_default_instance());
hdf5_output_param_ = const_cast< ::opencv_caffe::HDF5OutputParameter*>(
::opencv_caffe::HDF5OutputParameter::internal_default_instance());
hinge_loss_param_ = const_cast< ::opencv_caffe::HingeLossParameter*>(
::opencv_caffe::HingeLossParameter::internal_default_instance());
image_data_param_ = const_cast< ::opencv_caffe::ImageDataParameter*>(
::opencv_caffe::ImageDataParameter::internal_default_instance());
infogain_loss_param_ = const_cast< ::opencv_caffe::InfogainLossParameter*>(
::opencv_caffe::InfogainLossParameter::internal_default_instance());
inner_product_param_ = const_cast< ::opencv_caffe::InnerProductParameter*>(
::opencv_caffe::InnerProductParameter::internal_default_instance());
lrn_param_ = const_cast< ::opencv_caffe::LRNParameter*>(
::opencv_caffe::LRNParameter::internal_default_instance());
memory_data_param_ = const_cast< ::opencv_caffe::MemoryDataParameter*>(
::opencv_caffe::MemoryDataParameter::internal_default_instance());
mvn_param_ = const_cast< ::opencv_caffe::MVNParameter*>(
::opencv_caffe::MVNParameter::internal_default_instance());
pooling_param_ = const_cast< ::opencv_caffe::PoolingParameter*>(
::opencv_caffe::PoolingParameter::internal_default_instance());
power_param_ = const_cast< ::opencv_caffe::PowerParameter*>(
::opencv_caffe::PowerParameter::internal_default_instance());
relu_param_ = const_cast< ::opencv_caffe::ReLUParameter*>(
::opencv_caffe::ReLUParameter::internal_default_instance());
sigmoid_param_ = const_cast< ::opencv_caffe::SigmoidParameter*>(
::opencv_caffe::SigmoidParameter::internal_default_instance());
softmax_param_ = const_cast< ::opencv_caffe::SoftmaxParameter*>(
::opencv_caffe::SoftmaxParameter::internal_default_instance());
slice_param_ = const_cast< ::opencv_caffe::SliceParameter*>(
::opencv_caffe::SliceParameter::internal_default_instance());
tanh_param_ = const_cast< ::opencv_caffe::TanHParameter*>(
::opencv_caffe::TanHParameter::internal_default_instance());
threshold_param_ = const_cast< ::opencv_caffe::ThresholdParameter*>(
::opencv_caffe::ThresholdParameter::internal_default_instance());
window_data_param_ = const_cast< ::opencv_caffe::WindowDataParameter*>(
::opencv_caffe::WindowDataParameter::internal_default_instance());
transform_param_ = const_cast< ::opencv_caffe::TransformationParameter*>(
::opencv_caffe::TransformationParameter::internal_default_instance());
loss_param_ = const_cast< ::opencv_caffe::LossParameter*>(
::opencv_caffe::LossParameter::internal_default_instance());
layer_ = const_cast< ::opencv_caffe::V0LayerParameter*>(
::opencv_caffe::V0LayerParameter::internal_default_instance());
}
V1LayerParameter::V1LayerParameter(const V1LayerParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.V1LayerParameter)
}
void V1LayerParameter::SharedCtor() {
name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
accuracy_param_ = NULL;
argmax_param_ = NULL;
concat_param_ = NULL;
contrastive_loss_param_ = NULL;
convolution_param_ = NULL;
data_param_ = NULL;
dropout_param_ = NULL;
dummy_data_param_ = NULL;
eltwise_param_ = NULL;
exp_param_ = NULL;
hdf5_data_param_ = NULL;
hdf5_output_param_ = NULL;
hinge_loss_param_ = NULL;
image_data_param_ = NULL;
infogain_loss_param_ = NULL;
inner_product_param_ = NULL;
lrn_param_ = NULL;
memory_data_param_ = NULL;
mvn_param_ = NULL;
pooling_param_ = NULL;
power_param_ = NULL;
relu_param_ = NULL;
sigmoid_param_ = NULL;
softmax_param_ = NULL;
slice_param_ = NULL;
tanh_param_ = NULL;
threshold_param_ = NULL;
window_data_param_ = NULL;
transform_param_ = NULL;
loss_param_ = NULL;
layer_ = NULL;
type_ = 0;
_cached_size_ = 0;
}
V1LayerParameter::~V1LayerParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.V1LayerParameter)
SharedDtor();
}
void V1LayerParameter::SharedDtor() {
name_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
if (this != &V1LayerParameter_default_instance_.get()) {
delete accuracy_param_;
delete argmax_param_;
delete concat_param_;
delete contrastive_loss_param_;
delete convolution_param_;
delete data_param_;
delete dropout_param_;
delete dummy_data_param_;
delete eltwise_param_;
delete exp_param_;
delete hdf5_data_param_;
delete hdf5_output_param_;
delete hinge_loss_param_;
delete image_data_param_;
delete infogain_loss_param_;
delete inner_product_param_;
delete lrn_param_;
delete memory_data_param_;
delete mvn_param_;
delete pooling_param_;
delete power_param_;
delete relu_param_;
delete sigmoid_param_;
delete softmax_param_;
delete slice_param_;
delete tanh_param_;
delete threshold_param_;
delete window_data_param_;
delete transform_param_;
delete loss_param_;
delete layer_;
}
}
void V1LayerParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* V1LayerParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return V1LayerParameter_descriptor_;
}
const V1LayerParameter& V1LayerParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<V1LayerParameter> V1LayerParameter_default_instance_;
V1LayerParameter* V1LayerParameter::New(::google::protobuf::Arena* arena) const {
V1LayerParameter* n = new V1LayerParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void V1LayerParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.V1LayerParameter)
if (_has_bits_[0 / 32] & 36u) {
if (has_name()) {
name_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
type_ = 0;
}
if (_has_bits_[8 / 32] & 61440u) {
if (has_accuracy_param()) {
if (accuracy_param_ != NULL) accuracy_param_->::opencv_caffe::AccuracyParameter::Clear();
}
if (has_argmax_param()) {
if (argmax_param_ != NULL) argmax_param_->::opencv_caffe::ArgMaxParameter::Clear();
}
if (has_concat_param()) {
if (concat_param_ != NULL) concat_param_->::opencv_caffe::ConcatParameter::Clear();
}
if (has_contrastive_loss_param()) {
if (contrastive_loss_param_ != NULL) contrastive_loss_param_->::opencv_caffe::ContrastiveLossParameter::Clear();
}
}
if (_has_bits_[16 / 32] & 16711680u) {
if (has_convolution_param()) {
if (convolution_param_ != NULL) convolution_param_->::opencv_caffe::ConvolutionParameter::Clear();
}
if (has_data_param()) {
if (data_param_ != NULL) data_param_->::opencv_caffe::DataParameter::Clear();
}
if (has_dropout_param()) {
if (dropout_param_ != NULL) dropout_param_->::opencv_caffe::DropoutParameter::Clear();
}
if (has_dummy_data_param()) {
if (dummy_data_param_ != NULL) dummy_data_param_->::opencv_caffe::DummyDataParameter::Clear();
}
if (has_eltwise_param()) {
if (eltwise_param_ != NULL) eltwise_param_->::opencv_caffe::EltwiseParameter::Clear();
}
if (has_exp_param()) {
if (exp_param_ != NULL) exp_param_->::opencv_caffe::ExpParameter::Clear();
}
if (has_hdf5_data_param()) {
if (hdf5_data_param_ != NULL) hdf5_data_param_->::opencv_caffe::HDF5DataParameter::Clear();
}
if (has_hdf5_output_param()) {
if (hdf5_output_param_ != NULL) hdf5_output_param_->::opencv_caffe::HDF5OutputParameter::Clear();
}
}
if (_has_bits_[24 / 32] & 4278190080u) {
if (has_hinge_loss_param()) {
if (hinge_loss_param_ != NULL) hinge_loss_param_->::opencv_caffe::HingeLossParameter::Clear();
}
if (has_image_data_param()) {
if (image_data_param_ != NULL) image_data_param_->::opencv_caffe::ImageDataParameter::Clear();
}
if (has_infogain_loss_param()) {
if (infogain_loss_param_ != NULL) infogain_loss_param_->::opencv_caffe::InfogainLossParameter::Clear();
}
if (has_inner_product_param()) {
if (inner_product_param_ != NULL) inner_product_param_->::opencv_caffe::InnerProductParameter::Clear();
}
if (has_lrn_param()) {
if (lrn_param_ != NULL) lrn_param_->::opencv_caffe::LRNParameter::Clear();
}
if (has_memory_data_param()) {
if (memory_data_param_ != NULL) memory_data_param_->::opencv_caffe::MemoryDataParameter::Clear();
}
if (has_mvn_param()) {
if (mvn_param_ != NULL) mvn_param_->::opencv_caffe::MVNParameter::Clear();
}
if (has_pooling_param()) {
if (pooling_param_ != NULL) pooling_param_->::opencv_caffe::PoolingParameter::Clear();
}
}
if (_has_bits_[32 / 32] & 255u) {
if (has_power_param()) {
if (power_param_ != NULL) power_param_->::opencv_caffe::PowerParameter::Clear();
}
if (has_relu_param()) {
if (relu_param_ != NULL) relu_param_->::opencv_caffe::ReLUParameter::Clear();
}
if (has_sigmoid_param()) {
if (sigmoid_param_ != NULL) sigmoid_param_->::opencv_caffe::SigmoidParameter::Clear();
}
if (has_softmax_param()) {
if (softmax_param_ != NULL) softmax_param_->::opencv_caffe::SoftmaxParameter::Clear();
}
if (has_slice_param()) {
if (slice_param_ != NULL) slice_param_->::opencv_caffe::SliceParameter::Clear();
}
if (has_tanh_param()) {
if (tanh_param_ != NULL) tanh_param_->::opencv_caffe::TanHParameter::Clear();
}
if (has_threshold_param()) {
if (threshold_param_ != NULL) threshold_param_->::opencv_caffe::ThresholdParameter::Clear();
}
if (has_window_data_param()) {
if (window_data_param_ != NULL) window_data_param_->::opencv_caffe::WindowDataParameter::Clear();
}
}
if (_has_bits_[40 / 32] & 1792u) {
if (has_transform_param()) {
if (transform_param_ != NULL) transform_param_->::opencv_caffe::TransformationParameter::Clear();
}
if (has_loss_param()) {
if (loss_param_ != NULL) loss_param_->::opencv_caffe::LossParameter::Clear();
}
if (has_layer()) {
if (layer_ != NULL) layer_->::opencv_caffe::V0LayerParameter::Clear();
}
}
bottom_.Clear();
top_.Clear();
include_.Clear();
exclude_.Clear();
blobs_.Clear();
param_.Clear();
blob_share_mode_.Clear();
blobs_lr_.Clear();
weight_decay_.Clear();
loss_weight_.Clear();
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool V1LayerParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.V1LayerParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(16383);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional .opencv_caffe.V0LayerParameter layer = 1;
case 1: {
if (tag == 10) {
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_layer()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(18)) goto parse_bottom;
break;
}
// repeated string bottom = 2;
case 2: {
if (tag == 18) {
parse_bottom:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->add_bottom()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->bottom(this->bottom_size() - 1).data(),
this->bottom(this->bottom_size() - 1).length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.V1LayerParameter.bottom");
} else {
goto handle_unusual;
}
if (input->ExpectTag(18)) goto parse_bottom;
if (input->ExpectTag(26)) goto parse_top;
break;
}
// repeated string top = 3;
case 3: {
if (tag == 26) {
parse_top:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->add_top()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->top(this->top_size() - 1).data(),
this->top(this->top_size() - 1).length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.V1LayerParameter.top");
} else {
goto handle_unusual;
}
if (input->ExpectTag(26)) goto parse_top;
if (input->ExpectTag(34)) goto parse_name;
break;
}
// optional string name = 4;
case 4: {
if (tag == 34) {
parse_name:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_name()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->name().data(), this->name().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.V1LayerParameter.name");
} else {
goto handle_unusual;
}
if (input->ExpectTag(40)) goto parse_type;
break;
}
// optional .opencv_caffe.V1LayerParameter.LayerType type = 5;
case 5: {
if (tag == 40) {
parse_type:
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::V1LayerParameter_LayerType_IsValid(value)) {
set_type(static_cast< ::opencv_caffe::V1LayerParameter_LayerType >(value));
} else {
mutable_unknown_fields()->AddVarint(5, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectTag(50)) goto parse_blobs;
break;
}
// repeated .opencv_caffe.BlobProto blobs = 6;
case 6: {
if (tag == 50) {
parse_blobs:
DO_(input->IncrementRecursionDepth());
parse_loop_blobs:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtualNoRecursionDepth(
input, add_blobs()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(50)) goto parse_loop_blobs;
input->UnsafeDecrementRecursionDepth();
if (input->ExpectTag(61)) goto parse_blobs_lr;
break;
}
// repeated float blobs_lr = 7;
case 7: {
if (tag == 61) {
parse_blobs_lr:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
1, 61, input, this->mutable_blobs_lr())));
} else if (tag == 58) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, this->mutable_blobs_lr())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(61)) goto parse_blobs_lr;
if (input->ExpectTag(69)) goto parse_weight_decay;
break;
}
// repeated float weight_decay = 8;
case 8: {
if (tag == 69) {
parse_weight_decay:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
1, 69, input, this->mutable_weight_decay())));
} else if (tag == 66) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, this->mutable_weight_decay())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(69)) goto parse_weight_decay;
if (input->ExpectTag(74)) goto parse_concat_param;
break;
}
// optional .opencv_caffe.ConcatParameter concat_param = 9;
case 9: {
if (tag == 74) {
parse_concat_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_concat_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(82)) goto parse_convolution_param;
break;
}
// optional .opencv_caffe.ConvolutionParameter convolution_param = 10;
case 10: {
if (tag == 82) {
parse_convolution_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_convolution_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(90)) goto parse_data_param;
break;
}
// optional .opencv_caffe.DataParameter data_param = 11;
case 11: {
if (tag == 90) {
parse_data_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_data_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(98)) goto parse_dropout_param;
break;
}
// optional .opencv_caffe.DropoutParameter dropout_param = 12;
case 12: {
if (tag == 98) {
parse_dropout_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_dropout_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(106)) goto parse_hdf5_data_param;
break;
}
// optional .opencv_caffe.HDF5DataParameter hdf5_data_param = 13;
case 13: {
if (tag == 106) {
parse_hdf5_data_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_hdf5_data_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(114)) goto parse_hdf5_output_param;
break;
}
// optional .opencv_caffe.HDF5OutputParameter hdf5_output_param = 14;
case 14: {
if (tag == 114) {
parse_hdf5_output_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_hdf5_output_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(122)) goto parse_image_data_param;
break;
}
// optional .opencv_caffe.ImageDataParameter image_data_param = 15;
case 15: {
if (tag == 122) {
parse_image_data_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_image_data_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(130)) goto parse_infogain_loss_param;
break;
}
// optional .opencv_caffe.InfogainLossParameter infogain_loss_param = 16;
case 16: {
if (tag == 130) {
parse_infogain_loss_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_infogain_loss_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(138)) goto parse_inner_product_param;
break;
}
// optional .opencv_caffe.InnerProductParameter inner_product_param = 17;
case 17: {
if (tag == 138) {
parse_inner_product_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_inner_product_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(146)) goto parse_lrn_param;
break;
}
// optional .opencv_caffe.LRNParameter lrn_param = 18;
case 18: {
if (tag == 146) {
parse_lrn_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_lrn_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(154)) goto parse_pooling_param;
break;
}
// optional .opencv_caffe.PoolingParameter pooling_param = 19;
case 19: {
if (tag == 154) {
parse_pooling_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_pooling_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(162)) goto parse_window_data_param;
break;
}
// optional .opencv_caffe.WindowDataParameter window_data_param = 20;
case 20: {
if (tag == 162) {
parse_window_data_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_window_data_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(170)) goto parse_power_param;
break;
}
// optional .opencv_caffe.PowerParameter power_param = 21;
case 21: {
if (tag == 170) {
parse_power_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_power_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(178)) goto parse_memory_data_param;
break;
}
// optional .opencv_caffe.MemoryDataParameter memory_data_param = 22;
case 22: {
if (tag == 178) {
parse_memory_data_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_memory_data_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(186)) goto parse_argmax_param;
break;
}
// optional .opencv_caffe.ArgMaxParameter argmax_param = 23;
case 23: {
if (tag == 186) {
parse_argmax_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_argmax_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(194)) goto parse_eltwise_param;
break;
}
// optional .opencv_caffe.EltwiseParameter eltwise_param = 24;
case 24: {
if (tag == 194) {
parse_eltwise_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_eltwise_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(202)) goto parse_threshold_param;
break;
}
// optional .opencv_caffe.ThresholdParameter threshold_param = 25;
case 25: {
if (tag == 202) {
parse_threshold_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_threshold_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(210)) goto parse_dummy_data_param;
break;
}
// optional .opencv_caffe.DummyDataParameter dummy_data_param = 26;
case 26: {
if (tag == 210) {
parse_dummy_data_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_dummy_data_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(218)) goto parse_accuracy_param;
break;
}
// optional .opencv_caffe.AccuracyParameter accuracy_param = 27;
case 27: {
if (tag == 218) {
parse_accuracy_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_accuracy_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(234)) goto parse_hinge_loss_param;
break;
}
// optional .opencv_caffe.HingeLossParameter hinge_loss_param = 29;
case 29: {
if (tag == 234) {
parse_hinge_loss_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_hinge_loss_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(242)) goto parse_relu_param;
break;
}
// optional .opencv_caffe.ReLUParameter relu_param = 30;
case 30: {
if (tag == 242) {
parse_relu_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_relu_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(250)) goto parse_slice_param;
break;
}
// optional .opencv_caffe.SliceParameter slice_param = 31;
case 31: {
if (tag == 250) {
parse_slice_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_slice_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(258)) goto parse_include;
break;
}
// repeated .opencv_caffe.NetStateRule include = 32;
case 32: {
if (tag == 258) {
parse_include:
DO_(input->IncrementRecursionDepth());
parse_loop_include:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtualNoRecursionDepth(
input, add_include()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(258)) goto parse_loop_include;
if (input->ExpectTag(266)) goto parse_loop_exclude;
input->UnsafeDecrementRecursionDepth();
break;
}
// repeated .opencv_caffe.NetStateRule exclude = 33;
case 33: {
if (tag == 266) {
DO_(input->IncrementRecursionDepth());
parse_loop_exclude:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtualNoRecursionDepth(
input, add_exclude()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(266)) goto parse_loop_exclude;
input->UnsafeDecrementRecursionDepth();
if (input->ExpectTag(274)) goto parse_mvn_param;
break;
}
// optional .opencv_caffe.MVNParameter mvn_param = 34;
case 34: {
if (tag == 274) {
parse_mvn_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_mvn_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(285)) goto parse_loss_weight;
break;
}
// repeated float loss_weight = 35;
case 35: {
if (tag == 285) {
parse_loss_weight:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
2, 285, input, this->mutable_loss_weight())));
} else if (tag == 282) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, this->mutable_loss_weight())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(285)) goto parse_loss_weight;
if (input->ExpectTag(290)) goto parse_transform_param;
break;
}
// optional .opencv_caffe.TransformationParameter transform_param = 36;
case 36: {
if (tag == 290) {
parse_transform_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_transform_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(298)) goto parse_tanh_param;
break;
}
// optional .opencv_caffe.TanHParameter tanh_param = 37;
case 37: {
if (tag == 298) {
parse_tanh_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_tanh_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(306)) goto parse_sigmoid_param;
break;
}
// optional .opencv_caffe.SigmoidParameter sigmoid_param = 38;
case 38: {
if (tag == 306) {
parse_sigmoid_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_sigmoid_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(314)) goto parse_softmax_param;
break;
}
// optional .opencv_caffe.SoftmaxParameter softmax_param = 39;
case 39: {
if (tag == 314) {
parse_softmax_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_softmax_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(322)) goto parse_contrastive_loss_param;
break;
}
// optional .opencv_caffe.ContrastiveLossParameter contrastive_loss_param = 40;
case 40: {
if (tag == 322) {
parse_contrastive_loss_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_contrastive_loss_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(330)) goto parse_exp_param;
break;
}
// optional .opencv_caffe.ExpParameter exp_param = 41;
case 41: {
if (tag == 330) {
parse_exp_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_exp_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(338)) goto parse_loss_param;
break;
}
// optional .opencv_caffe.LossParameter loss_param = 42;
case 42: {
if (tag == 338) {
parse_loss_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_loss_param()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(8010)) goto parse_param;
break;
}
// repeated string param = 1001;
case 1001: {
if (tag == 8010) {
parse_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->add_param()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->param(this->param_size() - 1).data(),
this->param(this->param_size() - 1).length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.V1LayerParameter.param");
} else {
goto handle_unusual;
}
if (input->ExpectTag(8010)) goto parse_param;
if (input->ExpectTag(8016)) goto parse_blob_share_mode;
break;
}
// repeated .opencv_caffe.V1LayerParameter.DimCheckMode blob_share_mode = 1002;
case 1002: {
if (tag == 8016) {
parse_blob_share_mode:
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::V1LayerParameter_DimCheckMode_IsValid(value)) {
add_blob_share_mode(static_cast< ::opencv_caffe::V1LayerParameter_DimCheckMode >(value));
} else {
mutable_unknown_fields()->AddVarint(1002, value);
}
} else if (tag == 8018) {
DO_((::google::protobuf::internal::WireFormat::ReadPackedEnumPreserveUnknowns(
input,
1002,
::opencv_caffe::V1LayerParameter_DimCheckMode_IsValid,
mutable_unknown_fields(),
this->mutable_blob_share_mode())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(8016)) goto parse_blob_share_mode;
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.V1LayerParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.V1LayerParameter)
return false;
#undef DO_
}
void V1LayerParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.V1LayerParameter)
// optional .opencv_caffe.V0LayerParameter layer = 1;
if (has_layer()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
1, *this->layer_, output);
}
// repeated string bottom = 2;
for (int i = 0; i < this->bottom_size(); i++) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->bottom(i).data(), this->bottom(i).length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.V1LayerParameter.bottom");
::google::protobuf::internal::WireFormatLite::WriteString(
2, this->bottom(i), output);
}
// repeated string top = 3;
for (int i = 0; i < this->top_size(); i++) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->top(i).data(), this->top(i).length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.V1LayerParameter.top");
::google::protobuf::internal::WireFormatLite::WriteString(
3, this->top(i), output);
}
// optional string name = 4;
if (has_name()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->name().data(), this->name().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.V1LayerParameter.name");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
4, this->name(), output);
}
// optional .opencv_caffe.V1LayerParameter.LayerType type = 5;
if (has_type()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
5, this->type(), output);
}
// repeated .opencv_caffe.BlobProto blobs = 6;
for (unsigned int i = 0, n = this->blobs_size(); i < n; i++) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
6, this->blobs(i), output);
}
// repeated float blobs_lr = 7;
for (int i = 0; i < this->blobs_lr_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteFloat(
7, this->blobs_lr(i), output);
}
// repeated float weight_decay = 8;
for (int i = 0; i < this->weight_decay_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteFloat(
8, this->weight_decay(i), output);
}
// optional .opencv_caffe.ConcatParameter concat_param = 9;
if (has_concat_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
9, *this->concat_param_, output);
}
// optional .opencv_caffe.ConvolutionParameter convolution_param = 10;
if (has_convolution_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
10, *this->convolution_param_, output);
}
// optional .opencv_caffe.DataParameter data_param = 11;
if (has_data_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
11, *this->data_param_, output);
}
// optional .opencv_caffe.DropoutParameter dropout_param = 12;
if (has_dropout_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
12, *this->dropout_param_, output);
}
// optional .opencv_caffe.HDF5DataParameter hdf5_data_param = 13;
if (has_hdf5_data_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
13, *this->hdf5_data_param_, output);
}
// optional .opencv_caffe.HDF5OutputParameter hdf5_output_param = 14;
if (has_hdf5_output_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
14, *this->hdf5_output_param_, output);
}
// optional .opencv_caffe.ImageDataParameter image_data_param = 15;
if (has_image_data_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
15, *this->image_data_param_, output);
}
// optional .opencv_caffe.InfogainLossParameter infogain_loss_param = 16;
if (has_infogain_loss_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
16, *this->infogain_loss_param_, output);
}
// optional .opencv_caffe.InnerProductParameter inner_product_param = 17;
if (has_inner_product_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
17, *this->inner_product_param_, output);
}
// optional .opencv_caffe.LRNParameter lrn_param = 18;
if (has_lrn_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
18, *this->lrn_param_, output);
}
// optional .opencv_caffe.PoolingParameter pooling_param = 19;
if (has_pooling_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
19, *this->pooling_param_, output);
}
// optional .opencv_caffe.WindowDataParameter window_data_param = 20;
if (has_window_data_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
20, *this->window_data_param_, output);
}
// optional .opencv_caffe.PowerParameter power_param = 21;
if (has_power_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
21, *this->power_param_, output);
}
// optional .opencv_caffe.MemoryDataParameter memory_data_param = 22;
if (has_memory_data_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
22, *this->memory_data_param_, output);
}
// optional .opencv_caffe.ArgMaxParameter argmax_param = 23;
if (has_argmax_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
23, *this->argmax_param_, output);
}
// optional .opencv_caffe.EltwiseParameter eltwise_param = 24;
if (has_eltwise_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
24, *this->eltwise_param_, output);
}
// optional .opencv_caffe.ThresholdParameter threshold_param = 25;
if (has_threshold_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
25, *this->threshold_param_, output);
}
// optional .opencv_caffe.DummyDataParameter dummy_data_param = 26;
if (has_dummy_data_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
26, *this->dummy_data_param_, output);
}
// optional .opencv_caffe.AccuracyParameter accuracy_param = 27;
if (has_accuracy_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
27, *this->accuracy_param_, output);
}
// optional .opencv_caffe.HingeLossParameter hinge_loss_param = 29;
if (has_hinge_loss_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
29, *this->hinge_loss_param_, output);
}
// optional .opencv_caffe.ReLUParameter relu_param = 30;
if (has_relu_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
30, *this->relu_param_, output);
}
// optional .opencv_caffe.SliceParameter slice_param = 31;
if (has_slice_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
31, *this->slice_param_, output);
}
// repeated .opencv_caffe.NetStateRule include = 32;
for (unsigned int i = 0, n = this->include_size(); i < n; i++) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
32, this->include(i), output);
}
// repeated .opencv_caffe.NetStateRule exclude = 33;
for (unsigned int i = 0, n = this->exclude_size(); i < n; i++) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
33, this->exclude(i), output);
}
// optional .opencv_caffe.MVNParameter mvn_param = 34;
if (has_mvn_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
34, *this->mvn_param_, output);
}
// repeated float loss_weight = 35;
for (int i = 0; i < this->loss_weight_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteFloat(
35, this->loss_weight(i), output);
}
// optional .opencv_caffe.TransformationParameter transform_param = 36;
if (has_transform_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
36, *this->transform_param_, output);
}
// optional .opencv_caffe.TanHParameter tanh_param = 37;
if (has_tanh_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
37, *this->tanh_param_, output);
}
// optional .opencv_caffe.SigmoidParameter sigmoid_param = 38;
if (has_sigmoid_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
38, *this->sigmoid_param_, output);
}
// optional .opencv_caffe.SoftmaxParameter softmax_param = 39;
if (has_softmax_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
39, *this->softmax_param_, output);
}
// optional .opencv_caffe.ContrastiveLossParameter contrastive_loss_param = 40;
if (has_contrastive_loss_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
40, *this->contrastive_loss_param_, output);
}
// optional .opencv_caffe.ExpParameter exp_param = 41;
if (has_exp_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
41, *this->exp_param_, output);
}
// optional .opencv_caffe.LossParameter loss_param = 42;
if (has_loss_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
42, *this->loss_param_, output);
}
// repeated string param = 1001;
for (int i = 0; i < this->param_size(); i++) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->param(i).data(), this->param(i).length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.V1LayerParameter.param");
::google::protobuf::internal::WireFormatLite::WriteString(
1001, this->param(i), output);
}
// repeated .opencv_caffe.V1LayerParameter.DimCheckMode blob_share_mode = 1002;
for (int i = 0; i < this->blob_share_mode_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
1002, this->blob_share_mode(i), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.V1LayerParameter)
}
::google::protobuf::uint8* V1LayerParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.V1LayerParameter)
// optional .opencv_caffe.V0LayerParameter layer = 1;
if (has_layer()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
1, *this->layer_, false, target);
}
// repeated string bottom = 2;
for (int i = 0; i < this->bottom_size(); i++) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->bottom(i).data(), this->bottom(i).length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.V1LayerParameter.bottom");
target = ::google::protobuf::internal::WireFormatLite::
WriteStringToArray(2, this->bottom(i), target);
}
// repeated string top = 3;
for (int i = 0; i < this->top_size(); i++) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->top(i).data(), this->top(i).length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.V1LayerParameter.top");
target = ::google::protobuf::internal::WireFormatLite::
WriteStringToArray(3, this->top(i), target);
}
// optional string name = 4;
if (has_name()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->name().data(), this->name().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.V1LayerParameter.name");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
4, this->name(), target);
}
// optional .opencv_caffe.V1LayerParameter.LayerType type = 5;
if (has_type()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
5, this->type(), target);
}
// repeated .opencv_caffe.BlobProto blobs = 6;
for (unsigned int i = 0, n = this->blobs_size(); i < n; i++) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
6, this->blobs(i), false, target);
}
// repeated float blobs_lr = 7;
for (int i = 0; i < this->blobs_lr_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteFloatToArray(7, this->blobs_lr(i), target);
}
// repeated float weight_decay = 8;
for (int i = 0; i < this->weight_decay_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteFloatToArray(8, this->weight_decay(i), target);
}
// optional .opencv_caffe.ConcatParameter concat_param = 9;
if (has_concat_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
9, *this->concat_param_, false, target);
}
// optional .opencv_caffe.ConvolutionParameter convolution_param = 10;
if (has_convolution_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
10, *this->convolution_param_, false, target);
}
// optional .opencv_caffe.DataParameter data_param = 11;
if (has_data_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
11, *this->data_param_, false, target);
}
// optional .opencv_caffe.DropoutParameter dropout_param = 12;
if (has_dropout_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
12, *this->dropout_param_, false, target);
}
// optional .opencv_caffe.HDF5DataParameter hdf5_data_param = 13;
if (has_hdf5_data_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
13, *this->hdf5_data_param_, false, target);
}
// optional .opencv_caffe.HDF5OutputParameter hdf5_output_param = 14;
if (has_hdf5_output_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
14, *this->hdf5_output_param_, false, target);
}
// optional .opencv_caffe.ImageDataParameter image_data_param = 15;
if (has_image_data_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
15, *this->image_data_param_, false, target);
}
// optional .opencv_caffe.InfogainLossParameter infogain_loss_param = 16;
if (has_infogain_loss_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
16, *this->infogain_loss_param_, false, target);
}
// optional .opencv_caffe.InnerProductParameter inner_product_param = 17;
if (has_inner_product_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
17, *this->inner_product_param_, false, target);
}
// optional .opencv_caffe.LRNParameter lrn_param = 18;
if (has_lrn_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
18, *this->lrn_param_, false, target);
}
// optional .opencv_caffe.PoolingParameter pooling_param = 19;
if (has_pooling_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
19, *this->pooling_param_, false, target);
}
// optional .opencv_caffe.WindowDataParameter window_data_param = 20;
if (has_window_data_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
20, *this->window_data_param_, false, target);
}
// optional .opencv_caffe.PowerParameter power_param = 21;
if (has_power_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
21, *this->power_param_, false, target);
}
// optional .opencv_caffe.MemoryDataParameter memory_data_param = 22;
if (has_memory_data_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
22, *this->memory_data_param_, false, target);
}
// optional .opencv_caffe.ArgMaxParameter argmax_param = 23;
if (has_argmax_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
23, *this->argmax_param_, false, target);
}
// optional .opencv_caffe.EltwiseParameter eltwise_param = 24;
if (has_eltwise_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
24, *this->eltwise_param_, false, target);
}
// optional .opencv_caffe.ThresholdParameter threshold_param = 25;
if (has_threshold_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
25, *this->threshold_param_, false, target);
}
// optional .opencv_caffe.DummyDataParameter dummy_data_param = 26;
if (has_dummy_data_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
26, *this->dummy_data_param_, false, target);
}
// optional .opencv_caffe.AccuracyParameter accuracy_param = 27;
if (has_accuracy_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
27, *this->accuracy_param_, false, target);
}
// optional .opencv_caffe.HingeLossParameter hinge_loss_param = 29;
if (has_hinge_loss_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
29, *this->hinge_loss_param_, false, target);
}
// optional .opencv_caffe.ReLUParameter relu_param = 30;
if (has_relu_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
30, *this->relu_param_, false, target);
}
// optional .opencv_caffe.SliceParameter slice_param = 31;
if (has_slice_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
31, *this->slice_param_, false, target);
}
// repeated .opencv_caffe.NetStateRule include = 32;
for (unsigned int i = 0, n = this->include_size(); i < n; i++) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
32, this->include(i), false, target);
}
// repeated .opencv_caffe.NetStateRule exclude = 33;
for (unsigned int i = 0, n = this->exclude_size(); i < n; i++) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
33, this->exclude(i), false, target);
}
// optional .opencv_caffe.MVNParameter mvn_param = 34;
if (has_mvn_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
34, *this->mvn_param_, false, target);
}
// repeated float loss_weight = 35;
for (int i = 0; i < this->loss_weight_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteFloatToArray(35, this->loss_weight(i), target);
}
// optional .opencv_caffe.TransformationParameter transform_param = 36;
if (has_transform_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
36, *this->transform_param_, false, target);
}
// optional .opencv_caffe.TanHParameter tanh_param = 37;
if (has_tanh_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
37, *this->tanh_param_, false, target);
}
// optional .opencv_caffe.SigmoidParameter sigmoid_param = 38;
if (has_sigmoid_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
38, *this->sigmoid_param_, false, target);
}
// optional .opencv_caffe.SoftmaxParameter softmax_param = 39;
if (has_softmax_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
39, *this->softmax_param_, false, target);
}
// optional .opencv_caffe.ContrastiveLossParameter contrastive_loss_param = 40;
if (has_contrastive_loss_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
40, *this->contrastive_loss_param_, false, target);
}
// optional .opencv_caffe.ExpParameter exp_param = 41;
if (has_exp_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
41, *this->exp_param_, false, target);
}
// optional .opencv_caffe.LossParameter loss_param = 42;
if (has_loss_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
42, *this->loss_param_, false, target);
}
// repeated string param = 1001;
for (int i = 0; i < this->param_size(); i++) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->param(i).data(), this->param(i).length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.V1LayerParameter.param");
target = ::google::protobuf::internal::WireFormatLite::
WriteStringToArray(1001, this->param(i), target);
}
// repeated .opencv_caffe.V1LayerParameter.DimCheckMode blob_share_mode = 1002;
for (int i = 0; i < this->blob_share_mode_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
1002, this->blob_share_mode(i), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.V1LayerParameter)
return target;
}
size_t V1LayerParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.V1LayerParameter)
size_t total_size = 0;
if (_has_bits_[2 / 32] & 36u) {
// optional string name = 4;
if (has_name()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->name());
}
// optional .opencv_caffe.V1LayerParameter.LayerType type = 5;
if (has_type()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->type());
}
}
if (_has_bits_[12 / 32] & 61440u) {
// optional .opencv_caffe.AccuracyParameter accuracy_param = 27;
if (has_accuracy_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->accuracy_param_);
}
// optional .opencv_caffe.ArgMaxParameter argmax_param = 23;
if (has_argmax_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->argmax_param_);
}
// optional .opencv_caffe.ConcatParameter concat_param = 9;
if (has_concat_param()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->concat_param_);
}
// optional .opencv_caffe.ContrastiveLossParameter contrastive_loss_param = 40;
if (has_contrastive_loss_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->contrastive_loss_param_);
}
}
if (_has_bits_[16 / 32] & 16711680u) {
// optional .opencv_caffe.ConvolutionParameter convolution_param = 10;
if (has_convolution_param()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->convolution_param_);
}
// optional .opencv_caffe.DataParameter data_param = 11;
if (has_data_param()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->data_param_);
}
// optional .opencv_caffe.DropoutParameter dropout_param = 12;
if (has_dropout_param()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->dropout_param_);
}
// optional .opencv_caffe.DummyDataParameter dummy_data_param = 26;
if (has_dummy_data_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->dummy_data_param_);
}
// optional .opencv_caffe.EltwiseParameter eltwise_param = 24;
if (has_eltwise_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->eltwise_param_);
}
// optional .opencv_caffe.ExpParameter exp_param = 41;
if (has_exp_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->exp_param_);
}
// optional .opencv_caffe.HDF5DataParameter hdf5_data_param = 13;
if (has_hdf5_data_param()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->hdf5_data_param_);
}
// optional .opencv_caffe.HDF5OutputParameter hdf5_output_param = 14;
if (has_hdf5_output_param()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->hdf5_output_param_);
}
}
if (_has_bits_[24 / 32] & 4278190080u) {
// optional .opencv_caffe.HingeLossParameter hinge_loss_param = 29;
if (has_hinge_loss_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->hinge_loss_param_);
}
// optional .opencv_caffe.ImageDataParameter image_data_param = 15;
if (has_image_data_param()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->image_data_param_);
}
// optional .opencv_caffe.InfogainLossParameter infogain_loss_param = 16;
if (has_infogain_loss_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->infogain_loss_param_);
}
// optional .opencv_caffe.InnerProductParameter inner_product_param = 17;
if (has_inner_product_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->inner_product_param_);
}
// optional .opencv_caffe.LRNParameter lrn_param = 18;
if (has_lrn_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->lrn_param_);
}
// optional .opencv_caffe.MemoryDataParameter memory_data_param = 22;
if (has_memory_data_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->memory_data_param_);
}
// optional .opencv_caffe.MVNParameter mvn_param = 34;
if (has_mvn_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->mvn_param_);
}
// optional .opencv_caffe.PoolingParameter pooling_param = 19;
if (has_pooling_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->pooling_param_);
}
}
if (_has_bits_[32 / 32] & 255u) {
// optional .opencv_caffe.PowerParameter power_param = 21;
if (has_power_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->power_param_);
}
// optional .opencv_caffe.ReLUParameter relu_param = 30;
if (has_relu_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->relu_param_);
}
// optional .opencv_caffe.SigmoidParameter sigmoid_param = 38;
if (has_sigmoid_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->sigmoid_param_);
}
// optional .opencv_caffe.SoftmaxParameter softmax_param = 39;
if (has_softmax_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->softmax_param_);
}
// optional .opencv_caffe.SliceParameter slice_param = 31;
if (has_slice_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->slice_param_);
}
// optional .opencv_caffe.TanHParameter tanh_param = 37;
if (has_tanh_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->tanh_param_);
}
// optional .opencv_caffe.ThresholdParameter threshold_param = 25;
if (has_threshold_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->threshold_param_);
}
// optional .opencv_caffe.WindowDataParameter window_data_param = 20;
if (has_window_data_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->window_data_param_);
}
}
if (_has_bits_[40 / 32] & 1792u) {
// optional .opencv_caffe.TransformationParameter transform_param = 36;
if (has_transform_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->transform_param_);
}
// optional .opencv_caffe.LossParameter loss_param = 42;
if (has_loss_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->loss_param_);
}
// optional .opencv_caffe.V0LayerParameter layer = 1;
if (has_layer()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->layer_);
}
}
// repeated string bottom = 2;
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->bottom_size());
for (int i = 0; i < this->bottom_size(); i++) {
total_size += ::google::protobuf::internal::WireFormatLite::StringSize(
this->bottom(i));
}
// repeated string top = 3;
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->top_size());
for (int i = 0; i < this->top_size(); i++) {
total_size += ::google::protobuf::internal::WireFormatLite::StringSize(
this->top(i));
}
// repeated .opencv_caffe.NetStateRule include = 32;
{
unsigned int count = this->include_size();
total_size += 2UL * count;
for (unsigned int i = 0; i < count; i++) {
total_size +=
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
this->include(i));
}
}
// repeated .opencv_caffe.NetStateRule exclude = 33;
{
unsigned int count = this->exclude_size();
total_size += 2UL * count;
for (unsigned int i = 0; i < count; i++) {
total_size +=
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
this->exclude(i));
}
}
// repeated .opencv_caffe.BlobProto blobs = 6;
{
unsigned int count = this->blobs_size();
total_size += 1UL * count;
for (unsigned int i = 0; i < count; i++) {
total_size +=
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
this->blobs(i));
}
}
// repeated string param = 1001;
total_size += 2 *
::google::protobuf::internal::FromIntSize(this->param_size());
for (int i = 0; i < this->param_size(); i++) {
total_size += ::google::protobuf::internal::WireFormatLite::StringSize(
this->param(i));
}
// repeated .opencv_caffe.V1LayerParameter.DimCheckMode blob_share_mode = 1002;
{
size_t data_size = 0;
unsigned int count = this->blob_share_mode_size();for (unsigned int i = 0; i < count; i++) {
data_size += ::google::protobuf::internal::WireFormatLite::EnumSize(
this->blob_share_mode(i));
}
total_size += (2UL * count) + data_size;
}
// repeated float blobs_lr = 7;
{
size_t data_size = 0;
unsigned int count = this->blobs_lr_size();
data_size = 4UL * count;
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->blobs_lr_size());
total_size += data_size;
}
// repeated float weight_decay = 8;
{
size_t data_size = 0;
unsigned int count = this->weight_decay_size();
data_size = 4UL * count;
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->weight_decay_size());
total_size += data_size;
}
// repeated float loss_weight = 35;
{
size_t data_size = 0;
unsigned int count = this->loss_weight_size();
data_size = 4UL * count;
total_size += 2 *
::google::protobuf::internal::FromIntSize(this->loss_weight_size());
total_size += data_size;
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void V1LayerParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.V1LayerParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const V1LayerParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const V1LayerParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.V1LayerParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.V1LayerParameter)
UnsafeMergeFrom(*source);
}
}
void V1LayerParameter::MergeFrom(const V1LayerParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.V1LayerParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void V1LayerParameter::UnsafeMergeFrom(const V1LayerParameter& from) {
GOOGLE_DCHECK(&from != this);
bottom_.UnsafeMergeFrom(from.bottom_);
top_.UnsafeMergeFrom(from.top_);
include_.MergeFrom(from.include_);
exclude_.MergeFrom(from.exclude_);
blobs_.MergeFrom(from.blobs_);
param_.UnsafeMergeFrom(from.param_);
blob_share_mode_.UnsafeMergeFrom(from.blob_share_mode_);
blobs_lr_.UnsafeMergeFrom(from.blobs_lr_);
weight_decay_.UnsafeMergeFrom(from.weight_decay_);
loss_weight_.UnsafeMergeFrom(from.loss_weight_);
if (from._has_bits_[2 / 32] & (0xffu << (2 % 32))) {
if (from.has_name()) {
set_has_name();
name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.name_);
}
if (from.has_type()) {
set_type(from.type());
}
}
if (from._has_bits_[12 / 32] & (0xffu << (12 % 32))) {
if (from.has_accuracy_param()) {
mutable_accuracy_param()->::opencv_caffe::AccuracyParameter::MergeFrom(from.accuracy_param());
}
if (from.has_argmax_param()) {
mutable_argmax_param()->::opencv_caffe::ArgMaxParameter::MergeFrom(from.argmax_param());
}
if (from.has_concat_param()) {
mutable_concat_param()->::opencv_caffe::ConcatParameter::MergeFrom(from.concat_param());
}
if (from.has_contrastive_loss_param()) {
mutable_contrastive_loss_param()->::opencv_caffe::ContrastiveLossParameter::MergeFrom(from.contrastive_loss_param());
}
}
if (from._has_bits_[16 / 32] & (0xffu << (16 % 32))) {
if (from.has_convolution_param()) {
mutable_convolution_param()->::opencv_caffe::ConvolutionParameter::MergeFrom(from.convolution_param());
}
if (from.has_data_param()) {
mutable_data_param()->::opencv_caffe::DataParameter::MergeFrom(from.data_param());
}
if (from.has_dropout_param()) {
mutable_dropout_param()->::opencv_caffe::DropoutParameter::MergeFrom(from.dropout_param());
}
if (from.has_dummy_data_param()) {
mutable_dummy_data_param()->::opencv_caffe::DummyDataParameter::MergeFrom(from.dummy_data_param());
}
if (from.has_eltwise_param()) {
mutable_eltwise_param()->::opencv_caffe::EltwiseParameter::MergeFrom(from.eltwise_param());
}
if (from.has_exp_param()) {
mutable_exp_param()->::opencv_caffe::ExpParameter::MergeFrom(from.exp_param());
}
if (from.has_hdf5_data_param()) {
mutable_hdf5_data_param()->::opencv_caffe::HDF5DataParameter::MergeFrom(from.hdf5_data_param());
}
if (from.has_hdf5_output_param()) {
mutable_hdf5_output_param()->::opencv_caffe::HDF5OutputParameter::MergeFrom(from.hdf5_output_param());
}
}
if (from._has_bits_[24 / 32] & (0xffu << (24 % 32))) {
if (from.has_hinge_loss_param()) {
mutable_hinge_loss_param()->::opencv_caffe::HingeLossParameter::MergeFrom(from.hinge_loss_param());
}
if (from.has_image_data_param()) {
mutable_image_data_param()->::opencv_caffe::ImageDataParameter::MergeFrom(from.image_data_param());
}
if (from.has_infogain_loss_param()) {
mutable_infogain_loss_param()->::opencv_caffe::InfogainLossParameter::MergeFrom(from.infogain_loss_param());
}
if (from.has_inner_product_param()) {
mutable_inner_product_param()->::opencv_caffe::InnerProductParameter::MergeFrom(from.inner_product_param());
}
if (from.has_lrn_param()) {
mutable_lrn_param()->::opencv_caffe::LRNParameter::MergeFrom(from.lrn_param());
}
if (from.has_memory_data_param()) {
mutable_memory_data_param()->::opencv_caffe::MemoryDataParameter::MergeFrom(from.memory_data_param());
}
if (from.has_mvn_param()) {
mutable_mvn_param()->::opencv_caffe::MVNParameter::MergeFrom(from.mvn_param());
}
if (from.has_pooling_param()) {
mutable_pooling_param()->::opencv_caffe::PoolingParameter::MergeFrom(from.pooling_param());
}
}
if (from._has_bits_[32 / 32] & (0xffu << (32 % 32))) {
if (from.has_power_param()) {
mutable_power_param()->::opencv_caffe::PowerParameter::MergeFrom(from.power_param());
}
if (from.has_relu_param()) {
mutable_relu_param()->::opencv_caffe::ReLUParameter::MergeFrom(from.relu_param());
}
if (from.has_sigmoid_param()) {
mutable_sigmoid_param()->::opencv_caffe::SigmoidParameter::MergeFrom(from.sigmoid_param());
}
if (from.has_softmax_param()) {
mutable_softmax_param()->::opencv_caffe::SoftmaxParameter::MergeFrom(from.softmax_param());
}
if (from.has_slice_param()) {
mutable_slice_param()->::opencv_caffe::SliceParameter::MergeFrom(from.slice_param());
}
if (from.has_tanh_param()) {
mutable_tanh_param()->::opencv_caffe::TanHParameter::MergeFrom(from.tanh_param());
}
if (from.has_threshold_param()) {
mutable_threshold_param()->::opencv_caffe::ThresholdParameter::MergeFrom(from.threshold_param());
}
if (from.has_window_data_param()) {
mutable_window_data_param()->::opencv_caffe::WindowDataParameter::MergeFrom(from.window_data_param());
}
}
if (from._has_bits_[40 / 32] & (0xffu << (40 % 32))) {
if (from.has_transform_param()) {
mutable_transform_param()->::opencv_caffe::TransformationParameter::MergeFrom(from.transform_param());
}
if (from.has_loss_param()) {
mutable_loss_param()->::opencv_caffe::LossParameter::MergeFrom(from.loss_param());
}
if (from.has_layer()) {
mutable_layer()->::opencv_caffe::V0LayerParameter::MergeFrom(from.layer());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void V1LayerParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.V1LayerParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void V1LayerParameter::CopyFrom(const V1LayerParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.V1LayerParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool V1LayerParameter::IsInitialized() const {
return true;
}
void V1LayerParameter::Swap(V1LayerParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void V1LayerParameter::InternalSwap(V1LayerParameter* other) {
bottom_.UnsafeArenaSwap(&other->bottom_);
top_.UnsafeArenaSwap(&other->top_);
name_.Swap(&other->name_);
include_.UnsafeArenaSwap(&other->include_);
exclude_.UnsafeArenaSwap(&other->exclude_);
std::swap(type_, other->type_);
blobs_.UnsafeArenaSwap(&other->blobs_);
param_.UnsafeArenaSwap(&other->param_);
blob_share_mode_.UnsafeArenaSwap(&other->blob_share_mode_);
blobs_lr_.UnsafeArenaSwap(&other->blobs_lr_);
weight_decay_.UnsafeArenaSwap(&other->weight_decay_);
loss_weight_.UnsafeArenaSwap(&other->loss_weight_);
std::swap(accuracy_param_, other->accuracy_param_);
std::swap(argmax_param_, other->argmax_param_);
std::swap(concat_param_, other->concat_param_);
std::swap(contrastive_loss_param_, other->contrastive_loss_param_);
std::swap(convolution_param_, other->convolution_param_);
std::swap(data_param_, other->data_param_);
std::swap(dropout_param_, other->dropout_param_);
std::swap(dummy_data_param_, other->dummy_data_param_);
std::swap(eltwise_param_, other->eltwise_param_);
std::swap(exp_param_, other->exp_param_);
std::swap(hdf5_data_param_, other->hdf5_data_param_);
std::swap(hdf5_output_param_, other->hdf5_output_param_);
std::swap(hinge_loss_param_, other->hinge_loss_param_);
std::swap(image_data_param_, other->image_data_param_);
std::swap(infogain_loss_param_, other->infogain_loss_param_);
std::swap(inner_product_param_, other->inner_product_param_);
std::swap(lrn_param_, other->lrn_param_);
std::swap(memory_data_param_, other->memory_data_param_);
std::swap(mvn_param_, other->mvn_param_);
std::swap(pooling_param_, other->pooling_param_);
std::swap(power_param_, other->power_param_);
std::swap(relu_param_, other->relu_param_);
std::swap(sigmoid_param_, other->sigmoid_param_);
std::swap(softmax_param_, other->softmax_param_);
std::swap(slice_param_, other->slice_param_);
std::swap(tanh_param_, other->tanh_param_);
std::swap(threshold_param_, other->threshold_param_);
std::swap(window_data_param_, other->window_data_param_);
std::swap(transform_param_, other->transform_param_);
std::swap(loss_param_, other->loss_param_);
std::swap(layer_, other->layer_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
std::swap(_has_bits_[1], other->_has_bits_[1]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata V1LayerParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = V1LayerParameter_descriptor_;
metadata.reflection = V1LayerParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// V1LayerParameter
// repeated string bottom = 2;
int V1LayerParameter::bottom_size() const {
return bottom_.size();
}
void V1LayerParameter::clear_bottom() {
bottom_.Clear();
}
const ::std::string& V1LayerParameter::bottom(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.bottom)
return bottom_.Get(index);
}
::std::string* V1LayerParameter::mutable_bottom(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.bottom)
return bottom_.Mutable(index);
}
void V1LayerParameter::set_bottom(int index, const ::std::string& value) {
// @@protoc_insertion_point(field_set:opencv_caffe.V1LayerParameter.bottom)
bottom_.Mutable(index)->assign(value);
}
void V1LayerParameter::set_bottom(int index, const char* value) {
bottom_.Mutable(index)->assign(value);
// @@protoc_insertion_point(field_set_char:opencv_caffe.V1LayerParameter.bottom)
}
void V1LayerParameter::set_bottom(int index, const char* value, size_t size) {
bottom_.Mutable(index)->assign(
reinterpret_cast<const char*>(value), size);
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.V1LayerParameter.bottom)
}
::std::string* V1LayerParameter::add_bottom() {
// @@protoc_insertion_point(field_add_mutable:opencv_caffe.V1LayerParameter.bottom)
return bottom_.Add();
}
void V1LayerParameter::add_bottom(const ::std::string& value) {
bottom_.Add()->assign(value);
// @@protoc_insertion_point(field_add:opencv_caffe.V1LayerParameter.bottom)
}
void V1LayerParameter::add_bottom(const char* value) {
bottom_.Add()->assign(value);
// @@protoc_insertion_point(field_add_char:opencv_caffe.V1LayerParameter.bottom)
}
void V1LayerParameter::add_bottom(const char* value, size_t size) {
bottom_.Add()->assign(reinterpret_cast<const char*>(value), size);
// @@protoc_insertion_point(field_add_pointer:opencv_caffe.V1LayerParameter.bottom)
}
const ::google::protobuf::RepeatedPtrField< ::std::string>&
V1LayerParameter::bottom() const {
// @@protoc_insertion_point(field_list:opencv_caffe.V1LayerParameter.bottom)
return bottom_;
}
::google::protobuf::RepeatedPtrField< ::std::string>*
V1LayerParameter::mutable_bottom() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.V1LayerParameter.bottom)
return &bottom_;
}
// repeated string top = 3;
int V1LayerParameter::top_size() const {
return top_.size();
}
void V1LayerParameter::clear_top() {
top_.Clear();
}
const ::std::string& V1LayerParameter::top(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.top)
return top_.Get(index);
}
::std::string* V1LayerParameter::mutable_top(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.top)
return top_.Mutable(index);
}
void V1LayerParameter::set_top(int index, const ::std::string& value) {
// @@protoc_insertion_point(field_set:opencv_caffe.V1LayerParameter.top)
top_.Mutable(index)->assign(value);
}
void V1LayerParameter::set_top(int index, const char* value) {
top_.Mutable(index)->assign(value);
// @@protoc_insertion_point(field_set_char:opencv_caffe.V1LayerParameter.top)
}
void V1LayerParameter::set_top(int index, const char* value, size_t size) {
top_.Mutable(index)->assign(
reinterpret_cast<const char*>(value), size);
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.V1LayerParameter.top)
}
::std::string* V1LayerParameter::add_top() {
// @@protoc_insertion_point(field_add_mutable:opencv_caffe.V1LayerParameter.top)
return top_.Add();
}
void V1LayerParameter::add_top(const ::std::string& value) {
top_.Add()->assign(value);
// @@protoc_insertion_point(field_add:opencv_caffe.V1LayerParameter.top)
}
void V1LayerParameter::add_top(const char* value) {
top_.Add()->assign(value);
// @@protoc_insertion_point(field_add_char:opencv_caffe.V1LayerParameter.top)
}
void V1LayerParameter::add_top(const char* value, size_t size) {
top_.Add()->assign(reinterpret_cast<const char*>(value), size);
// @@protoc_insertion_point(field_add_pointer:opencv_caffe.V1LayerParameter.top)
}
const ::google::protobuf::RepeatedPtrField< ::std::string>&
V1LayerParameter::top() const {
// @@protoc_insertion_point(field_list:opencv_caffe.V1LayerParameter.top)
return top_;
}
::google::protobuf::RepeatedPtrField< ::std::string>*
V1LayerParameter::mutable_top() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.V1LayerParameter.top)
return &top_;
}
// optional string name = 4;
bool V1LayerParameter::has_name() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void V1LayerParameter::set_has_name() {
_has_bits_[0] |= 0x00000004u;
}
void V1LayerParameter::clear_has_name() {
_has_bits_[0] &= ~0x00000004u;
}
void V1LayerParameter::clear_name() {
name_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_name();
}
const ::std::string& V1LayerParameter::name() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.name)
return name_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void V1LayerParameter::set_name(const ::std::string& value) {
set_has_name();
name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.V1LayerParameter.name)
}
void V1LayerParameter::set_name(const char* value) {
set_has_name();
name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.V1LayerParameter.name)
}
void V1LayerParameter::set_name(const char* value, size_t size) {
set_has_name();
name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.V1LayerParameter.name)
}
::std::string* V1LayerParameter::mutable_name() {
set_has_name();
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.name)
return name_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* V1LayerParameter::release_name() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.name)
clear_has_name();
return name_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void V1LayerParameter::set_allocated_name(::std::string* name) {
if (name != NULL) {
set_has_name();
} else {
clear_has_name();
}
name_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), name);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.name)
}
// repeated .opencv_caffe.NetStateRule include = 32;
int V1LayerParameter::include_size() const {
return include_.size();
}
void V1LayerParameter::clear_include() {
include_.Clear();
}
const ::opencv_caffe::NetStateRule& V1LayerParameter::include(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.include)
return include_.Get(index);
}
::opencv_caffe::NetStateRule* V1LayerParameter::mutable_include(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.include)
return include_.Mutable(index);
}
::opencv_caffe::NetStateRule* V1LayerParameter::add_include() {
// @@protoc_insertion_point(field_add:opencv_caffe.V1LayerParameter.include)
return include_.Add();
}
::google::protobuf::RepeatedPtrField< ::opencv_caffe::NetStateRule >*
V1LayerParameter::mutable_include() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.V1LayerParameter.include)
return &include_;
}
const ::google::protobuf::RepeatedPtrField< ::opencv_caffe::NetStateRule >&
V1LayerParameter::include() const {
// @@protoc_insertion_point(field_list:opencv_caffe.V1LayerParameter.include)
return include_;
}
// repeated .opencv_caffe.NetStateRule exclude = 33;
int V1LayerParameter::exclude_size() const {
return exclude_.size();
}
void V1LayerParameter::clear_exclude() {
exclude_.Clear();
}
const ::opencv_caffe::NetStateRule& V1LayerParameter::exclude(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.exclude)
return exclude_.Get(index);
}
::opencv_caffe::NetStateRule* V1LayerParameter::mutable_exclude(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.exclude)
return exclude_.Mutable(index);
}
::opencv_caffe::NetStateRule* V1LayerParameter::add_exclude() {
// @@protoc_insertion_point(field_add:opencv_caffe.V1LayerParameter.exclude)
return exclude_.Add();
}
::google::protobuf::RepeatedPtrField< ::opencv_caffe::NetStateRule >*
V1LayerParameter::mutable_exclude() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.V1LayerParameter.exclude)
return &exclude_;
}
const ::google::protobuf::RepeatedPtrField< ::opencv_caffe::NetStateRule >&
V1LayerParameter::exclude() const {
// @@protoc_insertion_point(field_list:opencv_caffe.V1LayerParameter.exclude)
return exclude_;
}
// optional .opencv_caffe.V1LayerParameter.LayerType type = 5;
bool V1LayerParameter::has_type() const {
return (_has_bits_[0] & 0x00000020u) != 0;
}
void V1LayerParameter::set_has_type() {
_has_bits_[0] |= 0x00000020u;
}
void V1LayerParameter::clear_has_type() {
_has_bits_[0] &= ~0x00000020u;
}
void V1LayerParameter::clear_type() {
type_ = 0;
clear_has_type();
}
::opencv_caffe::V1LayerParameter_LayerType V1LayerParameter::type() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.type)
return static_cast< ::opencv_caffe::V1LayerParameter_LayerType >(type_);
}
void V1LayerParameter::set_type(::opencv_caffe::V1LayerParameter_LayerType value) {
assert(::opencv_caffe::V1LayerParameter_LayerType_IsValid(value));
set_has_type();
type_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V1LayerParameter.type)
}
// repeated .opencv_caffe.BlobProto blobs = 6;
int V1LayerParameter::blobs_size() const {
return blobs_.size();
}
void V1LayerParameter::clear_blobs() {
blobs_.Clear();
}
const ::opencv_caffe::BlobProto& V1LayerParameter::blobs(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.blobs)
return blobs_.Get(index);
}
::opencv_caffe::BlobProto* V1LayerParameter::mutable_blobs(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.blobs)
return blobs_.Mutable(index);
}
::opencv_caffe::BlobProto* V1LayerParameter::add_blobs() {
// @@protoc_insertion_point(field_add:opencv_caffe.V1LayerParameter.blobs)
return blobs_.Add();
}
::google::protobuf::RepeatedPtrField< ::opencv_caffe::BlobProto >*
V1LayerParameter::mutable_blobs() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.V1LayerParameter.blobs)
return &blobs_;
}
const ::google::protobuf::RepeatedPtrField< ::opencv_caffe::BlobProto >&
V1LayerParameter::blobs() const {
// @@protoc_insertion_point(field_list:opencv_caffe.V1LayerParameter.blobs)
return blobs_;
}
// repeated string param = 1001;
int V1LayerParameter::param_size() const {
return param_.size();
}
void V1LayerParameter::clear_param() {
param_.Clear();
}
const ::std::string& V1LayerParameter::param(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.param)
return param_.Get(index);
}
::std::string* V1LayerParameter::mutable_param(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.param)
return param_.Mutable(index);
}
void V1LayerParameter::set_param(int index, const ::std::string& value) {
// @@protoc_insertion_point(field_set:opencv_caffe.V1LayerParameter.param)
param_.Mutable(index)->assign(value);
}
void V1LayerParameter::set_param(int index, const char* value) {
param_.Mutable(index)->assign(value);
// @@protoc_insertion_point(field_set_char:opencv_caffe.V1LayerParameter.param)
}
void V1LayerParameter::set_param(int index, const char* value, size_t size) {
param_.Mutable(index)->assign(
reinterpret_cast<const char*>(value), size);
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.V1LayerParameter.param)
}
::std::string* V1LayerParameter::add_param() {
// @@protoc_insertion_point(field_add_mutable:opencv_caffe.V1LayerParameter.param)
return param_.Add();
}
void V1LayerParameter::add_param(const ::std::string& value) {
param_.Add()->assign(value);
// @@protoc_insertion_point(field_add:opencv_caffe.V1LayerParameter.param)
}
void V1LayerParameter::add_param(const char* value) {
param_.Add()->assign(value);
// @@protoc_insertion_point(field_add_char:opencv_caffe.V1LayerParameter.param)
}
void V1LayerParameter::add_param(const char* value, size_t size) {
param_.Add()->assign(reinterpret_cast<const char*>(value), size);
// @@protoc_insertion_point(field_add_pointer:opencv_caffe.V1LayerParameter.param)
}
const ::google::protobuf::RepeatedPtrField< ::std::string>&
V1LayerParameter::param() const {
// @@protoc_insertion_point(field_list:opencv_caffe.V1LayerParameter.param)
return param_;
}
::google::protobuf::RepeatedPtrField< ::std::string>*
V1LayerParameter::mutable_param() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.V1LayerParameter.param)
return &param_;
}
// repeated .opencv_caffe.V1LayerParameter.DimCheckMode blob_share_mode = 1002;
int V1LayerParameter::blob_share_mode_size() const {
return blob_share_mode_.size();
}
void V1LayerParameter::clear_blob_share_mode() {
blob_share_mode_.Clear();
}
::opencv_caffe::V1LayerParameter_DimCheckMode V1LayerParameter::blob_share_mode(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.blob_share_mode)
return static_cast< ::opencv_caffe::V1LayerParameter_DimCheckMode >(blob_share_mode_.Get(index));
}
void V1LayerParameter::set_blob_share_mode(int index, ::opencv_caffe::V1LayerParameter_DimCheckMode value) {
assert(::opencv_caffe::V1LayerParameter_DimCheckMode_IsValid(value));
blob_share_mode_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.V1LayerParameter.blob_share_mode)
}
void V1LayerParameter::add_blob_share_mode(::opencv_caffe::V1LayerParameter_DimCheckMode value) {
assert(::opencv_caffe::V1LayerParameter_DimCheckMode_IsValid(value));
blob_share_mode_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.V1LayerParameter.blob_share_mode)
}
const ::google::protobuf::RepeatedField<int>&
V1LayerParameter::blob_share_mode() const {
// @@protoc_insertion_point(field_list:opencv_caffe.V1LayerParameter.blob_share_mode)
return blob_share_mode_;
}
::google::protobuf::RepeatedField<int>*
V1LayerParameter::mutable_blob_share_mode() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.V1LayerParameter.blob_share_mode)
return &blob_share_mode_;
}
// repeated float blobs_lr = 7;
int V1LayerParameter::blobs_lr_size() const {
return blobs_lr_.size();
}
void V1LayerParameter::clear_blobs_lr() {
blobs_lr_.Clear();
}
float V1LayerParameter::blobs_lr(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.blobs_lr)
return blobs_lr_.Get(index);
}
void V1LayerParameter::set_blobs_lr(int index, float value) {
blobs_lr_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.V1LayerParameter.blobs_lr)
}
void V1LayerParameter::add_blobs_lr(float value) {
blobs_lr_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.V1LayerParameter.blobs_lr)
}
const ::google::protobuf::RepeatedField< float >&
V1LayerParameter::blobs_lr() const {
// @@protoc_insertion_point(field_list:opencv_caffe.V1LayerParameter.blobs_lr)
return blobs_lr_;
}
::google::protobuf::RepeatedField< float >*
V1LayerParameter::mutable_blobs_lr() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.V1LayerParameter.blobs_lr)
return &blobs_lr_;
}
// repeated float weight_decay = 8;
int V1LayerParameter::weight_decay_size() const {
return weight_decay_.size();
}
void V1LayerParameter::clear_weight_decay() {
weight_decay_.Clear();
}
float V1LayerParameter::weight_decay(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.weight_decay)
return weight_decay_.Get(index);
}
void V1LayerParameter::set_weight_decay(int index, float value) {
weight_decay_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.V1LayerParameter.weight_decay)
}
void V1LayerParameter::add_weight_decay(float value) {
weight_decay_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.V1LayerParameter.weight_decay)
}
const ::google::protobuf::RepeatedField< float >&
V1LayerParameter::weight_decay() const {
// @@protoc_insertion_point(field_list:opencv_caffe.V1LayerParameter.weight_decay)
return weight_decay_;
}
::google::protobuf::RepeatedField< float >*
V1LayerParameter::mutable_weight_decay() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.V1LayerParameter.weight_decay)
return &weight_decay_;
}
// repeated float loss_weight = 35;
int V1LayerParameter::loss_weight_size() const {
return loss_weight_.size();
}
void V1LayerParameter::clear_loss_weight() {
loss_weight_.Clear();
}
float V1LayerParameter::loss_weight(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.loss_weight)
return loss_weight_.Get(index);
}
void V1LayerParameter::set_loss_weight(int index, float value) {
loss_weight_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.V1LayerParameter.loss_weight)
}
void V1LayerParameter::add_loss_weight(float value) {
loss_weight_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.V1LayerParameter.loss_weight)
}
const ::google::protobuf::RepeatedField< float >&
V1LayerParameter::loss_weight() const {
// @@protoc_insertion_point(field_list:opencv_caffe.V1LayerParameter.loss_weight)
return loss_weight_;
}
::google::protobuf::RepeatedField< float >*
V1LayerParameter::mutable_loss_weight() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.V1LayerParameter.loss_weight)
return &loss_weight_;
}
// optional .opencv_caffe.AccuracyParameter accuracy_param = 27;
bool V1LayerParameter::has_accuracy_param() const {
return (_has_bits_[0] & 0x00001000u) != 0;
}
void V1LayerParameter::set_has_accuracy_param() {
_has_bits_[0] |= 0x00001000u;
}
void V1LayerParameter::clear_has_accuracy_param() {
_has_bits_[0] &= ~0x00001000u;
}
void V1LayerParameter::clear_accuracy_param() {
if (accuracy_param_ != NULL) accuracy_param_->::opencv_caffe::AccuracyParameter::Clear();
clear_has_accuracy_param();
}
const ::opencv_caffe::AccuracyParameter& V1LayerParameter::accuracy_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.accuracy_param)
return accuracy_param_ != NULL ? *accuracy_param_
: *::opencv_caffe::AccuracyParameter::internal_default_instance();
}
::opencv_caffe::AccuracyParameter* V1LayerParameter::mutable_accuracy_param() {
set_has_accuracy_param();
if (accuracy_param_ == NULL) {
accuracy_param_ = new ::opencv_caffe::AccuracyParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.accuracy_param)
return accuracy_param_;
}
::opencv_caffe::AccuracyParameter* V1LayerParameter::release_accuracy_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.accuracy_param)
clear_has_accuracy_param();
::opencv_caffe::AccuracyParameter* temp = accuracy_param_;
accuracy_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_accuracy_param(::opencv_caffe::AccuracyParameter* accuracy_param) {
delete accuracy_param_;
accuracy_param_ = accuracy_param;
if (accuracy_param) {
set_has_accuracy_param();
} else {
clear_has_accuracy_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.accuracy_param)
}
// optional .opencv_caffe.ArgMaxParameter argmax_param = 23;
bool V1LayerParameter::has_argmax_param() const {
return (_has_bits_[0] & 0x00002000u) != 0;
}
void V1LayerParameter::set_has_argmax_param() {
_has_bits_[0] |= 0x00002000u;
}
void V1LayerParameter::clear_has_argmax_param() {
_has_bits_[0] &= ~0x00002000u;
}
void V1LayerParameter::clear_argmax_param() {
if (argmax_param_ != NULL) argmax_param_->::opencv_caffe::ArgMaxParameter::Clear();
clear_has_argmax_param();
}
const ::opencv_caffe::ArgMaxParameter& V1LayerParameter::argmax_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.argmax_param)
return argmax_param_ != NULL ? *argmax_param_
: *::opencv_caffe::ArgMaxParameter::internal_default_instance();
}
::opencv_caffe::ArgMaxParameter* V1LayerParameter::mutable_argmax_param() {
set_has_argmax_param();
if (argmax_param_ == NULL) {
argmax_param_ = new ::opencv_caffe::ArgMaxParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.argmax_param)
return argmax_param_;
}
::opencv_caffe::ArgMaxParameter* V1LayerParameter::release_argmax_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.argmax_param)
clear_has_argmax_param();
::opencv_caffe::ArgMaxParameter* temp = argmax_param_;
argmax_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_argmax_param(::opencv_caffe::ArgMaxParameter* argmax_param) {
delete argmax_param_;
argmax_param_ = argmax_param;
if (argmax_param) {
set_has_argmax_param();
} else {
clear_has_argmax_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.argmax_param)
}
// optional .opencv_caffe.ConcatParameter concat_param = 9;
bool V1LayerParameter::has_concat_param() const {
return (_has_bits_[0] & 0x00004000u) != 0;
}
void V1LayerParameter::set_has_concat_param() {
_has_bits_[0] |= 0x00004000u;
}
void V1LayerParameter::clear_has_concat_param() {
_has_bits_[0] &= ~0x00004000u;
}
void V1LayerParameter::clear_concat_param() {
if (concat_param_ != NULL) concat_param_->::opencv_caffe::ConcatParameter::Clear();
clear_has_concat_param();
}
const ::opencv_caffe::ConcatParameter& V1LayerParameter::concat_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.concat_param)
return concat_param_ != NULL ? *concat_param_
: *::opencv_caffe::ConcatParameter::internal_default_instance();
}
::opencv_caffe::ConcatParameter* V1LayerParameter::mutable_concat_param() {
set_has_concat_param();
if (concat_param_ == NULL) {
concat_param_ = new ::opencv_caffe::ConcatParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.concat_param)
return concat_param_;
}
::opencv_caffe::ConcatParameter* V1LayerParameter::release_concat_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.concat_param)
clear_has_concat_param();
::opencv_caffe::ConcatParameter* temp = concat_param_;
concat_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_concat_param(::opencv_caffe::ConcatParameter* concat_param) {
delete concat_param_;
concat_param_ = concat_param;
if (concat_param) {
set_has_concat_param();
} else {
clear_has_concat_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.concat_param)
}
// optional .opencv_caffe.ContrastiveLossParameter contrastive_loss_param = 40;
bool V1LayerParameter::has_contrastive_loss_param() const {
return (_has_bits_[0] & 0x00008000u) != 0;
}
void V1LayerParameter::set_has_contrastive_loss_param() {
_has_bits_[0] |= 0x00008000u;
}
void V1LayerParameter::clear_has_contrastive_loss_param() {
_has_bits_[0] &= ~0x00008000u;
}
void V1LayerParameter::clear_contrastive_loss_param() {
if (contrastive_loss_param_ != NULL) contrastive_loss_param_->::opencv_caffe::ContrastiveLossParameter::Clear();
clear_has_contrastive_loss_param();
}
const ::opencv_caffe::ContrastiveLossParameter& V1LayerParameter::contrastive_loss_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.contrastive_loss_param)
return contrastive_loss_param_ != NULL ? *contrastive_loss_param_
: *::opencv_caffe::ContrastiveLossParameter::internal_default_instance();
}
::opencv_caffe::ContrastiveLossParameter* V1LayerParameter::mutable_contrastive_loss_param() {
set_has_contrastive_loss_param();
if (contrastive_loss_param_ == NULL) {
contrastive_loss_param_ = new ::opencv_caffe::ContrastiveLossParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.contrastive_loss_param)
return contrastive_loss_param_;
}
::opencv_caffe::ContrastiveLossParameter* V1LayerParameter::release_contrastive_loss_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.contrastive_loss_param)
clear_has_contrastive_loss_param();
::opencv_caffe::ContrastiveLossParameter* temp = contrastive_loss_param_;
contrastive_loss_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_contrastive_loss_param(::opencv_caffe::ContrastiveLossParameter* contrastive_loss_param) {
delete contrastive_loss_param_;
contrastive_loss_param_ = contrastive_loss_param;
if (contrastive_loss_param) {
set_has_contrastive_loss_param();
} else {
clear_has_contrastive_loss_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.contrastive_loss_param)
}
// optional .opencv_caffe.ConvolutionParameter convolution_param = 10;
bool V1LayerParameter::has_convolution_param() const {
return (_has_bits_[0] & 0x00010000u) != 0;
}
void V1LayerParameter::set_has_convolution_param() {
_has_bits_[0] |= 0x00010000u;
}
void V1LayerParameter::clear_has_convolution_param() {
_has_bits_[0] &= ~0x00010000u;
}
void V1LayerParameter::clear_convolution_param() {
if (convolution_param_ != NULL) convolution_param_->::opencv_caffe::ConvolutionParameter::Clear();
clear_has_convolution_param();
}
const ::opencv_caffe::ConvolutionParameter& V1LayerParameter::convolution_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.convolution_param)
return convolution_param_ != NULL ? *convolution_param_
: *::opencv_caffe::ConvolutionParameter::internal_default_instance();
}
::opencv_caffe::ConvolutionParameter* V1LayerParameter::mutable_convolution_param() {
set_has_convolution_param();
if (convolution_param_ == NULL) {
convolution_param_ = new ::opencv_caffe::ConvolutionParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.convolution_param)
return convolution_param_;
}
::opencv_caffe::ConvolutionParameter* V1LayerParameter::release_convolution_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.convolution_param)
clear_has_convolution_param();
::opencv_caffe::ConvolutionParameter* temp = convolution_param_;
convolution_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_convolution_param(::opencv_caffe::ConvolutionParameter* convolution_param) {
delete convolution_param_;
convolution_param_ = convolution_param;
if (convolution_param) {
set_has_convolution_param();
} else {
clear_has_convolution_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.convolution_param)
}
// optional .opencv_caffe.DataParameter data_param = 11;
bool V1LayerParameter::has_data_param() const {
return (_has_bits_[0] & 0x00020000u) != 0;
}
void V1LayerParameter::set_has_data_param() {
_has_bits_[0] |= 0x00020000u;
}
void V1LayerParameter::clear_has_data_param() {
_has_bits_[0] &= ~0x00020000u;
}
void V1LayerParameter::clear_data_param() {
if (data_param_ != NULL) data_param_->::opencv_caffe::DataParameter::Clear();
clear_has_data_param();
}
const ::opencv_caffe::DataParameter& V1LayerParameter::data_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.data_param)
return data_param_ != NULL ? *data_param_
: *::opencv_caffe::DataParameter::internal_default_instance();
}
::opencv_caffe::DataParameter* V1LayerParameter::mutable_data_param() {
set_has_data_param();
if (data_param_ == NULL) {
data_param_ = new ::opencv_caffe::DataParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.data_param)
return data_param_;
}
::opencv_caffe::DataParameter* V1LayerParameter::release_data_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.data_param)
clear_has_data_param();
::opencv_caffe::DataParameter* temp = data_param_;
data_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_data_param(::opencv_caffe::DataParameter* data_param) {
delete data_param_;
data_param_ = data_param;
if (data_param) {
set_has_data_param();
} else {
clear_has_data_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.data_param)
}
// optional .opencv_caffe.DropoutParameter dropout_param = 12;
bool V1LayerParameter::has_dropout_param() const {
return (_has_bits_[0] & 0x00040000u) != 0;
}
void V1LayerParameter::set_has_dropout_param() {
_has_bits_[0] |= 0x00040000u;
}
void V1LayerParameter::clear_has_dropout_param() {
_has_bits_[0] &= ~0x00040000u;
}
void V1LayerParameter::clear_dropout_param() {
if (dropout_param_ != NULL) dropout_param_->::opencv_caffe::DropoutParameter::Clear();
clear_has_dropout_param();
}
const ::opencv_caffe::DropoutParameter& V1LayerParameter::dropout_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.dropout_param)
return dropout_param_ != NULL ? *dropout_param_
: *::opencv_caffe::DropoutParameter::internal_default_instance();
}
::opencv_caffe::DropoutParameter* V1LayerParameter::mutable_dropout_param() {
set_has_dropout_param();
if (dropout_param_ == NULL) {
dropout_param_ = new ::opencv_caffe::DropoutParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.dropout_param)
return dropout_param_;
}
::opencv_caffe::DropoutParameter* V1LayerParameter::release_dropout_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.dropout_param)
clear_has_dropout_param();
::opencv_caffe::DropoutParameter* temp = dropout_param_;
dropout_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_dropout_param(::opencv_caffe::DropoutParameter* dropout_param) {
delete dropout_param_;
dropout_param_ = dropout_param;
if (dropout_param) {
set_has_dropout_param();
} else {
clear_has_dropout_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.dropout_param)
}
// optional .opencv_caffe.DummyDataParameter dummy_data_param = 26;
bool V1LayerParameter::has_dummy_data_param() const {
return (_has_bits_[0] & 0x00080000u) != 0;
}
void V1LayerParameter::set_has_dummy_data_param() {
_has_bits_[0] |= 0x00080000u;
}
void V1LayerParameter::clear_has_dummy_data_param() {
_has_bits_[0] &= ~0x00080000u;
}
void V1LayerParameter::clear_dummy_data_param() {
if (dummy_data_param_ != NULL) dummy_data_param_->::opencv_caffe::DummyDataParameter::Clear();
clear_has_dummy_data_param();
}
const ::opencv_caffe::DummyDataParameter& V1LayerParameter::dummy_data_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.dummy_data_param)
return dummy_data_param_ != NULL ? *dummy_data_param_
: *::opencv_caffe::DummyDataParameter::internal_default_instance();
}
::opencv_caffe::DummyDataParameter* V1LayerParameter::mutable_dummy_data_param() {
set_has_dummy_data_param();
if (dummy_data_param_ == NULL) {
dummy_data_param_ = new ::opencv_caffe::DummyDataParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.dummy_data_param)
return dummy_data_param_;
}
::opencv_caffe::DummyDataParameter* V1LayerParameter::release_dummy_data_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.dummy_data_param)
clear_has_dummy_data_param();
::opencv_caffe::DummyDataParameter* temp = dummy_data_param_;
dummy_data_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_dummy_data_param(::opencv_caffe::DummyDataParameter* dummy_data_param) {
delete dummy_data_param_;
dummy_data_param_ = dummy_data_param;
if (dummy_data_param) {
set_has_dummy_data_param();
} else {
clear_has_dummy_data_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.dummy_data_param)
}
// optional .opencv_caffe.EltwiseParameter eltwise_param = 24;
bool V1LayerParameter::has_eltwise_param() const {
return (_has_bits_[0] & 0x00100000u) != 0;
}
void V1LayerParameter::set_has_eltwise_param() {
_has_bits_[0] |= 0x00100000u;
}
void V1LayerParameter::clear_has_eltwise_param() {
_has_bits_[0] &= ~0x00100000u;
}
void V1LayerParameter::clear_eltwise_param() {
if (eltwise_param_ != NULL) eltwise_param_->::opencv_caffe::EltwiseParameter::Clear();
clear_has_eltwise_param();
}
const ::opencv_caffe::EltwiseParameter& V1LayerParameter::eltwise_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.eltwise_param)
return eltwise_param_ != NULL ? *eltwise_param_
: *::opencv_caffe::EltwiseParameter::internal_default_instance();
}
::opencv_caffe::EltwiseParameter* V1LayerParameter::mutable_eltwise_param() {
set_has_eltwise_param();
if (eltwise_param_ == NULL) {
eltwise_param_ = new ::opencv_caffe::EltwiseParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.eltwise_param)
return eltwise_param_;
}
::opencv_caffe::EltwiseParameter* V1LayerParameter::release_eltwise_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.eltwise_param)
clear_has_eltwise_param();
::opencv_caffe::EltwiseParameter* temp = eltwise_param_;
eltwise_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_eltwise_param(::opencv_caffe::EltwiseParameter* eltwise_param) {
delete eltwise_param_;
eltwise_param_ = eltwise_param;
if (eltwise_param) {
set_has_eltwise_param();
} else {
clear_has_eltwise_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.eltwise_param)
}
// optional .opencv_caffe.ExpParameter exp_param = 41;
bool V1LayerParameter::has_exp_param() const {
return (_has_bits_[0] & 0x00200000u) != 0;
}
void V1LayerParameter::set_has_exp_param() {
_has_bits_[0] |= 0x00200000u;
}
void V1LayerParameter::clear_has_exp_param() {
_has_bits_[0] &= ~0x00200000u;
}
void V1LayerParameter::clear_exp_param() {
if (exp_param_ != NULL) exp_param_->::opencv_caffe::ExpParameter::Clear();
clear_has_exp_param();
}
const ::opencv_caffe::ExpParameter& V1LayerParameter::exp_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.exp_param)
return exp_param_ != NULL ? *exp_param_
: *::opencv_caffe::ExpParameter::internal_default_instance();
}
::opencv_caffe::ExpParameter* V1LayerParameter::mutable_exp_param() {
set_has_exp_param();
if (exp_param_ == NULL) {
exp_param_ = new ::opencv_caffe::ExpParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.exp_param)
return exp_param_;
}
::opencv_caffe::ExpParameter* V1LayerParameter::release_exp_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.exp_param)
clear_has_exp_param();
::opencv_caffe::ExpParameter* temp = exp_param_;
exp_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_exp_param(::opencv_caffe::ExpParameter* exp_param) {
delete exp_param_;
exp_param_ = exp_param;
if (exp_param) {
set_has_exp_param();
} else {
clear_has_exp_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.exp_param)
}
// optional .opencv_caffe.HDF5DataParameter hdf5_data_param = 13;
bool V1LayerParameter::has_hdf5_data_param() const {
return (_has_bits_[0] & 0x00400000u) != 0;
}
void V1LayerParameter::set_has_hdf5_data_param() {
_has_bits_[0] |= 0x00400000u;
}
void V1LayerParameter::clear_has_hdf5_data_param() {
_has_bits_[0] &= ~0x00400000u;
}
void V1LayerParameter::clear_hdf5_data_param() {
if (hdf5_data_param_ != NULL) hdf5_data_param_->::opencv_caffe::HDF5DataParameter::Clear();
clear_has_hdf5_data_param();
}
const ::opencv_caffe::HDF5DataParameter& V1LayerParameter::hdf5_data_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.hdf5_data_param)
return hdf5_data_param_ != NULL ? *hdf5_data_param_
: *::opencv_caffe::HDF5DataParameter::internal_default_instance();
}
::opencv_caffe::HDF5DataParameter* V1LayerParameter::mutable_hdf5_data_param() {
set_has_hdf5_data_param();
if (hdf5_data_param_ == NULL) {
hdf5_data_param_ = new ::opencv_caffe::HDF5DataParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.hdf5_data_param)
return hdf5_data_param_;
}
::opencv_caffe::HDF5DataParameter* V1LayerParameter::release_hdf5_data_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.hdf5_data_param)
clear_has_hdf5_data_param();
::opencv_caffe::HDF5DataParameter* temp = hdf5_data_param_;
hdf5_data_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_hdf5_data_param(::opencv_caffe::HDF5DataParameter* hdf5_data_param) {
delete hdf5_data_param_;
hdf5_data_param_ = hdf5_data_param;
if (hdf5_data_param) {
set_has_hdf5_data_param();
} else {
clear_has_hdf5_data_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.hdf5_data_param)
}
// optional .opencv_caffe.HDF5OutputParameter hdf5_output_param = 14;
bool V1LayerParameter::has_hdf5_output_param() const {
return (_has_bits_[0] & 0x00800000u) != 0;
}
void V1LayerParameter::set_has_hdf5_output_param() {
_has_bits_[0] |= 0x00800000u;
}
void V1LayerParameter::clear_has_hdf5_output_param() {
_has_bits_[0] &= ~0x00800000u;
}
void V1LayerParameter::clear_hdf5_output_param() {
if (hdf5_output_param_ != NULL) hdf5_output_param_->::opencv_caffe::HDF5OutputParameter::Clear();
clear_has_hdf5_output_param();
}
const ::opencv_caffe::HDF5OutputParameter& V1LayerParameter::hdf5_output_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.hdf5_output_param)
return hdf5_output_param_ != NULL ? *hdf5_output_param_
: *::opencv_caffe::HDF5OutputParameter::internal_default_instance();
}
::opencv_caffe::HDF5OutputParameter* V1LayerParameter::mutable_hdf5_output_param() {
set_has_hdf5_output_param();
if (hdf5_output_param_ == NULL) {
hdf5_output_param_ = new ::opencv_caffe::HDF5OutputParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.hdf5_output_param)
return hdf5_output_param_;
}
::opencv_caffe::HDF5OutputParameter* V1LayerParameter::release_hdf5_output_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.hdf5_output_param)
clear_has_hdf5_output_param();
::opencv_caffe::HDF5OutputParameter* temp = hdf5_output_param_;
hdf5_output_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_hdf5_output_param(::opencv_caffe::HDF5OutputParameter* hdf5_output_param) {
delete hdf5_output_param_;
hdf5_output_param_ = hdf5_output_param;
if (hdf5_output_param) {
set_has_hdf5_output_param();
} else {
clear_has_hdf5_output_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.hdf5_output_param)
}
// optional .opencv_caffe.HingeLossParameter hinge_loss_param = 29;
bool V1LayerParameter::has_hinge_loss_param() const {
return (_has_bits_[0] & 0x01000000u) != 0;
}
void V1LayerParameter::set_has_hinge_loss_param() {
_has_bits_[0] |= 0x01000000u;
}
void V1LayerParameter::clear_has_hinge_loss_param() {
_has_bits_[0] &= ~0x01000000u;
}
void V1LayerParameter::clear_hinge_loss_param() {
if (hinge_loss_param_ != NULL) hinge_loss_param_->::opencv_caffe::HingeLossParameter::Clear();
clear_has_hinge_loss_param();
}
const ::opencv_caffe::HingeLossParameter& V1LayerParameter::hinge_loss_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.hinge_loss_param)
return hinge_loss_param_ != NULL ? *hinge_loss_param_
: *::opencv_caffe::HingeLossParameter::internal_default_instance();
}
::opencv_caffe::HingeLossParameter* V1LayerParameter::mutable_hinge_loss_param() {
set_has_hinge_loss_param();
if (hinge_loss_param_ == NULL) {
hinge_loss_param_ = new ::opencv_caffe::HingeLossParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.hinge_loss_param)
return hinge_loss_param_;
}
::opencv_caffe::HingeLossParameter* V1LayerParameter::release_hinge_loss_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.hinge_loss_param)
clear_has_hinge_loss_param();
::opencv_caffe::HingeLossParameter* temp = hinge_loss_param_;
hinge_loss_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_hinge_loss_param(::opencv_caffe::HingeLossParameter* hinge_loss_param) {
delete hinge_loss_param_;
hinge_loss_param_ = hinge_loss_param;
if (hinge_loss_param) {
set_has_hinge_loss_param();
} else {
clear_has_hinge_loss_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.hinge_loss_param)
}
// optional .opencv_caffe.ImageDataParameter image_data_param = 15;
bool V1LayerParameter::has_image_data_param() const {
return (_has_bits_[0] & 0x02000000u) != 0;
}
void V1LayerParameter::set_has_image_data_param() {
_has_bits_[0] |= 0x02000000u;
}
void V1LayerParameter::clear_has_image_data_param() {
_has_bits_[0] &= ~0x02000000u;
}
void V1LayerParameter::clear_image_data_param() {
if (image_data_param_ != NULL) image_data_param_->::opencv_caffe::ImageDataParameter::Clear();
clear_has_image_data_param();
}
const ::opencv_caffe::ImageDataParameter& V1LayerParameter::image_data_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.image_data_param)
return image_data_param_ != NULL ? *image_data_param_
: *::opencv_caffe::ImageDataParameter::internal_default_instance();
}
::opencv_caffe::ImageDataParameter* V1LayerParameter::mutable_image_data_param() {
set_has_image_data_param();
if (image_data_param_ == NULL) {
image_data_param_ = new ::opencv_caffe::ImageDataParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.image_data_param)
return image_data_param_;
}
::opencv_caffe::ImageDataParameter* V1LayerParameter::release_image_data_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.image_data_param)
clear_has_image_data_param();
::opencv_caffe::ImageDataParameter* temp = image_data_param_;
image_data_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_image_data_param(::opencv_caffe::ImageDataParameter* image_data_param) {
delete image_data_param_;
image_data_param_ = image_data_param;
if (image_data_param) {
set_has_image_data_param();
} else {
clear_has_image_data_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.image_data_param)
}
// optional .opencv_caffe.InfogainLossParameter infogain_loss_param = 16;
bool V1LayerParameter::has_infogain_loss_param() const {
return (_has_bits_[0] & 0x04000000u) != 0;
}
void V1LayerParameter::set_has_infogain_loss_param() {
_has_bits_[0] |= 0x04000000u;
}
void V1LayerParameter::clear_has_infogain_loss_param() {
_has_bits_[0] &= ~0x04000000u;
}
void V1LayerParameter::clear_infogain_loss_param() {
if (infogain_loss_param_ != NULL) infogain_loss_param_->::opencv_caffe::InfogainLossParameter::Clear();
clear_has_infogain_loss_param();
}
const ::opencv_caffe::InfogainLossParameter& V1LayerParameter::infogain_loss_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.infogain_loss_param)
return infogain_loss_param_ != NULL ? *infogain_loss_param_
: *::opencv_caffe::InfogainLossParameter::internal_default_instance();
}
::opencv_caffe::InfogainLossParameter* V1LayerParameter::mutable_infogain_loss_param() {
set_has_infogain_loss_param();
if (infogain_loss_param_ == NULL) {
infogain_loss_param_ = new ::opencv_caffe::InfogainLossParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.infogain_loss_param)
return infogain_loss_param_;
}
::opencv_caffe::InfogainLossParameter* V1LayerParameter::release_infogain_loss_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.infogain_loss_param)
clear_has_infogain_loss_param();
::opencv_caffe::InfogainLossParameter* temp = infogain_loss_param_;
infogain_loss_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_infogain_loss_param(::opencv_caffe::InfogainLossParameter* infogain_loss_param) {
delete infogain_loss_param_;
infogain_loss_param_ = infogain_loss_param;
if (infogain_loss_param) {
set_has_infogain_loss_param();
} else {
clear_has_infogain_loss_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.infogain_loss_param)
}
// optional .opencv_caffe.InnerProductParameter inner_product_param = 17;
bool V1LayerParameter::has_inner_product_param() const {
return (_has_bits_[0] & 0x08000000u) != 0;
}
void V1LayerParameter::set_has_inner_product_param() {
_has_bits_[0] |= 0x08000000u;
}
void V1LayerParameter::clear_has_inner_product_param() {
_has_bits_[0] &= ~0x08000000u;
}
void V1LayerParameter::clear_inner_product_param() {
if (inner_product_param_ != NULL) inner_product_param_->::opencv_caffe::InnerProductParameter::Clear();
clear_has_inner_product_param();
}
const ::opencv_caffe::InnerProductParameter& V1LayerParameter::inner_product_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.inner_product_param)
return inner_product_param_ != NULL ? *inner_product_param_
: *::opencv_caffe::InnerProductParameter::internal_default_instance();
}
::opencv_caffe::InnerProductParameter* V1LayerParameter::mutable_inner_product_param() {
set_has_inner_product_param();
if (inner_product_param_ == NULL) {
inner_product_param_ = new ::opencv_caffe::InnerProductParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.inner_product_param)
return inner_product_param_;
}
::opencv_caffe::InnerProductParameter* V1LayerParameter::release_inner_product_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.inner_product_param)
clear_has_inner_product_param();
::opencv_caffe::InnerProductParameter* temp = inner_product_param_;
inner_product_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_inner_product_param(::opencv_caffe::InnerProductParameter* inner_product_param) {
delete inner_product_param_;
inner_product_param_ = inner_product_param;
if (inner_product_param) {
set_has_inner_product_param();
} else {
clear_has_inner_product_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.inner_product_param)
}
// optional .opencv_caffe.LRNParameter lrn_param = 18;
bool V1LayerParameter::has_lrn_param() const {
return (_has_bits_[0] & 0x10000000u) != 0;
}
void V1LayerParameter::set_has_lrn_param() {
_has_bits_[0] |= 0x10000000u;
}
void V1LayerParameter::clear_has_lrn_param() {
_has_bits_[0] &= ~0x10000000u;
}
void V1LayerParameter::clear_lrn_param() {
if (lrn_param_ != NULL) lrn_param_->::opencv_caffe::LRNParameter::Clear();
clear_has_lrn_param();
}
const ::opencv_caffe::LRNParameter& V1LayerParameter::lrn_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.lrn_param)
return lrn_param_ != NULL ? *lrn_param_
: *::opencv_caffe::LRNParameter::internal_default_instance();
}
::opencv_caffe::LRNParameter* V1LayerParameter::mutable_lrn_param() {
set_has_lrn_param();
if (lrn_param_ == NULL) {
lrn_param_ = new ::opencv_caffe::LRNParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.lrn_param)
return lrn_param_;
}
::opencv_caffe::LRNParameter* V1LayerParameter::release_lrn_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.lrn_param)
clear_has_lrn_param();
::opencv_caffe::LRNParameter* temp = lrn_param_;
lrn_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_lrn_param(::opencv_caffe::LRNParameter* lrn_param) {
delete lrn_param_;
lrn_param_ = lrn_param;
if (lrn_param) {
set_has_lrn_param();
} else {
clear_has_lrn_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.lrn_param)
}
// optional .opencv_caffe.MemoryDataParameter memory_data_param = 22;
bool V1LayerParameter::has_memory_data_param() const {
return (_has_bits_[0] & 0x20000000u) != 0;
}
void V1LayerParameter::set_has_memory_data_param() {
_has_bits_[0] |= 0x20000000u;
}
void V1LayerParameter::clear_has_memory_data_param() {
_has_bits_[0] &= ~0x20000000u;
}
void V1LayerParameter::clear_memory_data_param() {
if (memory_data_param_ != NULL) memory_data_param_->::opencv_caffe::MemoryDataParameter::Clear();
clear_has_memory_data_param();
}
const ::opencv_caffe::MemoryDataParameter& V1LayerParameter::memory_data_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.memory_data_param)
return memory_data_param_ != NULL ? *memory_data_param_
: *::opencv_caffe::MemoryDataParameter::internal_default_instance();
}
::opencv_caffe::MemoryDataParameter* V1LayerParameter::mutable_memory_data_param() {
set_has_memory_data_param();
if (memory_data_param_ == NULL) {
memory_data_param_ = new ::opencv_caffe::MemoryDataParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.memory_data_param)
return memory_data_param_;
}
::opencv_caffe::MemoryDataParameter* V1LayerParameter::release_memory_data_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.memory_data_param)
clear_has_memory_data_param();
::opencv_caffe::MemoryDataParameter* temp = memory_data_param_;
memory_data_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_memory_data_param(::opencv_caffe::MemoryDataParameter* memory_data_param) {
delete memory_data_param_;
memory_data_param_ = memory_data_param;
if (memory_data_param) {
set_has_memory_data_param();
} else {
clear_has_memory_data_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.memory_data_param)
}
// optional .opencv_caffe.MVNParameter mvn_param = 34;
bool V1LayerParameter::has_mvn_param() const {
return (_has_bits_[0] & 0x40000000u) != 0;
}
void V1LayerParameter::set_has_mvn_param() {
_has_bits_[0] |= 0x40000000u;
}
void V1LayerParameter::clear_has_mvn_param() {
_has_bits_[0] &= ~0x40000000u;
}
void V1LayerParameter::clear_mvn_param() {
if (mvn_param_ != NULL) mvn_param_->::opencv_caffe::MVNParameter::Clear();
clear_has_mvn_param();
}
const ::opencv_caffe::MVNParameter& V1LayerParameter::mvn_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.mvn_param)
return mvn_param_ != NULL ? *mvn_param_
: *::opencv_caffe::MVNParameter::internal_default_instance();
}
::opencv_caffe::MVNParameter* V1LayerParameter::mutable_mvn_param() {
set_has_mvn_param();
if (mvn_param_ == NULL) {
mvn_param_ = new ::opencv_caffe::MVNParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.mvn_param)
return mvn_param_;
}
::opencv_caffe::MVNParameter* V1LayerParameter::release_mvn_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.mvn_param)
clear_has_mvn_param();
::opencv_caffe::MVNParameter* temp = mvn_param_;
mvn_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_mvn_param(::opencv_caffe::MVNParameter* mvn_param) {
delete mvn_param_;
mvn_param_ = mvn_param;
if (mvn_param) {
set_has_mvn_param();
} else {
clear_has_mvn_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.mvn_param)
}
// optional .opencv_caffe.PoolingParameter pooling_param = 19;
bool V1LayerParameter::has_pooling_param() const {
return (_has_bits_[0] & 0x80000000u) != 0;
}
void V1LayerParameter::set_has_pooling_param() {
_has_bits_[0] |= 0x80000000u;
}
void V1LayerParameter::clear_has_pooling_param() {
_has_bits_[0] &= ~0x80000000u;
}
void V1LayerParameter::clear_pooling_param() {
if (pooling_param_ != NULL) pooling_param_->::opencv_caffe::PoolingParameter::Clear();
clear_has_pooling_param();
}
const ::opencv_caffe::PoolingParameter& V1LayerParameter::pooling_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.pooling_param)
return pooling_param_ != NULL ? *pooling_param_
: *::opencv_caffe::PoolingParameter::internal_default_instance();
}
::opencv_caffe::PoolingParameter* V1LayerParameter::mutable_pooling_param() {
set_has_pooling_param();
if (pooling_param_ == NULL) {
pooling_param_ = new ::opencv_caffe::PoolingParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.pooling_param)
return pooling_param_;
}
::opencv_caffe::PoolingParameter* V1LayerParameter::release_pooling_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.pooling_param)
clear_has_pooling_param();
::opencv_caffe::PoolingParameter* temp = pooling_param_;
pooling_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_pooling_param(::opencv_caffe::PoolingParameter* pooling_param) {
delete pooling_param_;
pooling_param_ = pooling_param;
if (pooling_param) {
set_has_pooling_param();
} else {
clear_has_pooling_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.pooling_param)
}
// optional .opencv_caffe.PowerParameter power_param = 21;
bool V1LayerParameter::has_power_param() const {
return (_has_bits_[1] & 0x00000001u) != 0;
}
void V1LayerParameter::set_has_power_param() {
_has_bits_[1] |= 0x00000001u;
}
void V1LayerParameter::clear_has_power_param() {
_has_bits_[1] &= ~0x00000001u;
}
void V1LayerParameter::clear_power_param() {
if (power_param_ != NULL) power_param_->::opencv_caffe::PowerParameter::Clear();
clear_has_power_param();
}
const ::opencv_caffe::PowerParameter& V1LayerParameter::power_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.power_param)
return power_param_ != NULL ? *power_param_
: *::opencv_caffe::PowerParameter::internal_default_instance();
}
::opencv_caffe::PowerParameter* V1LayerParameter::mutable_power_param() {
set_has_power_param();
if (power_param_ == NULL) {
power_param_ = new ::opencv_caffe::PowerParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.power_param)
return power_param_;
}
::opencv_caffe::PowerParameter* V1LayerParameter::release_power_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.power_param)
clear_has_power_param();
::opencv_caffe::PowerParameter* temp = power_param_;
power_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_power_param(::opencv_caffe::PowerParameter* power_param) {
delete power_param_;
power_param_ = power_param;
if (power_param) {
set_has_power_param();
} else {
clear_has_power_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.power_param)
}
// optional .opencv_caffe.ReLUParameter relu_param = 30;
bool V1LayerParameter::has_relu_param() const {
return (_has_bits_[1] & 0x00000002u) != 0;
}
void V1LayerParameter::set_has_relu_param() {
_has_bits_[1] |= 0x00000002u;
}
void V1LayerParameter::clear_has_relu_param() {
_has_bits_[1] &= ~0x00000002u;
}
void V1LayerParameter::clear_relu_param() {
if (relu_param_ != NULL) relu_param_->::opencv_caffe::ReLUParameter::Clear();
clear_has_relu_param();
}
const ::opencv_caffe::ReLUParameter& V1LayerParameter::relu_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.relu_param)
return relu_param_ != NULL ? *relu_param_
: *::opencv_caffe::ReLUParameter::internal_default_instance();
}
::opencv_caffe::ReLUParameter* V1LayerParameter::mutable_relu_param() {
set_has_relu_param();
if (relu_param_ == NULL) {
relu_param_ = new ::opencv_caffe::ReLUParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.relu_param)
return relu_param_;
}
::opencv_caffe::ReLUParameter* V1LayerParameter::release_relu_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.relu_param)
clear_has_relu_param();
::opencv_caffe::ReLUParameter* temp = relu_param_;
relu_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_relu_param(::opencv_caffe::ReLUParameter* relu_param) {
delete relu_param_;
relu_param_ = relu_param;
if (relu_param) {
set_has_relu_param();
} else {
clear_has_relu_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.relu_param)
}
// optional .opencv_caffe.SigmoidParameter sigmoid_param = 38;
bool V1LayerParameter::has_sigmoid_param() const {
return (_has_bits_[1] & 0x00000004u) != 0;
}
void V1LayerParameter::set_has_sigmoid_param() {
_has_bits_[1] |= 0x00000004u;
}
void V1LayerParameter::clear_has_sigmoid_param() {
_has_bits_[1] &= ~0x00000004u;
}
void V1LayerParameter::clear_sigmoid_param() {
if (sigmoid_param_ != NULL) sigmoid_param_->::opencv_caffe::SigmoidParameter::Clear();
clear_has_sigmoid_param();
}
const ::opencv_caffe::SigmoidParameter& V1LayerParameter::sigmoid_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.sigmoid_param)
return sigmoid_param_ != NULL ? *sigmoid_param_
: *::opencv_caffe::SigmoidParameter::internal_default_instance();
}
::opencv_caffe::SigmoidParameter* V1LayerParameter::mutable_sigmoid_param() {
set_has_sigmoid_param();
if (sigmoid_param_ == NULL) {
sigmoid_param_ = new ::opencv_caffe::SigmoidParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.sigmoid_param)
return sigmoid_param_;
}
::opencv_caffe::SigmoidParameter* V1LayerParameter::release_sigmoid_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.sigmoid_param)
clear_has_sigmoid_param();
::opencv_caffe::SigmoidParameter* temp = sigmoid_param_;
sigmoid_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_sigmoid_param(::opencv_caffe::SigmoidParameter* sigmoid_param) {
delete sigmoid_param_;
sigmoid_param_ = sigmoid_param;
if (sigmoid_param) {
set_has_sigmoid_param();
} else {
clear_has_sigmoid_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.sigmoid_param)
}
// optional .opencv_caffe.SoftmaxParameter softmax_param = 39;
bool V1LayerParameter::has_softmax_param() const {
return (_has_bits_[1] & 0x00000008u) != 0;
}
void V1LayerParameter::set_has_softmax_param() {
_has_bits_[1] |= 0x00000008u;
}
void V1LayerParameter::clear_has_softmax_param() {
_has_bits_[1] &= ~0x00000008u;
}
void V1LayerParameter::clear_softmax_param() {
if (softmax_param_ != NULL) softmax_param_->::opencv_caffe::SoftmaxParameter::Clear();
clear_has_softmax_param();
}
const ::opencv_caffe::SoftmaxParameter& V1LayerParameter::softmax_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.softmax_param)
return softmax_param_ != NULL ? *softmax_param_
: *::opencv_caffe::SoftmaxParameter::internal_default_instance();
}
::opencv_caffe::SoftmaxParameter* V1LayerParameter::mutable_softmax_param() {
set_has_softmax_param();
if (softmax_param_ == NULL) {
softmax_param_ = new ::opencv_caffe::SoftmaxParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.softmax_param)
return softmax_param_;
}
::opencv_caffe::SoftmaxParameter* V1LayerParameter::release_softmax_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.softmax_param)
clear_has_softmax_param();
::opencv_caffe::SoftmaxParameter* temp = softmax_param_;
softmax_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_softmax_param(::opencv_caffe::SoftmaxParameter* softmax_param) {
delete softmax_param_;
softmax_param_ = softmax_param;
if (softmax_param) {
set_has_softmax_param();
} else {
clear_has_softmax_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.softmax_param)
}
// optional .opencv_caffe.SliceParameter slice_param = 31;
bool V1LayerParameter::has_slice_param() const {
return (_has_bits_[1] & 0x00000010u) != 0;
}
void V1LayerParameter::set_has_slice_param() {
_has_bits_[1] |= 0x00000010u;
}
void V1LayerParameter::clear_has_slice_param() {
_has_bits_[1] &= ~0x00000010u;
}
void V1LayerParameter::clear_slice_param() {
if (slice_param_ != NULL) slice_param_->::opencv_caffe::SliceParameter::Clear();
clear_has_slice_param();
}
const ::opencv_caffe::SliceParameter& V1LayerParameter::slice_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.slice_param)
return slice_param_ != NULL ? *slice_param_
: *::opencv_caffe::SliceParameter::internal_default_instance();
}
::opencv_caffe::SliceParameter* V1LayerParameter::mutable_slice_param() {
set_has_slice_param();
if (slice_param_ == NULL) {
slice_param_ = new ::opencv_caffe::SliceParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.slice_param)
return slice_param_;
}
::opencv_caffe::SliceParameter* V1LayerParameter::release_slice_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.slice_param)
clear_has_slice_param();
::opencv_caffe::SliceParameter* temp = slice_param_;
slice_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_slice_param(::opencv_caffe::SliceParameter* slice_param) {
delete slice_param_;
slice_param_ = slice_param;
if (slice_param) {
set_has_slice_param();
} else {
clear_has_slice_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.slice_param)
}
// optional .opencv_caffe.TanHParameter tanh_param = 37;
bool V1LayerParameter::has_tanh_param() const {
return (_has_bits_[1] & 0x00000020u) != 0;
}
void V1LayerParameter::set_has_tanh_param() {
_has_bits_[1] |= 0x00000020u;
}
void V1LayerParameter::clear_has_tanh_param() {
_has_bits_[1] &= ~0x00000020u;
}
void V1LayerParameter::clear_tanh_param() {
if (tanh_param_ != NULL) tanh_param_->::opencv_caffe::TanHParameter::Clear();
clear_has_tanh_param();
}
const ::opencv_caffe::TanHParameter& V1LayerParameter::tanh_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.tanh_param)
return tanh_param_ != NULL ? *tanh_param_
: *::opencv_caffe::TanHParameter::internal_default_instance();
}
::opencv_caffe::TanHParameter* V1LayerParameter::mutable_tanh_param() {
set_has_tanh_param();
if (tanh_param_ == NULL) {
tanh_param_ = new ::opencv_caffe::TanHParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.tanh_param)
return tanh_param_;
}
::opencv_caffe::TanHParameter* V1LayerParameter::release_tanh_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.tanh_param)
clear_has_tanh_param();
::opencv_caffe::TanHParameter* temp = tanh_param_;
tanh_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_tanh_param(::opencv_caffe::TanHParameter* tanh_param) {
delete tanh_param_;
tanh_param_ = tanh_param;
if (tanh_param) {
set_has_tanh_param();
} else {
clear_has_tanh_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.tanh_param)
}
// optional .opencv_caffe.ThresholdParameter threshold_param = 25;
bool V1LayerParameter::has_threshold_param() const {
return (_has_bits_[1] & 0x00000040u) != 0;
}
void V1LayerParameter::set_has_threshold_param() {
_has_bits_[1] |= 0x00000040u;
}
void V1LayerParameter::clear_has_threshold_param() {
_has_bits_[1] &= ~0x00000040u;
}
void V1LayerParameter::clear_threshold_param() {
if (threshold_param_ != NULL) threshold_param_->::opencv_caffe::ThresholdParameter::Clear();
clear_has_threshold_param();
}
const ::opencv_caffe::ThresholdParameter& V1LayerParameter::threshold_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.threshold_param)
return threshold_param_ != NULL ? *threshold_param_
: *::opencv_caffe::ThresholdParameter::internal_default_instance();
}
::opencv_caffe::ThresholdParameter* V1LayerParameter::mutable_threshold_param() {
set_has_threshold_param();
if (threshold_param_ == NULL) {
threshold_param_ = new ::opencv_caffe::ThresholdParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.threshold_param)
return threshold_param_;
}
::opencv_caffe::ThresholdParameter* V1LayerParameter::release_threshold_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.threshold_param)
clear_has_threshold_param();
::opencv_caffe::ThresholdParameter* temp = threshold_param_;
threshold_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_threshold_param(::opencv_caffe::ThresholdParameter* threshold_param) {
delete threshold_param_;
threshold_param_ = threshold_param;
if (threshold_param) {
set_has_threshold_param();
} else {
clear_has_threshold_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.threshold_param)
}
// optional .opencv_caffe.WindowDataParameter window_data_param = 20;
bool V1LayerParameter::has_window_data_param() const {
return (_has_bits_[1] & 0x00000080u) != 0;
}
void V1LayerParameter::set_has_window_data_param() {
_has_bits_[1] |= 0x00000080u;
}
void V1LayerParameter::clear_has_window_data_param() {
_has_bits_[1] &= ~0x00000080u;
}
void V1LayerParameter::clear_window_data_param() {
if (window_data_param_ != NULL) window_data_param_->::opencv_caffe::WindowDataParameter::Clear();
clear_has_window_data_param();
}
const ::opencv_caffe::WindowDataParameter& V1LayerParameter::window_data_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.window_data_param)
return window_data_param_ != NULL ? *window_data_param_
: *::opencv_caffe::WindowDataParameter::internal_default_instance();
}
::opencv_caffe::WindowDataParameter* V1LayerParameter::mutable_window_data_param() {
set_has_window_data_param();
if (window_data_param_ == NULL) {
window_data_param_ = new ::opencv_caffe::WindowDataParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.window_data_param)
return window_data_param_;
}
::opencv_caffe::WindowDataParameter* V1LayerParameter::release_window_data_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.window_data_param)
clear_has_window_data_param();
::opencv_caffe::WindowDataParameter* temp = window_data_param_;
window_data_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_window_data_param(::opencv_caffe::WindowDataParameter* window_data_param) {
delete window_data_param_;
window_data_param_ = window_data_param;
if (window_data_param) {
set_has_window_data_param();
} else {
clear_has_window_data_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.window_data_param)
}
// optional .opencv_caffe.TransformationParameter transform_param = 36;
bool V1LayerParameter::has_transform_param() const {
return (_has_bits_[1] & 0x00000100u) != 0;
}
void V1LayerParameter::set_has_transform_param() {
_has_bits_[1] |= 0x00000100u;
}
void V1LayerParameter::clear_has_transform_param() {
_has_bits_[1] &= ~0x00000100u;
}
void V1LayerParameter::clear_transform_param() {
if (transform_param_ != NULL) transform_param_->::opencv_caffe::TransformationParameter::Clear();
clear_has_transform_param();
}
const ::opencv_caffe::TransformationParameter& V1LayerParameter::transform_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.transform_param)
return transform_param_ != NULL ? *transform_param_
: *::opencv_caffe::TransformationParameter::internal_default_instance();
}
::opencv_caffe::TransformationParameter* V1LayerParameter::mutable_transform_param() {
set_has_transform_param();
if (transform_param_ == NULL) {
transform_param_ = new ::opencv_caffe::TransformationParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.transform_param)
return transform_param_;
}
::opencv_caffe::TransformationParameter* V1LayerParameter::release_transform_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.transform_param)
clear_has_transform_param();
::opencv_caffe::TransformationParameter* temp = transform_param_;
transform_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_transform_param(::opencv_caffe::TransformationParameter* transform_param) {
delete transform_param_;
transform_param_ = transform_param;
if (transform_param) {
set_has_transform_param();
} else {
clear_has_transform_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.transform_param)
}
// optional .opencv_caffe.LossParameter loss_param = 42;
bool V1LayerParameter::has_loss_param() const {
return (_has_bits_[1] & 0x00000200u) != 0;
}
void V1LayerParameter::set_has_loss_param() {
_has_bits_[1] |= 0x00000200u;
}
void V1LayerParameter::clear_has_loss_param() {
_has_bits_[1] &= ~0x00000200u;
}
void V1LayerParameter::clear_loss_param() {
if (loss_param_ != NULL) loss_param_->::opencv_caffe::LossParameter::Clear();
clear_has_loss_param();
}
const ::opencv_caffe::LossParameter& V1LayerParameter::loss_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.loss_param)
return loss_param_ != NULL ? *loss_param_
: *::opencv_caffe::LossParameter::internal_default_instance();
}
::opencv_caffe::LossParameter* V1LayerParameter::mutable_loss_param() {
set_has_loss_param();
if (loss_param_ == NULL) {
loss_param_ = new ::opencv_caffe::LossParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.loss_param)
return loss_param_;
}
::opencv_caffe::LossParameter* V1LayerParameter::release_loss_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.loss_param)
clear_has_loss_param();
::opencv_caffe::LossParameter* temp = loss_param_;
loss_param_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_loss_param(::opencv_caffe::LossParameter* loss_param) {
delete loss_param_;
loss_param_ = loss_param;
if (loss_param) {
set_has_loss_param();
} else {
clear_has_loss_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.loss_param)
}
// optional .opencv_caffe.V0LayerParameter layer = 1;
bool V1LayerParameter::has_layer() const {
return (_has_bits_[1] & 0x00000400u) != 0;
}
void V1LayerParameter::set_has_layer() {
_has_bits_[1] |= 0x00000400u;
}
void V1LayerParameter::clear_has_layer() {
_has_bits_[1] &= ~0x00000400u;
}
void V1LayerParameter::clear_layer() {
if (layer_ != NULL) layer_->::opencv_caffe::V0LayerParameter::Clear();
clear_has_layer();
}
const ::opencv_caffe::V0LayerParameter& V1LayerParameter::layer() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V1LayerParameter.layer)
return layer_ != NULL ? *layer_
: *::opencv_caffe::V0LayerParameter::internal_default_instance();
}
::opencv_caffe::V0LayerParameter* V1LayerParameter::mutable_layer() {
set_has_layer();
if (layer_ == NULL) {
layer_ = new ::opencv_caffe::V0LayerParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V1LayerParameter.layer)
return layer_;
}
::opencv_caffe::V0LayerParameter* V1LayerParameter::release_layer() {
// @@protoc_insertion_point(field_release:opencv_caffe.V1LayerParameter.layer)
clear_has_layer();
::opencv_caffe::V0LayerParameter* temp = layer_;
layer_ = NULL;
return temp;
}
void V1LayerParameter::set_allocated_layer(::opencv_caffe::V0LayerParameter* layer) {
delete layer_;
layer_ = layer;
if (layer) {
set_has_layer();
} else {
clear_has_layer();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V1LayerParameter.layer)
}
inline const V1LayerParameter* V1LayerParameter::internal_default_instance() {
return &V1LayerParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
const ::google::protobuf::EnumDescriptor* V0LayerParameter_PoolMethod_descriptor() {
protobuf_AssignDescriptorsOnce();
return V0LayerParameter_PoolMethod_descriptor_;
}
bool V0LayerParameter_PoolMethod_IsValid(int value) {
switch (value) {
case 0:
case 1:
case 2:
return true;
default:
return false;
}
}
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const V0LayerParameter_PoolMethod V0LayerParameter::MAX;
const V0LayerParameter_PoolMethod V0LayerParameter::AVE;
const V0LayerParameter_PoolMethod V0LayerParameter::STOCHASTIC;
const V0LayerParameter_PoolMethod V0LayerParameter::PoolMethod_MIN;
const V0LayerParameter_PoolMethod V0LayerParameter::PoolMethod_MAX;
const int V0LayerParameter::PoolMethod_ARRAYSIZE;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
::std::string* V0LayerParameter::_default_det_crop_mode_ = NULL;
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int V0LayerParameter::kNameFieldNumber;
const int V0LayerParameter::kTypeFieldNumber;
const int V0LayerParameter::kNumOutputFieldNumber;
const int V0LayerParameter::kBiastermFieldNumber;
const int V0LayerParameter::kWeightFillerFieldNumber;
const int V0LayerParameter::kBiasFillerFieldNumber;
const int V0LayerParameter::kPadFieldNumber;
const int V0LayerParameter::kKernelsizeFieldNumber;
const int V0LayerParameter::kGroupFieldNumber;
const int V0LayerParameter::kStrideFieldNumber;
const int V0LayerParameter::kPoolFieldNumber;
const int V0LayerParameter::kDropoutRatioFieldNumber;
const int V0LayerParameter::kLocalSizeFieldNumber;
const int V0LayerParameter::kAlphaFieldNumber;
const int V0LayerParameter::kBetaFieldNumber;
const int V0LayerParameter::kKFieldNumber;
const int V0LayerParameter::kSourceFieldNumber;
const int V0LayerParameter::kScaleFieldNumber;
const int V0LayerParameter::kMeanfileFieldNumber;
const int V0LayerParameter::kBatchsizeFieldNumber;
const int V0LayerParameter::kCropsizeFieldNumber;
const int V0LayerParameter::kMirrorFieldNumber;
const int V0LayerParameter::kBlobsFieldNumber;
const int V0LayerParameter::kBlobsLrFieldNumber;
const int V0LayerParameter::kWeightDecayFieldNumber;
const int V0LayerParameter::kRandSkipFieldNumber;
const int V0LayerParameter::kDetFgThresholdFieldNumber;
const int V0LayerParameter::kDetBgThresholdFieldNumber;
const int V0LayerParameter::kDetFgFractionFieldNumber;
const int V0LayerParameter::kDetContextPadFieldNumber;
const int V0LayerParameter::kDetCropModeFieldNumber;
const int V0LayerParameter::kNewNumFieldNumber;
const int V0LayerParameter::kNewChannelsFieldNumber;
const int V0LayerParameter::kNewHeightFieldNumber;
const int V0LayerParameter::kNewWidthFieldNumber;
const int V0LayerParameter::kShuffleImagesFieldNumber;
const int V0LayerParameter::kConcatDimFieldNumber;
const int V0LayerParameter::kHdf5OutputParamFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
V0LayerParameter::V0LayerParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.V0LayerParameter)
}
void V0LayerParameter::InitAsDefaultInstance() {
weight_filler_ = const_cast< ::opencv_caffe::FillerParameter*>(
::opencv_caffe::FillerParameter::internal_default_instance());
bias_filler_ = const_cast< ::opencv_caffe::FillerParameter*>(
::opencv_caffe::FillerParameter::internal_default_instance());
hdf5_output_param_ = const_cast< ::opencv_caffe::HDF5OutputParameter*>(
::opencv_caffe::HDF5OutputParameter::internal_default_instance());
}
V0LayerParameter::V0LayerParameter(const V0LayerParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.V0LayerParameter)
}
void V0LayerParameter::SharedCtor() {
name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
type_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
source_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
meanfile_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
det_crop_mode_.UnsafeSetDefault(_default_det_crop_mode_);
weight_filler_ = NULL;
bias_filler_ = NULL;
hdf5_output_param_ = NULL;
::memset(&num_output_, 0, reinterpret_cast<char*>(&new_width_) -
reinterpret_cast<char*>(&num_output_) + sizeof(new_width_));
concat_dim_ = 1u;
biasterm_ = true;
group_ = 1u;
stride_ = 1u;
dropout_ratio_ = 0.5f;
local_size_ = 5u;
alpha_ = 1;
beta_ = 0.75f;
k_ = 1;
scale_ = 1;
det_fg_threshold_ = 0.5f;
det_bg_threshold_ = 0.5f;
det_fg_fraction_ = 0.25f;
_cached_size_ = 0;
}
V0LayerParameter::~V0LayerParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.V0LayerParameter)
SharedDtor();
}
void V0LayerParameter::SharedDtor() {
name_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
type_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
source_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
meanfile_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
det_crop_mode_.DestroyNoArena(_default_det_crop_mode_);
if (this != &V0LayerParameter_default_instance_.get()) {
delete weight_filler_;
delete bias_filler_;
delete hdf5_output_param_;
}
}
void V0LayerParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* V0LayerParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return V0LayerParameter_descriptor_;
}
const V0LayerParameter& V0LayerParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<V0LayerParameter> V0LayerParameter_default_instance_;
V0LayerParameter* V0LayerParameter::New(::google::protobuf::Arena* arena) const {
V0LayerParameter* n = new V0LayerParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void V0LayerParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.V0LayerParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(V0LayerParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<V0LayerParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
if (_has_bits_[0 / 32] & 255u) {
ZR_(num_output_, kernelsize_);
if (has_name()) {
name_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
if (has_type()) {
type_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
biasterm_ = true;
if (has_weight_filler()) {
if (weight_filler_ != NULL) weight_filler_->::opencv_caffe::FillerParameter::Clear();
}
if (has_bias_filler()) {
if (bias_filler_ != NULL) bias_filler_->::opencv_caffe::FillerParameter::Clear();
}
}
if (_has_bits_[8 / 32] & 65280u) {
group_ = 1u;
stride_ = 1u;
pool_ = 0;
dropout_ratio_ = 0.5f;
local_size_ = 5u;
alpha_ = 1;
beta_ = 0.75f;
k_ = 1;
}
if (_has_bits_[16 / 32] & 4128768u) {
ZR_(batchsize_, cropsize_);
if (has_source()) {
source_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
scale_ = 1;
if (has_meanfile()) {
meanfile_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
mirror_ = false;
}
if (_has_bits_[24 / 32] & 4261412864u) {
ZR_(det_context_pad_, new_num_);
rand_skip_ = 0u;
det_fg_threshold_ = 0.5f;
det_bg_threshold_ = 0.5f;
det_fg_fraction_ = 0.25f;
if (has_det_crop_mode()) {
det_crop_mode_.ClearToDefaultNoArena(_default_det_crop_mode_);
}
}
if (_has_bits_[32 / 32] & 63u) {
ZR_(new_channels_, new_width_);
shuffle_images_ = false;
concat_dim_ = 1u;
if (has_hdf5_output_param()) {
if (hdf5_output_param_ != NULL) hdf5_output_param_->::opencv_caffe::HDF5OutputParameter::Clear();
}
}
#undef ZR_HELPER_
#undef ZR_
blobs_.Clear();
blobs_lr_.Clear();
weight_decay_.Clear();
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool V0LayerParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.V0LayerParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(16383);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional string name = 1;
case 1: {
if (tag == 10) {
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_name()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->name().data(), this->name().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.V0LayerParameter.name");
} else {
goto handle_unusual;
}
if (input->ExpectTag(18)) goto parse_type;
break;
}
// optional string type = 2;
case 2: {
if (tag == 18) {
parse_type:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_type()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->type().data(), this->type().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.V0LayerParameter.type");
} else {
goto handle_unusual;
}
if (input->ExpectTag(24)) goto parse_num_output;
break;
}
// optional uint32 num_output = 3;
case 3: {
if (tag == 24) {
parse_num_output:
set_has_num_output();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &num_output_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(32)) goto parse_biasterm;
break;
}
// optional bool biasterm = 4 [default = true];
case 4: {
if (tag == 32) {
parse_biasterm:
set_has_biasterm();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &biasterm_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(42)) goto parse_weight_filler;
break;
}
// optional .opencv_caffe.FillerParameter weight_filler = 5;
case 5: {
if (tag == 42) {
parse_weight_filler:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_weight_filler()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(50)) goto parse_bias_filler;
break;
}
// optional .opencv_caffe.FillerParameter bias_filler = 6;
case 6: {
if (tag == 50) {
parse_bias_filler:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_bias_filler()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(56)) goto parse_pad;
break;
}
// optional uint32 pad = 7 [default = 0];
case 7: {
if (tag == 56) {
parse_pad:
set_has_pad();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &pad_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(64)) goto parse_kernelsize;
break;
}
// optional uint32 kernelsize = 8;
case 8: {
if (tag == 64) {
parse_kernelsize:
set_has_kernelsize();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &kernelsize_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(72)) goto parse_group;
break;
}
// optional uint32 group = 9 [default = 1];
case 9: {
if (tag == 72) {
parse_group:
set_has_group();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &group_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(80)) goto parse_stride;
break;
}
// optional uint32 stride = 10 [default = 1];
case 10: {
if (tag == 80) {
parse_stride:
set_has_stride();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &stride_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(88)) goto parse_pool;
break;
}
// optional .opencv_caffe.V0LayerParameter.PoolMethod pool = 11 [default = MAX];
case 11: {
if (tag == 88) {
parse_pool:
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
input, &value)));
if (::opencv_caffe::V0LayerParameter_PoolMethod_IsValid(value)) {
set_pool(static_cast< ::opencv_caffe::V0LayerParameter_PoolMethod >(value));
} else {
mutable_unknown_fields()->AddVarint(11, value);
}
} else {
goto handle_unusual;
}
if (input->ExpectTag(101)) goto parse_dropout_ratio;
break;
}
// optional float dropout_ratio = 12 [default = 0.5];
case 12: {
if (tag == 101) {
parse_dropout_ratio:
set_has_dropout_ratio();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &dropout_ratio_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(104)) goto parse_local_size;
break;
}
// optional uint32 local_size = 13 [default = 5];
case 13: {
if (tag == 104) {
parse_local_size:
set_has_local_size();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &local_size_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(117)) goto parse_alpha;
break;
}
// optional float alpha = 14 [default = 1];
case 14: {
if (tag == 117) {
parse_alpha:
set_has_alpha();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &alpha_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(125)) goto parse_beta;
break;
}
// optional float beta = 15 [default = 0.75];
case 15: {
if (tag == 125) {
parse_beta:
set_has_beta();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &beta_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(130)) goto parse_source;
break;
}
// optional string source = 16;
case 16: {
if (tag == 130) {
parse_source:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_source()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->source().data(), this->source().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.V0LayerParameter.source");
} else {
goto handle_unusual;
}
if (input->ExpectTag(141)) goto parse_scale;
break;
}
// optional float scale = 17 [default = 1];
case 17: {
if (tag == 141) {
parse_scale:
set_has_scale();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &scale_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(146)) goto parse_meanfile;
break;
}
// optional string meanfile = 18;
case 18: {
if (tag == 146) {
parse_meanfile:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_meanfile()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->meanfile().data(), this->meanfile().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.V0LayerParameter.meanfile");
} else {
goto handle_unusual;
}
if (input->ExpectTag(152)) goto parse_batchsize;
break;
}
// optional uint32 batchsize = 19;
case 19: {
if (tag == 152) {
parse_batchsize:
set_has_batchsize();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &batchsize_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(160)) goto parse_cropsize;
break;
}
// optional uint32 cropsize = 20 [default = 0];
case 20: {
if (tag == 160) {
parse_cropsize:
set_has_cropsize();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &cropsize_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(168)) goto parse_mirror;
break;
}
// optional bool mirror = 21 [default = false];
case 21: {
if (tag == 168) {
parse_mirror:
set_has_mirror();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &mirror_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(181)) goto parse_k;
break;
}
// optional float k = 22 [default = 1];
case 22: {
if (tag == 181) {
parse_k:
set_has_k();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &k_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(402)) goto parse_blobs;
break;
}
// repeated .opencv_caffe.BlobProto blobs = 50;
case 50: {
if (tag == 402) {
parse_blobs:
DO_(input->IncrementRecursionDepth());
parse_loop_blobs:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtualNoRecursionDepth(
input, add_blobs()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(402)) goto parse_loop_blobs;
input->UnsafeDecrementRecursionDepth();
if (input->ExpectTag(413)) goto parse_blobs_lr;
break;
}
// repeated float blobs_lr = 51;
case 51: {
if (tag == 413) {
parse_blobs_lr:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
2, 413, input, this->mutable_blobs_lr())));
} else if (tag == 410) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, this->mutable_blobs_lr())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(413)) goto parse_blobs_lr;
if (input->ExpectTag(421)) goto parse_weight_decay;
break;
}
// repeated float weight_decay = 52;
case 52: {
if (tag == 421) {
parse_weight_decay:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
2, 421, input, this->mutable_weight_decay())));
} else if (tag == 418) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, this->mutable_weight_decay())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(421)) goto parse_weight_decay;
if (input->ExpectTag(424)) goto parse_rand_skip;
break;
}
// optional uint32 rand_skip = 53 [default = 0];
case 53: {
if (tag == 424) {
parse_rand_skip:
set_has_rand_skip();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &rand_skip_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(437)) goto parse_det_fg_threshold;
break;
}
// optional float det_fg_threshold = 54 [default = 0.5];
case 54: {
if (tag == 437) {
parse_det_fg_threshold:
set_has_det_fg_threshold();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &det_fg_threshold_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(445)) goto parse_det_bg_threshold;
break;
}
// optional float det_bg_threshold = 55 [default = 0.5];
case 55: {
if (tag == 445) {
parse_det_bg_threshold:
set_has_det_bg_threshold();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &det_bg_threshold_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(453)) goto parse_det_fg_fraction;
break;
}
// optional float det_fg_fraction = 56 [default = 0.25];
case 56: {
if (tag == 453) {
parse_det_fg_fraction:
set_has_det_fg_fraction();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &det_fg_fraction_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(464)) goto parse_det_context_pad;
break;
}
// optional uint32 det_context_pad = 58 [default = 0];
case 58: {
if (tag == 464) {
parse_det_context_pad:
set_has_det_context_pad();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &det_context_pad_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(474)) goto parse_det_crop_mode;
break;
}
// optional string det_crop_mode = 59 [default = "warp"];
case 59: {
if (tag == 474) {
parse_det_crop_mode:
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_det_crop_mode()));
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->det_crop_mode().data(), this->det_crop_mode().length(),
::google::protobuf::internal::WireFormat::PARSE,
"opencv_caffe.V0LayerParameter.det_crop_mode");
} else {
goto handle_unusual;
}
if (input->ExpectTag(480)) goto parse_new_num;
break;
}
// optional int32 new_num = 60 [default = 0];
case 60: {
if (tag == 480) {
parse_new_num:
set_has_new_num();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &new_num_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(488)) goto parse_new_channels;
break;
}
// optional int32 new_channels = 61 [default = 0];
case 61: {
if (tag == 488) {
parse_new_channels:
set_has_new_channels();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &new_channels_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(496)) goto parse_new_height;
break;
}
// optional int32 new_height = 62 [default = 0];
case 62: {
if (tag == 496) {
parse_new_height:
set_has_new_height();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &new_height_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(504)) goto parse_new_width;
break;
}
// optional int32 new_width = 63 [default = 0];
case 63: {
if (tag == 504) {
parse_new_width:
set_has_new_width();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &new_width_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(512)) goto parse_shuffle_images;
break;
}
// optional bool shuffle_images = 64 [default = false];
case 64: {
if (tag == 512) {
parse_shuffle_images:
set_has_shuffle_images();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &shuffle_images_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(520)) goto parse_concat_dim;
break;
}
// optional uint32 concat_dim = 65 [default = 1];
case 65: {
if (tag == 520) {
parse_concat_dim:
set_has_concat_dim();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &concat_dim_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(8010)) goto parse_hdf5_output_param;
break;
}
// optional .opencv_caffe.HDF5OutputParameter hdf5_output_param = 1001;
case 1001: {
if (tag == 8010) {
parse_hdf5_output_param:
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_hdf5_output_param()));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.V0LayerParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.V0LayerParameter)
return false;
#undef DO_
}
void V0LayerParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.V0LayerParameter)
// optional string name = 1;
if (has_name()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->name().data(), this->name().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.V0LayerParameter.name");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
1, this->name(), output);
}
// optional string type = 2;
if (has_type()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->type().data(), this->type().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.V0LayerParameter.type");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
2, this->type(), output);
}
// optional uint32 num_output = 3;
if (has_num_output()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(3, this->num_output(), output);
}
// optional bool biasterm = 4 [default = true];
if (has_biasterm()) {
::google::protobuf::internal::WireFormatLite::WriteBool(4, this->biasterm(), output);
}
// optional .opencv_caffe.FillerParameter weight_filler = 5;
if (has_weight_filler()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
5, *this->weight_filler_, output);
}
// optional .opencv_caffe.FillerParameter bias_filler = 6;
if (has_bias_filler()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
6, *this->bias_filler_, output);
}
// optional uint32 pad = 7 [default = 0];
if (has_pad()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(7, this->pad(), output);
}
// optional uint32 kernelsize = 8;
if (has_kernelsize()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(8, this->kernelsize(), output);
}
// optional uint32 group = 9 [default = 1];
if (has_group()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(9, this->group(), output);
}
// optional uint32 stride = 10 [default = 1];
if (has_stride()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(10, this->stride(), output);
}
// optional .opencv_caffe.V0LayerParameter.PoolMethod pool = 11 [default = MAX];
if (has_pool()) {
::google::protobuf::internal::WireFormatLite::WriteEnum(
11, this->pool(), output);
}
// optional float dropout_ratio = 12 [default = 0.5];
if (has_dropout_ratio()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(12, this->dropout_ratio(), output);
}
// optional uint32 local_size = 13 [default = 5];
if (has_local_size()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(13, this->local_size(), output);
}
// optional float alpha = 14 [default = 1];
if (has_alpha()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(14, this->alpha(), output);
}
// optional float beta = 15 [default = 0.75];
if (has_beta()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(15, this->beta(), output);
}
// optional string source = 16;
if (has_source()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->source().data(), this->source().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.V0LayerParameter.source");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
16, this->source(), output);
}
// optional float scale = 17 [default = 1];
if (has_scale()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(17, this->scale(), output);
}
// optional string meanfile = 18;
if (has_meanfile()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->meanfile().data(), this->meanfile().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.V0LayerParameter.meanfile");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
18, this->meanfile(), output);
}
// optional uint32 batchsize = 19;
if (has_batchsize()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(19, this->batchsize(), output);
}
// optional uint32 cropsize = 20 [default = 0];
if (has_cropsize()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(20, this->cropsize(), output);
}
// optional bool mirror = 21 [default = false];
if (has_mirror()) {
::google::protobuf::internal::WireFormatLite::WriteBool(21, this->mirror(), output);
}
// optional float k = 22 [default = 1];
if (has_k()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(22, this->k(), output);
}
// repeated .opencv_caffe.BlobProto blobs = 50;
for (unsigned int i = 0, n = this->blobs_size(); i < n; i++) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
50, this->blobs(i), output);
}
// repeated float blobs_lr = 51;
for (int i = 0; i < this->blobs_lr_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteFloat(
51, this->blobs_lr(i), output);
}
// repeated float weight_decay = 52;
for (int i = 0; i < this->weight_decay_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteFloat(
52, this->weight_decay(i), output);
}
// optional uint32 rand_skip = 53 [default = 0];
if (has_rand_skip()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(53, this->rand_skip(), output);
}
// optional float det_fg_threshold = 54 [default = 0.5];
if (has_det_fg_threshold()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(54, this->det_fg_threshold(), output);
}
// optional float det_bg_threshold = 55 [default = 0.5];
if (has_det_bg_threshold()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(55, this->det_bg_threshold(), output);
}
// optional float det_fg_fraction = 56 [default = 0.25];
if (has_det_fg_fraction()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(56, this->det_fg_fraction(), output);
}
// optional uint32 det_context_pad = 58 [default = 0];
if (has_det_context_pad()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(58, this->det_context_pad(), output);
}
// optional string det_crop_mode = 59 [default = "warp"];
if (has_det_crop_mode()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->det_crop_mode().data(), this->det_crop_mode().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.V0LayerParameter.det_crop_mode");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
59, this->det_crop_mode(), output);
}
// optional int32 new_num = 60 [default = 0];
if (has_new_num()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(60, this->new_num(), output);
}
// optional int32 new_channels = 61 [default = 0];
if (has_new_channels()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(61, this->new_channels(), output);
}
// optional int32 new_height = 62 [default = 0];
if (has_new_height()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(62, this->new_height(), output);
}
// optional int32 new_width = 63 [default = 0];
if (has_new_width()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(63, this->new_width(), output);
}
// optional bool shuffle_images = 64 [default = false];
if (has_shuffle_images()) {
::google::protobuf::internal::WireFormatLite::WriteBool(64, this->shuffle_images(), output);
}
// optional uint32 concat_dim = 65 [default = 1];
if (has_concat_dim()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(65, this->concat_dim(), output);
}
// optional .opencv_caffe.HDF5OutputParameter hdf5_output_param = 1001;
if (has_hdf5_output_param()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
1001, *this->hdf5_output_param_, output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.V0LayerParameter)
}
::google::protobuf::uint8* V0LayerParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.V0LayerParameter)
// optional string name = 1;
if (has_name()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->name().data(), this->name().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.V0LayerParameter.name");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
1, this->name(), target);
}
// optional string type = 2;
if (has_type()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->type().data(), this->type().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.V0LayerParameter.type");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
2, this->type(), target);
}
// optional uint32 num_output = 3;
if (has_num_output()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(3, this->num_output(), target);
}
// optional bool biasterm = 4 [default = true];
if (has_biasterm()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(4, this->biasterm(), target);
}
// optional .opencv_caffe.FillerParameter weight_filler = 5;
if (has_weight_filler()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
5, *this->weight_filler_, false, target);
}
// optional .opencv_caffe.FillerParameter bias_filler = 6;
if (has_bias_filler()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
6, *this->bias_filler_, false, target);
}
// optional uint32 pad = 7 [default = 0];
if (has_pad()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(7, this->pad(), target);
}
// optional uint32 kernelsize = 8;
if (has_kernelsize()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(8, this->kernelsize(), target);
}
// optional uint32 group = 9 [default = 1];
if (has_group()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(9, this->group(), target);
}
// optional uint32 stride = 10 [default = 1];
if (has_stride()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(10, this->stride(), target);
}
// optional .opencv_caffe.V0LayerParameter.PoolMethod pool = 11 [default = MAX];
if (has_pool()) {
target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray(
11, this->pool(), target);
}
// optional float dropout_ratio = 12 [default = 0.5];
if (has_dropout_ratio()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(12, this->dropout_ratio(), target);
}
// optional uint32 local_size = 13 [default = 5];
if (has_local_size()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(13, this->local_size(), target);
}
// optional float alpha = 14 [default = 1];
if (has_alpha()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(14, this->alpha(), target);
}
// optional float beta = 15 [default = 0.75];
if (has_beta()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(15, this->beta(), target);
}
// optional string source = 16;
if (has_source()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->source().data(), this->source().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.V0LayerParameter.source");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
16, this->source(), target);
}
// optional float scale = 17 [default = 1];
if (has_scale()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(17, this->scale(), target);
}
// optional string meanfile = 18;
if (has_meanfile()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->meanfile().data(), this->meanfile().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.V0LayerParameter.meanfile");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
18, this->meanfile(), target);
}
// optional uint32 batchsize = 19;
if (has_batchsize()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(19, this->batchsize(), target);
}
// optional uint32 cropsize = 20 [default = 0];
if (has_cropsize()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(20, this->cropsize(), target);
}
// optional bool mirror = 21 [default = false];
if (has_mirror()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(21, this->mirror(), target);
}
// optional float k = 22 [default = 1];
if (has_k()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(22, this->k(), target);
}
// repeated .opencv_caffe.BlobProto blobs = 50;
for (unsigned int i = 0, n = this->blobs_size(); i < n; i++) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
50, this->blobs(i), false, target);
}
// repeated float blobs_lr = 51;
for (int i = 0; i < this->blobs_lr_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteFloatToArray(51, this->blobs_lr(i), target);
}
// repeated float weight_decay = 52;
for (int i = 0; i < this->weight_decay_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteFloatToArray(52, this->weight_decay(i), target);
}
// optional uint32 rand_skip = 53 [default = 0];
if (has_rand_skip()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(53, this->rand_skip(), target);
}
// optional float det_fg_threshold = 54 [default = 0.5];
if (has_det_fg_threshold()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(54, this->det_fg_threshold(), target);
}
// optional float det_bg_threshold = 55 [default = 0.5];
if (has_det_bg_threshold()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(55, this->det_bg_threshold(), target);
}
// optional float det_fg_fraction = 56 [default = 0.25];
if (has_det_fg_fraction()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(56, this->det_fg_fraction(), target);
}
// optional uint32 det_context_pad = 58 [default = 0];
if (has_det_context_pad()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(58, this->det_context_pad(), target);
}
// optional string det_crop_mode = 59 [default = "warp"];
if (has_det_crop_mode()) {
::google::protobuf::internal::WireFormat::VerifyUTF8StringNamedField(
this->det_crop_mode().data(), this->det_crop_mode().length(),
::google::protobuf::internal::WireFormat::SERIALIZE,
"opencv_caffe.V0LayerParameter.det_crop_mode");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
59, this->det_crop_mode(), target);
}
// optional int32 new_num = 60 [default = 0];
if (has_new_num()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(60, this->new_num(), target);
}
// optional int32 new_channels = 61 [default = 0];
if (has_new_channels()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(61, this->new_channels(), target);
}
// optional int32 new_height = 62 [default = 0];
if (has_new_height()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(62, this->new_height(), target);
}
// optional int32 new_width = 63 [default = 0];
if (has_new_width()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(63, this->new_width(), target);
}
// optional bool shuffle_images = 64 [default = false];
if (has_shuffle_images()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(64, this->shuffle_images(), target);
}
// optional uint32 concat_dim = 65 [default = 1];
if (has_concat_dim()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(65, this->concat_dim(), target);
}
// optional .opencv_caffe.HDF5OutputParameter hdf5_output_param = 1001;
if (has_hdf5_output_param()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
1001, *this->hdf5_output_param_, false, target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.V0LayerParameter)
return target;
}
size_t V0LayerParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.V0LayerParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 255u) {
// optional string name = 1;
if (has_name()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->name());
}
// optional string type = 2;
if (has_type()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->type());
}
// optional uint32 num_output = 3;
if (has_num_output()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->num_output());
}
// optional bool biasterm = 4 [default = true];
if (has_biasterm()) {
total_size += 1 + 1;
}
// optional .opencv_caffe.FillerParameter weight_filler = 5;
if (has_weight_filler()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->weight_filler_);
}
// optional .opencv_caffe.FillerParameter bias_filler = 6;
if (has_bias_filler()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->bias_filler_);
}
// optional uint32 pad = 7 [default = 0];
if (has_pad()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->pad());
}
// optional uint32 kernelsize = 8;
if (has_kernelsize()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->kernelsize());
}
}
if (_has_bits_[8 / 32] & 65280u) {
// optional uint32 group = 9 [default = 1];
if (has_group()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->group());
}
// optional uint32 stride = 10 [default = 1];
if (has_stride()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->stride());
}
// optional .opencv_caffe.V0LayerParameter.PoolMethod pool = 11 [default = MAX];
if (has_pool()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::EnumSize(this->pool());
}
// optional float dropout_ratio = 12 [default = 0.5];
if (has_dropout_ratio()) {
total_size += 1 + 4;
}
// optional uint32 local_size = 13 [default = 5];
if (has_local_size()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->local_size());
}
// optional float alpha = 14 [default = 1];
if (has_alpha()) {
total_size += 1 + 4;
}
// optional float beta = 15 [default = 0.75];
if (has_beta()) {
total_size += 1 + 4;
}
// optional float k = 22 [default = 1];
if (has_k()) {
total_size += 2 + 4;
}
}
if (_has_bits_[16 / 32] & 4128768u) {
// optional string source = 16;
if (has_source()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->source());
}
// optional float scale = 17 [default = 1];
if (has_scale()) {
total_size += 2 + 4;
}
// optional string meanfile = 18;
if (has_meanfile()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->meanfile());
}
// optional uint32 batchsize = 19;
if (has_batchsize()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->batchsize());
}
// optional uint32 cropsize = 20 [default = 0];
if (has_cropsize()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->cropsize());
}
// optional bool mirror = 21 [default = false];
if (has_mirror()) {
total_size += 2 + 1;
}
}
if (_has_bits_[25 / 32] & 4261412864u) {
// optional uint32 rand_skip = 53 [default = 0];
if (has_rand_skip()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->rand_skip());
}
// optional float det_fg_threshold = 54 [default = 0.5];
if (has_det_fg_threshold()) {
total_size += 2 + 4;
}
// optional float det_bg_threshold = 55 [default = 0.5];
if (has_det_bg_threshold()) {
total_size += 2 + 4;
}
// optional float det_fg_fraction = 56 [default = 0.25];
if (has_det_fg_fraction()) {
total_size += 2 + 4;
}
// optional uint32 det_context_pad = 58 [default = 0];
if (has_det_context_pad()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->det_context_pad());
}
// optional string det_crop_mode = 59 [default = "warp"];
if (has_det_crop_mode()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->det_crop_mode());
}
// optional int32 new_num = 60 [default = 0];
if (has_new_num()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->new_num());
}
}
if (_has_bits_[32 / 32] & 63u) {
// optional int32 new_channels = 61 [default = 0];
if (has_new_channels()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->new_channels());
}
// optional int32 new_height = 62 [default = 0];
if (has_new_height()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->new_height());
}
// optional int32 new_width = 63 [default = 0];
if (has_new_width()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->new_width());
}
// optional bool shuffle_images = 64 [default = false];
if (has_shuffle_images()) {
total_size += 2 + 1;
}
// optional uint32 concat_dim = 65 [default = 1];
if (has_concat_dim()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->concat_dim());
}
// optional .opencv_caffe.HDF5OutputParameter hdf5_output_param = 1001;
if (has_hdf5_output_param()) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->hdf5_output_param_);
}
}
// repeated .opencv_caffe.BlobProto blobs = 50;
{
unsigned int count = this->blobs_size();
total_size += 2UL * count;
for (unsigned int i = 0; i < count; i++) {
total_size +=
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
this->blobs(i));
}
}
// repeated float blobs_lr = 51;
{
size_t data_size = 0;
unsigned int count = this->blobs_lr_size();
data_size = 4UL * count;
total_size += 2 *
::google::protobuf::internal::FromIntSize(this->blobs_lr_size());
total_size += data_size;
}
// repeated float weight_decay = 52;
{
size_t data_size = 0;
unsigned int count = this->weight_decay_size();
data_size = 4UL * count;
total_size += 2 *
::google::protobuf::internal::FromIntSize(this->weight_decay_size());
total_size += data_size;
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void V0LayerParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.V0LayerParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const V0LayerParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const V0LayerParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.V0LayerParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.V0LayerParameter)
UnsafeMergeFrom(*source);
}
}
void V0LayerParameter::MergeFrom(const V0LayerParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.V0LayerParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void V0LayerParameter::UnsafeMergeFrom(const V0LayerParameter& from) {
GOOGLE_DCHECK(&from != this);
blobs_.MergeFrom(from.blobs_);
blobs_lr_.UnsafeMergeFrom(from.blobs_lr_);
weight_decay_.UnsafeMergeFrom(from.weight_decay_);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_name()) {
set_has_name();
name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.name_);
}
if (from.has_type()) {
set_has_type();
type_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.type_);
}
if (from.has_num_output()) {
set_num_output(from.num_output());
}
if (from.has_biasterm()) {
set_biasterm(from.biasterm());
}
if (from.has_weight_filler()) {
mutable_weight_filler()->::opencv_caffe::FillerParameter::MergeFrom(from.weight_filler());
}
if (from.has_bias_filler()) {
mutable_bias_filler()->::opencv_caffe::FillerParameter::MergeFrom(from.bias_filler());
}
if (from.has_pad()) {
set_pad(from.pad());
}
if (from.has_kernelsize()) {
set_kernelsize(from.kernelsize());
}
}
if (from._has_bits_[8 / 32] & (0xffu << (8 % 32))) {
if (from.has_group()) {
set_group(from.group());
}
if (from.has_stride()) {
set_stride(from.stride());
}
if (from.has_pool()) {
set_pool(from.pool());
}
if (from.has_dropout_ratio()) {
set_dropout_ratio(from.dropout_ratio());
}
if (from.has_local_size()) {
set_local_size(from.local_size());
}
if (from.has_alpha()) {
set_alpha(from.alpha());
}
if (from.has_beta()) {
set_beta(from.beta());
}
if (from.has_k()) {
set_k(from.k());
}
}
if (from._has_bits_[16 / 32] & (0xffu << (16 % 32))) {
if (from.has_source()) {
set_has_source();
source_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.source_);
}
if (from.has_scale()) {
set_scale(from.scale());
}
if (from.has_meanfile()) {
set_has_meanfile();
meanfile_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.meanfile_);
}
if (from.has_batchsize()) {
set_batchsize(from.batchsize());
}
if (from.has_cropsize()) {
set_cropsize(from.cropsize());
}
if (from.has_mirror()) {
set_mirror(from.mirror());
}
}
if (from._has_bits_[25 / 32] & (0xffu << (25 % 32))) {
if (from.has_rand_skip()) {
set_rand_skip(from.rand_skip());
}
if (from.has_det_fg_threshold()) {
set_det_fg_threshold(from.det_fg_threshold());
}
if (from.has_det_bg_threshold()) {
set_det_bg_threshold(from.det_bg_threshold());
}
if (from.has_det_fg_fraction()) {
set_det_fg_fraction(from.det_fg_fraction());
}
if (from.has_det_context_pad()) {
set_det_context_pad(from.det_context_pad());
}
if (from.has_det_crop_mode()) {
set_has_det_crop_mode();
det_crop_mode_.AssignWithDefault(_default_det_crop_mode_, from.det_crop_mode_);
}
if (from.has_new_num()) {
set_new_num(from.new_num());
}
}
if (from._has_bits_[32 / 32] & (0xffu << (32 % 32))) {
if (from.has_new_channels()) {
set_new_channels(from.new_channels());
}
if (from.has_new_height()) {
set_new_height(from.new_height());
}
if (from.has_new_width()) {
set_new_width(from.new_width());
}
if (from.has_shuffle_images()) {
set_shuffle_images(from.shuffle_images());
}
if (from.has_concat_dim()) {
set_concat_dim(from.concat_dim());
}
if (from.has_hdf5_output_param()) {
mutable_hdf5_output_param()->::opencv_caffe::HDF5OutputParameter::MergeFrom(from.hdf5_output_param());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void V0LayerParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.V0LayerParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void V0LayerParameter::CopyFrom(const V0LayerParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.V0LayerParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool V0LayerParameter::IsInitialized() const {
return true;
}
void V0LayerParameter::Swap(V0LayerParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void V0LayerParameter::InternalSwap(V0LayerParameter* other) {
name_.Swap(&other->name_);
type_.Swap(&other->type_);
std::swap(num_output_, other->num_output_);
std::swap(biasterm_, other->biasterm_);
std::swap(weight_filler_, other->weight_filler_);
std::swap(bias_filler_, other->bias_filler_);
std::swap(pad_, other->pad_);
std::swap(kernelsize_, other->kernelsize_);
std::swap(group_, other->group_);
std::swap(stride_, other->stride_);
std::swap(pool_, other->pool_);
std::swap(dropout_ratio_, other->dropout_ratio_);
std::swap(local_size_, other->local_size_);
std::swap(alpha_, other->alpha_);
std::swap(beta_, other->beta_);
std::swap(k_, other->k_);
source_.Swap(&other->source_);
std::swap(scale_, other->scale_);
meanfile_.Swap(&other->meanfile_);
std::swap(batchsize_, other->batchsize_);
std::swap(cropsize_, other->cropsize_);
std::swap(mirror_, other->mirror_);
blobs_.UnsafeArenaSwap(&other->blobs_);
blobs_lr_.UnsafeArenaSwap(&other->blobs_lr_);
weight_decay_.UnsafeArenaSwap(&other->weight_decay_);
std::swap(rand_skip_, other->rand_skip_);
std::swap(det_fg_threshold_, other->det_fg_threshold_);
std::swap(det_bg_threshold_, other->det_bg_threshold_);
std::swap(det_fg_fraction_, other->det_fg_fraction_);
std::swap(det_context_pad_, other->det_context_pad_);
det_crop_mode_.Swap(&other->det_crop_mode_);
std::swap(new_num_, other->new_num_);
std::swap(new_channels_, other->new_channels_);
std::swap(new_height_, other->new_height_);
std::swap(new_width_, other->new_width_);
std::swap(shuffle_images_, other->shuffle_images_);
std::swap(concat_dim_, other->concat_dim_);
std::swap(hdf5_output_param_, other->hdf5_output_param_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
std::swap(_has_bits_[1], other->_has_bits_[1]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata V0LayerParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = V0LayerParameter_descriptor_;
metadata.reflection = V0LayerParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// V0LayerParameter
// optional string name = 1;
bool V0LayerParameter::has_name() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void V0LayerParameter::set_has_name() {
_has_bits_[0] |= 0x00000001u;
}
void V0LayerParameter::clear_has_name() {
_has_bits_[0] &= ~0x00000001u;
}
void V0LayerParameter::clear_name() {
name_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_name();
}
const ::std::string& V0LayerParameter::name() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.name)
return name_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void V0LayerParameter::set_name(const ::std::string& value) {
set_has_name();
name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.name)
}
void V0LayerParameter::set_name(const char* value) {
set_has_name();
name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.V0LayerParameter.name)
}
void V0LayerParameter::set_name(const char* value, size_t size) {
set_has_name();
name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.V0LayerParameter.name)
}
::std::string* V0LayerParameter::mutable_name() {
set_has_name();
// @@protoc_insertion_point(field_mutable:opencv_caffe.V0LayerParameter.name)
return name_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* V0LayerParameter::release_name() {
// @@protoc_insertion_point(field_release:opencv_caffe.V0LayerParameter.name)
clear_has_name();
return name_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void V0LayerParameter::set_allocated_name(::std::string* name) {
if (name != NULL) {
set_has_name();
} else {
clear_has_name();
}
name_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), name);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V0LayerParameter.name)
}
// optional string type = 2;
bool V0LayerParameter::has_type() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void V0LayerParameter::set_has_type() {
_has_bits_[0] |= 0x00000002u;
}
void V0LayerParameter::clear_has_type() {
_has_bits_[0] &= ~0x00000002u;
}
void V0LayerParameter::clear_type() {
type_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_type();
}
const ::std::string& V0LayerParameter::type() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.type)
return type_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void V0LayerParameter::set_type(const ::std::string& value) {
set_has_type();
type_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.type)
}
void V0LayerParameter::set_type(const char* value) {
set_has_type();
type_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.V0LayerParameter.type)
}
void V0LayerParameter::set_type(const char* value, size_t size) {
set_has_type();
type_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.V0LayerParameter.type)
}
::std::string* V0LayerParameter::mutable_type() {
set_has_type();
// @@protoc_insertion_point(field_mutable:opencv_caffe.V0LayerParameter.type)
return type_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* V0LayerParameter::release_type() {
// @@protoc_insertion_point(field_release:opencv_caffe.V0LayerParameter.type)
clear_has_type();
return type_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void V0LayerParameter::set_allocated_type(::std::string* type) {
if (type != NULL) {
set_has_type();
} else {
clear_has_type();
}
type_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), type);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V0LayerParameter.type)
}
// optional uint32 num_output = 3;
bool V0LayerParameter::has_num_output() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void V0LayerParameter::set_has_num_output() {
_has_bits_[0] |= 0x00000004u;
}
void V0LayerParameter::clear_has_num_output() {
_has_bits_[0] &= ~0x00000004u;
}
void V0LayerParameter::clear_num_output() {
num_output_ = 0u;
clear_has_num_output();
}
::google::protobuf::uint32 V0LayerParameter::num_output() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.num_output)
return num_output_;
}
void V0LayerParameter::set_num_output(::google::protobuf::uint32 value) {
set_has_num_output();
num_output_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.num_output)
}
// optional bool biasterm = 4 [default = true];
bool V0LayerParameter::has_biasterm() const {
return (_has_bits_[0] & 0x00000008u) != 0;
}
void V0LayerParameter::set_has_biasterm() {
_has_bits_[0] |= 0x00000008u;
}
void V0LayerParameter::clear_has_biasterm() {
_has_bits_[0] &= ~0x00000008u;
}
void V0LayerParameter::clear_biasterm() {
biasterm_ = true;
clear_has_biasterm();
}
bool V0LayerParameter::biasterm() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.biasterm)
return biasterm_;
}
void V0LayerParameter::set_biasterm(bool value) {
set_has_biasterm();
biasterm_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.biasterm)
}
// optional .opencv_caffe.FillerParameter weight_filler = 5;
bool V0LayerParameter::has_weight_filler() const {
return (_has_bits_[0] & 0x00000010u) != 0;
}
void V0LayerParameter::set_has_weight_filler() {
_has_bits_[0] |= 0x00000010u;
}
void V0LayerParameter::clear_has_weight_filler() {
_has_bits_[0] &= ~0x00000010u;
}
void V0LayerParameter::clear_weight_filler() {
if (weight_filler_ != NULL) weight_filler_->::opencv_caffe::FillerParameter::Clear();
clear_has_weight_filler();
}
const ::opencv_caffe::FillerParameter& V0LayerParameter::weight_filler() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.weight_filler)
return weight_filler_ != NULL ? *weight_filler_
: *::opencv_caffe::FillerParameter::internal_default_instance();
}
::opencv_caffe::FillerParameter* V0LayerParameter::mutable_weight_filler() {
set_has_weight_filler();
if (weight_filler_ == NULL) {
weight_filler_ = new ::opencv_caffe::FillerParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V0LayerParameter.weight_filler)
return weight_filler_;
}
::opencv_caffe::FillerParameter* V0LayerParameter::release_weight_filler() {
// @@protoc_insertion_point(field_release:opencv_caffe.V0LayerParameter.weight_filler)
clear_has_weight_filler();
::opencv_caffe::FillerParameter* temp = weight_filler_;
weight_filler_ = NULL;
return temp;
}
void V0LayerParameter::set_allocated_weight_filler(::opencv_caffe::FillerParameter* weight_filler) {
delete weight_filler_;
weight_filler_ = weight_filler;
if (weight_filler) {
set_has_weight_filler();
} else {
clear_has_weight_filler();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V0LayerParameter.weight_filler)
}
// optional .opencv_caffe.FillerParameter bias_filler = 6;
bool V0LayerParameter::has_bias_filler() const {
return (_has_bits_[0] & 0x00000020u) != 0;
}
void V0LayerParameter::set_has_bias_filler() {
_has_bits_[0] |= 0x00000020u;
}
void V0LayerParameter::clear_has_bias_filler() {
_has_bits_[0] &= ~0x00000020u;
}
void V0LayerParameter::clear_bias_filler() {
if (bias_filler_ != NULL) bias_filler_->::opencv_caffe::FillerParameter::Clear();
clear_has_bias_filler();
}
const ::opencv_caffe::FillerParameter& V0LayerParameter::bias_filler() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.bias_filler)
return bias_filler_ != NULL ? *bias_filler_
: *::opencv_caffe::FillerParameter::internal_default_instance();
}
::opencv_caffe::FillerParameter* V0LayerParameter::mutable_bias_filler() {
set_has_bias_filler();
if (bias_filler_ == NULL) {
bias_filler_ = new ::opencv_caffe::FillerParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V0LayerParameter.bias_filler)
return bias_filler_;
}
::opencv_caffe::FillerParameter* V0LayerParameter::release_bias_filler() {
// @@protoc_insertion_point(field_release:opencv_caffe.V0LayerParameter.bias_filler)
clear_has_bias_filler();
::opencv_caffe::FillerParameter* temp = bias_filler_;
bias_filler_ = NULL;
return temp;
}
void V0LayerParameter::set_allocated_bias_filler(::opencv_caffe::FillerParameter* bias_filler) {
delete bias_filler_;
bias_filler_ = bias_filler;
if (bias_filler) {
set_has_bias_filler();
} else {
clear_has_bias_filler();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V0LayerParameter.bias_filler)
}
// optional uint32 pad = 7 [default = 0];
bool V0LayerParameter::has_pad() const {
return (_has_bits_[0] & 0x00000040u) != 0;
}
void V0LayerParameter::set_has_pad() {
_has_bits_[0] |= 0x00000040u;
}
void V0LayerParameter::clear_has_pad() {
_has_bits_[0] &= ~0x00000040u;
}
void V0LayerParameter::clear_pad() {
pad_ = 0u;
clear_has_pad();
}
::google::protobuf::uint32 V0LayerParameter::pad() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.pad)
return pad_;
}
void V0LayerParameter::set_pad(::google::protobuf::uint32 value) {
set_has_pad();
pad_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.pad)
}
// optional uint32 kernelsize = 8;
bool V0LayerParameter::has_kernelsize() const {
return (_has_bits_[0] & 0x00000080u) != 0;
}
void V0LayerParameter::set_has_kernelsize() {
_has_bits_[0] |= 0x00000080u;
}
void V0LayerParameter::clear_has_kernelsize() {
_has_bits_[0] &= ~0x00000080u;
}
void V0LayerParameter::clear_kernelsize() {
kernelsize_ = 0u;
clear_has_kernelsize();
}
::google::protobuf::uint32 V0LayerParameter::kernelsize() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.kernelsize)
return kernelsize_;
}
void V0LayerParameter::set_kernelsize(::google::protobuf::uint32 value) {
set_has_kernelsize();
kernelsize_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.kernelsize)
}
// optional uint32 group = 9 [default = 1];
bool V0LayerParameter::has_group() const {
return (_has_bits_[0] & 0x00000100u) != 0;
}
void V0LayerParameter::set_has_group() {
_has_bits_[0] |= 0x00000100u;
}
void V0LayerParameter::clear_has_group() {
_has_bits_[0] &= ~0x00000100u;
}
void V0LayerParameter::clear_group() {
group_ = 1u;
clear_has_group();
}
::google::protobuf::uint32 V0LayerParameter::group() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.group)
return group_;
}
void V0LayerParameter::set_group(::google::protobuf::uint32 value) {
set_has_group();
group_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.group)
}
// optional uint32 stride = 10 [default = 1];
bool V0LayerParameter::has_stride() const {
return (_has_bits_[0] & 0x00000200u) != 0;
}
void V0LayerParameter::set_has_stride() {
_has_bits_[0] |= 0x00000200u;
}
void V0LayerParameter::clear_has_stride() {
_has_bits_[0] &= ~0x00000200u;
}
void V0LayerParameter::clear_stride() {
stride_ = 1u;
clear_has_stride();
}
::google::protobuf::uint32 V0LayerParameter::stride() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.stride)
return stride_;
}
void V0LayerParameter::set_stride(::google::protobuf::uint32 value) {
set_has_stride();
stride_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.stride)
}
// optional .opencv_caffe.V0LayerParameter.PoolMethod pool = 11 [default = MAX];
bool V0LayerParameter::has_pool() const {
return (_has_bits_[0] & 0x00000400u) != 0;
}
void V0LayerParameter::set_has_pool() {
_has_bits_[0] |= 0x00000400u;
}
void V0LayerParameter::clear_has_pool() {
_has_bits_[0] &= ~0x00000400u;
}
void V0LayerParameter::clear_pool() {
pool_ = 0;
clear_has_pool();
}
::opencv_caffe::V0LayerParameter_PoolMethod V0LayerParameter::pool() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.pool)
return static_cast< ::opencv_caffe::V0LayerParameter_PoolMethod >(pool_);
}
void V0LayerParameter::set_pool(::opencv_caffe::V0LayerParameter_PoolMethod value) {
assert(::opencv_caffe::V0LayerParameter_PoolMethod_IsValid(value));
set_has_pool();
pool_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.pool)
}
// optional float dropout_ratio = 12 [default = 0.5];
bool V0LayerParameter::has_dropout_ratio() const {
return (_has_bits_[0] & 0x00000800u) != 0;
}
void V0LayerParameter::set_has_dropout_ratio() {
_has_bits_[0] |= 0x00000800u;
}
void V0LayerParameter::clear_has_dropout_ratio() {
_has_bits_[0] &= ~0x00000800u;
}
void V0LayerParameter::clear_dropout_ratio() {
dropout_ratio_ = 0.5f;
clear_has_dropout_ratio();
}
float V0LayerParameter::dropout_ratio() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.dropout_ratio)
return dropout_ratio_;
}
void V0LayerParameter::set_dropout_ratio(float value) {
set_has_dropout_ratio();
dropout_ratio_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.dropout_ratio)
}
// optional uint32 local_size = 13 [default = 5];
bool V0LayerParameter::has_local_size() const {
return (_has_bits_[0] & 0x00001000u) != 0;
}
void V0LayerParameter::set_has_local_size() {
_has_bits_[0] |= 0x00001000u;
}
void V0LayerParameter::clear_has_local_size() {
_has_bits_[0] &= ~0x00001000u;
}
void V0LayerParameter::clear_local_size() {
local_size_ = 5u;
clear_has_local_size();
}
::google::protobuf::uint32 V0LayerParameter::local_size() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.local_size)
return local_size_;
}
void V0LayerParameter::set_local_size(::google::protobuf::uint32 value) {
set_has_local_size();
local_size_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.local_size)
}
// optional float alpha = 14 [default = 1];
bool V0LayerParameter::has_alpha() const {
return (_has_bits_[0] & 0x00002000u) != 0;
}
void V0LayerParameter::set_has_alpha() {
_has_bits_[0] |= 0x00002000u;
}
void V0LayerParameter::clear_has_alpha() {
_has_bits_[0] &= ~0x00002000u;
}
void V0LayerParameter::clear_alpha() {
alpha_ = 1;
clear_has_alpha();
}
float V0LayerParameter::alpha() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.alpha)
return alpha_;
}
void V0LayerParameter::set_alpha(float value) {
set_has_alpha();
alpha_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.alpha)
}
// optional float beta = 15 [default = 0.75];
bool V0LayerParameter::has_beta() const {
return (_has_bits_[0] & 0x00004000u) != 0;
}
void V0LayerParameter::set_has_beta() {
_has_bits_[0] |= 0x00004000u;
}
void V0LayerParameter::clear_has_beta() {
_has_bits_[0] &= ~0x00004000u;
}
void V0LayerParameter::clear_beta() {
beta_ = 0.75f;
clear_has_beta();
}
float V0LayerParameter::beta() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.beta)
return beta_;
}
void V0LayerParameter::set_beta(float value) {
set_has_beta();
beta_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.beta)
}
// optional float k = 22 [default = 1];
bool V0LayerParameter::has_k() const {
return (_has_bits_[0] & 0x00008000u) != 0;
}
void V0LayerParameter::set_has_k() {
_has_bits_[0] |= 0x00008000u;
}
void V0LayerParameter::clear_has_k() {
_has_bits_[0] &= ~0x00008000u;
}
void V0LayerParameter::clear_k() {
k_ = 1;
clear_has_k();
}
float V0LayerParameter::k() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.k)
return k_;
}
void V0LayerParameter::set_k(float value) {
set_has_k();
k_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.k)
}
// optional string source = 16;
bool V0LayerParameter::has_source() const {
return (_has_bits_[0] & 0x00010000u) != 0;
}
void V0LayerParameter::set_has_source() {
_has_bits_[0] |= 0x00010000u;
}
void V0LayerParameter::clear_has_source() {
_has_bits_[0] &= ~0x00010000u;
}
void V0LayerParameter::clear_source() {
source_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_source();
}
const ::std::string& V0LayerParameter::source() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.source)
return source_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void V0LayerParameter::set_source(const ::std::string& value) {
set_has_source();
source_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.source)
}
void V0LayerParameter::set_source(const char* value) {
set_has_source();
source_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.V0LayerParameter.source)
}
void V0LayerParameter::set_source(const char* value, size_t size) {
set_has_source();
source_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.V0LayerParameter.source)
}
::std::string* V0LayerParameter::mutable_source() {
set_has_source();
// @@protoc_insertion_point(field_mutable:opencv_caffe.V0LayerParameter.source)
return source_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* V0LayerParameter::release_source() {
// @@protoc_insertion_point(field_release:opencv_caffe.V0LayerParameter.source)
clear_has_source();
return source_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void V0LayerParameter::set_allocated_source(::std::string* source) {
if (source != NULL) {
set_has_source();
} else {
clear_has_source();
}
source_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), source);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V0LayerParameter.source)
}
// optional float scale = 17 [default = 1];
bool V0LayerParameter::has_scale() const {
return (_has_bits_[0] & 0x00020000u) != 0;
}
void V0LayerParameter::set_has_scale() {
_has_bits_[0] |= 0x00020000u;
}
void V0LayerParameter::clear_has_scale() {
_has_bits_[0] &= ~0x00020000u;
}
void V0LayerParameter::clear_scale() {
scale_ = 1;
clear_has_scale();
}
float V0LayerParameter::scale() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.scale)
return scale_;
}
void V0LayerParameter::set_scale(float value) {
set_has_scale();
scale_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.scale)
}
// optional string meanfile = 18;
bool V0LayerParameter::has_meanfile() const {
return (_has_bits_[0] & 0x00040000u) != 0;
}
void V0LayerParameter::set_has_meanfile() {
_has_bits_[0] |= 0x00040000u;
}
void V0LayerParameter::clear_has_meanfile() {
_has_bits_[0] &= ~0x00040000u;
}
void V0LayerParameter::clear_meanfile() {
meanfile_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
clear_has_meanfile();
}
const ::std::string& V0LayerParameter::meanfile() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.meanfile)
return meanfile_.GetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void V0LayerParameter::set_meanfile(const ::std::string& value) {
set_has_meanfile();
meanfile_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.meanfile)
}
void V0LayerParameter::set_meanfile(const char* value) {
set_has_meanfile();
meanfile_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.V0LayerParameter.meanfile)
}
void V0LayerParameter::set_meanfile(const char* value, size_t size) {
set_has_meanfile();
meanfile_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.V0LayerParameter.meanfile)
}
::std::string* V0LayerParameter::mutable_meanfile() {
set_has_meanfile();
// @@protoc_insertion_point(field_mutable:opencv_caffe.V0LayerParameter.meanfile)
return meanfile_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
::std::string* V0LayerParameter::release_meanfile() {
// @@protoc_insertion_point(field_release:opencv_caffe.V0LayerParameter.meanfile)
clear_has_meanfile();
return meanfile_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void V0LayerParameter::set_allocated_meanfile(::std::string* meanfile) {
if (meanfile != NULL) {
set_has_meanfile();
} else {
clear_has_meanfile();
}
meanfile_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), meanfile);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V0LayerParameter.meanfile)
}
// optional uint32 batchsize = 19;
bool V0LayerParameter::has_batchsize() const {
return (_has_bits_[0] & 0x00080000u) != 0;
}
void V0LayerParameter::set_has_batchsize() {
_has_bits_[0] |= 0x00080000u;
}
void V0LayerParameter::clear_has_batchsize() {
_has_bits_[0] &= ~0x00080000u;
}
void V0LayerParameter::clear_batchsize() {
batchsize_ = 0u;
clear_has_batchsize();
}
::google::protobuf::uint32 V0LayerParameter::batchsize() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.batchsize)
return batchsize_;
}
void V0LayerParameter::set_batchsize(::google::protobuf::uint32 value) {
set_has_batchsize();
batchsize_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.batchsize)
}
// optional uint32 cropsize = 20 [default = 0];
bool V0LayerParameter::has_cropsize() const {
return (_has_bits_[0] & 0x00100000u) != 0;
}
void V0LayerParameter::set_has_cropsize() {
_has_bits_[0] |= 0x00100000u;
}
void V0LayerParameter::clear_has_cropsize() {
_has_bits_[0] &= ~0x00100000u;
}
void V0LayerParameter::clear_cropsize() {
cropsize_ = 0u;
clear_has_cropsize();
}
::google::protobuf::uint32 V0LayerParameter::cropsize() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.cropsize)
return cropsize_;
}
void V0LayerParameter::set_cropsize(::google::protobuf::uint32 value) {
set_has_cropsize();
cropsize_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.cropsize)
}
// optional bool mirror = 21 [default = false];
bool V0LayerParameter::has_mirror() const {
return (_has_bits_[0] & 0x00200000u) != 0;
}
void V0LayerParameter::set_has_mirror() {
_has_bits_[0] |= 0x00200000u;
}
void V0LayerParameter::clear_has_mirror() {
_has_bits_[0] &= ~0x00200000u;
}
void V0LayerParameter::clear_mirror() {
mirror_ = false;
clear_has_mirror();
}
bool V0LayerParameter::mirror() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.mirror)
return mirror_;
}
void V0LayerParameter::set_mirror(bool value) {
set_has_mirror();
mirror_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.mirror)
}
// repeated .opencv_caffe.BlobProto blobs = 50;
int V0LayerParameter::blobs_size() const {
return blobs_.size();
}
void V0LayerParameter::clear_blobs() {
blobs_.Clear();
}
const ::opencv_caffe::BlobProto& V0LayerParameter::blobs(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.blobs)
return blobs_.Get(index);
}
::opencv_caffe::BlobProto* V0LayerParameter::mutable_blobs(int index) {
// @@protoc_insertion_point(field_mutable:opencv_caffe.V0LayerParameter.blobs)
return blobs_.Mutable(index);
}
::opencv_caffe::BlobProto* V0LayerParameter::add_blobs() {
// @@protoc_insertion_point(field_add:opencv_caffe.V0LayerParameter.blobs)
return blobs_.Add();
}
::google::protobuf::RepeatedPtrField< ::opencv_caffe::BlobProto >*
V0LayerParameter::mutable_blobs() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.V0LayerParameter.blobs)
return &blobs_;
}
const ::google::protobuf::RepeatedPtrField< ::opencv_caffe::BlobProto >&
V0LayerParameter::blobs() const {
// @@protoc_insertion_point(field_list:opencv_caffe.V0LayerParameter.blobs)
return blobs_;
}
// repeated float blobs_lr = 51;
int V0LayerParameter::blobs_lr_size() const {
return blobs_lr_.size();
}
void V0LayerParameter::clear_blobs_lr() {
blobs_lr_.Clear();
}
float V0LayerParameter::blobs_lr(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.blobs_lr)
return blobs_lr_.Get(index);
}
void V0LayerParameter::set_blobs_lr(int index, float value) {
blobs_lr_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.blobs_lr)
}
void V0LayerParameter::add_blobs_lr(float value) {
blobs_lr_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.V0LayerParameter.blobs_lr)
}
const ::google::protobuf::RepeatedField< float >&
V0LayerParameter::blobs_lr() const {
// @@protoc_insertion_point(field_list:opencv_caffe.V0LayerParameter.blobs_lr)
return blobs_lr_;
}
::google::protobuf::RepeatedField< float >*
V0LayerParameter::mutable_blobs_lr() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.V0LayerParameter.blobs_lr)
return &blobs_lr_;
}
// repeated float weight_decay = 52;
int V0LayerParameter::weight_decay_size() const {
return weight_decay_.size();
}
void V0LayerParameter::clear_weight_decay() {
weight_decay_.Clear();
}
float V0LayerParameter::weight_decay(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.weight_decay)
return weight_decay_.Get(index);
}
void V0LayerParameter::set_weight_decay(int index, float value) {
weight_decay_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.weight_decay)
}
void V0LayerParameter::add_weight_decay(float value) {
weight_decay_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.V0LayerParameter.weight_decay)
}
const ::google::protobuf::RepeatedField< float >&
V0LayerParameter::weight_decay() const {
// @@protoc_insertion_point(field_list:opencv_caffe.V0LayerParameter.weight_decay)
return weight_decay_;
}
::google::protobuf::RepeatedField< float >*
V0LayerParameter::mutable_weight_decay() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.V0LayerParameter.weight_decay)
return &weight_decay_;
}
// optional uint32 rand_skip = 53 [default = 0];
bool V0LayerParameter::has_rand_skip() const {
return (_has_bits_[0] & 0x02000000u) != 0;
}
void V0LayerParameter::set_has_rand_skip() {
_has_bits_[0] |= 0x02000000u;
}
void V0LayerParameter::clear_has_rand_skip() {
_has_bits_[0] &= ~0x02000000u;
}
void V0LayerParameter::clear_rand_skip() {
rand_skip_ = 0u;
clear_has_rand_skip();
}
::google::protobuf::uint32 V0LayerParameter::rand_skip() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.rand_skip)
return rand_skip_;
}
void V0LayerParameter::set_rand_skip(::google::protobuf::uint32 value) {
set_has_rand_skip();
rand_skip_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.rand_skip)
}
// optional float det_fg_threshold = 54 [default = 0.5];
bool V0LayerParameter::has_det_fg_threshold() const {
return (_has_bits_[0] & 0x04000000u) != 0;
}
void V0LayerParameter::set_has_det_fg_threshold() {
_has_bits_[0] |= 0x04000000u;
}
void V0LayerParameter::clear_has_det_fg_threshold() {
_has_bits_[0] &= ~0x04000000u;
}
void V0LayerParameter::clear_det_fg_threshold() {
det_fg_threshold_ = 0.5f;
clear_has_det_fg_threshold();
}
float V0LayerParameter::det_fg_threshold() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.det_fg_threshold)
return det_fg_threshold_;
}
void V0LayerParameter::set_det_fg_threshold(float value) {
set_has_det_fg_threshold();
det_fg_threshold_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.det_fg_threshold)
}
// optional float det_bg_threshold = 55 [default = 0.5];
bool V0LayerParameter::has_det_bg_threshold() const {
return (_has_bits_[0] & 0x08000000u) != 0;
}
void V0LayerParameter::set_has_det_bg_threshold() {
_has_bits_[0] |= 0x08000000u;
}
void V0LayerParameter::clear_has_det_bg_threshold() {
_has_bits_[0] &= ~0x08000000u;
}
void V0LayerParameter::clear_det_bg_threshold() {
det_bg_threshold_ = 0.5f;
clear_has_det_bg_threshold();
}
float V0LayerParameter::det_bg_threshold() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.det_bg_threshold)
return det_bg_threshold_;
}
void V0LayerParameter::set_det_bg_threshold(float value) {
set_has_det_bg_threshold();
det_bg_threshold_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.det_bg_threshold)
}
// optional float det_fg_fraction = 56 [default = 0.25];
bool V0LayerParameter::has_det_fg_fraction() const {
return (_has_bits_[0] & 0x10000000u) != 0;
}
void V0LayerParameter::set_has_det_fg_fraction() {
_has_bits_[0] |= 0x10000000u;
}
void V0LayerParameter::clear_has_det_fg_fraction() {
_has_bits_[0] &= ~0x10000000u;
}
void V0LayerParameter::clear_det_fg_fraction() {
det_fg_fraction_ = 0.25f;
clear_has_det_fg_fraction();
}
float V0LayerParameter::det_fg_fraction() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.det_fg_fraction)
return det_fg_fraction_;
}
void V0LayerParameter::set_det_fg_fraction(float value) {
set_has_det_fg_fraction();
det_fg_fraction_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.det_fg_fraction)
}
// optional uint32 det_context_pad = 58 [default = 0];
bool V0LayerParameter::has_det_context_pad() const {
return (_has_bits_[0] & 0x20000000u) != 0;
}
void V0LayerParameter::set_has_det_context_pad() {
_has_bits_[0] |= 0x20000000u;
}
void V0LayerParameter::clear_has_det_context_pad() {
_has_bits_[0] &= ~0x20000000u;
}
void V0LayerParameter::clear_det_context_pad() {
det_context_pad_ = 0u;
clear_has_det_context_pad();
}
::google::protobuf::uint32 V0LayerParameter::det_context_pad() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.det_context_pad)
return det_context_pad_;
}
void V0LayerParameter::set_det_context_pad(::google::protobuf::uint32 value) {
set_has_det_context_pad();
det_context_pad_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.det_context_pad)
}
// optional string det_crop_mode = 59 [default = "warp"];
bool V0LayerParameter::has_det_crop_mode() const {
return (_has_bits_[0] & 0x40000000u) != 0;
}
void V0LayerParameter::set_has_det_crop_mode() {
_has_bits_[0] |= 0x40000000u;
}
void V0LayerParameter::clear_has_det_crop_mode() {
_has_bits_[0] &= ~0x40000000u;
}
void V0LayerParameter::clear_det_crop_mode() {
det_crop_mode_.ClearToDefaultNoArena(_default_det_crop_mode_);
clear_has_det_crop_mode();
}
const ::std::string& V0LayerParameter::det_crop_mode() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.det_crop_mode)
return det_crop_mode_.GetNoArena(_default_det_crop_mode_);
}
void V0LayerParameter::set_det_crop_mode(const ::std::string& value) {
set_has_det_crop_mode();
det_crop_mode_.SetNoArena(_default_det_crop_mode_, value);
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.det_crop_mode)
}
void V0LayerParameter::set_det_crop_mode(const char* value) {
set_has_det_crop_mode();
det_crop_mode_.SetNoArena(_default_det_crop_mode_, ::std::string(value));
// @@protoc_insertion_point(field_set_char:opencv_caffe.V0LayerParameter.det_crop_mode)
}
void V0LayerParameter::set_det_crop_mode(const char* value, size_t size) {
set_has_det_crop_mode();
det_crop_mode_.SetNoArena(_default_det_crop_mode_,
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:opencv_caffe.V0LayerParameter.det_crop_mode)
}
::std::string* V0LayerParameter::mutable_det_crop_mode() {
set_has_det_crop_mode();
// @@protoc_insertion_point(field_mutable:opencv_caffe.V0LayerParameter.det_crop_mode)
return det_crop_mode_.MutableNoArena(_default_det_crop_mode_);
}
::std::string* V0LayerParameter::release_det_crop_mode() {
// @@protoc_insertion_point(field_release:opencv_caffe.V0LayerParameter.det_crop_mode)
clear_has_det_crop_mode();
return det_crop_mode_.ReleaseNoArena(_default_det_crop_mode_);
}
void V0LayerParameter::set_allocated_det_crop_mode(::std::string* det_crop_mode) {
if (det_crop_mode != NULL) {
set_has_det_crop_mode();
} else {
clear_has_det_crop_mode();
}
det_crop_mode_.SetAllocatedNoArena(_default_det_crop_mode_, det_crop_mode);
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V0LayerParameter.det_crop_mode)
}
// optional int32 new_num = 60 [default = 0];
bool V0LayerParameter::has_new_num() const {
return (_has_bits_[0] & 0x80000000u) != 0;
}
void V0LayerParameter::set_has_new_num() {
_has_bits_[0] |= 0x80000000u;
}
void V0LayerParameter::clear_has_new_num() {
_has_bits_[0] &= ~0x80000000u;
}
void V0LayerParameter::clear_new_num() {
new_num_ = 0;
clear_has_new_num();
}
::google::protobuf::int32 V0LayerParameter::new_num() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.new_num)
return new_num_;
}
void V0LayerParameter::set_new_num(::google::protobuf::int32 value) {
set_has_new_num();
new_num_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.new_num)
}
// optional int32 new_channels = 61 [default = 0];
bool V0LayerParameter::has_new_channels() const {
return (_has_bits_[1] & 0x00000001u) != 0;
}
void V0LayerParameter::set_has_new_channels() {
_has_bits_[1] |= 0x00000001u;
}
void V0LayerParameter::clear_has_new_channels() {
_has_bits_[1] &= ~0x00000001u;
}
void V0LayerParameter::clear_new_channels() {
new_channels_ = 0;
clear_has_new_channels();
}
::google::protobuf::int32 V0LayerParameter::new_channels() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.new_channels)
return new_channels_;
}
void V0LayerParameter::set_new_channels(::google::protobuf::int32 value) {
set_has_new_channels();
new_channels_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.new_channels)
}
// optional int32 new_height = 62 [default = 0];
bool V0LayerParameter::has_new_height() const {
return (_has_bits_[1] & 0x00000002u) != 0;
}
void V0LayerParameter::set_has_new_height() {
_has_bits_[1] |= 0x00000002u;
}
void V0LayerParameter::clear_has_new_height() {
_has_bits_[1] &= ~0x00000002u;
}
void V0LayerParameter::clear_new_height() {
new_height_ = 0;
clear_has_new_height();
}
::google::protobuf::int32 V0LayerParameter::new_height() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.new_height)
return new_height_;
}
void V0LayerParameter::set_new_height(::google::protobuf::int32 value) {
set_has_new_height();
new_height_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.new_height)
}
// optional int32 new_width = 63 [default = 0];
bool V0LayerParameter::has_new_width() const {
return (_has_bits_[1] & 0x00000004u) != 0;
}
void V0LayerParameter::set_has_new_width() {
_has_bits_[1] |= 0x00000004u;
}
void V0LayerParameter::clear_has_new_width() {
_has_bits_[1] &= ~0x00000004u;
}
void V0LayerParameter::clear_new_width() {
new_width_ = 0;
clear_has_new_width();
}
::google::protobuf::int32 V0LayerParameter::new_width() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.new_width)
return new_width_;
}
void V0LayerParameter::set_new_width(::google::protobuf::int32 value) {
set_has_new_width();
new_width_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.new_width)
}
// optional bool shuffle_images = 64 [default = false];
bool V0LayerParameter::has_shuffle_images() const {
return (_has_bits_[1] & 0x00000008u) != 0;
}
void V0LayerParameter::set_has_shuffle_images() {
_has_bits_[1] |= 0x00000008u;
}
void V0LayerParameter::clear_has_shuffle_images() {
_has_bits_[1] &= ~0x00000008u;
}
void V0LayerParameter::clear_shuffle_images() {
shuffle_images_ = false;
clear_has_shuffle_images();
}
bool V0LayerParameter::shuffle_images() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.shuffle_images)
return shuffle_images_;
}
void V0LayerParameter::set_shuffle_images(bool value) {
set_has_shuffle_images();
shuffle_images_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.shuffle_images)
}
// optional uint32 concat_dim = 65 [default = 1];
bool V0LayerParameter::has_concat_dim() const {
return (_has_bits_[1] & 0x00000010u) != 0;
}
void V0LayerParameter::set_has_concat_dim() {
_has_bits_[1] |= 0x00000010u;
}
void V0LayerParameter::clear_has_concat_dim() {
_has_bits_[1] &= ~0x00000010u;
}
void V0LayerParameter::clear_concat_dim() {
concat_dim_ = 1u;
clear_has_concat_dim();
}
::google::protobuf::uint32 V0LayerParameter::concat_dim() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.concat_dim)
return concat_dim_;
}
void V0LayerParameter::set_concat_dim(::google::protobuf::uint32 value) {
set_has_concat_dim();
concat_dim_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.V0LayerParameter.concat_dim)
}
// optional .opencv_caffe.HDF5OutputParameter hdf5_output_param = 1001;
bool V0LayerParameter::has_hdf5_output_param() const {
return (_has_bits_[1] & 0x00000020u) != 0;
}
void V0LayerParameter::set_has_hdf5_output_param() {
_has_bits_[1] |= 0x00000020u;
}
void V0LayerParameter::clear_has_hdf5_output_param() {
_has_bits_[1] &= ~0x00000020u;
}
void V0LayerParameter::clear_hdf5_output_param() {
if (hdf5_output_param_ != NULL) hdf5_output_param_->::opencv_caffe::HDF5OutputParameter::Clear();
clear_has_hdf5_output_param();
}
const ::opencv_caffe::HDF5OutputParameter& V0LayerParameter::hdf5_output_param() const {
// @@protoc_insertion_point(field_get:opencv_caffe.V0LayerParameter.hdf5_output_param)
return hdf5_output_param_ != NULL ? *hdf5_output_param_
: *::opencv_caffe::HDF5OutputParameter::internal_default_instance();
}
::opencv_caffe::HDF5OutputParameter* V0LayerParameter::mutable_hdf5_output_param() {
set_has_hdf5_output_param();
if (hdf5_output_param_ == NULL) {
hdf5_output_param_ = new ::opencv_caffe::HDF5OutputParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.V0LayerParameter.hdf5_output_param)
return hdf5_output_param_;
}
::opencv_caffe::HDF5OutputParameter* V0LayerParameter::release_hdf5_output_param() {
// @@protoc_insertion_point(field_release:opencv_caffe.V0LayerParameter.hdf5_output_param)
clear_has_hdf5_output_param();
::opencv_caffe::HDF5OutputParameter* temp = hdf5_output_param_;
hdf5_output_param_ = NULL;
return temp;
}
void V0LayerParameter::set_allocated_hdf5_output_param(::opencv_caffe::HDF5OutputParameter* hdf5_output_param) {
delete hdf5_output_param_;
hdf5_output_param_ = hdf5_output_param;
if (hdf5_output_param) {
set_has_hdf5_output_param();
} else {
clear_has_hdf5_output_param();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.V0LayerParameter.hdf5_output_param)
}
inline const V0LayerParameter* V0LayerParameter::internal_default_instance() {
return &V0LayerParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int PReLUParameter::kFillerFieldNumber;
const int PReLUParameter::kChannelSharedFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
PReLUParameter::PReLUParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.PReLUParameter)
}
void PReLUParameter::InitAsDefaultInstance() {
filler_ = const_cast< ::opencv_caffe::FillerParameter*>(
::opencv_caffe::FillerParameter::internal_default_instance());
}
PReLUParameter::PReLUParameter(const PReLUParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.PReLUParameter)
}
void PReLUParameter::SharedCtor() {
_cached_size_ = 0;
filler_ = NULL;
channel_shared_ = false;
}
PReLUParameter::~PReLUParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.PReLUParameter)
SharedDtor();
}
void PReLUParameter::SharedDtor() {
if (this != &PReLUParameter_default_instance_.get()) {
delete filler_;
}
}
void PReLUParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* PReLUParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return PReLUParameter_descriptor_;
}
const PReLUParameter& PReLUParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<PReLUParameter> PReLUParameter_default_instance_;
PReLUParameter* PReLUParameter::New(::google::protobuf::Arena* arena) const {
PReLUParameter* n = new PReLUParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void PReLUParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.PReLUParameter)
if (_has_bits_[0 / 32] & 3u) {
if (has_filler()) {
if (filler_ != NULL) filler_->::opencv_caffe::FillerParameter::Clear();
}
channel_shared_ = false;
}
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool PReLUParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.PReLUParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional .opencv_caffe.FillerParameter filler = 1;
case 1: {
if (tag == 10) {
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_filler()));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_channel_shared;
break;
}
// optional bool channel_shared = 2 [default = false];
case 2: {
if (tag == 16) {
parse_channel_shared:
set_has_channel_shared();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &channel_shared_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.PReLUParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.PReLUParameter)
return false;
#undef DO_
}
void PReLUParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.PReLUParameter)
// optional .opencv_caffe.FillerParameter filler = 1;
if (has_filler()) {
::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(
1, *this->filler_, output);
}
// optional bool channel_shared = 2 [default = false];
if (has_channel_shared()) {
::google::protobuf::internal::WireFormatLite::WriteBool(2, this->channel_shared(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.PReLUParameter)
}
::google::protobuf::uint8* PReLUParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.PReLUParameter)
// optional .opencv_caffe.FillerParameter filler = 1;
if (has_filler()) {
target = ::google::protobuf::internal::WireFormatLite::
InternalWriteMessageNoVirtualToArray(
1, *this->filler_, false, target);
}
// optional bool channel_shared = 2 [default = false];
if (has_channel_shared()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(2, this->channel_shared(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.PReLUParameter)
return target;
}
size_t PReLUParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.PReLUParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 3u) {
// optional .opencv_caffe.FillerParameter filler = 1;
if (has_filler()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::MessageSizeNoVirtual(
*this->filler_);
}
// optional bool channel_shared = 2 [default = false];
if (has_channel_shared()) {
total_size += 1 + 1;
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void PReLUParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.PReLUParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const PReLUParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const PReLUParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.PReLUParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.PReLUParameter)
UnsafeMergeFrom(*source);
}
}
void PReLUParameter::MergeFrom(const PReLUParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.PReLUParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void PReLUParameter::UnsafeMergeFrom(const PReLUParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_filler()) {
mutable_filler()->::opencv_caffe::FillerParameter::MergeFrom(from.filler());
}
if (from.has_channel_shared()) {
set_channel_shared(from.channel_shared());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void PReLUParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.PReLUParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void PReLUParameter::CopyFrom(const PReLUParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.PReLUParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool PReLUParameter::IsInitialized() const {
return true;
}
void PReLUParameter::Swap(PReLUParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void PReLUParameter::InternalSwap(PReLUParameter* other) {
std::swap(filler_, other->filler_);
std::swap(channel_shared_, other->channel_shared_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata PReLUParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = PReLUParameter_descriptor_;
metadata.reflection = PReLUParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// PReLUParameter
// optional .opencv_caffe.FillerParameter filler = 1;
bool PReLUParameter::has_filler() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void PReLUParameter::set_has_filler() {
_has_bits_[0] |= 0x00000001u;
}
void PReLUParameter::clear_has_filler() {
_has_bits_[0] &= ~0x00000001u;
}
void PReLUParameter::clear_filler() {
if (filler_ != NULL) filler_->::opencv_caffe::FillerParameter::Clear();
clear_has_filler();
}
const ::opencv_caffe::FillerParameter& PReLUParameter::filler() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PReLUParameter.filler)
return filler_ != NULL ? *filler_
: *::opencv_caffe::FillerParameter::internal_default_instance();
}
::opencv_caffe::FillerParameter* PReLUParameter::mutable_filler() {
set_has_filler();
if (filler_ == NULL) {
filler_ = new ::opencv_caffe::FillerParameter;
}
// @@protoc_insertion_point(field_mutable:opencv_caffe.PReLUParameter.filler)
return filler_;
}
::opencv_caffe::FillerParameter* PReLUParameter::release_filler() {
// @@protoc_insertion_point(field_release:opencv_caffe.PReLUParameter.filler)
clear_has_filler();
::opencv_caffe::FillerParameter* temp = filler_;
filler_ = NULL;
return temp;
}
void PReLUParameter::set_allocated_filler(::opencv_caffe::FillerParameter* filler) {
delete filler_;
filler_ = filler;
if (filler) {
set_has_filler();
} else {
clear_has_filler();
}
// @@protoc_insertion_point(field_set_allocated:opencv_caffe.PReLUParameter.filler)
}
// optional bool channel_shared = 2 [default = false];
bool PReLUParameter::has_channel_shared() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void PReLUParameter::set_has_channel_shared() {
_has_bits_[0] |= 0x00000002u;
}
void PReLUParameter::clear_has_channel_shared() {
_has_bits_[0] &= ~0x00000002u;
}
void PReLUParameter::clear_channel_shared() {
channel_shared_ = false;
clear_has_channel_shared();
}
bool PReLUParameter::channel_shared() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PReLUParameter.channel_shared)
return channel_shared_;
}
void PReLUParameter::set_channel_shared(bool value) {
set_has_channel_shared();
channel_shared_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PReLUParameter.channel_shared)
}
inline const PReLUParameter* PReLUParameter::internal_default_instance() {
return &PReLUParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int NormalizedBBox::kXminFieldNumber;
const int NormalizedBBox::kYminFieldNumber;
const int NormalizedBBox::kXmaxFieldNumber;
const int NormalizedBBox::kYmaxFieldNumber;
const int NormalizedBBox::kLabelFieldNumber;
const int NormalizedBBox::kDifficultFieldNumber;
const int NormalizedBBox::kScoreFieldNumber;
const int NormalizedBBox::kSizeFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
NormalizedBBox::NormalizedBBox()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.NormalizedBBox)
}
void NormalizedBBox::InitAsDefaultInstance() {
}
NormalizedBBox::NormalizedBBox(const NormalizedBBox& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.NormalizedBBox)
}
void NormalizedBBox::SharedCtor() {
_cached_size_ = 0;
::memset(&xmin_, 0, reinterpret_cast<char*>(&size_) -
reinterpret_cast<char*>(&xmin_) + sizeof(size_));
}
NormalizedBBox::~NormalizedBBox() {
// @@protoc_insertion_point(destructor:opencv_caffe.NormalizedBBox)
SharedDtor();
}
void NormalizedBBox::SharedDtor() {
}
void NormalizedBBox::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* NormalizedBBox::descriptor() {
protobuf_AssignDescriptorsOnce();
return NormalizedBBox_descriptor_;
}
const NormalizedBBox& NormalizedBBox::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<NormalizedBBox> NormalizedBBox_default_instance_;
NormalizedBBox* NormalizedBBox::New(::google::protobuf::Arena* arena) const {
NormalizedBBox* n = new NormalizedBBox;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void NormalizedBBox::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.NormalizedBBox)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(NormalizedBBox, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<NormalizedBBox*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
ZR_(xmin_, size_);
#undef ZR_HELPER_
#undef ZR_
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool NormalizedBBox::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.NormalizedBBox)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional float xmin = 1;
case 1: {
if (tag == 13) {
set_has_xmin();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &xmin_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(21)) goto parse_ymin;
break;
}
// optional float ymin = 2;
case 2: {
if (tag == 21) {
parse_ymin:
set_has_ymin();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &ymin_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(29)) goto parse_xmax;
break;
}
// optional float xmax = 3;
case 3: {
if (tag == 29) {
parse_xmax:
set_has_xmax();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &xmax_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(37)) goto parse_ymax;
break;
}
// optional float ymax = 4;
case 4: {
if (tag == 37) {
parse_ymax:
set_has_ymax();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &ymax_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(40)) goto parse_label;
break;
}
// optional int32 label = 5;
case 5: {
if (tag == 40) {
parse_label:
set_has_label();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &label_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(48)) goto parse_difficult;
break;
}
// optional bool difficult = 6;
case 6: {
if (tag == 48) {
parse_difficult:
set_has_difficult();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
input, &difficult_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(61)) goto parse_score;
break;
}
// optional float score = 7;
case 7: {
if (tag == 61) {
parse_score:
set_has_score();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &score_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(69)) goto parse_size;
break;
}
// optional float size = 8;
case 8: {
if (tag == 69) {
parse_size:
set_has_size();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &size_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.NormalizedBBox)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.NormalizedBBox)
return false;
#undef DO_
}
void NormalizedBBox::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.NormalizedBBox)
// optional float xmin = 1;
if (has_xmin()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(1, this->xmin(), output);
}
// optional float ymin = 2;
if (has_ymin()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(2, this->ymin(), output);
}
// optional float xmax = 3;
if (has_xmax()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(3, this->xmax(), output);
}
// optional float ymax = 4;
if (has_ymax()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(4, this->ymax(), output);
}
// optional int32 label = 5;
if (has_label()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(5, this->label(), output);
}
// optional bool difficult = 6;
if (has_difficult()) {
::google::protobuf::internal::WireFormatLite::WriteBool(6, this->difficult(), output);
}
// optional float score = 7;
if (has_score()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(7, this->score(), output);
}
// optional float size = 8;
if (has_size()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(8, this->size(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.NormalizedBBox)
}
::google::protobuf::uint8* NormalizedBBox::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.NormalizedBBox)
// optional float xmin = 1;
if (has_xmin()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(1, this->xmin(), target);
}
// optional float ymin = 2;
if (has_ymin()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(2, this->ymin(), target);
}
// optional float xmax = 3;
if (has_xmax()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(3, this->xmax(), target);
}
// optional float ymax = 4;
if (has_ymax()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(4, this->ymax(), target);
}
// optional int32 label = 5;
if (has_label()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(5, this->label(), target);
}
// optional bool difficult = 6;
if (has_difficult()) {
target = ::google::protobuf::internal::WireFormatLite::WriteBoolToArray(6, this->difficult(), target);
}
// optional float score = 7;
if (has_score()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(7, this->score(), target);
}
// optional float size = 8;
if (has_size()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(8, this->size(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.NormalizedBBox)
return target;
}
size_t NormalizedBBox::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.NormalizedBBox)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 255u) {
// optional float xmin = 1;
if (has_xmin()) {
total_size += 1 + 4;
}
// optional float ymin = 2;
if (has_ymin()) {
total_size += 1 + 4;
}
// optional float xmax = 3;
if (has_xmax()) {
total_size += 1 + 4;
}
// optional float ymax = 4;
if (has_ymax()) {
total_size += 1 + 4;
}
// optional int32 label = 5;
if (has_label()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->label());
}
// optional bool difficult = 6;
if (has_difficult()) {
total_size += 1 + 1;
}
// optional float score = 7;
if (has_score()) {
total_size += 1 + 4;
}
// optional float size = 8;
if (has_size()) {
total_size += 1 + 4;
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void NormalizedBBox::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.NormalizedBBox)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const NormalizedBBox* source =
::google::protobuf::internal::DynamicCastToGenerated<const NormalizedBBox>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.NormalizedBBox)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.NormalizedBBox)
UnsafeMergeFrom(*source);
}
}
void NormalizedBBox::MergeFrom(const NormalizedBBox& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.NormalizedBBox)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void NormalizedBBox::UnsafeMergeFrom(const NormalizedBBox& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_xmin()) {
set_xmin(from.xmin());
}
if (from.has_ymin()) {
set_ymin(from.ymin());
}
if (from.has_xmax()) {
set_xmax(from.xmax());
}
if (from.has_ymax()) {
set_ymax(from.ymax());
}
if (from.has_label()) {
set_label(from.label());
}
if (from.has_difficult()) {
set_difficult(from.difficult());
}
if (from.has_score()) {
set_score(from.score());
}
if (from.has_size()) {
set_size(from.size());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void NormalizedBBox::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.NormalizedBBox)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void NormalizedBBox::CopyFrom(const NormalizedBBox& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.NormalizedBBox)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool NormalizedBBox::IsInitialized() const {
return true;
}
void NormalizedBBox::Swap(NormalizedBBox* other) {
if (other == this) return;
InternalSwap(other);
}
void NormalizedBBox::InternalSwap(NormalizedBBox* other) {
std::swap(xmin_, other->xmin_);
std::swap(ymin_, other->ymin_);
std::swap(xmax_, other->xmax_);
std::swap(ymax_, other->ymax_);
std::swap(label_, other->label_);
std::swap(difficult_, other->difficult_);
std::swap(score_, other->score_);
std::swap(size_, other->size_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata NormalizedBBox::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = NormalizedBBox_descriptor_;
metadata.reflection = NormalizedBBox_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// NormalizedBBox
// optional float xmin = 1;
bool NormalizedBBox::has_xmin() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void NormalizedBBox::set_has_xmin() {
_has_bits_[0] |= 0x00000001u;
}
void NormalizedBBox::clear_has_xmin() {
_has_bits_[0] &= ~0x00000001u;
}
void NormalizedBBox::clear_xmin() {
xmin_ = 0;
clear_has_xmin();
}
float NormalizedBBox::xmin() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NormalizedBBox.xmin)
return xmin_;
}
void NormalizedBBox::set_xmin(float value) {
set_has_xmin();
xmin_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.NormalizedBBox.xmin)
}
// optional float ymin = 2;
bool NormalizedBBox::has_ymin() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void NormalizedBBox::set_has_ymin() {
_has_bits_[0] |= 0x00000002u;
}
void NormalizedBBox::clear_has_ymin() {
_has_bits_[0] &= ~0x00000002u;
}
void NormalizedBBox::clear_ymin() {
ymin_ = 0;
clear_has_ymin();
}
float NormalizedBBox::ymin() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NormalizedBBox.ymin)
return ymin_;
}
void NormalizedBBox::set_ymin(float value) {
set_has_ymin();
ymin_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.NormalizedBBox.ymin)
}
// optional float xmax = 3;
bool NormalizedBBox::has_xmax() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void NormalizedBBox::set_has_xmax() {
_has_bits_[0] |= 0x00000004u;
}
void NormalizedBBox::clear_has_xmax() {
_has_bits_[0] &= ~0x00000004u;
}
void NormalizedBBox::clear_xmax() {
xmax_ = 0;
clear_has_xmax();
}
float NormalizedBBox::xmax() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NormalizedBBox.xmax)
return xmax_;
}
void NormalizedBBox::set_xmax(float value) {
set_has_xmax();
xmax_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.NormalizedBBox.xmax)
}
// optional float ymax = 4;
bool NormalizedBBox::has_ymax() const {
return (_has_bits_[0] & 0x00000008u) != 0;
}
void NormalizedBBox::set_has_ymax() {
_has_bits_[0] |= 0x00000008u;
}
void NormalizedBBox::clear_has_ymax() {
_has_bits_[0] &= ~0x00000008u;
}
void NormalizedBBox::clear_ymax() {
ymax_ = 0;
clear_has_ymax();
}
float NormalizedBBox::ymax() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NormalizedBBox.ymax)
return ymax_;
}
void NormalizedBBox::set_ymax(float value) {
set_has_ymax();
ymax_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.NormalizedBBox.ymax)
}
// optional int32 label = 5;
bool NormalizedBBox::has_label() const {
return (_has_bits_[0] & 0x00000010u) != 0;
}
void NormalizedBBox::set_has_label() {
_has_bits_[0] |= 0x00000010u;
}
void NormalizedBBox::clear_has_label() {
_has_bits_[0] &= ~0x00000010u;
}
void NormalizedBBox::clear_label() {
label_ = 0;
clear_has_label();
}
::google::protobuf::int32 NormalizedBBox::label() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NormalizedBBox.label)
return label_;
}
void NormalizedBBox::set_label(::google::protobuf::int32 value) {
set_has_label();
label_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.NormalizedBBox.label)
}
// optional bool difficult = 6;
bool NormalizedBBox::has_difficult() const {
return (_has_bits_[0] & 0x00000020u) != 0;
}
void NormalizedBBox::set_has_difficult() {
_has_bits_[0] |= 0x00000020u;
}
void NormalizedBBox::clear_has_difficult() {
_has_bits_[0] &= ~0x00000020u;
}
void NormalizedBBox::clear_difficult() {
difficult_ = false;
clear_has_difficult();
}
bool NormalizedBBox::difficult() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NormalizedBBox.difficult)
return difficult_;
}
void NormalizedBBox::set_difficult(bool value) {
set_has_difficult();
difficult_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.NormalizedBBox.difficult)
}
// optional float score = 7;
bool NormalizedBBox::has_score() const {
return (_has_bits_[0] & 0x00000040u) != 0;
}
void NormalizedBBox::set_has_score() {
_has_bits_[0] |= 0x00000040u;
}
void NormalizedBBox::clear_has_score() {
_has_bits_[0] &= ~0x00000040u;
}
void NormalizedBBox::clear_score() {
score_ = 0;
clear_has_score();
}
float NormalizedBBox::score() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NormalizedBBox.score)
return score_;
}
void NormalizedBBox::set_score(float value) {
set_has_score();
score_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.NormalizedBBox.score)
}
// optional float size = 8;
bool NormalizedBBox::has_size() const {
return (_has_bits_[0] & 0x00000080u) != 0;
}
void NormalizedBBox::set_has_size() {
_has_bits_[0] |= 0x00000080u;
}
void NormalizedBBox::clear_has_size() {
_has_bits_[0] &= ~0x00000080u;
}
void NormalizedBBox::clear_size() {
size_ = 0;
clear_has_size();
}
float NormalizedBBox::size() const {
// @@protoc_insertion_point(field_get:opencv_caffe.NormalizedBBox.size)
return size_;
}
void NormalizedBBox::set_size(float value) {
set_has_size();
size_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.NormalizedBBox.size)
}
inline const NormalizedBBox* NormalizedBBox::internal_default_instance() {
return &NormalizedBBox_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int ROIPoolingParameter::kPooledHFieldNumber;
const int ROIPoolingParameter::kPooledWFieldNumber;
const int ROIPoolingParameter::kSpatialScaleFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
ROIPoolingParameter::ROIPoolingParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.ROIPoolingParameter)
}
void ROIPoolingParameter::InitAsDefaultInstance() {
}
ROIPoolingParameter::ROIPoolingParameter(const ROIPoolingParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.ROIPoolingParameter)
}
void ROIPoolingParameter::SharedCtor() {
_cached_size_ = 0;
::memset(&pooled_h_, 0, reinterpret_cast<char*>(&pooled_w_) -
reinterpret_cast<char*>(&pooled_h_) + sizeof(pooled_w_));
spatial_scale_ = 1;
}
ROIPoolingParameter::~ROIPoolingParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.ROIPoolingParameter)
SharedDtor();
}
void ROIPoolingParameter::SharedDtor() {
}
void ROIPoolingParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* ROIPoolingParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return ROIPoolingParameter_descriptor_;
}
const ROIPoolingParameter& ROIPoolingParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<ROIPoolingParameter> ROIPoolingParameter_default_instance_;
ROIPoolingParameter* ROIPoolingParameter::New(::google::protobuf::Arena* arena) const {
ROIPoolingParameter* n = new ROIPoolingParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void ROIPoolingParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.ROIPoolingParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(ROIPoolingParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<ROIPoolingParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
if (_has_bits_[0 / 32] & 7u) {
ZR_(pooled_h_, pooled_w_);
spatial_scale_ = 1;
}
#undef ZR_HELPER_
#undef ZR_
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool ROIPoolingParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.ROIPoolingParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional uint32 pooled_h = 1 [default = 0];
case 1: {
if (tag == 8) {
set_has_pooled_h();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &pooled_h_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_pooled_w;
break;
}
// optional uint32 pooled_w = 2 [default = 0];
case 2: {
if (tag == 16) {
parse_pooled_w:
set_has_pooled_w();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &pooled_w_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(29)) goto parse_spatial_scale;
break;
}
// optional float spatial_scale = 3 [default = 1];
case 3: {
if (tag == 29) {
parse_spatial_scale:
set_has_spatial_scale();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &spatial_scale_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.ROIPoolingParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.ROIPoolingParameter)
return false;
#undef DO_
}
void ROIPoolingParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.ROIPoolingParameter)
// optional uint32 pooled_h = 1 [default = 0];
if (has_pooled_h()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(1, this->pooled_h(), output);
}
// optional uint32 pooled_w = 2 [default = 0];
if (has_pooled_w()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(2, this->pooled_w(), output);
}
// optional float spatial_scale = 3 [default = 1];
if (has_spatial_scale()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(3, this->spatial_scale(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.ROIPoolingParameter)
}
::google::protobuf::uint8* ROIPoolingParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.ROIPoolingParameter)
// optional uint32 pooled_h = 1 [default = 0];
if (has_pooled_h()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(1, this->pooled_h(), target);
}
// optional uint32 pooled_w = 2 [default = 0];
if (has_pooled_w()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(2, this->pooled_w(), target);
}
// optional float spatial_scale = 3 [default = 1];
if (has_spatial_scale()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(3, this->spatial_scale(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.ROIPoolingParameter)
return target;
}
size_t ROIPoolingParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.ROIPoolingParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 7u) {
// optional uint32 pooled_h = 1 [default = 0];
if (has_pooled_h()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->pooled_h());
}
// optional uint32 pooled_w = 2 [default = 0];
if (has_pooled_w()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->pooled_w());
}
// optional float spatial_scale = 3 [default = 1];
if (has_spatial_scale()) {
total_size += 1 + 4;
}
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void ROIPoolingParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.ROIPoolingParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const ROIPoolingParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const ROIPoolingParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.ROIPoolingParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.ROIPoolingParameter)
UnsafeMergeFrom(*source);
}
}
void ROIPoolingParameter::MergeFrom(const ROIPoolingParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.ROIPoolingParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void ROIPoolingParameter::UnsafeMergeFrom(const ROIPoolingParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_pooled_h()) {
set_pooled_h(from.pooled_h());
}
if (from.has_pooled_w()) {
set_pooled_w(from.pooled_w());
}
if (from.has_spatial_scale()) {
set_spatial_scale(from.spatial_scale());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void ROIPoolingParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.ROIPoolingParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void ROIPoolingParameter::CopyFrom(const ROIPoolingParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.ROIPoolingParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool ROIPoolingParameter::IsInitialized() const {
return true;
}
void ROIPoolingParameter::Swap(ROIPoolingParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void ROIPoolingParameter::InternalSwap(ROIPoolingParameter* other) {
std::swap(pooled_h_, other->pooled_h_);
std::swap(pooled_w_, other->pooled_w_);
std::swap(spatial_scale_, other->spatial_scale_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata ROIPoolingParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = ROIPoolingParameter_descriptor_;
metadata.reflection = ROIPoolingParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// ROIPoolingParameter
// optional uint32 pooled_h = 1 [default = 0];
bool ROIPoolingParameter::has_pooled_h() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void ROIPoolingParameter::set_has_pooled_h() {
_has_bits_[0] |= 0x00000001u;
}
void ROIPoolingParameter::clear_has_pooled_h() {
_has_bits_[0] &= ~0x00000001u;
}
void ROIPoolingParameter::clear_pooled_h() {
pooled_h_ = 0u;
clear_has_pooled_h();
}
::google::protobuf::uint32 ROIPoolingParameter::pooled_h() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ROIPoolingParameter.pooled_h)
return pooled_h_;
}
void ROIPoolingParameter::set_pooled_h(::google::protobuf::uint32 value) {
set_has_pooled_h();
pooled_h_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ROIPoolingParameter.pooled_h)
}
// optional uint32 pooled_w = 2 [default = 0];
bool ROIPoolingParameter::has_pooled_w() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void ROIPoolingParameter::set_has_pooled_w() {
_has_bits_[0] |= 0x00000002u;
}
void ROIPoolingParameter::clear_has_pooled_w() {
_has_bits_[0] &= ~0x00000002u;
}
void ROIPoolingParameter::clear_pooled_w() {
pooled_w_ = 0u;
clear_has_pooled_w();
}
::google::protobuf::uint32 ROIPoolingParameter::pooled_w() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ROIPoolingParameter.pooled_w)
return pooled_w_;
}
void ROIPoolingParameter::set_pooled_w(::google::protobuf::uint32 value) {
set_has_pooled_w();
pooled_w_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ROIPoolingParameter.pooled_w)
}
// optional float spatial_scale = 3 [default = 1];
bool ROIPoolingParameter::has_spatial_scale() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void ROIPoolingParameter::set_has_spatial_scale() {
_has_bits_[0] |= 0x00000004u;
}
void ROIPoolingParameter::clear_has_spatial_scale() {
_has_bits_[0] &= ~0x00000004u;
}
void ROIPoolingParameter::clear_spatial_scale() {
spatial_scale_ = 1;
clear_has_spatial_scale();
}
float ROIPoolingParameter::spatial_scale() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ROIPoolingParameter.spatial_scale)
return spatial_scale_;
}
void ROIPoolingParameter::set_spatial_scale(float value) {
set_has_spatial_scale();
spatial_scale_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ROIPoolingParameter.spatial_scale)
}
inline const ROIPoolingParameter* ROIPoolingParameter::internal_default_instance() {
return &ROIPoolingParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int ProposalParameter::kFeatStrideFieldNumber;
const int ProposalParameter::kBaseSizeFieldNumber;
const int ProposalParameter::kMinSizeFieldNumber;
const int ProposalParameter::kRatioFieldNumber;
const int ProposalParameter::kScaleFieldNumber;
const int ProposalParameter::kPreNmsTopnFieldNumber;
const int ProposalParameter::kPostNmsTopnFieldNumber;
const int ProposalParameter::kNmsThreshFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
ProposalParameter::ProposalParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.ProposalParameter)
}
void ProposalParameter::InitAsDefaultInstance() {
}
ProposalParameter::ProposalParameter(const ProposalParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.ProposalParameter)
}
void ProposalParameter::SharedCtor() {
_cached_size_ = 0;
feat_stride_ = 16u;
base_size_ = 16u;
min_size_ = 16u;
pre_nms_topn_ = 6000u;
post_nms_topn_ = 300u;
nms_thresh_ = 0.7f;
}
ProposalParameter::~ProposalParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.ProposalParameter)
SharedDtor();
}
void ProposalParameter::SharedDtor() {
}
void ProposalParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* ProposalParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return ProposalParameter_descriptor_;
}
const ProposalParameter& ProposalParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<ProposalParameter> ProposalParameter_default_instance_;
ProposalParameter* ProposalParameter::New(::google::protobuf::Arena* arena) const {
ProposalParameter* n = new ProposalParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void ProposalParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.ProposalParameter)
if (_has_bits_[0 / 32] & 231u) {
feat_stride_ = 16u;
base_size_ = 16u;
min_size_ = 16u;
pre_nms_topn_ = 6000u;
post_nms_topn_ = 300u;
nms_thresh_ = 0.7f;
}
ratio_.Clear();
scale_.Clear();
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool ProposalParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.ProposalParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// optional uint32 feat_stride = 1 [default = 16];
case 1: {
if (tag == 8) {
set_has_feat_stride();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &feat_stride_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_base_size;
break;
}
// optional uint32 base_size = 2 [default = 16];
case 2: {
if (tag == 16) {
parse_base_size:
set_has_base_size();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &base_size_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(24)) goto parse_min_size;
break;
}
// optional uint32 min_size = 3 [default = 16];
case 3: {
if (tag == 24) {
parse_min_size:
set_has_min_size();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &min_size_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(37)) goto parse_ratio;
break;
}
// repeated float ratio = 4;
case 4: {
if (tag == 37) {
parse_ratio:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
1, 37, input, this->mutable_ratio())));
} else if (tag == 34) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, this->mutable_ratio())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(37)) goto parse_ratio;
if (input->ExpectTag(45)) goto parse_scale;
break;
}
// repeated float scale = 5;
case 5: {
if (tag == 45) {
parse_scale:
DO_((::google::protobuf::internal::WireFormatLite::ReadRepeatedPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
1, 45, input, this->mutable_scale())));
} else if (tag == 42) {
DO_((::google::protobuf::internal::WireFormatLite::ReadPackedPrimitiveNoInline<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, this->mutable_scale())));
} else {
goto handle_unusual;
}
if (input->ExpectTag(45)) goto parse_scale;
if (input->ExpectTag(48)) goto parse_pre_nms_topn;
break;
}
// optional uint32 pre_nms_topn = 6 [default = 6000];
case 6: {
if (tag == 48) {
parse_pre_nms_topn:
set_has_pre_nms_topn();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &pre_nms_topn_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(56)) goto parse_post_nms_topn;
break;
}
// optional uint32 post_nms_topn = 7 [default = 300];
case 7: {
if (tag == 56) {
parse_post_nms_topn:
set_has_post_nms_topn();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::uint32, ::google::protobuf::internal::WireFormatLite::TYPE_UINT32>(
input, &post_nms_topn_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(69)) goto parse_nms_thresh;
break;
}
// optional float nms_thresh = 8 [default = 0.7];
case 8: {
if (tag == 69) {
parse_nms_thresh:
set_has_nms_thresh();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &nms_thresh_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.ProposalParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.ProposalParameter)
return false;
#undef DO_
}
void ProposalParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.ProposalParameter)
// optional uint32 feat_stride = 1 [default = 16];
if (has_feat_stride()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(1, this->feat_stride(), output);
}
// optional uint32 base_size = 2 [default = 16];
if (has_base_size()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(2, this->base_size(), output);
}
// optional uint32 min_size = 3 [default = 16];
if (has_min_size()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(3, this->min_size(), output);
}
// repeated float ratio = 4;
for (int i = 0; i < this->ratio_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteFloat(
4, this->ratio(i), output);
}
// repeated float scale = 5;
for (int i = 0; i < this->scale_size(); i++) {
::google::protobuf::internal::WireFormatLite::WriteFloat(
5, this->scale(i), output);
}
// optional uint32 pre_nms_topn = 6 [default = 6000];
if (has_pre_nms_topn()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(6, this->pre_nms_topn(), output);
}
// optional uint32 post_nms_topn = 7 [default = 300];
if (has_post_nms_topn()) {
::google::protobuf::internal::WireFormatLite::WriteUInt32(7, this->post_nms_topn(), output);
}
// optional float nms_thresh = 8 [default = 0.7];
if (has_nms_thresh()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(8, this->nms_thresh(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.ProposalParameter)
}
::google::protobuf::uint8* ProposalParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.ProposalParameter)
// optional uint32 feat_stride = 1 [default = 16];
if (has_feat_stride()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(1, this->feat_stride(), target);
}
// optional uint32 base_size = 2 [default = 16];
if (has_base_size()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(2, this->base_size(), target);
}
// optional uint32 min_size = 3 [default = 16];
if (has_min_size()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(3, this->min_size(), target);
}
// repeated float ratio = 4;
for (int i = 0; i < this->ratio_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteFloatToArray(4, this->ratio(i), target);
}
// repeated float scale = 5;
for (int i = 0; i < this->scale_size(); i++) {
target = ::google::protobuf::internal::WireFormatLite::
WriteFloatToArray(5, this->scale(i), target);
}
// optional uint32 pre_nms_topn = 6 [default = 6000];
if (has_pre_nms_topn()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(6, this->pre_nms_topn(), target);
}
// optional uint32 post_nms_topn = 7 [default = 300];
if (has_post_nms_topn()) {
target = ::google::protobuf::internal::WireFormatLite::WriteUInt32ToArray(7, this->post_nms_topn(), target);
}
// optional float nms_thresh = 8 [default = 0.7];
if (has_nms_thresh()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(8, this->nms_thresh(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.ProposalParameter)
return target;
}
size_t ProposalParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.ProposalParameter)
size_t total_size = 0;
if (_has_bits_[0 / 32] & 231u) {
// optional uint32 feat_stride = 1 [default = 16];
if (has_feat_stride()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->feat_stride());
}
// optional uint32 base_size = 2 [default = 16];
if (has_base_size()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->base_size());
}
// optional uint32 min_size = 3 [default = 16];
if (has_min_size()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->min_size());
}
// optional uint32 pre_nms_topn = 6 [default = 6000];
if (has_pre_nms_topn()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->pre_nms_topn());
}
// optional uint32 post_nms_topn = 7 [default = 300];
if (has_post_nms_topn()) {
total_size += 1 +
::google::protobuf::internal::WireFormatLite::UInt32Size(
this->post_nms_topn());
}
// optional float nms_thresh = 8 [default = 0.7];
if (has_nms_thresh()) {
total_size += 1 + 4;
}
}
// repeated float ratio = 4;
{
size_t data_size = 0;
unsigned int count = this->ratio_size();
data_size = 4UL * count;
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->ratio_size());
total_size += data_size;
}
// repeated float scale = 5;
{
size_t data_size = 0;
unsigned int count = this->scale_size();
data_size = 4UL * count;
total_size += 1 *
::google::protobuf::internal::FromIntSize(this->scale_size());
total_size += data_size;
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void ProposalParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.ProposalParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const ProposalParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const ProposalParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.ProposalParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.ProposalParameter)
UnsafeMergeFrom(*source);
}
}
void ProposalParameter::MergeFrom(const ProposalParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.ProposalParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void ProposalParameter::UnsafeMergeFrom(const ProposalParameter& from) {
GOOGLE_DCHECK(&from != this);
ratio_.UnsafeMergeFrom(from.ratio_);
scale_.UnsafeMergeFrom(from.scale_);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_feat_stride()) {
set_feat_stride(from.feat_stride());
}
if (from.has_base_size()) {
set_base_size(from.base_size());
}
if (from.has_min_size()) {
set_min_size(from.min_size());
}
if (from.has_pre_nms_topn()) {
set_pre_nms_topn(from.pre_nms_topn());
}
if (from.has_post_nms_topn()) {
set_post_nms_topn(from.post_nms_topn());
}
if (from.has_nms_thresh()) {
set_nms_thresh(from.nms_thresh());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void ProposalParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.ProposalParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void ProposalParameter::CopyFrom(const ProposalParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.ProposalParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool ProposalParameter::IsInitialized() const {
return true;
}
void ProposalParameter::Swap(ProposalParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void ProposalParameter::InternalSwap(ProposalParameter* other) {
std::swap(feat_stride_, other->feat_stride_);
std::swap(base_size_, other->base_size_);
std::swap(min_size_, other->min_size_);
ratio_.UnsafeArenaSwap(&other->ratio_);
scale_.UnsafeArenaSwap(&other->scale_);
std::swap(pre_nms_topn_, other->pre_nms_topn_);
std::swap(post_nms_topn_, other->post_nms_topn_);
std::swap(nms_thresh_, other->nms_thresh_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata ProposalParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = ProposalParameter_descriptor_;
metadata.reflection = ProposalParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// ProposalParameter
// optional uint32 feat_stride = 1 [default = 16];
bool ProposalParameter::has_feat_stride() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void ProposalParameter::set_has_feat_stride() {
_has_bits_[0] |= 0x00000001u;
}
void ProposalParameter::clear_has_feat_stride() {
_has_bits_[0] &= ~0x00000001u;
}
void ProposalParameter::clear_feat_stride() {
feat_stride_ = 16u;
clear_has_feat_stride();
}
::google::protobuf::uint32 ProposalParameter::feat_stride() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ProposalParameter.feat_stride)
return feat_stride_;
}
void ProposalParameter::set_feat_stride(::google::protobuf::uint32 value) {
set_has_feat_stride();
feat_stride_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ProposalParameter.feat_stride)
}
// optional uint32 base_size = 2 [default = 16];
bool ProposalParameter::has_base_size() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void ProposalParameter::set_has_base_size() {
_has_bits_[0] |= 0x00000002u;
}
void ProposalParameter::clear_has_base_size() {
_has_bits_[0] &= ~0x00000002u;
}
void ProposalParameter::clear_base_size() {
base_size_ = 16u;
clear_has_base_size();
}
::google::protobuf::uint32 ProposalParameter::base_size() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ProposalParameter.base_size)
return base_size_;
}
void ProposalParameter::set_base_size(::google::protobuf::uint32 value) {
set_has_base_size();
base_size_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ProposalParameter.base_size)
}
// optional uint32 min_size = 3 [default = 16];
bool ProposalParameter::has_min_size() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void ProposalParameter::set_has_min_size() {
_has_bits_[0] |= 0x00000004u;
}
void ProposalParameter::clear_has_min_size() {
_has_bits_[0] &= ~0x00000004u;
}
void ProposalParameter::clear_min_size() {
min_size_ = 16u;
clear_has_min_size();
}
::google::protobuf::uint32 ProposalParameter::min_size() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ProposalParameter.min_size)
return min_size_;
}
void ProposalParameter::set_min_size(::google::protobuf::uint32 value) {
set_has_min_size();
min_size_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ProposalParameter.min_size)
}
// repeated float ratio = 4;
int ProposalParameter::ratio_size() const {
return ratio_.size();
}
void ProposalParameter::clear_ratio() {
ratio_.Clear();
}
float ProposalParameter::ratio(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.ProposalParameter.ratio)
return ratio_.Get(index);
}
void ProposalParameter::set_ratio(int index, float value) {
ratio_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.ProposalParameter.ratio)
}
void ProposalParameter::add_ratio(float value) {
ratio_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.ProposalParameter.ratio)
}
const ::google::protobuf::RepeatedField< float >&
ProposalParameter::ratio() const {
// @@protoc_insertion_point(field_list:opencv_caffe.ProposalParameter.ratio)
return ratio_;
}
::google::protobuf::RepeatedField< float >*
ProposalParameter::mutable_ratio() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.ProposalParameter.ratio)
return &ratio_;
}
// repeated float scale = 5;
int ProposalParameter::scale_size() const {
return scale_.size();
}
void ProposalParameter::clear_scale() {
scale_.Clear();
}
float ProposalParameter::scale(int index) const {
// @@protoc_insertion_point(field_get:opencv_caffe.ProposalParameter.scale)
return scale_.Get(index);
}
void ProposalParameter::set_scale(int index, float value) {
scale_.Set(index, value);
// @@protoc_insertion_point(field_set:opencv_caffe.ProposalParameter.scale)
}
void ProposalParameter::add_scale(float value) {
scale_.Add(value);
// @@protoc_insertion_point(field_add:opencv_caffe.ProposalParameter.scale)
}
const ::google::protobuf::RepeatedField< float >&
ProposalParameter::scale() const {
// @@protoc_insertion_point(field_list:opencv_caffe.ProposalParameter.scale)
return scale_;
}
::google::protobuf::RepeatedField< float >*
ProposalParameter::mutable_scale() {
// @@protoc_insertion_point(field_mutable_list:opencv_caffe.ProposalParameter.scale)
return &scale_;
}
// optional uint32 pre_nms_topn = 6 [default = 6000];
bool ProposalParameter::has_pre_nms_topn() const {
return (_has_bits_[0] & 0x00000020u) != 0;
}
void ProposalParameter::set_has_pre_nms_topn() {
_has_bits_[0] |= 0x00000020u;
}
void ProposalParameter::clear_has_pre_nms_topn() {
_has_bits_[0] &= ~0x00000020u;
}
void ProposalParameter::clear_pre_nms_topn() {
pre_nms_topn_ = 6000u;
clear_has_pre_nms_topn();
}
::google::protobuf::uint32 ProposalParameter::pre_nms_topn() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ProposalParameter.pre_nms_topn)
return pre_nms_topn_;
}
void ProposalParameter::set_pre_nms_topn(::google::protobuf::uint32 value) {
set_has_pre_nms_topn();
pre_nms_topn_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ProposalParameter.pre_nms_topn)
}
// optional uint32 post_nms_topn = 7 [default = 300];
bool ProposalParameter::has_post_nms_topn() const {
return (_has_bits_[0] & 0x00000040u) != 0;
}
void ProposalParameter::set_has_post_nms_topn() {
_has_bits_[0] |= 0x00000040u;
}
void ProposalParameter::clear_has_post_nms_topn() {
_has_bits_[0] &= ~0x00000040u;
}
void ProposalParameter::clear_post_nms_topn() {
post_nms_topn_ = 300u;
clear_has_post_nms_topn();
}
::google::protobuf::uint32 ProposalParameter::post_nms_topn() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ProposalParameter.post_nms_topn)
return post_nms_topn_;
}
void ProposalParameter::set_post_nms_topn(::google::protobuf::uint32 value) {
set_has_post_nms_topn();
post_nms_topn_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ProposalParameter.post_nms_topn)
}
// optional float nms_thresh = 8 [default = 0.7];
bool ProposalParameter::has_nms_thresh() const {
return (_has_bits_[0] & 0x00000080u) != 0;
}
void ProposalParameter::set_has_nms_thresh() {
_has_bits_[0] |= 0x00000080u;
}
void ProposalParameter::clear_has_nms_thresh() {
_has_bits_[0] &= ~0x00000080u;
}
void ProposalParameter::clear_nms_thresh() {
nms_thresh_ = 0.7f;
clear_has_nms_thresh();
}
float ProposalParameter::nms_thresh() const {
// @@protoc_insertion_point(field_get:opencv_caffe.ProposalParameter.nms_thresh)
return nms_thresh_;
}
void ProposalParameter::set_nms_thresh(float value) {
set_has_nms_thresh();
nms_thresh_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.ProposalParameter.nms_thresh)
}
inline const ProposalParameter* ProposalParameter::internal_default_instance() {
return &ProposalParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// ===================================================================
#if !defined(_MSC_VER) || _MSC_VER >= 1900
const int PSROIPoolingParameter::kSpatialScaleFieldNumber;
const int PSROIPoolingParameter::kOutputDimFieldNumber;
const int PSROIPoolingParameter::kGroupSizeFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
PSROIPoolingParameter::PSROIPoolingParameter()
: ::google::protobuf::Message(), _internal_metadata_(NULL) {
if (this != internal_default_instance()) protobuf_InitDefaults_opencv_2dcaffe_2eproto();
SharedCtor();
// @@protoc_insertion_point(constructor:opencv_caffe.PSROIPoolingParameter)
}
void PSROIPoolingParameter::InitAsDefaultInstance() {
}
PSROIPoolingParameter::PSROIPoolingParameter(const PSROIPoolingParameter& from)
: ::google::protobuf::Message(),
_internal_metadata_(NULL) {
SharedCtor();
UnsafeMergeFrom(from);
// @@protoc_insertion_point(copy_constructor:opencv_caffe.PSROIPoolingParameter)
}
void PSROIPoolingParameter::SharedCtor() {
_cached_size_ = 0;
::memset(&spatial_scale_, 0, reinterpret_cast<char*>(&group_size_) -
reinterpret_cast<char*>(&spatial_scale_) + sizeof(group_size_));
}
PSROIPoolingParameter::~PSROIPoolingParameter() {
// @@protoc_insertion_point(destructor:opencv_caffe.PSROIPoolingParameter)
SharedDtor();
}
void PSROIPoolingParameter::SharedDtor() {
}
void PSROIPoolingParameter::SetCachedSize(int size) const {
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
}
const ::google::protobuf::Descriptor* PSROIPoolingParameter::descriptor() {
protobuf_AssignDescriptorsOnce();
return PSROIPoolingParameter_descriptor_;
}
const PSROIPoolingParameter& PSROIPoolingParameter::default_instance() {
protobuf_InitDefaults_opencv_2dcaffe_2eproto();
return *internal_default_instance();
}
::google::protobuf::internal::ExplicitlyConstructed<PSROIPoolingParameter> PSROIPoolingParameter_default_instance_;
PSROIPoolingParameter* PSROIPoolingParameter::New(::google::protobuf::Arena* arena) const {
PSROIPoolingParameter* n = new PSROIPoolingParameter;
if (arena != NULL) {
arena->Own(n);
}
return n;
}
void PSROIPoolingParameter::Clear() {
// @@protoc_insertion_point(message_clear_start:opencv_caffe.PSROIPoolingParameter)
#if defined(__clang__)
#define ZR_HELPER_(f) \
_Pragma("clang diagnostic push") \
_Pragma("clang diagnostic ignored \"-Winvalid-offsetof\"") \
__builtin_offsetof(PSROIPoolingParameter, f) \
_Pragma("clang diagnostic pop")
#else
#define ZR_HELPER_(f) reinterpret_cast<char*>(\
&reinterpret_cast<PSROIPoolingParameter*>(16)->f)
#endif
#define ZR_(first, last) do {\
::memset(&(first), 0,\
ZR_HELPER_(last) - ZR_HELPER_(first) + sizeof(last));\
} while (0)
ZR_(spatial_scale_, group_size_);
#undef ZR_HELPER_
#undef ZR_
_has_bits_.Clear();
if (_internal_metadata_.have_unknown_fields()) {
mutable_unknown_fields()->Clear();
}
}
bool PSROIPoolingParameter::MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) {
#define DO_(EXPRESSION) if (!GOOGLE_PREDICT_TRUE(EXPRESSION)) goto failure
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:opencv_caffe.PSROIPoolingParameter)
for (;;) {
::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoff(127);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// required float spatial_scale = 1;
case 1: {
if (tag == 13) {
set_has_spatial_scale();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
float, ::google::protobuf::internal::WireFormatLite::TYPE_FLOAT>(
input, &spatial_scale_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(16)) goto parse_output_dim;
break;
}
// required int32 output_dim = 2;
case 2: {
if (tag == 16) {
parse_output_dim:
set_has_output_dim();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &output_dim_)));
} else {
goto handle_unusual;
}
if (input->ExpectTag(24)) goto parse_group_size;
break;
}
// required int32 group_size = 3;
case 3: {
if (tag == 24) {
parse_group_size:
set_has_group_size();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
::google::protobuf::int32, ::google::protobuf::internal::WireFormatLite::TYPE_INT32>(
input, &group_size_)));
} else {
goto handle_unusual;
}
if (input->ExpectAtEnd()) goto success;
break;
}
default: {
handle_unusual:
if (tag == 0 ||
::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) {
goto success;
}
DO_(::google::protobuf::internal::WireFormat::SkipField(
input, tag, mutable_unknown_fields()));
break;
}
}
}
success:
// @@protoc_insertion_point(parse_success:opencv_caffe.PSROIPoolingParameter)
return true;
failure:
// @@protoc_insertion_point(parse_failure:opencv_caffe.PSROIPoolingParameter)
return false;
#undef DO_
}
void PSROIPoolingParameter::SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const {
// @@protoc_insertion_point(serialize_start:opencv_caffe.PSROIPoolingParameter)
// required float spatial_scale = 1;
if (has_spatial_scale()) {
::google::protobuf::internal::WireFormatLite::WriteFloat(1, this->spatial_scale(), output);
}
// required int32 output_dim = 2;
if (has_output_dim()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(2, this->output_dim(), output);
}
// required int32 group_size = 3;
if (has_group_size()) {
::google::protobuf::internal::WireFormatLite::WriteInt32(3, this->group_size(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
unknown_fields(), output);
}
// @@protoc_insertion_point(serialize_end:opencv_caffe.PSROIPoolingParameter)
}
::google::protobuf::uint8* PSROIPoolingParameter::InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const {
(void)deterministic; // Unused
// @@protoc_insertion_point(serialize_to_array_start:opencv_caffe.PSROIPoolingParameter)
// required float spatial_scale = 1;
if (has_spatial_scale()) {
target = ::google::protobuf::internal::WireFormatLite::WriteFloatToArray(1, this->spatial_scale(), target);
}
// required int32 output_dim = 2;
if (has_output_dim()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(2, this->output_dim(), target);
}
// required int32 group_size = 3;
if (has_group_size()) {
target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(3, this->group_size(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
unknown_fields(), target);
}
// @@protoc_insertion_point(serialize_to_array_end:opencv_caffe.PSROIPoolingParameter)
return target;
}
size_t PSROIPoolingParameter::RequiredFieldsByteSizeFallback() const {
// @@protoc_insertion_point(required_fields_byte_size_fallback_start:opencv_caffe.PSROIPoolingParameter)
size_t total_size = 0;
if (has_spatial_scale()) {
// required float spatial_scale = 1;
total_size += 1 + 4;
}
if (has_output_dim()) {
// required int32 output_dim = 2;
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->output_dim());
}
if (has_group_size()) {
// required int32 group_size = 3;
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->group_size());
}
return total_size;
}
size_t PSROIPoolingParameter::ByteSizeLong() const {
// @@protoc_insertion_point(message_byte_size_start:opencv_caffe.PSROIPoolingParameter)
size_t total_size = 0;
if (((_has_bits_[0] & 0x00000007) ^ 0x00000007) == 0) { // All required fields are present.
// required float spatial_scale = 1;
total_size += 1 + 4;
// required int32 output_dim = 2;
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->output_dim());
// required int32 group_size = 3;
total_size += 1 +
::google::protobuf::internal::WireFormatLite::Int32Size(
this->group_size());
} else {
total_size += RequiredFieldsByteSizeFallback();
}
if (_internal_metadata_.have_unknown_fields()) {
total_size +=
::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize(
unknown_fields());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
GOOGLE_SAFE_CONCURRENT_WRITES_BEGIN();
_cached_size_ = cached_size;
GOOGLE_SAFE_CONCURRENT_WRITES_END();
return total_size;
}
void PSROIPoolingParameter::MergeFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_merge_from_start:opencv_caffe.PSROIPoolingParameter)
if (GOOGLE_PREDICT_FALSE(&from == this)) MergeFromFail(__LINE__);
const PSROIPoolingParameter* source =
::google::protobuf::internal::DynamicCastToGenerated<const PSROIPoolingParameter>(
&from);
if (source == NULL) {
// @@protoc_insertion_point(generalized_merge_from_cast_fail:opencv_caffe.PSROIPoolingParameter)
::google::protobuf::internal::ReflectionOps::Merge(from, this);
} else {
// @@protoc_insertion_point(generalized_merge_from_cast_success:opencv_caffe.PSROIPoolingParameter)
UnsafeMergeFrom(*source);
}
}
void PSROIPoolingParameter::MergeFrom(const PSROIPoolingParameter& from) {
// @@protoc_insertion_point(class_specific_merge_from_start:opencv_caffe.PSROIPoolingParameter)
if (GOOGLE_PREDICT_TRUE(&from != this)) {
UnsafeMergeFrom(from);
} else {
MergeFromFail(__LINE__);
}
}
void PSROIPoolingParameter::UnsafeMergeFrom(const PSROIPoolingParameter& from) {
GOOGLE_DCHECK(&from != this);
if (from._has_bits_[0 / 32] & (0xffu << (0 % 32))) {
if (from.has_spatial_scale()) {
set_spatial_scale(from.spatial_scale());
}
if (from.has_output_dim()) {
set_output_dim(from.output_dim());
}
if (from.has_group_size()) {
set_group_size(from.group_size());
}
}
if (from._internal_metadata_.have_unknown_fields()) {
::google::protobuf::UnknownFieldSet::MergeToInternalMetdata(
from.unknown_fields(), &_internal_metadata_);
}
}
void PSROIPoolingParameter::CopyFrom(const ::google::protobuf::Message& from) {
// @@protoc_insertion_point(generalized_copy_from_start:opencv_caffe.PSROIPoolingParameter)
if (&from == this) return;
Clear();
MergeFrom(from);
}
void PSROIPoolingParameter::CopyFrom(const PSROIPoolingParameter& from) {
// @@protoc_insertion_point(class_specific_copy_from_start:opencv_caffe.PSROIPoolingParameter)
if (&from == this) return;
Clear();
UnsafeMergeFrom(from);
}
bool PSROIPoolingParameter::IsInitialized() const {
if ((_has_bits_[0] & 0x00000007) != 0x00000007) return false;
return true;
}
void PSROIPoolingParameter::Swap(PSROIPoolingParameter* other) {
if (other == this) return;
InternalSwap(other);
}
void PSROIPoolingParameter::InternalSwap(PSROIPoolingParameter* other) {
std::swap(spatial_scale_, other->spatial_scale_);
std::swap(output_dim_, other->output_dim_);
std::swap(group_size_, other->group_size_);
std::swap(_has_bits_[0], other->_has_bits_[0]);
_internal_metadata_.Swap(&other->_internal_metadata_);
std::swap(_cached_size_, other->_cached_size_);
}
::google::protobuf::Metadata PSROIPoolingParameter::GetMetadata() const {
protobuf_AssignDescriptorsOnce();
::google::protobuf::Metadata metadata;
metadata.descriptor = PSROIPoolingParameter_descriptor_;
metadata.reflection = PSROIPoolingParameter_reflection_;
return metadata;
}
#if PROTOBUF_INLINE_NOT_IN_HEADERS
// PSROIPoolingParameter
// required float spatial_scale = 1;
bool PSROIPoolingParameter::has_spatial_scale() const {
return (_has_bits_[0] & 0x00000001u) != 0;
}
void PSROIPoolingParameter::set_has_spatial_scale() {
_has_bits_[0] |= 0x00000001u;
}
void PSROIPoolingParameter::clear_has_spatial_scale() {
_has_bits_[0] &= ~0x00000001u;
}
void PSROIPoolingParameter::clear_spatial_scale() {
spatial_scale_ = 0;
clear_has_spatial_scale();
}
float PSROIPoolingParameter::spatial_scale() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PSROIPoolingParameter.spatial_scale)
return spatial_scale_;
}
void PSROIPoolingParameter::set_spatial_scale(float value) {
set_has_spatial_scale();
spatial_scale_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PSROIPoolingParameter.spatial_scale)
}
// required int32 output_dim = 2;
bool PSROIPoolingParameter::has_output_dim() const {
return (_has_bits_[0] & 0x00000002u) != 0;
}
void PSROIPoolingParameter::set_has_output_dim() {
_has_bits_[0] |= 0x00000002u;
}
void PSROIPoolingParameter::clear_has_output_dim() {
_has_bits_[0] &= ~0x00000002u;
}
void PSROIPoolingParameter::clear_output_dim() {
output_dim_ = 0;
clear_has_output_dim();
}
::google::protobuf::int32 PSROIPoolingParameter::output_dim() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PSROIPoolingParameter.output_dim)
return output_dim_;
}
void PSROIPoolingParameter::set_output_dim(::google::protobuf::int32 value) {
set_has_output_dim();
output_dim_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PSROIPoolingParameter.output_dim)
}
// required int32 group_size = 3;
bool PSROIPoolingParameter::has_group_size() const {
return (_has_bits_[0] & 0x00000004u) != 0;
}
void PSROIPoolingParameter::set_has_group_size() {
_has_bits_[0] |= 0x00000004u;
}
void PSROIPoolingParameter::clear_has_group_size() {
_has_bits_[0] &= ~0x00000004u;
}
void PSROIPoolingParameter::clear_group_size() {
group_size_ = 0;
clear_has_group_size();
}
::google::protobuf::int32 PSROIPoolingParameter::group_size() const {
// @@protoc_insertion_point(field_get:opencv_caffe.PSROIPoolingParameter.group_size)
return group_size_;
}
void PSROIPoolingParameter::set_group_size(::google::protobuf::int32 value) {
set_has_group_size();
group_size_ = value;
// @@protoc_insertion_point(field_set:opencv_caffe.PSROIPoolingParameter.group_size)
}
inline const PSROIPoolingParameter* PSROIPoolingParameter::internal_default_instance() {
return &PSROIPoolingParameter_default_instance_.get();
}
#endif // PROTOBUF_INLINE_NOT_IN_HEADERS
// @@protoc_insertion_point(namespace_scope)
} // namespace opencv_caffe
// @@protoc_insertion_point(global_scope)