blob_id stringlengths 40 40 | directory_id stringlengths 40 40 | path stringlengths 4 201 | content_id stringlengths 40 40 | detected_licenses listlengths 0 85 | license_type stringclasses 2
values | repo_name stringlengths 7 100 | snapshot_id stringlengths 40 40 | revision_id stringlengths 40 40 | branch_name stringclasses 260
values | visit_date timestamp[us] | revision_date timestamp[us] | committer_date timestamp[us] | github_id int64 11.4k 681M ⌀ | star_events_count int64 0 209k | fork_events_count int64 0 110k | gha_license_id stringclasses 17
values | gha_event_created_at timestamp[us] | gha_created_at timestamp[us] | gha_language stringclasses 80
values | src_encoding stringclasses 28
values | language stringclasses 1
value | is_vendor bool 1
class | is_generated bool 2
classes | length_bytes int64 8 9.86M | extension stringclasses 52
values | content stringlengths 8 9.86M | authors listlengths 1 1 | author stringlengths 0 119 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0f0cd3026f5b79d128408e00078eb61bad831f0d | 60bb67415a192d0c421719de7822c1819d5ba7ac | /blazetest/src/mathtest/dmatdmatschur/LHaLHb.cpp | 978531612910dcfcef6a46669d84126dcef52a64 | [
"BSD-3-Clause"
] | permissive | rtohid/blaze | 48decd51395d912730add9bc0d19e617ecae8624 | 7852d9e22aeb89b907cb878c28d6ca75e5528431 | refs/heads/master | 2020-04-16T16:48:03.915504 | 2018-12-19T20:29:42 | 2018-12-19T20:29:42 | 165,750,036 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 4,026 | cpp | //=================================================================================================
/*!
// \file src/mathtest/dmatdmatschur/LHaLHb.cpp
// \brief Source file for the LHaLHb dense matrix/dense matrix Schur product math test
//
// Copyright (C) 2012-2018 Klaus Iglberger - All Rights Reserved
//
// This file is part of the Blaze library. You can redistribute it and/or modify it under
// the terms of the New (Revised) BSD License. Redistribution and use in source and binary
// forms, with or without modification, are permitted provided that the following conditions
// are met:
//
// 1. Redistributions of source code must retain the above copyright notice, this list of
// conditions and the following disclaimer.
// 2. Redistributions in binary form must reproduce the above copyright notice, this list
// of conditions and the following disclaimer in the documentation and/or other materials
// provided with the distribution.
// 3. Neither the names of the Blaze development group nor the names of its contributors
// may be used to endorse or promote products derived from this software without specific
// prior written permission.
//
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
// OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT
// SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
// INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
// TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
// BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
// CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
// ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
// DAMAGE.
*/
//=================================================================================================
//*************************************************************************************************
// Includes
//*************************************************************************************************
#include <cstdlib>
#include <iostream>
#include <blaze/math/HybridMatrix.h>
#include <blaze/math/LowerMatrix.h>
#include <blazetest/mathtest/Creator.h>
#include <blazetest/mathtest/dmatdmatschur/OperationTest.h>
#include <blazetest/system/MathTest.h>
//=================================================================================================
//
// MAIN FUNCTION
//
//=================================================================================================
//*************************************************************************************************
int main()
{
std::cout << " Running 'LHaLHb'..." << std::endl;
using blazetest::mathtest::TypeA;
using blazetest::mathtest::TypeB;
try
{
// Matrix type definitions
using LHa = blaze::LowerMatrix< blaze::HybridMatrix<TypeA,128UL,128UL> >;
using LHb = blaze::LowerMatrix< blaze::HybridMatrix<TypeB,128UL,128UL> >;
// Creator type definitions
using CLHa = blazetest::Creator<LHa>;
using CLHb = blazetest::Creator<LHb>;
// Running tests with small matrices
for( size_t i=0UL; i<=9UL; ++i ) {
RUN_DMATDMATSCHUR_OPERATION_TEST( CLHa( i ), CLHb( i ) );
}
// Running tests with large matrices
RUN_DMATDMATSCHUR_OPERATION_TEST( CLHa( 67UL ), CLHb( 67UL ) );
RUN_DMATDMATSCHUR_OPERATION_TEST( CLHa( 128UL ), CLHb( 128UL ) );
}
catch( std::exception& ex ) {
std::cerr << "\n\n ERROR DETECTED during dense matrix/dense matrix Schur product:\n"
<< ex.what() << "\n";
return EXIT_FAILURE;
}
return EXIT_SUCCESS;
}
//*************************************************************************************************
| [
"klaus.iglberger@gmail.com"
] | klaus.iglberger@gmail.com |
e78858e63cab872d6c6f2ed5dd95580d1f7add72 | cc552dd935ba90713665de58ecaafa1d19e01397 | /renderarea.cpp | 47b6dddcb72dba2b021bd0dcfdde41bc56263c49 | [] | no_license | MStolpovskiy/QtCurvesCPP | 3bdeafe26301889430092e7cc3474284c54c204c | 231c6f2fc6749afd6f138d65c058ff9d32607363 | refs/heads/master | 2020-12-22T12:51:35.204359 | 2020-01-31T09:58:21 | 2020-01-31T09:58:21 | 236,788,570 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 5,599 | cpp | #include "renderarea.h"
#include <QtMath>
RenderArea::RenderArea(QWidget *parent) :
QWidget(parent),
mBackgroundColor(QColor(0, 0, 255)),
mShape(Astroid)
{
mPen.setWidth(2);
mPen.setColor(QColor(255, 255, 255));
on_shape_changed();
}
QSize RenderArea::minimumSizeHint() const {
return QSize(1000, 1000);
}
QSize RenderArea::sizeHint() const {
return QSize(1000, 1000);
}
void RenderArea::on_shape_changed() {
switch (mShape) {
case RenderArea::Astroid:
mScale = 90;
mIntervalLength = 2 * M_PI;
mStepCount = 256;
break;
case RenderArea::Cycloid:
mScale = 10;
mIntervalLength = 4 * M_PI;
mStepCount = 128;
break;
case RenderArea::HuygensCycloid:
mScale = 10;
mIntervalLength = 2 * M_PI;
mStepCount = 256;
break;
case RenderArea::HypoCycloid:
mScale = 40;
mIntervalLength = 2 * M_PI;
mStepCount = 256;
break;
case RenderArea::Line:
mScale = 100; // line length in pixels
mIntervalLength = 1; // not really needed
mStepCount = 2;
case RenderArea::Circle:
mScale = 100;
mIntervalLength = 2 * M_PI;
mStepCount = 128;
break;
case RenderArea::Ellipse:
mScale = 75;
mIntervalLength = 2 * M_PI;
mStepCount = 128;
break;
case RenderArea::Fancy:
mScale = 10;
mIntervalLength = 12 * M_PI;
mStepCount = 512;
break;
case RenderArea::Starfish:
mScale = 25;
mIntervalLength = 6 * M_PI;
mStepCount = 256;
break;
case RenderArea::Cloud:
case RenderArea::Star:
mScale = 10;
mIntervalLength = 28 * M_PI;
mStepCount = 256;
break;
default:
break;
}
}
QPointF RenderArea::compute(float t) {
switch (mShape) {
case RenderArea::Astroid:
return compute_astroid(t);
break;
case RenderArea::Cycloid:
return compute_cycloid(t);
break;
case RenderArea::HuygensCycloid:
return compute_huygens(t);
break;
case RenderArea::HypoCycloid:
return compute_hypo(t);
break;
case RenderArea::Line:
return compute_line(t);
break;
case RenderArea::Circle:
return compute_circle(t);
break;
case RenderArea::Ellipse:
return compute_ellipse(t);
break;
case RenderArea::Fancy:
return compute_fancy(t);
break;
case RenderArea::Starfish:
return compute_starfish(t);
break;
case RenderArea::Cloud:
return compute_cloud(t, -1);
break;
case RenderArea::Star:
return compute_cloud(t, +1);
break;
default:
break;
}
return QPoint(0, 0);
}
QPointF RenderArea::compute_astroid(float t) {
float cos_t = cos(t);
float sin_t = sin(t);
float x = 2 * cos_t * cos_t * cos_t;
float y = 2 * sin_t * sin_t * sin_t;
return QPointF(x, y);
}
QPointF RenderArea::compute_cycloid(float t) {
return QPointF(
1.5 * (1 - cos(t)), // X
1.5 * (t - sin(t)) // Y
);
}
QPointF RenderArea::compute_huygens(float t) {
return QPointF(
4 * (3 * cos(t) - cos(3 * t)), // X
4 * (3 * sin(t) - sin(3 * t)) // Y
);
}
QPointF RenderArea::compute_hypo(float t) {
return QPointF(
1.5 * (2 * cos(t) + cos(2 * t)), // X
1.5 * (2 * sin(t) - sin(2 * t)) // Y
);
}
QPointF RenderArea::compute_line(float t) {
return QPointF(
t, // X
t // Y
);
}
QPointF RenderArea::compute_circle(float t) {
return QPointF(
cos(t), // X
sin(t) // Y
);
}
QPointF RenderArea::compute_ellipse(float t) {
float a = 2., b = 1.1;
return QPointF(
a * cos(t), // X
b * sin(t) // Y
);
}
QPointF RenderArea::compute_fancy(float t) {
float a = 11., b = 6.;
float x = a * cos(t) - b * cos (a / b * t);
float y = a * sin(t) - b * sin (a / b * t);
return QPointF(x, y);
}
QPointF RenderArea::compute_starfish(float t) {
float R = 5., r = 3., d = 5.;
float x = (R - r) * cos(t) + d * cos ((R - r) / r * t);
float y = (R - r) * sin(t) - d * sin ((R - r) / r * t);
return QPointF(x, y);
}
QPointF RenderArea::compute_cloud(float t, int sign = -1) {
float a = 14., b = 1.;
float x = (a + b) * cos(t * b / a) + sign * b * cos ((a + b) / a * t);
float y = (a + b) * sin(t * b / a) - b * sin ((a + b) / a * t);
return QPointF(x, y);
}
void RenderArea::paintEvent(QPaintEvent *event) {
Q_UNUSED(event);
QPainter painter(this);
painter.setRenderHint(QPainter::Antialiasing, true);
painter.setBrush(mBackgroundColor);
painter.setPen(mPen);
// drawing area
painter.drawRect(this->rect());
QPoint center = this->rect().center();
float step = mIntervalLength / mStepCount;
QPoint lastPixel;
for (float t=0; t<mIntervalLength + step; t+=step) {
QPointF point = compute(t);
QPoint pixel;
pixel.setX(point.x() * mScale + center.x());
pixel.setY(point.y() * mScale + center.y());
if (t == 0) {
lastPixel = pixel;
continue;
}
// painter.drawPoint(pixel);
QLineF line(pixel, lastPixel);
painter.drawLine(line);
lastPixel = pixel;
}
}
| [
"m-stol@yandex.ru"
] | m-stol@yandex.ru |
4dde2613320844270691d9f0922b7e2e673735a9 | 03ee754445d2dc6abbb3c1f2a57a35519f8acc96 | /test_static.cpp | 03ce0aed1f12d36f21ffb17f2f31f137369dce21 | [] | no_license | mizan-cs/Practise-Code | d34a67d1f3ea7a9a81e8096020227b705ca5ec13 | 74b21d810c242af249a17ec8fef683fdb3c0d1b0 | refs/heads/master | 2021-01-19T21:19:25.831029 | 2017-09-09T03:23:47 | 2017-09-09T03:23:47 | 101,249,329 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 317 | cpp | #include<iostream>
using namespace std;
class Sample{
public:
static int totObj;
static void PrintInfo()
{
cout<<"Total Object :"<<totObj<<"\n";
}
};
int Sample::totObj = 0;
int main()
{
Sample::totObj = 500;
Sample::PrintInfo();
return 0;
}
| [
"mysalfe02@gmail.com"
] | mysalfe02@gmail.com |
ce52ff20fbc50e58f30886d1d928aa68d9414765 | 35f575c997f226e4662ae214735e29186e93d1bf | /dependencies/bullet/src/examples/ExampleBrowser/OpenGLExampleBrowser.cpp | a76cdfe5b3fd7ffb287282be1450e1d78e004dfb | [
"Zlib",
"Apache-2.0"
] | permissive | PTSD-3D/PTSD-Engine | b227aa52b9f948a7794c0075295e70d4a71c4353 | 2f523b8a7fd768c8e3cfd634e53d8c34b3b359ef | refs/heads/main | 2023-05-04T03:25:26.093194 | 2021-05-27T21:10:25 | 2021-05-27T21:10:25 | 345,047,719 | 3 | 0 | Apache-2.0 | 2021-05-27T21:10:26 | 2021-03-06T08:50:35 | C++ | UTF-8 | C++ | false | false | 33,556 | cpp | #include "OpenGLExampleBrowser.h"
#include "LinearMath/btQuickprof.h"
#include "../OpenGLWindow/OpenGLInclude.h"
#include "../OpenGLWindow/SimpleOpenGL2App.h"
#ifndef NO_OPENGL3
#include "../OpenGLWindow/SimpleOpenGL3App.h"
#endif
#include "../CommonInterfaces/CommonRenderInterface.h"
#ifdef __APPLE__
#include "../OpenGLWindow/MacOpenGLWindow.h"
#else
#ifdef _WIN32
#include "../OpenGLWindow/Win32OpenGLWindow.h"
#else
//let's cross the fingers it is Linux/X11
#ifdef BT_USE_EGL
#include "../OpenGLWindow/EGLOpenGLWindow.h"
#else
#include "../OpenGLWindow/X11OpenGLWindow.h"
#endif //BT_USE_EGL
#endif //_WIN32
#endif //__APPLE__
#include "../ThirdPartyLibs/Gwen/Renderers/OpenGL_DebugFont.h"
#include "LinearMath/btThreads.h"
#include "Bullet3Common/b3Vector3.h"
#include "assert.h"
#include <stdio.h>
#include "GwenGUISupport/gwenInternalData.h"
#include "GwenGUISupport/gwenUserInterface.h"
#include "../Utils/b3Clock.h"
#include "../Utils/ChromeTraceUtil.h"
#include "GwenGUISupport/GwenParameterInterface.h"
#ifndef BT_NO_PROFILE
#include "GwenGUISupport/GwenProfileWindow.h"
#endif
#include "GwenGUISupport/GwenTextureWindow.h"
#include "GwenGUISupport/GraphingTexture.h"
#include "../CommonInterfaces/Common2dCanvasInterface.h"
#include "../CommonInterfaces/CommonExampleInterface.h"
#include "Bullet3Common/b3CommandLineArgs.h"
#include "../OpenGLWindow/SimpleCamera.h"
#include "../OpenGLWindow/SimpleOpenGL2Renderer.h"
#include "ExampleEntries.h"
#include "OpenGLGuiHelper.h"
#include "Bullet3Common/b3FileUtils.h"
#include "LinearMath/btIDebugDraw.h"
//quick test for file import, @todo(erwincoumans) make it more general and add other file formats
#include "../Importers/ImportURDFDemo/ImportURDFSetup.h"
#include "../Importers/ImportBullet/SerializeSetup.h"
#include "Bullet3Common/b3HashMap.h"
struct GL3TexLoader : public MyTextureLoader
{
b3HashMap<b3HashString, GLint> m_hashMap;
virtual void LoadTexture(Gwen::Texture* pTexture)
{
Gwen::String namestr = pTexture->name.Get();
const char* n = namestr.c_str();
GLint* texIdPtr = m_hashMap[n];
if (texIdPtr)
{
pTexture->m_intData = *texIdPtr;
}
}
virtual void FreeTexture(Gwen::Texture* pTexture)
{
}
};
struct OpenGLExampleBrowserInternalData
{
Gwen::Renderer::Base* m_gwenRenderer;
CommonGraphicsApp* m_app;
#ifndef BT_NO_PROFILE
MyProfileWindow* m_profWindow;
#endif //BT_NO_PROFILE
btAlignedObjectArray<Gwen::Controls::TreeNode*> m_nodes;
GwenUserInterface* m_gui;
GL3TexLoader* m_myTexLoader;
struct MyMenuItemHander* m_handler2;
btAlignedObjectArray<MyMenuItemHander*> m_handlers;
OpenGLExampleBrowserInternalData()
: m_gwenRenderer(0),
m_app(0),
// m_profWindow(0),
m_gui(0),
m_myTexLoader(0),
m_handler2(0)
{
}
};
static CommonGraphicsApp* s_app = 0;
static CommonWindowInterface* s_window = 0;
static CommonParameterInterface* s_parameterInterface = 0;
static CommonRenderInterface* s_instancingRenderer = 0;
static OpenGLGuiHelper* s_guiHelper = 0;
#ifndef BT_NO_PROFILE
static MyProfileWindow* s_profWindow = 0;
#endif //BT_NO_PROFILE
static SharedMemoryInterface* sSharedMem = 0;
#define DEMO_SELECTION_COMBOBOX 13
const char* startFileName = "0_Bullet3Demo.txt";
char staticPngFileName[1024];
//static GwenUserInterface* gui = 0;
static GwenUserInterface* gui2 = 0;
static int sCurrentDemoIndex = -1;
static int sCurrentHightlighted = 0;
static CommonExampleInterface* sCurrentDemo = 0;
static b3AlignedObjectArray<const char*> allNames;
static float gFixedTimeStep = 0;
bool gAllowRetina = true;
bool gDisableDemoSelection = false;
int gRenderDevice = -1;
int gWindowBackend = 0;
static class ExampleEntries* gAllExamples = 0;
bool sUseOpenGL2 = false;
#ifndef USE_OPENGL3
extern bool useShadowMap;
#endif
bool visualWireframe = false;
static bool renderVisualGeometry = true;
static bool renderGrid = true;
static bool gEnableRenderLoop = true;
bool renderGui = true;
static bool enable_experimental_opencl = false;
static bool gEnableDefaultKeyboardShortcuts = true;
static bool gEnableDefaultMousePicking = true;
int gDebugDrawFlags = 0;
static bool pauseSimulation = false;
static bool singleStepSimulation = false;
int midiBaseIndex = 176;
extern bool gDisableDeactivation;
int gSharedMemoryKey = -1;
///some quick test variable for the OpenCL examples
int gPreferredOpenCLDeviceIndex = -1;
int gPreferredOpenCLPlatformIndex = -1;
int gGpuArraySizeX = 45;
int gGpuArraySizeY = 55;
int gGpuArraySizeZ = 45;
//#include <float.h>
//unsigned int fp_control_state = _controlfp(_EM_INEXACT, _MCW_EM);
void deleteDemo()
{
if (sCurrentDemo)
{
sCurrentDemo->exitPhysics();
s_instancingRenderer->removeAllInstances();
delete sCurrentDemo;
sCurrentDemo = 0;
delete s_guiHelper;
s_guiHelper = 0;
// CProfileManager::CleanupMemory();
}
}
const char* gPngFileName = 0;
int gPngSkipFrames = 0;
b3KeyboardCallback prevKeyboardCallback = 0;
void MyKeyboardCallback(int key, int state)
{
//b3Printf("key=%d, state=%d", key, state);
bool handled = false;
if (renderGui)
{
if (gui2 && !handled)
{
handled = gui2->keyboardCallback(key, state);
}
}
if (!handled && sCurrentDemo)
{
handled = sCurrentDemo->keyboardCallback(key, state);
}
//checkout: is it desired to ignore keys, if the demo already handles them?
//if (handled)
// return;
if (gEnableDefaultKeyboardShortcuts)
{
if (key == 'a' && state)
{
gDebugDrawFlags ^= btIDebugDraw::DBG_DrawAabb;
}
if (key == 'c' && state)
{
gDebugDrawFlags ^= btIDebugDraw::DBG_DrawContactPoints;
}
if (key == 'd' && state)
{
gDebugDrawFlags ^= btIDebugDraw::DBG_NoDeactivation;
gDisableDeactivation = ((gDebugDrawFlags & btIDebugDraw::DBG_NoDeactivation) != 0);
}
if (key == 'j' && state)
{
gDebugDrawFlags ^= btIDebugDraw::DBG_DrawFrames;
}
if (key == 'k' && state)
{
gDebugDrawFlags ^= btIDebugDraw::DBG_DrawConstraints;
}
if (key == 'l' && state)
{
gDebugDrawFlags ^= btIDebugDraw::DBG_DrawConstraintLimits;
}
if (key == 'w' && state)
{
visualWireframe = !visualWireframe;
gDebugDrawFlags ^= btIDebugDraw::DBG_DrawWireframe;
}
if (key == 'v' && state)
{
renderVisualGeometry = !renderVisualGeometry;
}
if (key == 'g' && state)
{
renderGrid = !renderGrid;
renderGui = !renderGui;
}
if (key == 'i' && state)
{
pauseSimulation = !pauseSimulation;
}
if (key == 'o' && state)
{
singleStepSimulation = true;
}
if (key == 'p')
{
if (state)
{
b3ChromeUtilsStartTimings();
}
else
{
#ifdef _WIN32
b3ChromeUtilsStopTimingsAndWriteJsonFile("timings");
#else
b3ChromeUtilsStopTimingsAndWriteJsonFile("/tmp/timings");
#endif
}
}
#ifndef NO_OPENGL3
if (key == 's' && state)
{
useShadowMap = !useShadowMap;
}
#endif
if (key == B3G_F1)
{
static int count = 0;
if (state)
{
b3Printf("F1 pressed %d", count++);
if (gPngFileName)
{
b3Printf("disable image dump");
gPngFileName = 0;
}
else
{
gPngFileName = gAllExamples->getExampleName(sCurrentDemoIndex);
b3Printf("enable image dump %s", gPngFileName);
}
}
else
{
b3Printf("F1 released %d", count++);
}
}
}
if (key == B3G_ESCAPE && s_window)
{
s_window->setRequestExit();
}
if (prevKeyboardCallback)
prevKeyboardCallback(key, state);
}
b3MouseMoveCallback prevMouseMoveCallback = 0;
static void MyMouseMoveCallback(float x, float y)
{
bool handled = false;
if (sCurrentDemo)
handled = sCurrentDemo->mouseMoveCallback(x, y);
if (renderGui)
{
if (!handled && gui2)
handled = gui2->mouseMoveCallback(x, y);
}
if (!handled)
{
if (prevMouseMoveCallback)
prevMouseMoveCallback(x, y);
}
}
b3MouseButtonCallback prevMouseButtonCallback = 0;
static void MyMouseButtonCallback(int button, int state, float x, float y)
{
bool handled = false;
//try picking first
if (sCurrentDemo)
handled = sCurrentDemo->mouseButtonCallback(button, state, x, y);
if (renderGui)
{
if (!handled && gui2)
handled = gui2->mouseButtonCallback(button, state, x, y);
}
if (!handled)
{
if (prevMouseButtonCallback)
prevMouseButtonCallback(button, state, x, y);
}
// b3DefaultMouseButtonCallback(button,state,x,y);
}
#include <string.h>
struct FileImporterByExtension
{
std::string m_extension;
CommonExampleInterface::CreateFunc* m_createFunc;
};
static btAlignedObjectArray<FileImporterByExtension> gFileImporterByExtension;
void OpenGLExampleBrowser::registerFileImporter(const char* extension, CommonExampleInterface::CreateFunc* createFunc)
{
FileImporterByExtension fi;
fi.m_extension = extension;
fi.m_createFunc = createFunc;
gFileImporterByExtension.push_back(fi);
}
#include "../SharedMemory/SharedMemoryPublic.h"
void OpenGLExampleBrowserVisualizerFlagCallback(int flag, bool enable)
{
if (flag == COV_ENABLE_Y_AXIS_UP)
{
//either Y = up or Z
int upAxis = enable ? 1 : 2;
s_app->setUpAxis(upAxis);
}
if (flag == COV_ENABLE_RENDERING)
{
gEnableRenderLoop = (enable != 0);
}
if (flag == COV_ENABLE_SINGLE_STEP_RENDERING)
{
if (enable)
{
gEnableRenderLoop = false;
singleStepSimulation = true;
}
else
{
gEnableRenderLoop = true;
singleStepSimulation = false;
}
}
if (flag == COV_ENABLE_SHADOWS)
{
useShadowMap = enable;
}
if (flag == COV_ENABLE_GUI)
{
renderGui = enable;
renderGrid = enable;
}
if (flag == COV_ENABLE_KEYBOARD_SHORTCUTS)
{
gEnableDefaultKeyboardShortcuts = enable;
}
if (flag == COV_ENABLE_MOUSE_PICKING)
{
gEnableDefaultMousePicking = enable;
}
if (flag == COV_ENABLE_WIREFRAME)
{
visualWireframe = enable;
if (visualWireframe)
{
gDebugDrawFlags |= btIDebugDraw::DBG_DrawWireframe;
}
else
{
gDebugDrawFlags &= ~btIDebugDraw::DBG_DrawWireframe;
}
}
}
void openFileDemo(const char* filename)
{
deleteDemo();
s_guiHelper = new OpenGLGuiHelper(s_app, sUseOpenGL2);
s_guiHelper->setVisualizerFlagCallback(OpenGLExampleBrowserVisualizerFlagCallback);
s_parameterInterface->removeAllParameters();
CommonExampleOptions options(s_guiHelper, 1);
options.m_fileName = filename;
char fullPath[1024];
sprintf(fullPath, "%s", filename);
b3FileUtils::toLower(fullPath);
for (int i = 0; i < gFileImporterByExtension.size(); i++)
{
if (strstr(fullPath, gFileImporterByExtension[i].m_extension.c_str()))
{
sCurrentDemo = gFileImporterByExtension[i].m_createFunc(options);
}
}
if (sCurrentDemo)
{
sCurrentDemo->initPhysics();
sCurrentDemo->resetCamera();
}
}
void selectDemo(int demoIndex)
{
bool resetCamera = (sCurrentDemoIndex != demoIndex);
sCurrentDemoIndex = demoIndex;
sCurrentHightlighted = demoIndex;
int numDemos = gAllExamples->getNumRegisteredExamples();
if (demoIndex > numDemos)
{
demoIndex = 0;
}
deleteDemo();
CommonExampleInterface::CreateFunc* func = gAllExamples->getExampleCreateFunc(demoIndex);
if (func)
{
if (s_parameterInterface)
{
s_parameterInterface->removeAllParameters();
}
int option = gAllExamples->getExampleOption(demoIndex);
s_guiHelper = new OpenGLGuiHelper(s_app, sUseOpenGL2);
s_guiHelper->setVisualizerFlagCallback(OpenGLExampleBrowserVisualizerFlagCallback);
CommonExampleOptions options(s_guiHelper, option);
options.m_sharedMem = sSharedMem;
sCurrentDemo = (*func)(options);
if (sCurrentDemo)
{
if (gui2)
{
gui2->setStatusBarMessage("Status: OK", false);
}
b3Printf("Selected demo: %s", gAllExamples->getExampleName(demoIndex));
if (gui2)
{
gui2->setExampleDescription(gAllExamples->getExampleDescription(demoIndex));
}
sCurrentDemo->initPhysics();
if (resetCamera)
{
sCurrentDemo->resetCamera();
}
}
}
}
#include <stdio.h>
static void saveCurrentSettings(int currentEntry, const char* startFileName)
{
FILE* f = fopen(startFileName, "w");
if (f)
{
fprintf(f, "--start_demo_name=%s\n", gAllExamples->getExampleName(sCurrentDemoIndex));
fprintf(f, "--mouse_move_multiplier=%f\n", s_app->getMouseMoveMultiplier());
fprintf(f, "--mouse_wheel_multiplier=%f\n", s_app->getMouseWheelMultiplier());
float red, green, blue;
s_app->getBackgroundColor(&red, &green, &blue);
fprintf(f, "--background_color_red= %f\n", red);
fprintf(f, "--background_color_green= %f\n", green);
fprintf(f, "--background_color_blue= %f\n", blue);
fprintf(f, "--fixed_timestep= %f\n", gFixedTimeStep);
if (!gAllowRetina)
{
fprintf(f, "--disable_retina");
}
if (enable_experimental_opencl)
{
fprintf(f, "--enable_experimental_opencl\n");
}
// if (sUseOpenGL2 )
// {
// fprintf(f,"--opengl2\n");
// }
fclose(f);
}
};
static void loadCurrentSettings(const char* startFileName, b3CommandLineArgs& args)
{
//int currentEntry= 0;
FILE* f = fopen(startFileName, "r");
if (f)
{
char oneline[1024];
char* argv[] = {0, &oneline[0]};
while (fgets(oneline, 1024, f) != NULL)
{
char* pos;
if ((pos = strchr(oneline, '\n')) != NULL)
*pos = '\0';
args.addArgs(2, argv);
}
fclose(f);
}
};
void MyComboBoxCallback(int comboId, const char* item)
{
//printf("comboId = %d, item = %s\n",comboId, item);
if (comboId == DEMO_SELECTION_COMBOBOX)
{
//find selected item
for (int i = 0; i < allNames.size(); i++)
{
if (strcmp(item, allNames[i]) == 0)
{
selectDemo(i);
saveCurrentSettings(sCurrentDemoIndex, startFileName);
break;
}
}
}
}
//in case of multi-threading, don't submit messages while the GUI is rendering (causing crashes)
static bool gBlockGuiMessages = false;
void MyGuiPrintf(const char* msg)
{
printf("b3Printf: %s\n", msg);
if (!gDisableDemoSelection && !gBlockGuiMessages)
{
gui2->textOutput(msg);
gui2->forceUpdateScrollBars();
}
}
void MyStatusBarPrintf(const char* msg)
{
printf("b3Printf: %s\n", msg);
if (!gDisableDemoSelection && !gBlockGuiMessages)
{
bool isLeft = true;
gui2->setStatusBarMessage(msg, isLeft);
}
}
void MyStatusBarError(const char* msg)
{
printf("Warning: %s\n", msg);
if (!gDisableDemoSelection && !gBlockGuiMessages)
{
bool isLeft = false;
gui2->setStatusBarMessage(msg, isLeft);
gui2->textOutput(msg);
gui2->forceUpdateScrollBars();
}
btAssert(0);
}
struct MyMenuItemHander : public Gwen::Event::Handler
{
int m_buttonId;
MyMenuItemHander(int buttonId)
: m_buttonId(buttonId)
{
}
void onButtonA(Gwen::Controls::Base* pControl)
{
//const Gwen::String& name = pControl->GetName();
Gwen::Controls::TreeNode* node = (Gwen::Controls::TreeNode*)pControl;
// Gwen::Controls::Label* l = node->GetButton();
Gwen::UnicodeString la = node->GetButton()->GetText(); // node->GetButton()->GetName();// GetText();
Gwen::String laa = Gwen::Utility::UnicodeToString(la);
// const char* ha = laa.c_str();
//printf("selected %s\n", ha);
//int dep = but->IsDepressed();
//int tog = but->GetToggleState();
// if (m_data->m_toggleButtonCallback)
// (*m_data->m_toggleButtonCallback)(m_buttonId, tog);
}
void onButtonB(Gwen::Controls::Base* pControl)
{
Gwen::Controls::Label* label = (Gwen::Controls::Label*)pControl;
Gwen::UnicodeString la = label->GetText(); // node->GetButton()->GetName();// GetText();
Gwen::String laa = Gwen::Utility::UnicodeToString(la);
//const char* ha = laa.c_str();
if (!gDisableDemoSelection)
{
selectDemo(sCurrentHightlighted);
saveCurrentSettings(sCurrentDemoIndex, startFileName);
}
}
void onButtonC(Gwen::Controls::Base* pControl)
{
/*Gwen::Controls::Label* label = (Gwen::Controls::Label*) pControl;
Gwen::UnicodeString la = label->GetText();// node->GetButton()->GetName();// GetText();
Gwen::String laa = Gwen::Utility::UnicodeToString(la);
const char* ha = laa.c_str();
printf("onButtonC ! %s\n", ha);
*/
}
void onButtonD(Gwen::Controls::Base* pControl)
{
/* Gwen::Controls::Label* label = (Gwen::Controls::Label*) pControl;
Gwen::UnicodeString la = label->GetText();// node->GetButton()->GetName();// GetText();
Gwen::String laa = Gwen::Utility::UnicodeToString(la);
const char* ha = laa.c_str();
*/
// printf("onKeyReturn ! \n");
if (!gDisableDemoSelection)
{
selectDemo(sCurrentHightlighted);
saveCurrentSettings(sCurrentDemoIndex, startFileName);
}
}
void onButtonE(Gwen::Controls::Base* pControl)
{
// printf("select %d\n",m_buttonId);
sCurrentHightlighted = m_buttonId;
gui2->setExampleDescription(gAllExamples->getExampleDescription(sCurrentHightlighted));
}
void onButtonF(Gwen::Controls::Base* pControl)
{
//printf("selection changed!\n");
}
void onButtonG(Gwen::Controls::Base* pControl)
{
//printf("onButtonG !\n");
}
};
void quitCallback()
{
s_window->setRequestExit();
}
void fileOpenCallback()
{
char filename[1024];
int len = s_window->fileOpenDialog(filename, 1024);
if (len)
{
//todo(erwincoumans) check if it is actually URDF
//printf("file open:%s\n", filename);
openFileDemo(filename);
}
}
#define MAX_GRAPH_WINDOWS 5
struct QuickCanvas : public Common2dCanvasInterface
{
GL3TexLoader* m_myTexLoader;
MyGraphWindow* m_gw[MAX_GRAPH_WINDOWS];
GraphingTexture* m_gt[MAX_GRAPH_WINDOWS];
int m_curNumGraphWindows;
QuickCanvas(GL3TexLoader* myTexLoader)
: m_myTexLoader(myTexLoader),
m_curNumGraphWindows(0)
{
for (int i = 0; i < MAX_GRAPH_WINDOWS; i++)
{
m_gw[i] = 0;
m_gt[i] = 0;
}
}
virtual ~QuickCanvas() {}
virtual int createCanvas(const char* canvasName, int width, int height, int xPos, int yPos)
{
if (m_curNumGraphWindows < MAX_GRAPH_WINDOWS)
{
//find a slot
int slot = m_curNumGraphWindows;
btAssert(slot < MAX_GRAPH_WINDOWS);
if (slot >= MAX_GRAPH_WINDOWS)
return 0; //don't crash
m_curNumGraphWindows++;
MyGraphInput input(gui2->getInternalData());
input.m_width = width;
input.m_height = height;
input.m_xPos = xPos;
input.m_yPos = yPos;
input.m_name = canvasName;
input.m_texName = canvasName;
m_gt[slot] = new GraphingTexture;
m_gt[slot]->create(width, height);
int texId = m_gt[slot]->getTextureId();
m_myTexLoader->m_hashMap.insert(canvasName, texId);
m_gw[slot] = setupTextureWindow(input);
return slot;
}
return -1;
}
virtual void destroyCanvas(int canvasId)
{
btAssert(canvasId >= 0);
delete m_gt[canvasId];
m_gt[canvasId] = 0;
destroyTextureWindow(m_gw[canvasId]);
m_gw[canvasId] = 0;
m_curNumGraphWindows--;
}
virtual void setPixel(int canvasId, int x, int y, unsigned char red, unsigned char green, unsigned char blue, unsigned char alpha)
{
btAssert(canvasId >= 0);
btAssert(canvasId < m_curNumGraphWindows);
m_gt[canvasId]->setPixel(x, y, red, green, blue, alpha);
}
virtual void getPixel(int canvasId, int x, int y, unsigned char& red, unsigned char& green, unsigned char& blue, unsigned char& alpha)
{
btAssert(canvasId >= 0);
btAssert(canvasId < m_curNumGraphWindows);
m_gt[canvasId]->getPixel(x, y, red, green, blue, alpha);
}
virtual void refreshImageData(int canvasId)
{
m_gt[canvasId]->uploadImageData();
}
};
OpenGLExampleBrowser::OpenGLExampleBrowser(class ExampleEntries* examples)
{
m_internalData = new OpenGLExampleBrowserInternalData;
gAllExamples = examples;
}
OpenGLExampleBrowser::~OpenGLExampleBrowser()
{
deleteDemo();
for (int i = 0; i < m_internalData->m_nodes.size(); i++)
{
delete m_internalData->m_nodes[i];
}
delete m_internalData->m_handler2;
for (int i = 0; i < m_internalData->m_handlers.size(); i++)
{
delete m_internalData->m_handlers[i];
}
m_internalData->m_handlers.clear();
m_internalData->m_nodes.clear();
delete s_parameterInterface;
s_parameterInterface = 0;
delete s_app->m_2dCanvasInterface;
s_app->m_2dCanvasInterface = 0;
#ifndef BT_NO_PROFILE
destroyProfileWindow(m_internalData->m_profWindow);
#endif
m_internalData->m_gui->exit();
delete m_internalData->m_gui;
delete m_internalData->m_gwenRenderer;
delete m_internalData->m_myTexLoader;
delete m_internalData->m_app;
s_app = 0;
delete m_internalData;
gFileImporterByExtension.clear();
gAllExamples = 0;
}
#include "EmptyExample.h"
bool OpenGLExampleBrowser::init(int argc, char* argv[])
{
b3CommandLineArgs args(argc, argv);
loadCurrentSettings(startFileName, args);
if (args.CheckCmdLineFlag("nogui"))
{
renderGrid = false;
renderGui = false;
}
if (args.CheckCmdLineFlag("tracing"))
{
b3ChromeUtilsStartTimings();
}
args.GetCmdLineArgument("fixed_timestep", gFixedTimeStep);
args.GetCmdLineArgument("png_skip_frames", gPngSkipFrames);
///The OpenCL rigid body pipeline is experimental and
///most OpenCL drivers and OpenCL compilers have issues with our kernels.
///If you have a high-end desktop GPU such as AMD 7970 or better, or NVIDIA GTX 680 with up-to-date drivers
///you could give it a try
///Note that several old OpenCL physics examples still have to be ported over to this new Example Browser
if (args.CheckCmdLineFlag("enable_experimental_opencl"))
{
enable_experimental_opencl = true;
gAllExamples->initOpenCLExampleEntries();
}
if (args.CheckCmdLineFlag("disable_retina"))
{
gAllowRetina = false;
}
int width = 1024;
int height = 768;
if (args.CheckCmdLineFlag("width"))
{
args.GetCmdLineArgument("width", width);
}
if (args.CheckCmdLineFlag("height"))
{
args.GetCmdLineArgument("height", height);
}
#ifndef NO_OPENGL3
SimpleOpenGL3App* simpleApp = 0;
sUseOpenGL2 = args.CheckCmdLineFlag("opengl2");
args.GetCmdLineArgument("render_device", gRenderDevice);
args.GetCmdLineArgument("window_backend", gWindowBackend);
#else
sUseOpenGL2 = true;
#endif
const char* appTitle = "Bullet Physics ExampleBrowser";
#if defined(_DEBUG) || defined(DEBUG)
const char* optMode = "Debug build (slow)";
#else
const char* optMode = "Release build";
#endif
#ifdef B3_USE_GLFW
const char* glContext = "[glfw]";
#else
const char* glContext = "[btgl]";
#endif
if (sUseOpenGL2)
{
char title[1024];
sprintf(title, "%s using limited OpenGL2 fallback %s %s", appTitle, glContext, optMode);
s_app = new SimpleOpenGL2App(title, width, height);
s_app->m_renderer = new SimpleOpenGL2Renderer(width, height);
}
#ifndef NO_OPENGL3
else
{
char title[1024];
sprintf(title, "%s using OpenGL3+ %s %s", appTitle, glContext, optMode);
simpleApp = new SimpleOpenGL3App(title, width, height, gAllowRetina, gWindowBackend, gRenderDevice);
s_app = simpleApp;
}
#endif
m_internalData->m_app = s_app;
char* gVideoFileName = 0;
args.GetCmdLineArgument("mp4", gVideoFileName);
int gVideoFps = 0;
args.GetCmdLineArgument("mp4fps", gVideoFps);
if (gVideoFps)
{
simpleApp->setMp4Fps(gVideoFps);
}
#ifndef NO_OPENGL3
if (gVideoFileName)
simpleApp->dumpFramesToVideo(gVideoFileName);
#endif
s_instancingRenderer = s_app->m_renderer;
s_window = s_app->m_window;
width = s_window->getWidth();
height = s_window->getHeight();
prevMouseMoveCallback = s_window->getMouseMoveCallback();
s_window->setMouseMoveCallback(MyMouseMoveCallback);
prevMouseButtonCallback = s_window->getMouseButtonCallback();
s_window->setMouseButtonCallback(MyMouseButtonCallback);
prevKeyboardCallback = s_window->getKeyboardCallback();
s_window->setKeyboardCallback(MyKeyboardCallback);
s_app->m_renderer->getActiveCamera()->setCameraDistance(13);
s_app->m_renderer->getActiveCamera()->setCameraPitch(0);
s_app->m_renderer->getActiveCamera()->setCameraTargetPosition(0, 0, 0);
float mouseMoveMult = s_app->getMouseMoveMultiplier();
if (args.GetCmdLineArgument("mouse_move_multiplier", mouseMoveMult))
{
s_app->setMouseMoveMultiplier(mouseMoveMult);
}
float mouseWheelMult = s_app->getMouseWheelMultiplier();
if (args.GetCmdLineArgument("mouse_wheel_multiplier", mouseWheelMult))
{
s_app->setMouseWheelMultiplier(mouseWheelMult);
}
args.GetCmdLineArgument("shared_memory_key", gSharedMemoryKey);
float red, green, blue;
s_app->getBackgroundColor(&red, &green, &blue);
args.GetCmdLineArgument("background_color_red", red);
args.GetCmdLineArgument("background_color_green", green);
args.GetCmdLineArgument("background_color_blue", blue);
s_app->setBackgroundColor(red, green, blue);
b3SetCustomWarningMessageFunc(MyGuiPrintf);
b3SetCustomPrintfFunc(MyGuiPrintf);
b3SetCustomErrorMessageFunc(MyStatusBarError);
assert(glGetError() == GL_NO_ERROR);
{
GL3TexLoader* myTexLoader = new GL3TexLoader;
m_internalData->m_myTexLoader = myTexLoader;
if (sUseOpenGL2)
{
m_internalData->m_gwenRenderer = new Gwen::Renderer::OpenGL_DebugFont(s_window->getRetinaScale());
}
#ifndef NO_OPENGL3
else
{
sth_stash* fontstash = simpleApp->getFontStash();
m_internalData->m_gwenRenderer = new GwenOpenGL3CoreRenderer(simpleApp->m_primRenderer, fontstash, width, height, s_window->getRetinaScale(), myTexLoader);
}
#endif
gui2 = new GwenUserInterface;
m_internalData->m_gui = gui2;
m_internalData->m_myTexLoader = myTexLoader;
gui2->init(width, height, m_internalData->m_gwenRenderer, s_window->getRetinaScale());
}
//gui = 0;// new GwenUserInterface;
GL3TexLoader* myTexLoader = m_internalData->m_myTexLoader;
// = myTexLoader;
//
if (gui2)
{
// gui->getInternalData()->m_explorerPage
Gwen::Controls::TreeControl* tree = gui2->getInternalData()->m_explorerTreeCtrl;
//gui->getInternalData()->pRenderer->setTextureLoader(myTexLoader);
#ifndef BT_NO_PROFILE
s_profWindow = setupProfileWindow(gui2->getInternalData());
m_internalData->m_profWindow = s_profWindow;
profileWindowSetVisible(s_profWindow, false);
#endif //BT_NO_PROFILE
gui2->setFocus();
s_parameterInterface = s_app->m_parameterInterface = new GwenParameterInterface(gui2->getInternalData());
s_app->m_2dCanvasInterface = new QuickCanvas(myTexLoader);
///add some demos to the gAllExamples
int numDemos = gAllExamples->getNumRegisteredExamples();
//char nodeText[1024];
//int curDemo = 0;
int selectedDemo = 0;
Gwen::Controls::TreeNode* curNode = tree;
m_internalData->m_handler2 = new MyMenuItemHander(-1);
char* demoNameFromCommandOption = 0;
args.GetCmdLineArgument("start_demo_name", demoNameFromCommandOption);
if (demoNameFromCommandOption)
{
selectedDemo = -1;
}
tree->onReturnKeyDown.Add(m_internalData->m_handler2, &MyMenuItemHander::onButtonD);
int firstAvailableDemoIndex = -1;
Gwen::Controls::TreeNode* firstNode = 0;
for (int d = 0; d < numDemos; d++)
{
// sprintf(nodeText, "Node %d", i);
Gwen::UnicodeString nodeUText = Gwen::Utility::StringToUnicode(gAllExamples->getExampleName(d));
if (gAllExamples->getExampleCreateFunc(d)) //was test for gAllExamples[d].m_menuLevel==1
{
Gwen::Controls::TreeNode* pNode = curNode->AddNode(nodeUText);
if (firstAvailableDemoIndex < 0)
{
firstAvailableDemoIndex = d;
firstNode = pNode;
}
if (d == selectedDemo)
{
firstAvailableDemoIndex = d;
firstNode = pNode;
//pNode->SetSelected(true);
//tree->ExpandAll();
// tree->ForceUpdateScrollBars();
//tree->OnKeyLeft(true);
// tree->OnKeyRight(true);
//tree->ExpandAll();
// selectDemo(d);
}
if (demoNameFromCommandOption)
{
const char* demoName = gAllExamples->getExampleName(d);
int res = strcmp(demoName, demoNameFromCommandOption);
if (res == 0)
{
firstAvailableDemoIndex = d;
firstNode = pNode;
}
}
#if 1
MyMenuItemHander* handler = new MyMenuItemHander(d);
m_internalData->m_handlers.push_back(handler);
pNode->onNamePress.Add(handler, &MyMenuItemHander::onButtonA);
pNode->GetButton()->onDoubleClick.Add(handler, &MyMenuItemHander::onButtonB);
pNode->GetButton()->onDown.Add(handler, &MyMenuItemHander::onButtonC);
pNode->onSelect.Add(handler, &MyMenuItemHander::onButtonE);
pNode->onReturnKeyDown.Add(handler, &MyMenuItemHander::onButtonG);
pNode->onSelectChange.Add(handler, &MyMenuItemHander::onButtonF);
#endif
// pNode->onKeyReturn.Add(handler, &MyMenuItemHander::onButtonD);
// pNode->GetButton()->onKeyboardReturn.Add(handler, &MyMenuItemHander::onButtonD);
// pNode->onNamePress.Add(handler, &MyMenuItemHander::onButtonD);
// pNode->onKeyboardPressed.Add(handler, &MyMenuItemHander::onButtonD);
// pNode->OnKeyPress
}
else
{
curNode = tree->AddNode(nodeUText);
m_internalData->m_nodes.push_back(curNode);
}
}
if (sCurrentDemo == 0)
{
if (firstAvailableDemoIndex >= 0)
{
firstNode->SetSelected(true);
while (firstNode != tree)
{
firstNode->ExpandAll();
firstNode = (Gwen::Controls::TreeNode*)firstNode->GetParent();
}
selectDemo(firstAvailableDemoIndex);
}
}
free(demoNameFromCommandOption);
demoNameFromCommandOption = 0;
btAssert(sCurrentDemo != 0);
if (sCurrentDemo == 0)
{
printf("Error, no demo/example\n");
exit(0);
}
gui2->registerFileOpenCallback(fileOpenCallback);
gui2->registerQuitCallback(quitCallback);
}
return true;
}
CommonExampleInterface* OpenGLExampleBrowser::getCurrentExample()
{
btAssert(sCurrentDemo);
return sCurrentDemo;
}
bool OpenGLExampleBrowser::requestedExit()
{
return s_window->requestedExit();
}
void OpenGLExampleBrowser::updateGraphics()
{
if (sCurrentDemo)
{
if (!pauseSimulation || singleStepSimulation)
{
//B3_PROFILE("sCurrentDemo->updateGraphics");
sCurrentDemo->updateGraphics();
}
}
}
void OpenGLExampleBrowser::update(float deltaTime)
{
b3ChromeUtilsEnableProfiling();
if (!gEnableRenderLoop && !singleStepSimulation)
{
B3_PROFILE("updateGraphics");
sCurrentDemo->updateGraphics();
return;
}
B3_PROFILE("OpenGLExampleBrowser::update");
//assert(glGetError() == GL_NO_ERROR);
{
B3_PROFILE("s_instancingRenderer");
s_instancingRenderer->init();
}
DrawGridData dg;
dg.upAxis = s_app->getUpAxis();
{
BT_PROFILE("Update Camera and Light");
s_instancingRenderer->updateCamera(dg.upAxis);
}
static int frameCount = 0;
frameCount++;
if (0)
{
BT_PROFILE("Draw frame counter");
char bla[1024];
sprintf(bla, "Frame %d", frameCount);
s_app->drawText(bla, 10, 10);
}
if (gPngFileName)
{
static int skip = 0;
skip--;
if (skip < 0)
{
skip = gPngSkipFrames;
//printf("gPngFileName=%s\n",gPngFileName);
static int s_frameCount = 0;
sprintf(staticPngFileName, "%s%d.png", gPngFileName, s_frameCount++);
//b3Printf("Made screenshot %s",staticPngFileName);
s_app->dumpNextFrameToPng(staticPngFileName);
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
}
}
if (sCurrentDemo)
{
if (!pauseSimulation || singleStepSimulation)
{
//printf("---------------------------------------------------\n");
//printf("Framecount = %d\n",frameCount);
B3_PROFILE("sCurrentDemo->stepSimulation");
if (gFixedTimeStep > 0)
{
sCurrentDemo->stepSimulation(gFixedTimeStep);
}
else
{
sCurrentDemo->stepSimulation(deltaTime); //1./60.f);
}
}
if (renderGrid)
{
BT_PROFILE("Draw Grid");
//glPolygonOffset(3.0, 3);
//glEnable(GL_POLYGON_OFFSET_FILL);
s_app->drawGrid(dg);
}
if (renderVisualGeometry && ((gDebugDrawFlags & btIDebugDraw::DBG_DrawWireframe) == 0))
{
if (visualWireframe)
{
glPolygonMode(GL_FRONT_AND_BACK, GL_LINE);
}
BT_PROFILE("Render Scene");
sCurrentDemo->renderScene();
}
else
{
B3_PROFILE("physicsDebugDraw");
glPolygonMode(GL_FRONT_AND_BACK, GL_FILL);
sCurrentDemo->physicsDebugDraw(gDebugDrawFlags);
}
}
{
if (gui2 && s_guiHelper && s_guiHelper->getRenderInterface() && s_guiHelper->getRenderInterface()->getActiveCamera())
{
B3_PROFILE("setStatusBarMessage");
char msg[1024];
float camDist = s_guiHelper->getRenderInterface()->getActiveCamera()->getCameraDistance();
float pitch = s_guiHelper->getRenderInterface()->getActiveCamera()->getCameraPitch();
float yaw = s_guiHelper->getRenderInterface()->getActiveCamera()->getCameraYaw();
float camTarget[3];
float camPos[3];
s_guiHelper->getRenderInterface()->getActiveCamera()->getCameraPosition(camPos);
s_guiHelper->getRenderInterface()->getActiveCamera()->getCameraTargetPosition(camTarget);
sprintf(msg, "camTargetPos=%2.2f,%2.2f,%2.2f, dist=%2.2f, pitch=%2.2f, yaw=%2.2f", camTarget[0], camTarget[1], camTarget[2], camDist, pitch, yaw);
gui2->setStatusBarMessage(msg, true);
}
}
static int toggle = 1;
if (renderGui)
{
B3_PROFILE("renderGui");
#ifndef BT_NO_PROFILE
if (!pauseSimulation || singleStepSimulation)
{
if (isProfileWindowVisible(s_profWindow))
{
processProfileData(s_profWindow, false);
}
}
#endif //#ifndef BT_NO_PROFILE
{
B3_PROFILE("updateOpenGL");
if (sUseOpenGL2)
{
saveOpenGLState(s_instancingRenderer->getScreenWidth() * s_window->getRetinaScale(), s_instancingRenderer->getScreenHeight() * s_window->getRetinaScale());
}
if (m_internalData->m_gui)
{
gBlockGuiMessages = true;
m_internalData->m_gui->draw(s_instancingRenderer->getScreenWidth(), s_instancingRenderer->getScreenHeight());
gBlockGuiMessages = false;
}
if (sUseOpenGL2)
{
restoreOpenGLState();
}
}
}
singleStepSimulation = false;
toggle = 1 - toggle;
{
BT_PROFILE("Sync Parameters");
if (s_parameterInterface)
{
s_parameterInterface->syncParameters();
}
}
{
BT_PROFILE("Swap Buffers");
s_app->swapBuffer();
}
if (gui2)
{
B3_PROFILE("forceUpdateScrollBars");
gui2->forceUpdateScrollBars();
}
}
void OpenGLExampleBrowser::setSharedMemoryInterface(class SharedMemoryInterface* sharedMem)
{
gDisableDemoSelection = true;
sSharedMem = sharedMem;
}
| [
"noreply@github.com"
] | noreply@github.com |
1372466a2ca5dd2ff36e42156a8aaff39e97c72c | b6414f6d07063c6ee8927a829110bdb299c88c74 | /SmallExplosion.h | d3999dc2f5be958e14ae3c072c6dc2245b4616f1 | [] | no_license | 8Observer8/Tanks | 041d08b4bca61efc021d31304409bfa3d37ecb36 | 6c59d9b9d84c1f4d61eaecb624b41238c502dfaa | refs/heads/master | 2020-05-27T16:00:06.277467 | 2015-01-13T14:08:57 | 2015-01-13T14:08:57 | 28,709,990 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,412 | h | /*
The Game Tanks
Copyright (C) 2014 Enzhaev Ivan
Email: 8observer8@gmail.com
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef SMALLEXPLOSION_H
#define SMALLEXPLOSION_H
#include <QTimer>
#include <QObject>
#include "Plane.h"
#include <vector>
class SmallExplosion : public QObject, public Plane
{
Q_OBJECT
public:
SmallExplosion( QOpenGLShaderProgram *program, int vertexAttr,
int textureAttr, int textureUniform );
~SmallExplosion();
void start();
signals:
void signalShowSmallExplosion( bool show );
private slots:
void slotShowSmallExplosion();
private:
void genTextures();
std::vector<QOpenGLTexture*> m_textures;
QTimer m_timer;
};
#endif // SMALLEXPLOSION_H
| [
"8observer8@gmail.com"
] | 8observer8@gmail.com |
bf44a4f2be5c574ab693689e723ade6b233218f6 | 02fec111191ecede92d844422125ac8482171bde | /CodCad/CodCad-QuadradoMagico.cpp | cfbee6f343af67eb22155d3d819be1db1a36cc75 | [] | no_license | Lucas3H/Maratona | 475825b249659e376a1f63a6b3b6a1e15c0d4287 | 97a2e2a91fb60243124fc2ffb4193e1b72924c3c | refs/heads/master | 2020-11-24T18:35:24.456960 | 2020-11-06T14:00:56 | 2020-11-06T14:00:56 | 228,292,025 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 618 | cpp | #include<iostream>
using namespace std;
int main(){
int soma=0, n, var=0;
int q[10][10];
bool x=1;
cin>>n;
for(int i=0; i<n; i++){
for(int j=0; j<n; j++){
cin>>q[i][j];
}
}
for(int i=0; i<n; i++){
soma+=q[i][n-1-i];
var+=q[i][i];
}
if(soma!=var){
x=0;
}
for(int i=0; i<n; i++){
var=0;
for(int j=0; j<n; j++){
var+=q[i][j];
}
if(soma!=var){
x=0;
}
}
for(int i=0; i<n; i++){
var=0;
for(int j=0; j<n; j++){
var+=q[j][i];
}
if(soma!=var){
x=0;
}
}
if(x==0){
cout<<-1;
}
else{
cout<<soma;
}
}
| [
"lucashhh@usp.br"
] | lucashhh@usp.br |
d2678f0a97ed507c80e486e28cdce41633b5b7c7 | 8ed61980185397f8a11ad5851e3ffff09682c501 | /thirdparty/GeometricTools/WildMagic5/LibMathematics/Rational/Wm5IVector.inl | 734c5c1e29c1aaccd89f543ceed475abb7129388 | [
"BSD-2-Clause-Views"
] | permissive | SoMa-Project/vision | 8975a2b368f69538a05bd57b0c3eda553b783b55 | ea8199d98edc363b2be79baa7c691da3a5a6cc86 | refs/heads/melodic | 2023-04-12T22:49:13.125788 | 2021-01-11T15:28:30 | 2021-01-11T15:28:30 | 80,823,825 | 1 | 0 | NOASSERTION | 2021-04-20T21:27:03 | 2017-02-03T11:36:44 | C++ | UTF-8 | C++ | false | false | 7,422 | inl | // Geometric Tools, LLC
// Copyright (c) 1998-2014
// Distributed under the Boost Software License, Version 1.0.
// http://www.boost.org/LICENSE_1_0.txt
// http://www.geometrictools.com/License/Boost/LICENSE_1_0.txt
//
// File Version: 5.0.1 (2011/03/27)
//----------------------------------------------------------------------------
template <int VSIZE>
IVector<VSIZE>::IVector ()
{
// For efficiency in construction of large arrays of vectors, the
// default constructor does not initialize the vector.
}
//----------------------------------------------------------------------------
template <int VSIZE>
IVector<VSIZE>::IVector (const IVector& vec)
{
for (int i = 0; i < VSIZE; ++i)
{
mTuple[i] = vec.mTuple[i];
}
}
//----------------------------------------------------------------------------
template <int VSIZE>
inline IVector<VSIZE>::operator const int64_t* () const
{
return mTuple;
}
//----------------------------------------------------------------------------
template <int VSIZE>
inline IVector<VSIZE>::operator int64_t* ()
{
return mTuple;
}
//----------------------------------------------------------------------------
template <int VSIZE>
inline const int64_t& IVector<VSIZE>::operator[] (int i) const
{
assertion(0 <= i && i < VSIZE, "Invalid index\n");
return mTuple[i];
}
//----------------------------------------------------------------------------
template <int VSIZE>
inline int64_t& IVector<VSIZE>::operator[] (int i)
{
assertion(0 <= i && i < VSIZE, "Invalid index\n");
return mTuple[i];
}
//----------------------------------------------------------------------------
template <int VSIZE>
IVector<VSIZE>& IVector<VSIZE>::operator= (const IVector& vec)
{
for (int i = 0; i < VSIZE; ++i)
{
mTuple[i] = vec.mTuple[i];
}
return *this;
}
//----------------------------------------------------------------------------
template <int VSIZE>
bool IVector<VSIZE>::operator== (const IVector& vec) const
{
for (int i = 0; i < VSIZE; ++i)
{
if (mTuple[i] != vec.mTuple[i])
{
return false;
}
}
return true;
}
//----------------------------------------------------------------------------
template <int VSIZE>
bool IVector<VSIZE>::operator!= (const IVector& vec) const
{
return !operator==(vec);
}
//----------------------------------------------------------------------------
template <int VSIZE>
int IVector<VSIZE>::CompareArrays (const IVector& vec) const
{
for (int i = 0; i < VSIZE; ++i)
{
if (mTuple[i] < vec.mTuple[i])
{
return -1;
}
if (mTuple[i] > vec.mTuple[i])
{
return +1;
}
}
return 0;
}
//----------------------------------------------------------------------------
template <int VSIZE>
bool IVector<VSIZE>::operator< (const IVector& vec) const
{
return CompareArrays(vec) < 0;
}
//----------------------------------------------------------------------------
template <int VSIZE>
bool IVector<VSIZE>::operator<= (const IVector& vec) const
{
return CompareArrays(vec) <= 0;
}
//----------------------------------------------------------------------------
template <int VSIZE>
bool IVector<VSIZE>::operator> (const IVector& vec) const
{
return CompareArrays(vec) > 0;
}
//----------------------------------------------------------------------------
template <int VSIZE>
bool IVector<VSIZE>::operator>= (const IVector& vec) const
{
return CompareArrays(vec) >= 0;
}
//----------------------------------------------------------------------------
template <int VSIZE>
IVector<VSIZE> IVector<VSIZE>::operator+ (const IVector& vec) const
{
IVector<VSIZE> iSum;
for (int i = 0; i < VSIZE; ++i)
{
iSum.mTuple[i] = mTuple[i] + vec.mTuple[i];
}
return iSum;
}
//----------------------------------------------------------------------------
template <int VSIZE>
IVector<VSIZE> IVector<VSIZE>::operator- (const IVector& vec) const
{
IVector<VSIZE> diff;
for (int i = 0; i < VSIZE; ++i)
{
diff.mTuple[i] = mTuple[i] - vec.mTuple[i];
}
return diff;
}
//----------------------------------------------------------------------------
template <int VSIZE>
IVector<VSIZE> IVector<VSIZE>::operator* (const int64_t& scalar) const
{
IVector<VSIZE> prod;
for (int i = 0; i < VSIZE; ++i)
{
prod.mTuple[i] = scalar*mTuple[i];
}
return prod;
}
//----------------------------------------------------------------------------
template <int VSIZE>
IVector<VSIZE> IVector<VSIZE>::operator/ (const int64_t& scalar) const
{
assertion(scalar != 0, "Division by zero\n");
IVector<VSIZE> div;
for (int i = 0; i < VSIZE; ++i)
{
div.mTuple[i] = mTuple[i]/scalar;
}
return div;
}
//----------------------------------------------------------------------------
template <int VSIZE>
IVector<VSIZE> IVector<VSIZE>::operator- () const
{
IVector<VSIZE> neg;
for (int i = 0; i < VSIZE; ++i)
{
neg.mTuple[i] = -mTuple[i];
}
return neg;
}
//----------------------------------------------------------------------------
template <int VSIZE>
IVector<VSIZE> operator* (const int64_t& scalar, const IVector<VSIZE>& vec)
{
IVector<VSIZE> prod;
for (int i = 0; i < VSIZE; ++i)
{
prod[i] = scalar*vec[i];
}
return prod;
}
//----------------------------------------------------------------------------
template <int VSIZE>
IVector<VSIZE>& IVector<VSIZE>::operator+= (const IVector& vec)
{
for (int i = 0; i < VSIZE; ++i)
{
mTuple[i] += vec.mTuple[i];
}
return *this;
}
//----------------------------------------------------------------------------
template <int VSIZE>
IVector<VSIZE>& IVector<VSIZE>::operator-= (const IVector& vec)
{
for (int i = 0; i < VSIZE; ++i)
{
mTuple[i] -= vec.mTuple[i];
}
return *this;
}
//----------------------------------------------------------------------------
template <int VSIZE>
IVector<VSIZE>& IVector<VSIZE>::operator*= (const int64_t& scalar)
{
for (int i = 0; i < VSIZE; ++i)
{
mTuple[i] *= scalar;
}
return *this;
}
//----------------------------------------------------------------------------
template <int VSIZE>
IVector<VSIZE>& IVector<VSIZE>::operator/= (const int64_t& scalar)
{
assertion(scalar != 0, "Division by zero\n");
for (int i = 0; i < VSIZE; ++i)
{
mTuple[i] /= scalar;
}
return *this;
}
//----------------------------------------------------------------------------
template <int VSIZE>
int64_t IVector<VSIZE>::SquaredLength () const
{
int64_t sqrLen = 0;
for (int i = 0; i < VSIZE; ++i)
{
sqrLen += mTuple[i]*mTuple[i];
}
return sqrLen;
}
//----------------------------------------------------------------------------
template <int VSIZE>
int64_t IVector<VSIZE>::Dot (const IVector& vec) const
{
int64_t dot = 0;
for (int i = 0; i < VSIZE; ++i)
{
dot += mTuple[i]*vec.mTuple[i];
}
return dot;
}
//----------------------------------------------------------------------------
| [
"j.abele@tu-berlin.de"
] | j.abele@tu-berlin.de |
410446620c847a1bd23770d4bb40fb37719686f1 | ce90498e9c35592a62b4e4ecffe97f4ac5064fb8 | /src/VM/BuiltIn/BuiltInError.hpp | ad694d299ff55818530522174d78dd2d573bd6fe | [] | no_license | Vazzi/Schemepp | 5d394fd54e59285fe8a7271c55cf879249c8a049 | 8531a3c37e2a396246d1404789b5655b49b1af10 | refs/heads/master | 2016-08-12T10:15:34.605039 | 2016-01-24T20:29:30 | 2016-01-24T20:29:30 | 50,294,063 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 314 | hpp | #ifndef __BUILT_IN_ERROR_HPP__
#define __BUILT_IN_ERROR_HPP__
#include <stdexcept>
#include <string>
using std::runtime_error;
using std::string;
class BuiltInError: public runtime_error {
public:
BuiltInError(const string& err): runtime_error(err) {}
};
#endif /* ifndef __BUILT_IN_ERROR_HPP__ */
| [
"vlasakjakub@gmail.com"
] | vlasakjakub@gmail.com |
011753b16c0b7a600daaf567536c1c4e41b08fec | 1482cd4ca87b24d7a28d8d195bc4bb3396b998d7 | /Populating Next Right Pointers in Each Node II.cpp | 36dcf6ee05ecb0276e6c006f7874f081f8aaa0f0 | [
"MIT"
] | permissive | Xe0n0/LeetCode | 964f36c75576d48dfdceb5b36bbfc022a2ddc77b | a7a383d88d222edaadd52b317e848f06632a569a | refs/heads/master | 2020-04-16T08:02:15.010990 | 2016-03-11T04:26:52 | 2016-03-11T04:26:52 | 12,356,023 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,587 | cpp | //we have recursive solution
class Solution {
public:
void connect(TreeLinkNode *root) {
// Start typing your C/C++ solution below
// DO NOT write int main() function
if (root == NULL) return;
TreeLinkNode *node = root;
while (node->left || node->right) {
if (node->left) {
node->left->next = node->right;
if (node->right)
node->right->next = node;
else
node->left->next = node;
node = node->left;
}
else {
node->right->next = node;
node = node->right;
}
}
if (node == root) return;
TreeLinkNode *prev = node;
TreeLinkNode *lefts = NULL;
node = node->next;
while (node != NULL) {
//travel up along right next
while (node != NULL &&
(node->right == prev || node->left == prev)) {
prev->next = lefts;
lefts = prev;
prev = node;
node = node->next;
}
if (node == NULL) break;
//when prev is left child of node
while (node->left||node->right) {
if (node->left) {
node->left->next = node->right;
if (node->right)
node->right->next = node;
else
node->left->next = node;
node = node->left;
}
else {
node->right->next = node;
node = node->right;
}
if (lefts) {
TreeLinkNode *t = lefts;
lefts = lefts->next;
t->next = node;
}
}
prev = node;
node = node->next;
}
//node = root;
//while (node) {
// node->next = NULL;
//if (node->right)
// node = node->right;
//else
// node = node->left;
//}
while (lefts) {
TreeLinkNode *t = lefts;
lefts = lefts->next;
t->next = NULL;
}
root->next = NULL;
}
}; | [
"thelongestmailaccounteverexist@gmail.com"
] | thelongestmailaccounteverexist@gmail.com |
b235aad989f2ee61025c7fc3fe783856041622fc | 81b99a7f3a42a2f6109b0a8eff8320f21e99065c | /GraphVertex.h | 1dcd794b9cc1af5b6a5401554a21af0386114c86 | [] | no_license | RosaTheMathGal/Alcuin | 3224e6f9f76a78181085f5b107bbe6448af6b964 | c3a4f772bb49226dbe08755f64b60653fd89ccc4 | refs/heads/master | 2021-01-05T01:13:22.627770 | 2020-02-19T20:55:43 | 2020-02-19T20:55:43 | 240,825,950 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 923 | h | #ifndef GRAPHVERTEX_H
#define GRAPHVERTEX_H
#include <vector>
#include <string>
#include <iostream>
class GraphVertex {
public:
GraphVertex() { label = "Just a little node!"; }
GraphVertex(std::string label) { this->label = label; }
~GraphVertex() { std::cout << label << " says goodnight!" << std::endl; } // The cute message is for debug
void PrintLabel() { std::cout << label << std::endl; }
std::string GetLabel() const { return label; }
void SetLabel(std::string label) { this->label = label; }
std::vector<GraphVertex*> GetConnections() const { return connections; }
void AddConnection(GraphVertex* connectedNode);
private:
std::string label; // Label is a generic string to encode whatever data you need for a graph/network
bool originalAdder = false; // Flag to prevent recursion for AddConnection(). See comment at implementation!!
std::vector<GraphVertex*> connections;
};
#endif
| [
"mdg49@students.uwf.edu"
] | mdg49@students.uwf.edu |
a5ab7101fdc048a91069ffdd34887cc9ec16b807 | 1b18d1066d43962af9561b88639d336e895df637 | /src/platform-linux/include.hpp | 86532be987c75aafdcc22d77e8e5b5c14b0dabeb | [] | no_license | calint/gleso-linux | dd98f197b3d7d445a66482a3ec329beb0f88fe69 | 8cbdd65e888f8319dab8e43eba54aedc82e521a3 | refs/heads/master | 2021-01-17T12:24:49.813288 | 2017-06-13T08:08:33 | 2017-06-13T08:08:33 | 33,423,299 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 195 | hpp | #pragma once
#include<GL/glew.h>
#include<stdio.h>
#include<GLFW/glfw3.h>
#define GLESO_EMBEDDED
//#undef GLESO_EMBEDDED
#define p(...)printf(__VA_ARGS__)
#define dbg(...)printf(__VA_ARGS__)
| [
"calin.tenitchi@gmail.com"
] | calin.tenitchi@gmail.com |
18d980ec377456393bbb16d39ca994a0f4f2925a | b550f32f61389cbccf484e631ff38ffb401c24ff | /windows/runner/main.cpp | 274f351ca30085e8cefa95fdf2a83fd014f080a9 | [] | no_license | manvir-minilive/Minilive_Flutter | c2665aaf7c6b0626308ab8237bdae338c7a80766 | beeff29360815e9425f9958fbbe632b50381fb36 | refs/heads/main | 2023-08-03T07:09:17.124616 | 2021-09-14T04:38:14 | 2021-09-14T04:38:14 | 403,933,367 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,224 | cpp | #include <flutter/dart_project.h>
#include <flutter/flutter_view_controller.h>
#include <windows.h>
#include "flutter_window.h"
#include "run_loop.h"
#include "utils.h"
int APIENTRY wWinMain(_In_ HINSTANCE instance, _In_opt_ HINSTANCE prev,
_In_ wchar_t *command_line, _In_ int show_command) {
// Attach to console when present (e.g., 'flutter run') or create a
// new console when running with a debugger.
if (!::AttachConsole(ATTACH_PARENT_PROCESS) && ::IsDebuggerPresent()) {
CreateAndAttachConsole();
}
// Initialize COM, so that it is available for use in the library and/or
// plugins.
::CoInitializeEx(nullptr, COINIT_APARTMENTTHREADED);
RunLoop run_loop;
flutter::DartProject project(L"data");
std::vector<std::string> command_line_arguments =
GetCommandLineArguments();
project.set_dart_entrypoint_arguments(std::move(command_line_arguments));
FlutterWindow window(&run_loop, project);
Win32Window::Point origin(10, 10);
Win32Window::Size size(1280, 720);
if (!window.CreateAndShow(L"flutter_shorts", origin, size)) {
return EXIT_FAILURE;
}
window.SetQuitOnClose(true);
run_loop.Run();
::CoUninitialize();
return EXIT_SUCCESS;
}
| [
"mohan@minilive.in"
] | mohan@minilive.in |
33b5510c345f02c6a7ed1a3a1c1270c070472990 | bdfaff6f3e3fbd373b72b984b7305e92d14da90c | /base/VuoRunnerCocoa+Conversion.hh | faf39dfdf013675bf7226c25b4d9930292b5e959 | [] | no_license | alcomposer/vuo | 809888bbc20d242db5d782b8a87696c0fdeb7286 | 2a6a2aedd296cbd198c372215ecfdae2210dedae | refs/heads/master | 2021-01-16T23:31:11.424222 | 2015-12-28T05:26:47 | 2015-12-28T05:26:47 | 48,317,125 | 0 | 0 | null | 2015-12-20T11:11:49 | 2015-12-20T11:11:49 | null | UTF-8 | C++ | false | false | 2,298 | hh | /**
* @file
* VuoRunnerCocoa+Conversion header.
*
* @copyright Copyright © 2012–2014 Kosada Incorporated.
* This interface description may be modified and distributed under the terms of the GNU Lesser General Public License (LGPL) version 2 or later.
* For more information, see http://vuo.org/license.
*/
#if defined(__OBJC__) || defined(DOXYGEN)
#ifndef VUORUNNERCOCOACONVERSION_H
#define VUORUNNERCOCOACONVERSION_H
#include <string>
using namespace std;
#include "VuoRunnerCocoa.h"
extern "C" {
#include "VuoImage.h"
}
/**
* Methods for converting between Cocoa types and Vuo types.
*/
@interface VuoRunnerCocoa (Conversion)
+ (id)cocoaObjectWithVuoValue:(json_object *)vuoValue ofType:(string)type;
+ (json_object *)vuoValueWithCocoaObject:(id)value;
+ (NSImage *)nsImageWithVuoImage:(VuoImage)vi;
+ (NSArray *)menuItemsForType:(string)type;
@end
/**
* Methods for converting between Cocoa types and Vuo types.
*/
@interface NSNumber (VuoRunnerCocoaConversion)
- (json_object *)vuoValue;
@end
/**
* Methods for converting between Cocoa types and Vuo types.
*/
@interface NSString (VuoRunnerCocoaConversion)
- (json_object *)vuoValue;
@end
/**
* Methods for converting between Cocoa types and Vuo types.
*/
@interface NSColor (VuoRunnerCocoaConversion)
- (json_object *)vuoValue;
@end
/**
* Methods for converting between Cocoa types and Vuo types.
*/
@interface CIColor (VuoRunnerCocoaConversion)
- (json_object *)vuoValue;
@end
/**
* Methods for converting between Cocoa types and Vuo types.
*/
@interface NSImage (VuoRunnerCocoaConversion)
- (json_object *)vuoValue;
@end
/**
* Methods for converting between Cocoa types and Vuo types.
*/
@interface NSBitmapImageRep (VuoRunnerCocoaConversion)
- (json_object *)vuoValue;
@end
/**
* Methods for converting between Cocoa types and Vuo types.
*/
@interface NSValue (VuoRunnerCocoaConversion)
- (json_object *)vuoValue;
@end
/**
* Methods for converting between Cocoa types and Vuo types.
*/
@interface NSData (VuoRunnerCocoaConversion)
- (json_object *)vuoValue;
@end
/**
* Methods for converting between Cocoa types and Vuo types.
*/
@interface NSArray (VuoRunnerCocoaConversion)
- (json_object *)vuoValue;
@end
#endif // VUORUNNERCOCOACONVERSION_H
#endif // defined(__OBJC__) || defined(DOXYGEN)
| [
"info@vuo.org"
] | info@vuo.org |
6c9fe3107f139caf6732fd8ff360848a3ef8b041 | c1626152963432aa221a4a9b0e4767a4608a51f7 | /src/boost/preprocessor/punctuation/comma_if.hpp | 7a4a2bc3bba94606377f72cad12236d951e89df7 | [
"MIT"
] | permissive | 107-systems/107-Arduino-BoostUnits | d2bffefc2787e99173797c9a89d47961718f9b03 | f1a4dfa7bf2af78c422bf10ba0c30e2a703cb69b | refs/heads/main | 2023-09-06T03:46:02.903776 | 2023-09-05T09:32:35 | 2023-09-05T09:32:35 | 401,328,494 | 0 | 0 | MIT | 2023-09-05T09:32:37 | 2021-08-30T12:03:20 | C++ | UTF-8 | C++ | false | false | 1,012 | hpp | # /* Copyright (C) 2001
# * Housemarque Oy
# * http://www.housemarque.com
# *
# * Distributed under the Boost Software License, Version 1.0. (See
# * accompanying file LICENSE_1_0.txt or copy at
# * http://www.boost.org/LICENSE_1_0.txt)
# */
#
# /* Revised by Paul Mensonides (2002) */
#
# /* See http://www.boost.org for most recent version. */
#
# ifndef BOOST_PREPROCESSOR_PUNCTUATION_COMMA_IF_HPP
# define BOOST_PREPROCESSOR_PUNCTUATION_COMMA_IF_HPP
#
# include "boost/preprocessor/config/config.hpp"
# include "boost/preprocessor/control/if.hpp"
# include "boost/preprocessor/facilities/empty.hpp"
# include "boost/preprocessor/punctuation/comma.hpp"
#
# /* BOOST_PP_COMMA_IF */
#
# if ~BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_EDG()
# define BOOST_PP_COMMA_IF(cond) BOOST_PP_IF(cond, BOOST_PP_COMMA, BOOST_PP_EMPTY)()
# else
# define BOOST_PP_COMMA_IF(cond) BOOST_PP_COMMA_IF_I(cond)
# define BOOST_PP_COMMA_IF_I(cond) BOOST_PP_IF(cond, BOOST_PP_COMMA, BOOST_PP_EMPTY)()
# endif
#
# endif
| [
"cto@lxrobotics.com"
] | cto@lxrobotics.com |
46800d50f0422b8fb6cc80177d588ccf2a7ce3c8 | 68b40958c5c232c8eeff533d2fba92c83803a01c | /TD4/TD4/gestionnaire.h | 2cf1a35398d39f4275e5aff507946ad2f2311b29 | [] | no_license | lotmek/td_inf1010 | 4adc270d190c63bff043fff799c66769401c77b0 | 78d1a6302c69f5fae914a18557742a7a05d8d7ef | refs/heads/master | 2022-03-26T20:38:42.364782 | 2019-11-25T18:14:25 | 2019-11-25T18:14:25 | 210,163,985 | 0 | 0 | null | null | null | null | ISO-8859-1 | C++ | false | false | 1,092 | h | /*
* Titre : gestionnaire.h - Travail Pratique #4
* Date : 5 Octobre 2019
* Auteur : Philippe CÔTÉ-MORNEAULT
*/
#ifndef GESTIONNAIRE_H
#define GESTIONNAIRE_H
#include <vector>
#include "membrePremium.h"
#include "solde.h"
#include "debogageMemoire.hpp"
class Gestionnaire {
public:
// Constructeur
Gestionnaire();
~Gestionnaire();
// Getters
vector<Membre*> getMembres() const;
vector<Coupon*> getCoupons() const;
void ajouterMembre(Membre* membre);
void ajouterCoupon(Coupon* coupon);
Membre* trouverMembre(const string& nomMembre) const;
// TODO
void assignerBillet(Billet* billet, const string& nomMembre, bool utiliserCoupon);
double appliquerCoupon(Membre* membre, double prix);
void acheterCoupon(const string& nomMembre);
// TODO
double calculerRevenu();
// TODO
int calculerNombreBilletsEnSolde();
// TODO: Retirer cette fonction par afficher()
//friend ostream& operator<<(ostream& o, const Gestionnaire& gestionnaire);
// TODO
void afficher(ostream& o);
private:
vector<Membre*> membres_;
vector<Coupon*> coupons_;
};
#endif // !GESTIONNAIRE_H
| [
"mathblin@hotmail.com"
] | mathblin@hotmail.com |
f506d0f6ba8b28013dc60fea3a29c94332b2124f | ea41b223a1956f7b474eafe2b6a30986f0493be8 | /SDK/杀机_BP_JP_Hair_Acc01_functions.cpp | 26c9941e3c4a46b057f1fbd69aabdb2468d61400 | [] | no_license | Chazyboy775/Dead-by-Daylight-SDK | 0717a27f79fd4c9da76219894af3f9e2e8c69361 | 28253097481d359694b34dd852222fc75981977c | refs/heads/master | 2022-04-03T17:25:22.678211 | 2020-02-14T02:10:56 | 2020-02-14T02:10:56 | null | 0 | 0 | null | null | null | null | WINDOWS-1252 | C++ | false | false | 2,634 | cpp | // ÀèÃ÷ɱ»ú (4.22.3) SDK
#ifdef _MSC_VER
#pragma pack(push, 0x8)
#endif
#include "ɱ»ú_BP_JP_Hair_Acc01_parameters.hpp"
namespace SDK
{
//---------------------------------------------------------------------------
//Functions
//---------------------------------------------------------------------------
// Function Engine.SkeletalMeshActor.OnRep_ReplicatedPhysAsset
// (Native, Public)
// FunctionAddress:0x00007FF682017AF0 offset:2f07af0
void ABP_JP_Hair_Acc01_C::OnRep_ReplicatedPhysAsset()
{
static UFunction* fn;
if(!fn)
fn = UObject::FindObject<UFunction>(_xor_("Function Engine.SkeletalMeshActor.OnRep_ReplicatedPhysAsset"));
ABP_JP_Hair_Acc01_C_OnRep_ReplicatedPhysAsset_Params params;
auto flags = fn->FunctionFlags;
fn->FunctionFlags |= 0x400;
UObject::ProcessEvent(fn, ¶ms);
fn->FunctionFlags = flags;
}
// Function Engine.SkeletalMeshActor.OnRep_ReplicatedMesh
// (Native, Public)
// FunctionAddress:0x00007FF68068D990 offset:157d990
void ABP_JP_Hair_Acc01_C::OnRep_ReplicatedMesh()
{
static UFunction* fn;
if(!fn)
fn = UObject::FindObject<UFunction>(_xor_("Function Engine.SkeletalMeshActor.OnRep_ReplicatedMesh"));
ABP_JP_Hair_Acc01_C_OnRep_ReplicatedMesh_Params params;
auto flags = fn->FunctionFlags;
fn->FunctionFlags |= 0x400;
UObject::ProcessEvent(fn, ¶ms);
fn->FunctionFlags = flags;
}
// Function Engine.SkeletalMeshActor.OnRep_ReplicatedMaterial1
// (Native, Public)
// FunctionAddress:0x00007FF6820B0D50 offset:2fa0d50
void ABP_JP_Hair_Acc01_C::OnRep_ReplicatedMaterial1()
{
static UFunction* fn;
if(!fn)
fn = UObject::FindObject<UFunction>(_xor_("Function Engine.SkeletalMeshActor.OnRep_ReplicatedMaterial1"));
ABP_JP_Hair_Acc01_C_OnRep_ReplicatedMaterial1_Params params;
auto flags = fn->FunctionFlags;
fn->FunctionFlags |= 0x400;
UObject::ProcessEvent(fn, ¶ms);
fn->FunctionFlags = flags;
}
// Function Engine.SkeletalMeshActor.OnRep_ReplicatedMaterial0
// (Native, Public)
// FunctionAddress:0x00007FF6820B10D0 offset:2fa10d0
void ABP_JP_Hair_Acc01_C::OnRep_ReplicatedMaterial0()
{
static UFunction* fn;
if(!fn)
fn = UObject::FindObject<UFunction>(_xor_("Function Engine.SkeletalMeshActor.OnRep_ReplicatedMaterial0"));
ABP_JP_Hair_Acc01_C_OnRep_ReplicatedMaterial0_Params params;
auto flags = fn->FunctionFlags;
fn->FunctionFlags |= 0x400;
UObject::ProcessEvent(fn, ¶ms);
fn->FunctionFlags = flags;
}
}
#ifdef _MSC_VER
#pragma pack(pop)
#endif
| [
"1263178881@qq.com"
] | 1263178881@qq.com |
10a886227e07665648e5e0154ffabce85c0e1eeb | 43dba494813d36a06aa547aa7dc37d66dc52cb8e | /helloworld.cpp | d8c2738bb4d0c6dd966bc8d0228c237d58b16d7a | [] | no_license | zackLiuzz/obstacle_detection | 7c057f186bc52619a3cba6ce153e4b87b3189b57 | 342579bfa3e488af0ee6f753fc3c25ac6a2f179d | refs/heads/master | 2021-07-06T10:31:50.112791 | 2021-01-11T13:45:00 | 2021-01-11T13:45:00 | 221,839,166 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 65 | cpp | #include <iostream>
int main(){
std::cout<<"hello world!"
}
| [
"noreply@github.com"
] | noreply@github.com |
16147d3fbe30bb615f814c23b0822b3b2edd406a | 9c7c58220a546d583e22f8737a59e7cc8bb206e6 | /Project/MyProject/MyProject/Source/MyProjectEditor/Private/BaseFrame/AppEditor/Asset/ExportAssetDependecies/Public/MyExportAssetDependeciesStyle.h | 0f99190937ebab004293352d1bc13d7f27245108 | [] | no_license | SiCoYu/UE | 7176f9ece890e226f21cf972e5da4c3c4c4bfe41 | 31722c056d40ad362e5c4a0cba53b05f51a19324 | refs/heads/master | 2021-03-08T05:00:32.137142 | 2019-07-03T12:20:25 | 2019-07-03T12:20:25 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 543 | h | // Copyright 1998-2018 Epic Games, Inc. All Rights Reserved.
#pragma once
#include "SlateBasics.h"
class FMyExportAssetDependeciesStyle
{
public:
static void Initialize();
static void Shutdown();
/** reloads textures used by slate renderer */
static void ReloadTextures();
/** @return The Slate style set for the Shooter game */
static const ISlateStyle& Get();
static FName GetStyleSetName();
private:
static TSharedRef< class FSlateStyleSet > Create();
private:
static TSharedPtr< class FSlateStyleSet > StyleInstance;
}; | [
"kuangben2001@163.com"
] | kuangben2001@163.com |
c298f3f0cd2e5807453146967433c0e58a86fbb7 | 1a67547aa20a393743184909d5a8b9a1409f60cc | /includes/LIEF/third-party/boost/leaf/detail/print.hpp | d7c981498a60215dbb832e8a379f041c3433c445 | [
"MIT"
] | permissive | Unam3dd/WinPack | 321809b9bd9a313f38a9996287d616745a27ea65 | 3dc08408cf10e39cd65bae27dc42b8c2ef7a0733 | refs/heads/main | 2023-06-16T01:42:21.135468 | 2021-07-13T09:33:25 | 2021-07-13T09:33:25 | 382,937,092 | 4 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 3,760 | hpp | #ifndef BOOST_LEAF_DETAIL_PRINT_HPP_INCLUDED
#define BOOST_LEAF_DETAIL_PRINT_HPP_INCLUDED
// Copyright (c) 2018-2020 Emil Dotchevski and Reverge Studios, Inc.
// Distributed under the Boost Software License, Version 1.0. (See accompanying
// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
#if defined(__clang__)
# pragma clang system_header
#elif (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_LEAF_ENABLE_WARNINGS)
# pragma GCC system_header
#elif defined(_MSC_VER) && !defined(BOOST_LEAF_ENABLE_WARNINGS)
# pragma warning(push,1)
#endif
#include <boost/leaf/detail/optional.hpp>
#include <exception>
#include <ostream>
#include <cstring>
namespace boost { namespace leaf {
namespace leaf_detail
{
template <int N>
BOOST_LEAF_CONSTEXPR inline char const * check_prefix( char const * t, char const (&prefix)[N] )
{
return std::strncmp(t,prefix,sizeof(prefix)-1)==0 ? t+sizeof(prefix)-1 : t;
}
}
template <class Name>
inline char const * type() noexcept
{
using leaf_detail::check_prefix;
char const * t =
#ifdef __FUNCSIG__
__FUNCSIG__;
#else
__PRETTY_FUNCTION__;
#endif
#if defined(__clang__)
BOOST_LEAF_ASSERT(check_prefix(t,"const char *boost::leaf::type() ")==t+32);
return t+32;
#elif defined(__GNUC__)
BOOST_LEAF_ASSERT(check_prefix(t,"const char* boost::leaf::type() ")==t+32);
return t+32;
#else
char const * clang_style = check_prefix(t,"const char *boost::leaf::type() ");
if( clang_style!=t )
return clang_style;
char const * gcc_style = check_prefix(t,"const char* boost::leaf::type() ");
if( gcc_style!=t )
return gcc_style;
#endif
return t;
}
namespace leaf_detail
{
template <class T, class E = void>
struct is_printable: std::false_type
{
};
template <class T>
struct is_printable<T, decltype(std::declval<std::ostream&>()<<std::declval<T const &>(), void())>: std::true_type
{
};
////////////////////////////////////////
template <class T, class E = void>
struct has_printable_member_value: std::false_type
{
};
template <class T>
struct has_printable_member_value<T, decltype(std::declval<std::ostream&>()<<std::declval<T const &>().value, void())>: std::true_type
{
};
////////////////////////////////////////
template <class Wrapper, bool WrapperPrintable=is_printable<Wrapper>::value, bool ValuePrintable=has_printable_member_value<Wrapper>::value>
struct diagnostic;
template <class Wrapper, bool ValuePrintable>
struct diagnostic<Wrapper, true, ValuePrintable>
{
static constexpr bool is_invisible = false;
static void print( std::ostream & os, Wrapper const & x )
{
os << x;
}
};
template <class Wrapper>
struct diagnostic<Wrapper, false, true>
{
static constexpr bool is_invisible = false;
static void print( std::ostream & os, Wrapper const & x )
{
os << type<Wrapper>() << ": " << x.value;
}
};
template <class Wrapper>
struct diagnostic<Wrapper, false, false>
{
static constexpr bool is_invisible = false;
static void print( std::ostream & os, Wrapper const & )
{
os << type<Wrapper>() << ": {Non-Printable}";
}
};
template <>
struct diagnostic<std::exception_ptr, false, false>
{
static constexpr bool is_invisible = true;
BOOST_LEAF_CONSTEXPR static void print( std::ostream &, std::exception_ptr const & )
{
}
};
template <class T>
void optional<T>::print( std::ostream & os, int key_to_print ) const
{
if( !diagnostic<T>::is_invisible )
if( int k = key() )
{
if( key_to_print )
{
if( key_to_print!=k )
return;
}
else
os << '[' << k << ']';
diagnostic<T>::print(os, value_);
os << std::endl;
}
}
} // leaf_detail
} }
#endif
| [
"skyrim.gaming@gmail.com"
] | skyrim.gaming@gmail.com |
1ccd876be16458bf180f2a354fcca69ad6b0102b | 8c7591fcf16e64564ab18a0d762e0402dff30194 | /aiko/modules/display_module.hpp | 14de15688c2521049c1b251d62758b98cfb8b113 | [
"BSD-2-Clause"
] | permissive | jotask/AikoEngineTest | b40f4bfbbbf51426dbdbb60c8d5de5ade42bf774 | 01a237515194549259dd658d0cda08b9a0243783 | refs/heads/master | 2020-11-28T07:08:48.944024 | 2019-12-26T16:57:53 | 2019-12-26T16:57:53 | 229,738,737 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,086 | hpp | #pragma once
#include "config/config.hpp"
#include "modules/module.hpp"
#include <GLFW/glfw3.h>
#include <glm.hpp>
#include <string>
#include <vector>
#include <functional>
namespace aiko
{
class Renderer;
class Display : public Module
{
public:
Display(Engine& engine);
void connect(ModuleConnector& moduleConnector) override;
virtual bool init() override;
virtual bool release() override;
glm::vec2 getFrameBufferSize();
GLFWwindow* getWindow() const;
bool isWindowOpen();
// GLFW listeners.
static void windowCloseListener(GLFWwindow* win);
static void windowResizeListener(GLFWwindow* win, int width, int height);
static void keyPressListener(GLFWwindow* win, int key, int scancode, int action, int mods);
static void mouseMoveListener(GLFWwindow* win, double x, double y);
static void mouseEnterListener(GLFWwindow* win, int entered);
private:
GLFWwindow* m_window;
Renderer* m_renderer;
};
}
| [
"jota_sk@hotmail.com"
] | jota_sk@hotmail.com |
3cd9328b6868ccceab94ac04c9a388c8ecdb4e4e | a3d6556180e74af7b555f8d47d3fea55b94bcbda | /ash/components/arc/system_ui/arc_system_ui_bridge_unittest.cc | 822589df1869fc3a58a90b232ab318b3f1334f6c | [
"BSD-3-Clause"
] | permissive | chromium/chromium | aaa9eda10115b50b0616d2f1aed5ef35d1d779d6 | a401d6cf4f7bf0e2d2e964c512ebb923c3d8832c | refs/heads/main | 2023-08-24T00:35:12.585945 | 2023-08-23T22:01:11 | 2023-08-23T22:01:11 | 120,360,765 | 17,408 | 7,102 | BSD-3-Clause | 2023-09-10T23:44:27 | 2018-02-05T20:55:32 | null | UTF-8 | C++ | false | false | 8,225 | cc | // Copyright 2022 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "ash/components/arc/system_ui/arc_system_ui_bridge.h"
#include <memory>
#include "ash/components/arc/session/arc_bridge_service.h"
#include "ash/components/arc/session/arc_service_manager.h"
#include "ash/components/arc/test/connection_holder_util.h"
#include "ash/components/arc/test/fake_system_ui_instance.h"
#include "ash/components/arc/test/test_browser_context.h"
#include "ash/style/color_palette_controller.h"
#include "base/logging.h"
#include "base/memory/raw_ptr.h"
#include "base/test/mock_log.h"
#include "base/test/scoped_feature_list.h"
#include "chromeos/constants/chromeos_features.h"
#include "content/public/test/browser_task_environment.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "ui/gfx/color_palette.h"
using ::testing::_;
namespace arc {
#define EXPECT_ERROR_LOG(matcher) \
if (DLOG_IS_ON(ERROR)) { \
EXPECT_CALL(log_, Log(logging::LOG_ERROR, _, _, _, matcher)) \
.WillOnce(testing::Return(true)); /* suppress logging */ \
}
class TestColorPaletteController : public ash::ColorPaletteController {
public:
TestColorPaletteController() = default;
~TestColorPaletteController() override = default;
void SetSeed(ash::ColorPaletteSeed seed) { seed_ = seed; }
void AddObserver(Observer* observer) override {}
void RemoveObserver(Observer* observer) override {}
void SetColorScheme(ash::ColorScheme scheme,
const AccountId& account_id,
base::OnceClosure on_complete) override {}
void SetStaticColor(SkColor seed_color,
const AccountId& account_id,
base::OnceClosure on_complete) override {}
void SelectLocalAccount(const AccountId& account_id) override {}
SkColor GetUserWallpaperColorOrDefault(SkColor default_color) const override {
return SK_ColorGREEN;
}
absl::optional<ash::ColorPaletteSeed> GetColorPaletteSeed(
const AccountId& account_id) const override {
return seed_;
}
absl::optional<ash::ColorPaletteSeed> GetCurrentSeed() const override {
return seed_;
}
bool UsesWallpaperSeedColor(const AccountId& account_id) const override {
return true;
}
ash::ColorScheme GetColorScheme(const AccountId& account_id) const override {
return seed_.scheme;
}
absl::optional<SkColor> GetStaticColor(
const AccountId& account_id) const override {
return seed_.seed_color;
}
bool GetUseKMeansPref(const AccountId& account_id) const override {
return false;
}
void GenerateSampleColorSchemes(
base::span<const ash::ColorScheme> color_scheme_buttons,
ash::ColorPaletteController::SampleColorSchemeCallback callback)
const override {}
private:
ash::ColorPaletteSeed seed_;
};
class ArcSystemUIBridgeTest : public testing::Test {
protected:
ArcSystemUIBridgeTest()
: task_environment_(content::BrowserTaskEnvironment::IO_MAINLOOP),
bridge_(ArcSystemUIBridge::GetForBrowserContextForTesting(&context_)) {
// ARC has VLOG(1) enabled. Ignore and suppress these logs if the test
// will verify log output. Note the "if" must match the "if" in
// `EXPECT_ERROR_LOG`.
if (DLOG_IS_ON(ERROR)) {
EXPECT_CALL(log_, Log(-1, _, _, _, _))
.WillRepeatedly(testing::Return(true));
}
}
~ArcSystemUIBridgeTest() override = default;
void SetUp() override {
test_palette_ = std::make_unique<TestColorPaletteController>();
bridge_->SetColorPaletteControllerForTesting(test_palette_.get());
ArcServiceManager::Get()->arc_bridge_service()->system_ui()->SetInstance(
&system_ui_instance_);
WaitForInstanceReady(
ArcServiceManager::Get()->arc_bridge_service()->system_ui());
}
void TearDown() override {
ArcServiceManager::Get()->arc_bridge_service()->system_ui()->CloseInstance(
&system_ui_instance_);
bridge_->Shutdown();
if (test_palette_) {
// Only run cleanup if simulating that Shell still exists.
bridge_->SetColorPaletteControllerForTesting(nullptr);
test_palette_.reset();
}
}
explicit ArcSystemUIBridgeTest(const ArcSystemUIBridge&) = delete;
ArcSystemUIBridgeTest& operator=(const ArcSystemUIBridge&) = delete;
content::BrowserTaskEnvironment task_environment_;
ArcServiceManager arc_service_manager_;
TestBrowserContext context_;
FakeSystemUiInstance system_ui_instance_;
std::unique_ptr<TestColorPaletteController> test_palette_;
const raw_ptr<ArcSystemUIBridge, ExperimentalAsh> bridge_;
base::test::MockLog log_;
};
TEST_F(ArcSystemUIBridgeTest, ConstructDestruct) {}
TEST_F(ArcSystemUIBridgeTest, DestroyColorPaletteControllerFirst) {
// Simulate Shell destruction.
bridge_->OnShellDestroying();
// Delete the ColorPaletteController like Shell would.
test_palette_.reset();
// This would crash in `TearDown()` before https://crbug.com/1431544 was
// fixed.
}
TEST_F(ArcSystemUIBridgeTest, OnColorModeChanged) {
EXPECT_FALSE(system_ui_instance_.dark_theme_status());
ash::ColorPaletteSeed seed;
seed.color_mode = ui::ColorProviderKey::ColorMode::kDark;
bridge_->OnColorPaletteChanging(seed);
EXPECT_TRUE(system_ui_instance_.dark_theme_status());
ArcServiceManager::Get()->arc_bridge_service()->system_ui()->CloseInstance(
&system_ui_instance_);
EXPECT_ERROR_LOG(testing::HasSubstr("Failed to send theme status"));
log_.StartCapturingLogs();
seed.color_mode = ui::ColorProviderKey::ColorMode::kLight;
bridge_->OnColorPaletteChanging(seed);
}
TEST_F(ArcSystemUIBridgeTest, OnConnectionReady) {
base::test::ScopedFeatureList features(chromeos::features::kJelly);
EXPECT_FALSE(system_ui_instance_.dark_theme_status());
ash::ColorPaletteSeed seed;
seed.color_mode = ui::ColorProviderKey::ColorMode::kDark;
seed.scheme = ash::ColorScheme::kVibrant;
seed.seed_color = SK_ColorMAGENTA;
test_palette_->SetSeed(seed);
// When the connection is ready, bridge will read the current seed from the
// ColorPaletteController.
bridge_->OnConnectionReady();
EXPECT_TRUE(system_ui_instance_.dark_theme_status());
EXPECT_EQ(static_cast<uint32_t>(SK_ColorMAGENTA),
system_ui_instance_.source_color());
EXPECT_EQ(mojom::ThemeStyleType::VIBRANT, system_ui_instance_.theme_style());
}
TEST_F(ArcSystemUIBridgeTest, JellyDisabled) {
base::test::ScopedFeatureList features;
features.InitAndDisableFeature(chromeos::features::kJelly);
ash::ColorPaletteSeed seed;
seed.seed_color = SK_ColorGREEN;
seed.scheme = ash::ColorScheme::kVibrant;
bridge_->OnColorPaletteChanging(seed);
EXPECT_EQ(gfx::kGoogleBlue400, system_ui_instance_.source_color());
EXPECT_EQ(mojom::ThemeStyleType::TONAL_SPOT,
system_ui_instance_.theme_style());
}
TEST_F(ArcSystemUIBridgeTest, SendOverlayColor) {
// Verify that the test data is not the default
ASSERT_NE((uint32_t)50, system_ui_instance_.source_color());
ASSERT_NE(mojom::ThemeStyleType::EXPRESSIVE,
system_ui_instance_.theme_style());
bridge_->SendOverlayColor(50, mojom::ThemeStyleType::EXPRESSIVE);
EXPECT_EQ((uint32_t)50, system_ui_instance_.source_color());
EXPECT_EQ(mojom::ThemeStyleType::EXPRESSIVE,
system_ui_instance_.theme_style());
}
TEST_F(ArcSystemUIBridgeTest, OnConnectionReady_NeutralToSpritzConversion) {
base::test::ScopedFeatureList features(chromeos::features::kJelly);
EXPECT_FALSE(system_ui_instance_.dark_theme_status());
ash::ColorPaletteSeed seed;
seed.color_mode = ui::ColorProviderKey::ColorMode::kLight;
seed.scheme = ash::ColorScheme::kNeutral;
seed.seed_color = SK_ColorCYAN;
test_palette_->SetSeed(seed);
// When the connection is ready, bridge will read the current seed from the
// ColorPaletteController.
bridge_->OnConnectionReady();
EXPECT_FALSE(system_ui_instance_.dark_theme_status());
EXPECT_EQ(static_cast<uint32_t>(SK_ColorCYAN),
system_ui_instance_.source_color());
EXPECT_EQ(mojom::ThemeStyleType::SPRITZ, system_ui_instance_.theme_style());
}
} // namespace arc
| [
"chromium-scoped@luci-project-accounts.iam.gserviceaccount.com"
] | chromium-scoped@luci-project-accounts.iam.gserviceaccount.com |
322cbba353d7993db6db11b3e644095b8b62cf29 | d0b96a9846a6201945485f88f698096bf7269b6f | /code/src/vector_maximum_worker.hpp | cf3e1fcf51c7ccd50878174550419fdd3e9df4dd | [] | no_license | oxehealth/vector-maximum-worker | 9f2601207d9edd5eb4df8ea584596c78aeabb808 | ee67b8530cd8fdcf9705768a9247f002449cad50 | refs/heads/master | 2021-01-19T07:08:11.946271 | 2017-04-07T14:24:26 | 2017-04-07T14:24:26 | 87,525,296 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 826 | hpp | /*
Homework exercise
send us code for a "worker" that can find the largest elements
of various input vectors. The input arrives on one thread, and
the answers will be read on another, and the work needs to be
done in a way that avoids the calculation being done on either
calling thread, but using a maximum number of worker threads.
*/
#include <vector>
// Here is the skeleton of the class:
class VectorMaximumWorker
{
public:
// Construct the vector maximum worker with
// the maximum number of threads it can run.
VectorMaximumWorker(std::size_t n);
// Submit a vector to calculate the maximum of.
void Submit(const std::vector<float> & v);
// Retrieve a result.
// Blocks until a result is available.
// Returns the maximum of the latest vector
float BlockingGetResult() const;
};
| [
"ron.haskins@oxehealth.com"
] | ron.haskins@oxehealth.com |
fd82028980080a095000ffbc8ab10f24a8884e6b | 7d2c80bbe8b5d6a5a1be33d1e6880d36968401d8 | /ortools/port/file_nonport.cc | c148e6a672e09fb4e24df5c13d5797b637a60d67 | [
"Apache-2.0",
"LicenseRef-scancode-generic-cla",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | chenweichang/or-tools | 7e994563594f530761c33e1b73ab00e92d800c2d | c728f8da988e5b7ea2d8c8b79ffb2e5582f508d8 | refs/heads/master | 2020-03-12T00:14:33.701252 | 2018-04-20T07:18:44 | 2018-04-20T07:18:44 | 130,344,622 | 2 | 0 | Apache-2.0 | 2018-04-20T10:01:10 | 2018-04-20T10:01:10 | null | UTF-8 | C++ | false | false | 1,278 | cc | // Copyright 2010-2017 Google
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
#include "ortools/port/file.h"
#include "ortools/base/file.h"
namespace operations_research {
::util::Status FileSetContents(absl::string_view file_name,
absl::string_view content) {
return file::SetContents(file_name, content, file::Defaults());
}
::util::Status FileGetContents(absl::string_view file_name, std::string* output) {
return file::GetContents(file_name, output, file::Defaults());
}
bool PortableTemporaryFile(const char* directory_prefix, std::string* filename_out) {
return false;
}
::util::Status DeleteFile(absl::string_view file_name) {
return file::Delete(file_name, file::Defaults());
}
} // namespace operations_research
| [
"lperron@google.com"
] | lperron@google.com |
217641430cefd395581f7e2ed5260bd10b04660b | 6b40e9dccf2edc767c44df3acd9b626fcd586b4d | /NT/net/ias/providers/accounting/reporteventcmd.cpp | ac5e56363511203d671ad5ff8324622e4be6500a | [] | no_license | jjzhang166/WinNT5_src_20201004 | 712894fcf94fb82c49e5cd09d719da00740e0436 | b2db264153b80fbb91ef5fc9f57b387e223dbfc2 | refs/heads/Win2K3 | 2023-08-12T01:31:59.670176 | 2021-10-14T15:14:37 | 2021-10-14T15:14:37 | 586,134,273 | 1 | 0 | null | 2023-01-07T03:47:45 | 2023-01-07T03:47:44 | null | UTF-8 | C++ | false | false | 9,981 | cpp | ///////////////////////////////////////////////////////////////////////////////
//
// Copyright (c) Microsoft Corporation
//
// SYNOPSIS
//
// Defines the class ReportEventCommand.
//
///////////////////////////////////////////////////////////////////////////////
#include "ias.h"
#include "reporteventcmd.h"
#include "msdasc.h"
HRESULT ReportEventCommand::Prepare(IDBCreateSession* dbCreateSession) throw ()
{
HRESULT hr;
CComPtr<IDBCreateCommand> dbCreateCommand;
hr = dbCreateSession->CreateSession(
0,
__uuidof(IDBCreateCommand),
reinterpret_cast<IUnknown**>(&dbCreateCommand)
);
if (FAILED(hr))
{
TraceOleDbError("IDBCreateSession::CreateSession", hr);
return hr;
}
CComPtr<ICommandText> commandText;
hr = dbCreateCommand->CreateCommand(
0,
__uuidof(ICommandText),
reinterpret_cast<IUnknown**>(&commandText)
);
if (FAILED(hr))
{
TraceOleDbError("IDBCreateCommand::CreateCommand", hr);
return hr;
}
hr = commandText->SetCommandText(
DBGUID_SQL,
L"{rpc dbo.report_event}"
);
if (FAILED(hr))
{
TraceOleDbError("ICommandText::SetCommandText", hr);
return hr;
}
CComPtr<ICommandWithParameters> commandWithParameters;
hr = commandText->QueryInterface(
__uuidof(ICommandWithParameters),
reinterpret_cast<void**>(&commandWithParameters)
);
if (FAILED(hr))
{
TraceComError("IUnknown::QueryInterface(ICommandWithParameters", hr);
return hr;
}
// When using RPC call semantics, the stored procedure always has a return
// value even if it's not declared. Thus, we bind and ignore.
static const DB_UPARAMS paramOrdinal[] =
{
1,
2
};
static const DBPARAMBINDINFO dbParamBindInfo[] =
{
{
L"int", // pwszDataSourceType
L"return_value", // pwszName
sizeof(long), // ulParamSize
DBPARAMFLAGS_ISOUTPUT, // dwFlags
0, // bPrecision
0 // bScale
},
{
L"ntext", // pwszDataSourceType
L"@doc", // pwszName
~0, // ulParamSize
DBPARAMFLAGS_ISINPUT, // dwFlags
0, // bPrecision
0 // bScale
}
};
hr = commandWithParameters->SetParameterInfo(
2,
paramOrdinal,
dbParamBindInfo
);
if (FAILED(hr))
{
TraceOleDbError("ICommandWithParameters::SetParameterInfo", hr);
return hr;
}
CComPtr<IAccessor> accessor;
hr = commandText->QueryInterface(
__uuidof(IAccessor),
reinterpret_cast<void**>(&accessor)
);
if (FAILED(hr))
{
TraceComError("IUnknown::QueryInterface(IAccessor)", hr);
return hr;
}
static const DBBINDING dbBinding[] =
{
{
1, // iOrdinal
0, // obValue
0, // obLength
0, // obStatus
0, // pTypeInfo
0, // pObject
0, // pBindExt
DBPART_VALUE, // dwPart
DBMEMOWNER_CLIENTOWNED, // dwMemOwner
DBPARAMIO_OUTPUT, // eParamIO
0, // cbMaxLen
0, // dwFlags
DBTYPE_I4, // wType
0, // bPrecision
0 // bScale
},
{
2, // iOrdinal
offsetof(SprocParams, doc), // obValue
0, // obLength
0, // obStatus
0, // pTypeInfo
0, // pObject
0, // pBindExt
DBPART_VALUE, // dwPart
DBMEMOWNER_CLIENTOWNED, // dwMemOwner
DBPARAMIO_INPUT, // eParamIO
0, // cbMaxLen
0, // dwFlags
(DBTYPE_WSTR | DBTYPE_BYREF), // wType
0, // bPrecision
0 // bScale
}
};
HACCESSOR h;
hr = accessor->CreateAccessor(
DBACCESSOR_PARAMETERDATA,
2,
dbBinding,
sizeof(SprocParams),
&h,
0
);
if (FAILED(hr))
{
TraceOleDbError("IAccessor::CreateAccessor", hr);
return hr;
}
// Everything succeeded, so release the old resources ...
ReleaseAccessorHandle();
// ... and store the new.
command = commandText;
accessorManager = accessor;
accessorHandle = h;
return S_OK;
}
HRESULT ReportEventCommand::Execute(const wchar_t* doc) throw ()
{
SprocParams data =
{
0,
doc
};
DBPARAMS dbParmas =
{
&data, // pData
1, // cParamSets
accessorHandle // hAccessor
};
HRESULT hr = command->Execute(
0,
IID_NULL,
&dbParmas,
0,
0
);
if (FAILED(hr))
{
TraceOleDbError("ICommand::Execute", hr);
}
return hr;
}
void ReportEventCommand::Unprepare() throw ()
{
ReleaseAccessorHandle();
accessorManager.Release();
command.Release();
version = 0;
}
HRESULT ReportEventCommand::CreateDataSource(
const wchar_t* initString,
IDBCreateSession** newDataSource
) throw ()
{
HRESULT hr;
CComPtr<IDataInitialize> dataInitialize;
hr = CoCreateInstance(
CLSID_MSDAINITIALIZE,
0,
CLSCTX_INPROC_SERVER,
__uuidof(IDataInitialize),
reinterpret_cast<void**>(&dataInitialize)
);
if (FAILED(hr))
{
TraceComError("CoCreateInstance(MSDAINITIALIZE)", hr);
return hr;
}
CComPtr<IDBInitialize> dbInitialize;
hr = dataInitialize->GetDataSource(
0,
CLSCTX_INPROC_SERVER,
initString,
__uuidof(IDBInitialize),
reinterpret_cast<IUnknown**>(&dbInitialize)
);
if (FAILED(hr))
{
TraceOleDbError("IDataInitialize::GetDataSource", hr);
return hr;
}
hr = dbInitialize->Initialize();
if (FAILED(hr))
{
TraceOleDbError("IDBInitialize::Initialize", hr);
return hr;
}
hr = dbInitialize->QueryInterface(
__uuidof(IDBCreateSession),
reinterpret_cast<void**>(newDataSource)
);
if (FAILED(hr))
{
TraceComError("IUnknown::QueryInterface(IDBCreateSession)", hr);
return hr;
}
return S_OK;
}
void ReportEventCommand::ReleaseAccessorHandle() throw ()
{
if ((accessorHandle != 0) && accessorManager)
{
accessorManager->ReleaseAccessor(accessorHandle, 0);
}
accessorHandle = 0;
}
void ReportEventCommand::TraceComError(
const char* function,
HRESULT error
) throw ()
{
IASTracePrintf("%s failed; return value = 0x%08X", function, error);
}
void ReportEventCommand::TraceOleDbError(
const char* function,
HRESULT error
) throw ()
{
IASTracePrintf("%s failed; return value = 0x%08X", function, error);
IErrorInfo* errInfo;
if (GetErrorInfo(0, &errInfo) == S_OK)
{
HRESULT hr;
BSTR description;
hr = errInfo->GetDescription(&description);
if (SUCCEEDED(hr))
{
IASTracePrintf("\tDescription: %S", description);
SysFreeString(description);
}
IErrorRecords* errRecords;
hr = errInfo->QueryInterface(
__uuidof(IErrorRecords),
reinterpret_cast<void**>(&errRecords)
);
if (SUCCEEDED(hr))
{
ULONG numRecords = 0;
errRecords->GetRecordCount(&numRecords);
for (ULONG i = 0; i < numRecords; ++i)
{
ERRORINFO info;
hr = errRecords->GetBasicErrorInfo(i, &info);
if (SUCCEEDED(hr))
{
IASTracePrintf(
"\tRecord %lu: hrError = 0x%08X; dwMinor = 0x%08X",
i,
info.hrError,
info.dwMinor
);
}
}
errRecords->Release();
}
errInfo->Release();
}
}
| [
"seta7D5@protonmail.com"
] | seta7D5@protonmail.com |
d86484a35f957341482481076a8d946d177526d0 | 8da9d3c3e769ead17f5ad4a4cba6fb3e84a9e340 | /src/chila/connectionTools/designer/app/connectors/gen/MainWindow.hpp | ab74ab7a11897ce565c1f9f167b00542271bf52c | [] | no_license | blockspacer/chila | 6884a540fafa73db37f2bf0117410c33044adbcf | b95290725b54696f7cefc1c430582f90542b1dec | refs/heads/master | 2021-06-05T10:22:53.536352 | 2016-08-24T15:07:49 | 2016-08-24T15:07:49 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 12,918 | hpp | // ******************************************************************
// * This is auto-generated code *
// * - DO NOT MODIFY - *
// ******************************************************************
#ifndef CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__MAINWINDOW_HPP
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__MAINWINDOW_HPP
#define BOOST_MPL_CFG_NO_PREPROCESSED_HEADERS
#undef FUSION_MAX_VECTOR_SIZE
#undef BOOST_MPL_LIMIT_VECTOR_SIZE
#define FUSION_MAX_VECTOR_SIZE 50
#define BOOST_MPL_LIMIT_VECTOR_SIZE 50
#include <boost/call_traits.hpp>
#include <boost/function.hpp>
#include <chila/lib/misc/MemFnExecuter.hpp>
#include <chila/lib/misc/Path.hpp>
#include <string>
#include <chila/connectionTools/lib/codegen/FunctionSigCreator.hpp>
#include <chila/connectionTools/lib/codegen/EventExecuter.hpp>
#include <chila/connectionTools/lib/codegen/Connector.hpp>
#include <chila/connectionTools/lib/other/macrosExp.hpp>
#include <chila/connectionTools/lib/codegen/macrosDef.hpp>
#include <chila/lib/misc/macrosExp.hpp>
#define MY_BIND_ACTION(name) \
CHILA_CONNECTIONTOOLS_LIB_CODEGEN__BIND_ACTION(Target, target, name)
#define DEF_CONNECTOR_ARGUMENT CHILA_CONNECTIONTOOLS_LIB_CODEGEN__DEF_CONNECTOR_ARGUMENT
#define DEF_CONNECTOR_FUNCTION CHILA_CONNECTIONTOOLS_LIB_CODEGEN__DEF_CONNECTOR_FUNCTION
#define DEF_ARG_ALIAS CHILA_CONNECTIONTOOLS_LIB_CODEGEN__DEF_ARG_ALIAS
#define DEF_ARG_ALIAS_LINK CHILA_CONNECTIONTOOLS_LIB_CODEGEN__DEF_ARG_ALIAS_LINK
// Arguments defines
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ARGS_MainWindow \
(moduleName) \
(nodePath) \
(nodeId) \
(value) \
(action) \
(actionList) \
(errorText) \
(outputText) \
(openNode) \
(isExpandable) \
(textProperties)
// Event defines
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_EVENTS_MainWindow \
(launcher_starting) \
(launcher_started) \
(launcher_deactivating) \
(launcher_deactivated) \
(launcher_finishing) \
(launcher_finished) \
(actionRequest) \
(undoRequest) \
(redoRequest) \
(saveRequest) \
(moveUpRequest) \
(moveDownRequest) \
(actionListRequired) \
(flowNodesRequired) \
(flowNodeSelected) \
(checkNodes) \
(expandFlowNode) \
(designNodeRequested)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_EVENT_ARGS_MainWindow_launcher_starting \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_EVENT_ARGS_MainWindow_launcher_started \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_EVENT_ARGS_MainWindow_launcher_deactivating \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_EVENT_ARGS_MainWindow_launcher_deactivated \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_EVENT_ARGS_MainWindow_launcher_finishing \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_EVENT_ARGS_MainWindow_launcher_finished \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_EVENT_ARGS_MainWindow_actionRequest \
(nodePath)(action)(value)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_EVENT_ARGS_MainWindow_undoRequest \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_EVENT_ARGS_MainWindow_redoRequest \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_EVENT_ARGS_MainWindow_saveRequest \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_EVENT_ARGS_MainWindow_moveUpRequest \
(nodePath)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_EVENT_ARGS_MainWindow_moveDownRequest \
(nodePath)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_EVENT_ARGS_MainWindow_actionListRequired \
(nodePath)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_EVENT_ARGS_MainWindow_flowNodesRequired \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_EVENT_ARGS_MainWindow_flowNodeSelected \
(nodePath)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_EVENT_ARGS_MainWindow_checkNodes \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_EVENT_ARGS_MainWindow_expandFlowNode \
(nodePath)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_EVENT_ARGS_MainWindow_designNodeRequested \
(nodePath)
// Action defines
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTIONS_MainWindow \
(launcher_start) \
(launcher_deactivate) \
(launcher_finish) \
(waitEvent) \
(addNode) \
(setNodeValue) \
(addOutputText) \
(clearOutput) \
(actionNotPerformed) \
(removeNode) \
(removeChildren) \
(removeAllChildren) \
(selectNode) \
(showActions) \
(renameNode) \
(addFlowNode) \
(noMoreFlowNodes) \
(saveDesignTreeState) \
(restoreDesignTreeState)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_ARGS_MainWindow_launcher_start \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_ARGS_MainWindow_launcher_deactivate \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_ARGS_MainWindow_launcher_finish \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_ARGS_MainWindow_waitEvent \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_ARGS_MainWindow_addNode \
(nodePath)(value)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_ARGS_MainWindow_setNodeValue \
(nodePath)(value)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_ARGS_MainWindow_addOutputText \
(textProperties)(outputText)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_ARGS_MainWindow_clearOutput \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_ARGS_MainWindow_actionNotPerformed \
(errorText)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_ARGS_MainWindow_removeNode \
(nodePath)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_ARGS_MainWindow_removeChildren \
(nodePath)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_ARGS_MainWindow_removeAllChildren \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_ARGS_MainWindow_selectNode \
(nodePath)(openNode)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_ARGS_MainWindow_showActions \
(nodePath)(actionList)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_ARGS_MainWindow_renameNode \
(nodePath)(nodeId)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_ARGS_MainWindow_addFlowNode \
(nodePath)(value)(isExpandable)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_ARGS_MainWindow_noMoreFlowNodes \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_ARGS_MainWindow_saveDesignTreeState \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_ARGS_MainWindow_restoreDesignTreeState \
// Actions' called events
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_EVCALLED_MainWindow_launcher_start \
(launcher_started)(flowNodesRequired)(actionListRequired)(saveRequest)(flowNodeSelected)(checkNodes)(expandFlowNode)(moveUpRequest)(moveDownRequest)(undoRequest)(redoRequest)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_EVCALLED_MainWindow_launcher_deactivate \
(launcher_deactivated)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_EVCALLED_MainWindow_launcher_finish \
(launcher_finished)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_EVCALLED_MainWindow_waitEvent \
(actionListRequired)(actionRequest)(saveRequest)(undoRequest)(redoRequest)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_EVCALLED_MainWindow_addNode \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_EVCALLED_MainWindow_setNodeValue \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_EVCALLED_MainWindow_addOutputText \
(designNodeRequested)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_EVCALLED_MainWindow_clearOutput \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_EVCALLED_MainWindow_actionNotPerformed \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_EVCALLED_MainWindow_removeNode \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_EVCALLED_MainWindow_removeChildren \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_EVCALLED_MainWindow_removeAllChildren \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_EVCALLED_MainWindow_selectNode \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_EVCALLED_MainWindow_showActions \
(actionRequest)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_EVCALLED_MainWindow_renameNode \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_EVCALLED_MainWindow_addFlowNode \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_EVCALLED_MainWindow_noMoreFlowNodes \
(flowNodeSelected)
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_EVCALLED_MainWindow_saveDesignTreeState \
#define CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN__CONNECTOR_ACTION_EVCALLED_MainWindow_restoreDesignTreeState \
CHILA_LIB_MISC__DEF_NAMESPACE(6, (chila,connectionTools,designer,app,connectors,gen))
{
/** This class serves as a event and action connector for the connector.
* Connectors should hold an instance of this class and connect their actions
* in the constructor.
*/
template <typename _ArgTypes>
struct MainWindow final: public chila::connectionTools::lib::codegen::ConnectorImpl<MainWindow<_ArgTypes>>
{
static chila::lib::misc::Path path() { return "chila.connectionTools.designer.app.connectors.gen.MainWindow"; }
typedef MainWindow Connector;
typedef _ArgTypes ArgTypes;
// Arguments
struct Arguments
{
CHILA_CONNECTIONTOOLS_LIB_CODEGEN__DEF_CONNECTOR_ARGUMENTS( \
CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN, MainWindow)
};
// Events
struct Events
{
CHILA_CONNECTIONTOOLS_LIB_CODEGEN__DEF_CONNECTOR_FUNCTIONS(
CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN, EVENT, MainWindow)
CHILA_CONNECTIONTOOLS_LIB_CODEGEN__DEF_CONNECTOR_FUN_FUSIONSEQ(
CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN, EVENT, MainWindow)
} events;
// Actions
struct Actions
{
CHILA_CONNECTIONTOOLS_LIB_CODEGEN__DEF_CONNECTOR_FUNCTIONS(
CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN, ACTION, MainWindow)
CHILA_CONNECTIONTOOLS_LIB_CODEGEN__DEF_CONNECTOR_FUN_FUSIONSEQ(
CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN, ACTION, MainWindow)
Actions(Connector &connector) :
CHILA_CONNECTIONTOOLS_LIB_CODEGEN__ACTIONS_INIT(
CHILA_CONNECTIONTOOLS_DESIGNER_APP_CONNECTORS_GEN, MainWindow) {}
} actions;
MainWindow() : actions(*this) {}
// Binds the actions to 'target'
template <typename Target>
void bindActions(Target &target)
{
MY_BIND_ACTION(launcher_start);
MY_BIND_ACTION(launcher_deactivate);
MY_BIND_ACTION(launcher_finish);
MY_BIND_ACTION(waitEvent);
MY_BIND_ACTION(addNode);
MY_BIND_ACTION(setNodeValue);
MY_BIND_ACTION(addOutputText);
MY_BIND_ACTION(clearOutput);
MY_BIND_ACTION(actionNotPerformed);
MY_BIND_ACTION(removeNode);
MY_BIND_ACTION(removeChildren);
MY_BIND_ACTION(removeAllChildren);
MY_BIND_ACTION(selectNode);
MY_BIND_ACTION(showActions);
MY_BIND_ACTION(renameNode);
MY_BIND_ACTION(addFlowNode);
MY_BIND_ACTION(noMoreFlowNodes);
MY_BIND_ACTION(saveDesignTreeState);
MY_BIND_ACTION(restoreDesignTreeState);
}
};
}}}}}}
#undef MY_BIND_ACTION
#undef DEF_CONNECTOR_ARGUMENT
#undef DEF_CONNECTOR_FUNCTION
#undef DEF_ARG_ALIAS
#undef DEF_ARG_ALIAS_LINK
#endif
| [
"chilabot@gmail.com"
] | chilabot@gmail.com |
fcb913c951da2f2b8164d295ba3654bb1b9898ac | 22069dac0dc17447536bad91a158c96165dc9889 | /EmbSysLib/Src/Com/Hardware/Display/DisplayGraphic.h | 564da209ae5b1592038703e9d3ca83a8b4e8925e | [
"MIT"
] | permissive | Gagonjh/Embedded-C-Tic-Tac-Toe | 6a8168e938e24ccd8ccd83d2d3763b4a97334348 | 72f0cf1d21877faf633988ff4df680f0ff9284b9 | refs/heads/master | 2023-06-12T02:56:19.249830 | 2021-07-09T18:44:27 | 2021-07-09T18:44:27 | 375,101,112 | 0 | 0 | null | 2021-07-06T15:24:09 | 2021-06-08T18:02:43 | C | UTF-8 | C++ | false | false | 9,114 | h | //*******************************************************************
/*!
\file DisplayGraphic.h
\author Thomas Breuer
\date 10.03.2011
*/
//*******************************************************************
#ifndef _HW_DISPLAY_GRAPHIC_H
#define _HW_DISPLAY_GRAPHIC_H
//*******************************************************************
#include "Display.h"
#include "DisplayFont.h"
//*******************************************************************
/*!
\class cHwDisplayGraphic
\brief Abstract class supporting graphic displays
This class is derived from \a cHwDisplay and adds some basic
methods to draw graphic primitives. \n
The position is given relative to the upper left
corner with coordinates x (=colum) and y (=line).\n
Colors are coded in 16 bit: RRRR.RGGG.GGGB.BBBB\n
- Bit 15 - 11 red
- Bit 10 - 6 green
- Bit 5 - 0 blue
Derived classes should at least:
- initialize the hardware
- implement cHwDisplay::clear() to clear the display and fill it
with background color
- implement setArea() and setPixel()
\see cHwDisplay
\example cHwDisplayGraphic.cpp
*/
#define RGB2COLOR(red,green,blue) \
( ((blue >> 3) << 0) /* 5 bit, 0.. 4 */ \
| ((green >> 2) << 5) /* 6 bit, 5..10 */ \
| ((red >> 3) << 11) /* 5 bit, 11..15 */ \
)
class cHwDisplayGraphic : public cHwDisplay
{
public:
//---------------------------------------------------------------
/*! Predefined color map
*/
//*******************************************************************
//
// color coding: rrrrr gggggg bbbbb
//
//*******************************************************************
/*! Predefined colors
*/
typedef enum
{
// Red Green Blue
Black = RGB2COLOR( 0, 0, 0 ), //!< -
Navy = RGB2COLOR( 0, 48, 96 ), //!< -
DarkGreen = RGB2COLOR( 0, 128, 0 ), //!< -
DarkCyan = RGB2COLOR( 0, 128, 128 ), //!< -
Maroon = RGB2COLOR( 128, 0, 0 ), //!< -
Purple = RGB2COLOR( 128, 0, 128 ), //!< -
Olive = RGB2COLOR( 128, 196, 0 ), //!< -
Grey = RGB2COLOR( 192, 192, 192 ), //!< -
DarkGrey = RGB2COLOR( 128, 128, 128 ), //!< -
Blue = RGB2COLOR( 0, 0, 255 ), //!< -
Green = RGB2COLOR( 0, 255, 0 ), //!< -
Cyan = RGB2COLOR( 0, 255, 255 ), //!< -
Red = RGB2COLOR( 255, 0, 0 ), //!< -
Magenta = RGB2COLOR( 255, 0, 255 ), //!< -
Yellow = RGB2COLOR( 255, 255, 0 ), //!< -
White = RGB2COLOR( 255, 255, 255 ), //!< -
DarkBlue = RGB2COLOR( 0, 0, 192 ), //!< -
} colorPredefined;
// #undef RGB2COLOR
protected:
//---------------------------------------------------------------
// Initialize hardware and set font type and font zoom size
// font: Character font used in cHwDisplay::putChar()
// zoom: Zoom size of character
//
cHwDisplayGraphic( cHwDisplayFont font,
BYTE zoom = 1 );
public:
//---------------------------------------------------------------
/*! Set a new font type and font zoom size
\param font Character font used in cHwDisplay::putChar()
\param zoom Zoom size of character
*/
virtual void setFont( cHwDisplayFont font,
BYTE zoom = 1 );
//---------------------------------------------------------------
/*! Set font zoom size. The actual font is not changed
\param zoom Zoom size of character
*/
virtual void setZoom(BYTE zoom = 1);
//---------------------------------------------------------------
/*! Set background color, which is used in clear() und putChar()
\param color Background Color
*/
virtual void setBackColor( WORD color );
//---------------------------------------------------------------
/*! Set painting color, which is used in putPixel() and
putRectangle()
\param color Farbwert gem. Tabelle \b colorPredefined
*/
virtual void setPaintColor( WORD color );
//---------------------------------------------------------------
/*! Set text color, wich is used in cHwDisplay::putChar()
\param color Text color
*/
virtual void setTextColor( WORD color );
//---------------------------------------------------------------
/*! Set position of next character
\param x Horiontal position in pixel coordinates
\param y Vertical position in pixel coordinates
*/
virtual void gotoPixelPos(WORD x,
WORD y);
//---------------------------------------------------------------
/*! Set position of next character
\param line Horiontal position in character coordinates
\param colum Vertical position in character coordinates
*/
virtual void gotoTextPos( BYTE line,
BYTE colum );
//---------------------------------------------------------------
/*! Put character at actual position and auto increment colum for
next character
\param c Character (ASCII code)
*/
virtual void putChar( char c );
//---------------------------------------------------------------
/*! Paint a pixel in actual painting color
\param x Horiontal position in pixel coordinates
\param y Vertical position in pixel coordinates
*/
virtual void putPixel( WORD x,
WORD y );
//---------------------------------------------------------------
/*! Paint a filled rectangle in actual painting color
\param x Horiontal position in pixel coordinates
\param y Vertical position in pixel coordinates
\param w Width
\param h Height
*/
virtual void putRectangle( WORD x,
WORD y,
WORD w,
WORD h );
//---------------------------------------------------------------
/*! Draw a bitmap\n
Format: 16 bits per pixel
\param x Horiontal position in pixel coordinates (left)
\param y Vertical position in pixel coordinates (top)
\param w Width of bitmap
\param h Height of bitmap
\param bitmap Pointer to bitmap data
*/
virtual void putBitmap( WORD x,
WORD y,
WORD w,
WORD h,
const WORD *bitmap );
//---------------------------------------------------------------
// TODO: write comment
virtual void refresh( void )
{
}
//---------------------------------------------------------------
/*! /todo comment
*/
virtual cHwDisplayFont getDefaultFont( void )
{
return( font );
}
//---------------------------------------------------------------
/*! Get horizontal display size
\return Number of pixel
*/
virtual WORD getWidth( void )
{
return( Hsize );
}
//---------------------------------------------------------------
/*! Get vertical display size
\return Number of pixel
*/
virtual WORD getHeight( void )
{
return( Vsize );
}
private:
//---------------------------------------------------------------
// Set painting area. The next calls to setPixel(BYTE color) will
// draw a pixel in this area with auto increment of horizontal
// and vertical coordinates
// x: Horiontal position in pixel coordinates (left)
// y: Vertical position in pixel coordinates (top)
// w: Width
// h: Height
//
virtual void setArea( WORD x,
WORD y,
WORD w,
WORD h ) = 0;
//---------------------------------------------------------------
// Draw a pixel at absolute position
// color: Pixel color
// x: Horiontal position in pixel coordinate
// y: Vertical position in pixel coordinate
//
virtual void setPixel( WORD color,
WORD x,
WORD y ) = 0;
//---------------------------------------------------------------
// Draw a pixel at relative position within the area defined by
// setArea(). The horizontal and vertical position is incremented
// automatically (horizontal, vertical at end of line)
// color: Pixel color
//
virtual void setPixel( WORD color ) = 0;
protected:
//---------------------------------------------------------------
WORD xPos;
WORD yPos;
DWORD Hsize;
DWORD Vsize;
//---------------------------------------------------------------
cHwDisplayFont font;
BYTE zoom;
//---------------------------------------------------------------
WORD BackColor;
WORD PaintColor;
WORD TextColor;
}; //cHwDisplayGraphic
#endif
| [
"joshua.hahn@smail.inf.h-brs.de"
] | joshua.hahn@smail.inf.h-brs.de |
c83b80d18939660a1400119a5143eeba9702c093 | 29b838b1680ac9ba0602950e3602e6bb8775b61f | /CONTEST/pp.cpp | 6df1871608af56a4e3617d63cbb403df3e9f071b | [] | no_license | sidsrivastavasks/CP-Programs | eeb74e7084679df5a923997a1e201eaf44818626 | da12f5e74f937b94e78ce17642b7d5ebc7760306 | refs/heads/main | 2023-08-03T20:09:59.220248 | 2021-09-16T18:02:40 | 2021-09-16T18:02:40 | 359,374,844 | 0 | 1 | null | null | null | null | UTF-8 | C++ | false | false | 302 | cpp | #include<bits/stdc++.h>
using namespace std;
#define ll long long
ll closepoweroftwo(ll x)
{
ll power = 1;
int count = 1;
while(power*2 <= x){
power*=2;
count++;
}
return count;
}
int main()
{
ll t;
cin>>t;
while(t--)
{
ll n;
cin>>n;
cout<<closepoweroftwo(n)<<endl;
}
}
| [
"55981532+sidsrivastavasks@users.noreply.github.com"
] | 55981532+sidsrivastavasks@users.noreply.github.com |
bd261e58985bf321f0ad6113d7ba05cefe46ed9d | 550276f69179729515773b9ca443528b9961aa73 | /src/ftxui/screen/color_info.cpp | 184bec7e6c0bc270b964b66b9e75a4aef2e05e17 | [
"MIT"
] | permissive | mikel785/FTXUI | 7bff0532129c7f211bbb396f3d764208b877ea54 | 5291f660ca189a3dc28791b5d8375406bb492a0f | refs/heads/master | 2022-12-10T18:58:09.959160 | 2020-09-06T11:46:56 | 2020-09-07T09:25:50 | 296,164,029 | 1 | 0 | MIT | 2020-09-16T22:49:45 | 2020-09-16T22:49:44 | null | UTF-8 | C++ | false | false | 19,139 | cpp | #include "ftxui/screen/color_info.hpp"
namespace ftxui {
// clang-format off
const ColorInfo palette256[] = {
{"Black" , 0 , 0 , 0 , 0 , 0 , 0 , 0 } ,
{"Maroon" , 1 , 128 , 0 , 0 , 0 , 255 , 128 } ,
{"Green" , 2 , 0 , 128 , 0 , 85 , 255 , 128 } ,
{"Olive" , 3 , 128 , 128 , 0 , 43 , 255 , 128 } ,
{"Navy" , 4 , 0 , 0 , 128 , 171 , 255 , 128 } ,
{"Purple" , 5 , 128 , 0 , 128 , 213 , 255 , 128 } ,
{"Teal" , 6 , 0 , 128 , 128 , 128 , 255 , 128 } ,
{"Silver" , 7 , 192 , 192 , 192 , 0 , 0 , 192 } ,
{"Grey" , 8 , 128 , 128 , 128 , 0 , 0 , 128 } ,
{"Red" , 9 , 255 , 0 , 0 , 0 , 255 , 255 } ,
{"Lime" , 10 , 0 , 255 , 0 , 85 , 255 , 255 } ,
{"Yellow" , 11 , 255 , 255 , 0 , 43 , 255 , 255 } ,
{"Blue" , 12 , 0 , 0 , 255 , 171 , 255 , 255 } ,
{"Fuchsia" , 13 , 255 , 0 , 255 , 213 , 255 , 255 } ,
{"Aqua" , 14 , 0 , 255 , 255 , 128 , 255 , 255 } ,
{"White" , 15 , 255 , 255 , 255 , 0 , 0 , 255 } ,
{"Grey0" , 16 , 0 , 0 , 0 , 0 , 0 , 0 } ,
{"NavyBlue" , 17 , 0 , 0 , 95 , 171 , 255 , 95 } ,
{"DarkBlue" , 18 , 0 , 0 , 135 , 171 , 255 , 135 } ,
{"Blue3" , 19 , 0 , 0 , 175 , 171 , 255 , 175 } ,
{"Blue3Bis" , 20 , 0 , 0 , 215 , 171 , 255 , 215 } ,
{"Blue1" , 21 , 0 , 0 , 255 , 171 , 255 , 255 } ,
{"DarkGreen" , 22 , 0 , 95 , 0 , 85 , 255 , 95 } ,
{"DeepSkyBlue4" , 23 , 0 , 95 , 95 , 128 , 255 , 95 } ,
{"DeepSkyBlue4Bis" , 24 , 0 , 95 , 135 , 141 , 255 , 135 } ,
{"DeepSkyBlue4Ter" , 25 , 0 , 95 , 175 , 148 , 255 , 175 } ,
{"DodgerBlue3" , 26 , 0 , 95 , 215 , 152 , 255 , 215 } ,
{"DodgerBlue2" , 27 , 0 , 95 , 255 , 155 , 255 , 255 } ,
{"Green4" , 28 , 0 , 135 , 0 , 85 , 255 , 135 } ,
{"SpringGreen4" , 29 , 0 , 135 , 95 , 115 , 255 , 135 } ,
{"Turquoise4" , 30 , 0 , 135 , 135 , 128 , 255 , 135 } ,
{"DeepSkyBlue3" , 31 , 0 , 135 , 175 , 138 , 255 , 175 } ,
{"DeepSkyBlue3Bis" , 32 , 0 , 135 , 215 , 144 , 255 , 215 } ,
{"DodgerBlue1" , 33 , 0 , 135 , 255 , 149 , 255 , 255 } ,
{"Green3" , 34 , 0 , 175 , 0 , 85 , 255 , 175 } ,
{"SpringGreen3" , 35 , 0 , 175 , 95 , 108 , 255 , 175 } ,
{"DarkCyan" , 36 , 0 , 175 , 135 , 118 , 255 , 175 } ,
{"LightSeaGreen" , 37 , 0 , 175 , 175 , 128 , 255 , 175 } ,
{"DeepSkyBlue2" , 38 , 0 , 175 , 215 , 136 , 255 , 215 } ,
{"DeepSkyBlue1" , 39 , 0 , 175 , 255 , 142 , 255 , 255 } ,
{"Green3Bis" , 40 , 0 , 215 , 0 , 85 , 255 , 215 } ,
{"SpringGreen3Bis" , 41 , 0 , 215 , 95 , 104 , 255 , 215 } ,
{"SpringGreen2" , 42 , 0 , 215 , 135 , 112 , 255 , 215 } ,
{"Cyan3" , 43 , 0 , 215 , 175 , 120 , 255 , 215 } ,
{"DarkTurquoise" , 44 , 0 , 215 , 215 , 128 , 255 , 215 } ,
{"Turquoise2" , 45 , 0 , 215 , 255 , 135 , 255 , 255 } ,
{"Green1" , 46 , 0 , 255 , 0 , 85 , 255 , 255 } ,
{"SpringGreen2Bis" , 47 , 0 , 255 , 95 , 101 , 255 , 255 } ,
{"SpringGreen1" , 48 , 0 , 255 , 135 , 107 , 255 , 255 } ,
{"MediumSpringGreen" , 49 , 0 , 255 , 175 , 114 , 255 , 255 } ,
{"Cyan2" , 50 , 0 , 255 , 215 , 121 , 255 , 255 } ,
{"Cyan1" , 51 , 0 , 255 , 255 , 128 , 255 , 255 } ,
{"DarkRed" , 52 , 95 , 0 , 0 , 0 , 255 , 95 } ,
{"DeepPink4Ter" , 53 , 95 , 0 , 95 , 213 , 255 , 95 } ,
{"Purple4" , 54 , 95 , 0 , 135 , 201 , 255 , 135 } ,
{"Purple4Bis" , 55 , 95 , 0 , 175 , 194 , 255 , 175 } ,
{"Purple3" , 56 , 95 , 0 , 215 , 190 , 255 , 215 } ,
{"BlueViolet" , 57 , 95 , 0 , 255 , 187 , 255 , 255 } ,
{"Orange4" , 58 , 95 , 95 , 0 , 43 , 255 , 95 } ,
{"Grey37" , 59 , 95 , 95 , 95 , 0 , 0 , 95 } ,
{"MediumPurple4" , 60 , 95 , 95 , 135 , 171 , 75 , 135 } ,
{"SlateBlue3" , 61 , 95 , 95 , 175 , 171 , 116 , 175 } ,
{"SlateBlue3Bis" , 62 , 95 , 95 , 215 , 171 , 142 , 215 } ,
{"RoyalBlue1" , 63 , 95 , 95 , 255 , 171 , 160 , 255 } ,
{"Chartreuse4" , 64 , 95 , 135 , 0 , 55 , 255 , 135 } ,
{"DarkSeaGreen4" , 65 , 95 , 135 , 95 , 85 , 75 , 135 } ,
{"PaleTurquoise4" , 66 , 95 , 135 , 135 , 128 , 75 , 135 } ,
{"SteelBlue" , 67 , 95 , 135 , 175 , 150 , 116 , 175 } ,
{"SteelBlue3" , 68 , 95 , 135 , 215 , 157 , 142 , 215 } ,
{"CornflowerBlue" , 69 , 95 , 135 , 255 , 161 , 160 , 255 } ,
{"Chartreuse3" , 70 , 95 , 175 , 0 , 62 , 255 , 175 } ,
{"DarkSeaGreen4Bis" , 71 , 95 , 175 , 95 , 85 , 116 , 175 } ,
{"CadetBlue" , 72 , 95 , 175 , 135 , 106 , 116 , 175 } ,
{"CadetBlueBis" , 73 , 95 , 175 , 175 , 128 , 116 , 175 } ,
{"SkyBlue3" , 74 , 95 , 175 , 215 , 143 , 142 , 215 } ,
{"SteelBlue1" , 75 , 95 , 175 , 255 , 150 , 160 , 255 } ,
{"Chartreuse3Bis" , 76 , 95 , 215 , 0 , 66 , 255 , 215 } ,
{"PaleGreen3Bis" , 77 , 95 , 215 , 95 , 85 , 142 , 215 } ,
{"SeaGreen3" , 78 , 95 , 215 , 135 , 99 , 142 , 215 } ,
{"Aquamarine3" , 79 , 95 , 215 , 175 , 113 , 142 , 215 } ,
{"MediumTurquoise" , 80 , 95 , 215 , 215 , 128 , 142 , 215 } ,
{"SteelBlue1Bis" , 81 , 95 , 215 , 255 , 139 , 160 , 255 } ,
{"Chartreuse2Bis" , 82 , 95 , 255 , 0 , 69 , 255 , 255 } ,
{"SeaGreen2" , 83 , 95 , 255 , 95 , 85 , 160 , 255 } ,
{"SeaGreen1" , 84 , 95 , 255 , 135 , 95 , 160 , 255 } ,
{"SeaGreen1Bis" , 85 , 95 , 255 , 175 , 106 , 160 , 255 } ,
{"Aquamarine1Bis" , 86 , 95 , 255 , 215 , 117 , 160 , 255 } ,
{"DarkSlateGray2" , 87 , 95 , 255 , 255 , 128 , 160 , 255 } ,
{"DarkRedBis" , 88 , 135 , 0 , 0 , 0 , 255 , 135 } ,
{"DeepPink4Bis" , 89 , 135 , 0 , 95 , 226 , 255 , 135 } ,
{"DarkMagenta" , 90 , 135 , 0 , 135 , 213 , 255 , 135 } ,
{"DarkMagentaBis" , 91 , 135 , 0 , 175 , 204 , 255 , 175 } ,
{"DarkVioletBis" , 92 , 135 , 0 , 215 , 198 , 255 , 215 } ,
{"PurpleBis" , 93 , 135 , 0 , 255 , 193 , 255 , 255 } ,
{"Orange4Bis" , 94 , 135 , 95 , 0 , 30 , 255 , 135 } ,
{"LightPink4" , 95 , 135 , 95 , 95 , 0 , 75 , 135 } ,
{"Plum4" , 96 , 135 , 95 , 135 , 213 , 75 , 135 } ,
{"MediumPurple3" , 97 , 135 , 95 , 175 , 192 , 116 , 175 } ,
{"MediumPurple3Bis" , 98 , 135 , 95 , 215 , 185 , 142 , 215 } ,
{"SlateBlue1" , 99 , 135 , 95 , 255 , 181 , 160 , 255 } ,
{"Yellow4" , 100 , 135 , 135 , 0 , 43 , 255 , 135 } ,
{"Wheat4" , 101 , 135 , 135 , 95 , 43 , 75 , 135 } ,
{"Grey53" , 102 , 135 , 135 , 135 , 0 , 0 , 135 } ,
{"LightSlateGrey" , 103 , 135 , 135 , 175 , 171 , 58 , 175 } ,
{"MediumPurple" , 104 , 135 , 135 , 215 , 171 , 94 , 215 } ,
{"LightSlateBlue" , 105 , 135 , 135 , 255 , 171 , 120 , 255 } ,
{"Yellow4Bis" , 106 , 135 , 175 , 0 , 52 , 255 , 175 } ,
{"DarkOliveGreen3" , 107 , 135 , 175 , 95 , 64 , 116 , 175 } ,
{"DarkSeaGreen" , 108 , 135 , 175 , 135 , 85 , 58 , 175 } ,
{"LightSkyBlue3" , 109 , 135 , 175 , 175 , 128 , 58 , 175 } ,
{"LightSkyBlue3Bis" , 110 , 135 , 175 , 215 , 150 , 94 , 215 } ,
{"SkyBlue2" , 111 , 135 , 175 , 255 , 157 , 120 , 255 } ,
{"Chartreuse2" , 112 , 135 , 215 , 0 , 58 , 255 , 215 } ,
{"DarkOliveGreen3Bis" , 113 , 135 , 215 , 95 , 71 , 142 , 215 } ,
{"PaleGreen3" , 114 , 135 , 215 , 135 , 85 , 94 , 215 } ,
{"DarkSeaGreen3" , 115 , 135 , 215 , 175 , 106 , 94 , 215 } ,
{"DarkSlateGray3" , 116 , 135 , 215 , 215 , 128 , 94 , 215 } ,
{"SkyBlue1" , 117 , 135 , 215 , 255 , 143 , 120 , 255 } ,
{"Chartreuse1" , 118 , 135 , 255 , 0 , 63 , 255 , 255 } ,
{"LightGreen" , 119 , 135 , 255 , 95 , 75 , 160 , 255 } ,
{"LightGreenBis" , 120 , 135 , 255 , 135 , 85 , 120 , 255 } ,
{"PaleGreen1" , 121 , 135 , 255 , 175 , 99 , 120 , 255 } ,
{"Aquamarine1" , 122 , 135 , 255 , 215 , 113 , 120 , 255 } ,
{"DarkSlateGray1" , 123 , 135 , 255 , 255 , 128 , 120 , 255 } ,
{"Red3" , 124 , 175 , 0 , 0 , 0 , 255 , 175 } ,
{"DeepPink4" , 125 , 175 , 0 , 95 , 233 , 255 , 175 } ,
{"MediumVioletRed" , 126 , 175 , 0 , 135 , 223 , 255 , 175 } ,
{"Magenta3" , 127 , 175 , 0 , 175 , 213 , 255 , 175 } ,
{"DarkViolet" , 128 , 175 , 0 , 215 , 206 , 255 , 215 } ,
{"Purple" , 129 , 175 , 0 , 255 , 200 , 255 , 255 } ,
{"DarkOrange3" , 130 , 175 , 95 , 0 , 23 , 255 , 175 } ,
{"IndianRed" , 131 , 175 , 95 , 95 , 0 , 116 , 175 } ,
{"HotPink3" , 132 , 175 , 95 , 135 , 235 , 116 , 175 } ,
{"MediumOrchid3" , 133 , 175 , 95 , 175 , 213 , 116 , 175 } ,
{"MediumOrchid" , 134 , 175 , 95 , 215 , 199 , 142 , 215 } ,
{"MediumPurple2" , 135 , 175 , 95 , 255 , 192 , 160 , 255 } ,
{"DarkGoldenrod" , 136 , 175 , 135 , 0 , 33 , 255 , 175 } ,
{"LightSalmon3" , 137 , 175 , 135 , 95 , 21 , 116 , 175 } ,
{"RosyBrown" , 138 , 175 , 135 , 135 , 0 , 58 , 175 } ,
{"Grey63" , 139 , 175 , 135 , 175 , 213 , 58 , 175 } ,
{"MediumPurple2Bis" , 140 , 175 , 135 , 215 , 192 , 94 , 215 } ,
{"MediumPurple1" , 141 , 175 , 135 , 255 , 185 , 120 , 255 } ,
{"Gold3" , 142 , 175 , 175 , 0 , 43 , 255 , 175 } ,
{"DarkKhaki" , 143 , 175 , 175 , 95 , 43 , 116 , 175 } ,
{"NavajoWhite3" , 144 , 175 , 175 , 135 , 43 , 58 , 175 } ,
{"Grey69" , 145 , 175 , 175 , 175 , 0 , 0 , 175 } ,
{"LightSteelBlue3" , 146 , 175 , 175 , 215 , 171 , 47 , 215 } ,
{"LightSteelBlue" , 147 , 175 , 175 , 255 , 171 , 80 , 255 } ,
{"Yellow3" , 148 , 175 , 215 , 0 , 50 , 255 , 215 } ,
{"DarkOliveGreen3Ter" , 149 , 175 , 215 , 95 , 57 , 142 , 215 } ,
{"DarkSeaGreen3Bis" , 150 , 175 , 215 , 135 , 64 , 94 , 215 } ,
{"DarkSeaGreen2" , 151 , 175 , 215 , 175 , 85 , 47 , 215 } ,
{"LightCyan3" , 152 , 175 , 215 , 215 , 128 , 47 , 215 } ,
{"LightSkyBlue1" , 153 , 175 , 215 , 255 , 150 , 80 , 255 } ,
{"GreenYellow" , 154 , 175 , 255 , 0 , 56 , 255 , 255 } ,
{"DarkOliveGreen2" , 155 , 175 , 255 , 95 , 64 , 160 , 255 } ,
{"PaleGreen1Bis" , 156 , 175 , 255 , 135 , 71 , 120 , 255 } ,
{"DarkSeaGreen2Bis" , 157 , 175 , 255 , 175 , 85 , 80 , 255 } ,
{"DarkSeaGreen1" , 158 , 175 , 255 , 215 , 106 , 80 , 255 } ,
{"PaleTurquoise1" , 159 , 175 , 255 , 255 , 128 , 80 , 255 } ,
{"Red3Bis" , 160 , 215 , 0 , 0 , 0 , 255 , 215 } ,
{"DeepPink3" , 161 , 215 , 0 , 95 , 237 , 255 , 215 } ,
{"DeepPink3Bis" , 162 , 215 , 0 , 135 , 229 , 255 , 215 } ,
{"Magenta3Bis" , 163 , 215 , 0 , 175 , 221 , 255 , 215 } ,
{"Magenta3Ter" , 164 , 215 , 0 , 215 , 213 , 255 , 215 } ,
{"Magenta2" , 165 , 215 , 0 , 255 , 207 , 255 , 255 } ,
{"DarkOrange3Bis" , 166 , 215 , 95 , 0 , 19 , 255 , 215 } ,
{"IndianRedBis" , 167 , 215 , 95 , 95 , 0 , 142 , 215 } ,
{"HotPink3Bis" , 168 , 215 , 95 , 135 , 242 , 142 , 215 } ,
{"HotPink2" , 169 , 215 , 95 , 175 , 228 , 142 , 215 } ,
{"Orchid" , 170 , 215 , 95 , 215 , 213 , 142 , 215 } ,
{"MediumOrchid1" , 171 , 215 , 95 , 255 , 203 , 160 , 255 } ,
{"Orange3" , 172 , 215 , 135 , 0 , 27 , 255 , 215 } ,
{"LightSalmon3" , 173 , 215 , 135 , 95 , 14 , 142 , 215 } ,
{"LightPink3" , 174 , 215 , 135 , 135 , 0 , 94 , 215 } ,
{"Pink3" , 175 , 215 , 135 , 175 , 235 , 94 , 215 } ,
{"Plum3" , 176 , 215 , 135 , 215 , 213 , 94 , 215 } ,
{"Violet" , 177 , 215 , 135 , 255 , 199 , 120 , 255 } ,
{"Gold3Bis" , 178 , 215 , 175 , 0 , 35 , 255 , 215 } ,
{"LightGoldenrod3" , 179 , 215 , 175 , 95 , 28 , 142 , 215 } ,
{"Tan" , 180 , 215 , 175 , 135 , 21 , 94 , 215 } ,
{"MistyRose3" , 181 , 215 , 175 , 175 , 0 , 47 , 215 } ,
{"Thistle3" , 182 , 215 , 175 , 215 , 213 , 47 , 215 } ,
{"Plum2" , 183 , 215 , 175 , 255 , 192 , 80 , 255 } ,
{"Yellow3Bis" , 184 , 215 , 215 , 0 , 43 , 255 , 215 } ,
{"Khaki3" , 185 , 215 , 215 , 95 , 43 , 142 , 215 } ,
{"LightGoldenrod2" , 186 , 215 , 215 , 135 , 43 , 94 , 215 } ,
{"LightYellow3" , 187 , 215 , 215 , 175 , 43 , 47 , 215 } ,
{"Grey84" , 188 , 215 , 215 , 215 , 0 , 0 , 215 } ,
{"LightSteelBlue1" , 189 , 215 , 215 , 255 , 171 , 40 , 255 } ,
{"Yellow2" , 190 , 215 , 255 , 0 , 49 , 255 , 255 } ,
{"DarkOliveGreen1" , 191 , 215 , 255 , 95 , 53 , 160 , 255 } ,
{"DarkOliveGreen1Bis" , 192 , 215 , 255 , 135 , 57 , 120 , 255 } ,
{"DarkSeaGreen1Bis" , 193 , 215 , 255 , 175 , 64 , 80 , 255 } ,
{"Honeydew2" , 194 , 215 , 255 , 215 , 85 , 40 , 255 } ,
{"LightCyan1Bis" , 195 , 215 , 255 , 255 , 128 , 40 , 255 } ,
{"Red1" , 196 , 255 , 0 , 0 , 0 , 255 , 255 } ,
{"DeepPink2" , 197 , 255 , 0 , 95 , 240 , 255 , 255 } ,
{"DeepPink1" , 198 , 255 , 0 , 135 , 234 , 255 , 255 } ,
{"DeepPink1Bis" , 199 , 255 , 0 , 175 , 227 , 255 , 255 } ,
{"Magenta2Bis" , 200 , 255 , 0 , 215 , 220 , 255 , 255 } ,
{"Magenta1" , 201 , 255 , 0 , 255 , 213 , 255 , 255 } ,
{"OrangeRed1" , 202 , 255 , 95 , 0 , 16 , 255 , 255 } ,
{"IndianRed1" , 203 , 255 , 95 , 95 , 0 , 160 , 255 } ,
{"IndianRed1Bis" , 204 , 255 , 95 , 135 , 246 , 160 , 255 } ,
{"HotPink" , 205 , 255 , 95 , 175 , 235 , 160 , 255 } ,
{"HotPinkBis" , 206 , 255 , 95 , 215 , 224 , 160 , 255 } ,
{"MediumOrchid1Bis" , 207 , 255 , 95 , 255 , 213 , 160 , 255 } ,
{"DarkOrange" , 208 , 255 , 135 , 0 , 22 , 255 , 255 } ,
{"Salmon1" , 209 , 255 , 135 , 95 , 10 , 160 , 255 } ,
{"LightCoral" , 210 , 255 , 135 , 135 , 0 , 120 , 255 } ,
{"PaleVioletRed1" , 211 , 255 , 135 , 175 , 242 , 120 , 255 } ,
{"Orchid2" , 212 , 255 , 135 , 215 , 228 , 120 , 255 } ,
{"Orchid1" , 213 , 255 , 135 , 255 , 213 , 120 , 255 } ,
{"Orange1" , 214 , 255 , 175 , 0 , 29 , 255 , 255 } ,
{"SandyBrown" , 215 , 255 , 175 , 95 , 21 , 160 , 255 } ,
{"LightSalmon1" , 216 , 255 , 175 , 135 , 14 , 120 , 255 } ,
{"LightPink1" , 217 , 255 , 175 , 175 , 0 , 80 , 255 } ,
{"Pink1" , 218 , 255 , 175 , 215 , 235 , 80 , 255 } ,
{"Plum1" , 219 , 255 , 175 , 255 , 213 , 80 , 255 } ,
{"Gold1" , 220 , 255 , 215 , 0 , 36 , 255 , 255 } ,
{"LightGoldenrod2Bis" , 221 , 255 , 215 , 95 , 32 , 160 , 255 } ,
{"LightGoldenrod2Ter" , 222 , 255 , 215 , 135 , 28 , 120 , 255 } ,
{"NavajoWhite1" , 223 , 255 , 215 , 175 , 21 , 80 , 255 } ,
{"MistyRose1" , 224 , 255 , 215 , 215 , 0 , 40 , 255 } ,
{"Thistle1" , 225 , 255 , 215 , 255 , 213 , 40 , 255 } ,
{"Yellow1" , 226 , 255 , 255 , 0 , 43 , 255 , 255 } ,
{"LightGoldenrod1" , 227 , 255 , 255 , 95 , 43 , 160 , 255 } ,
{"Khaki1" , 228 , 255 , 255 , 135 , 43 , 120 , 255 } ,
{"Wheat1" , 229 , 255 , 255 , 175 , 43 , 80 , 255 } ,
{"Cornsilk1" , 230 , 255 , 255 , 215 , 43 , 40 , 255 } ,
{"Grey100" , 231 , 255 , 255 , 255 , 0 , 0 , 255 } ,
{"Grey3" , 232 , 8 , 8 , 8 , 0 , 0 , 8 } ,
{"Grey7" , 233 , 18 , 18 , 18 , 0 , 0 , 18 } ,
{"Grey11" , 234 , 28 , 28 , 28 , 0 , 0 , 28 } ,
{"Grey15" , 235 , 38 , 38 , 38 , 0 , 0 , 38 } ,
{"Grey19" , 236 , 48 , 48 , 48 , 0 , 0 , 48 } ,
{"Grey23" , 237 , 58 , 58 , 58 , 0 , 0 , 58 } ,
{"Grey27" , 238 , 68 , 68 , 68 , 0 , 0 , 68 } ,
{"Grey30" , 239 , 78 , 78 , 78 , 0 , 0 , 78 } ,
{"Grey35" , 240 , 88 , 88 , 88 , 0 , 0 , 88 } ,
{"Grey39" , 241 , 98 , 98 , 98 , 0 , 0 , 98 } ,
{"Grey42" , 242 , 108 , 108 , 108 , 0 , 0 , 108 } ,
{"Grey46" , 243 , 118 , 118 , 118 , 0 , 0 , 118 } ,
{"Grey50" , 244 , 128 , 128 , 128 , 0 , 0 , 128 } ,
{"Grey54" , 245 , 138 , 138 , 138 , 0 , 0 , 138 } ,
{"Grey58" , 246 , 148 , 148 , 148 , 0 , 0 , 148 } ,
{"Grey62" , 247 , 158 , 158 , 158 , 0 , 0 , 158 } ,
{"Grey66" , 248 , 168 , 168 , 168 , 0 , 0 , 168 } ,
{"Grey70" , 249 , 178 , 178 , 178 , 0 , 0 , 178 } ,
{"Grey74" , 250 , 188 , 188 , 188 , 0 , 0 , 188 } ,
{"Grey78" , 251 , 198 , 198 , 198 , 0 , 0 , 198 } ,
{"Grey82" , 252 , 208 , 208 , 208 , 0 , 0 , 208 } ,
{"Grey85" , 253 , 218 , 218 , 218 , 0 , 0 , 218 } ,
{"Grey89" , 254 , 228 , 228 , 228 , 0 , 0 , 228 } ,
{"Grey93" , 255 , 238 , 238 , 238 , 0 , 0 , 238 } ,
} ;
ColorInfo GetColorInfo(Color::Palette256 index) {
return palette256[int(index)];
}
// clang-format off
}
// Copyright 2020 Arthur Sonzogni. All rights reserved.
// Use of this source code is governed by the MIT license that can be found in
// the LICENSE file.
| [
"sonzogniarthur@gmail.com"
] | sonzogniarthur@gmail.com |
4301768d4bcd88671bc485af510042ac94bc41d7 | 7a17d90d655482898c6777c101d3ab6578ccc6ba | /SDK/PUBG_BuildPatchServices_structs.hpp | 4ca5a582da58345b7acdc17d5059028c527c06d6 | [] | no_license | Chordp/PUBG-SDK | 7625f4a419d5b028f7ff5afa5db49e18fcee5de6 | 1b23c750ec97cb842bf5bc2b827da557e4ff828f | refs/heads/master | 2022-08-25T10:07:15.641579 | 2022-08-14T14:12:48 | 2022-08-14T14:12:48 | 245,409,493 | 17 | 7 | null | null | null | null | UTF-8 | C++ | false | false | 4,790 | hpp | #pragma once
// PUBG (9.1.5.3) SDK
#ifdef _MSC_VER
#pragma pack(push, 0x8)
#endif
#include "PUBG_Basic.hpp"
#include "PUBG_CoreUObject_classes.hpp"
namespace SDK
{
//---------------------------------------------------------------------------
//Enums
//---------------------------------------------------------------------------
// Enum BuildPatchServices.EManifestFileHeader
enum class EManifestFileHeader : uint8_t
{
STORED_RAW = 0,
STORED_COMPRESSED = 1,
STORED_MAX = 2
};
//---------------------------------------------------------------------------
//Script Structs
//---------------------------------------------------------------------------
// ScriptStruct BuildPatchServices.SHAHashData
// 0x0014
struct FSHAHashData
{
unsigned char Hash[0x14]; // 0x0000(0x0001) (ZeroConstructor, IsPlainOldData)
};
// ScriptStruct BuildPatchServices.ChunkPartData
// 0x0018
struct FChunkPartData
{
struct FGuid Guid; // 0x0000(0x0010) (IsPlainOldData)
uint32_t Offset; // 0x0010(0x0004) (ZeroConstructor, IsPlainOldData)
uint32_t Size; // 0x0014(0x0004) (ZeroConstructor, IsPlainOldData)
};
// ScriptStruct BuildPatchServices.FileManifestData
// 0x0070
struct FFileManifestData
{
struct FString Filename; // 0x0000(0x0010) (ZeroConstructor)
struct FSHAHashData FileHash; // 0x0010(0x0014)
unsigned char UnknownData00[0x4]; // 0x0024(0x0004) MISSED OFFSET
TArray<struct FChunkPartData> FileChunkParts; // 0x0028(0x0010) (ZeroConstructor)
TArray<struct FString> InstallTags; // 0x0038(0x0010) (ZeroConstructor)
bool bIsUnixExecutable; // 0x0048(0x0001) (ZeroConstructor, IsPlainOldData)
unsigned char UnknownData01[0x7]; // 0x0049(0x0007) MISSED OFFSET
struct FString SymlinkTarget; // 0x0050(0x0010) (ZeroConstructor)
bool bIsReadOnly; // 0x0060(0x0001) (ZeroConstructor, IsPlainOldData)
bool bIsCompressed; // 0x0061(0x0001) (ZeroConstructor, IsPlainOldData)
unsigned char UnknownData02[0xE]; // 0x0062(0x000E) MISSED OFFSET
};
// ScriptStruct BuildPatchServices.ChunkInfoData
// 0x0040
struct FChunkInfoData
{
struct FGuid Guid; // 0x0000(0x0010) (IsPlainOldData)
uint64_t Hash; // 0x0010(0x0008) (ZeroConstructor, IsPlainOldData)
struct FSHAHashData ShaHash; // 0x0018(0x0014)
unsigned char UnknownData00[0x4]; // 0x002C(0x0004) MISSED OFFSET
int64_t FileSize; // 0x0030(0x0008) (ZeroConstructor, IsPlainOldData)
unsigned char GroupNumber; // 0x0038(0x0001) (ZeroConstructor, IsPlainOldData)
unsigned char UnknownData01[0x7]; // 0x0039(0x0007) MISSED OFFSET
};
// ScriptStruct BuildPatchServices.CustomFieldData
// 0x0020
struct FCustomFieldData
{
struct FString Key; // 0x0000(0x0010) (ZeroConstructor)
struct FString Value; // 0x0010(0x0010) (ZeroConstructor)
};
}
#ifdef _MSC_VER
#pragma pack(pop)
#endif
| [
"1263178881@qq.com"
] | 1263178881@qq.com |
6a092f45cc18dd5ba0f7bb2c159bd0b33904e2b8 | fb7efe44f4d9f30d623f880d0eb620f3a81f0fbd | /third_party/WebKit/Source/core/html/custom/V0CustomElementMicrotaskImportStep.h | 0a5df60e7b2960046ea82f77c5087d43eb2c5fca | [
"BSD-2-Clause",
"LGPL-2.1-only",
"LGPL-2.0-only",
"LGPL-2.0-or-later",
"GPL-1.0-or-later",
"MIT",
"Apache-2.0",
"LicenseRef-scancode-warranty-disclaimer",
"GPL-2.0-only",
"LicenseRef-scancode-other-copyleft",
"BSD-3-Clause"
] | permissive | wzyy2/chromium-browser | 2644b0daf58f8b3caee8a6c09a2b448b2dfe059c | eb905f00a0f7e141e8d6c89be8fb26192a88c4b7 | refs/heads/master | 2022-11-23T20:25:08.120045 | 2018-01-16T06:41:26 | 2018-01-16T06:41:26 | 117,618,467 | 3 | 2 | BSD-3-Clause | 2022-11-20T22:03:57 | 2018-01-16T02:09:10 | null | UTF-8 | C++ | false | false | 2,998 | h | /*
* Copyright (C) 2013 Google Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer
* in the documentation and/or other materials provided with the
* distribution.
* 3. Neither the name of Google Inc. nor the names of its contributors
* may be used to endorse or promote products derived from this
* software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef V0CustomElementMicrotaskImportStep_h
#define V0CustomElementMicrotaskImportStep_h
#include "core/html/custom/V0CustomElementMicrotaskStep.h"
#include "platform/heap/Handle.h"
namespace blink {
class V0CustomElementSyncMicrotaskQueue;
class HTMLImportChild;
// Processes the Custom Elements in an HTML Import. This is a
// composite step which processes the Custom Elements created by
// parsing the import, and its sub-imports.
//
// This step blocks further Custom Element microtask processing if its
// import isn't "ready" (finished parsing and running script.)
class V0CustomElementMicrotaskImportStep final
: public V0CustomElementMicrotaskStep {
public:
static V0CustomElementMicrotaskImportStep* Create(HTMLImportChild* import) {
return new V0CustomElementMicrotaskImportStep(import);
}
~V0CustomElementMicrotaskImportStep() override;
// API for HTML Imports
void Invalidate();
void ImportDidFinishLoading();
DECLARE_VIRTUAL_TRACE();
private:
explicit V0CustomElementMicrotaskImportStep(HTMLImportChild*);
void DidUpgradeAllCustomElements();
bool ShouldWaitForImport() const;
// V0CustomElementMicrotaskStep
Result Process() final;
#if !defined(NDEBUG)
void Show(unsigned indent) override;
#endif
WeakMember<HTMLImportChild> import_;
Member<V0CustomElementSyncMicrotaskQueue> queue_;
};
} // namespace blink
#endif // V0CustomElementMicrotaskImportStep_h
| [
"jacob-chen@iotwrt.com"
] | jacob-chen@iotwrt.com |
f0468eec65a78639a1da540765b127698a6cf4ce | 94cba6a96d60e26895c8f5f78c7de415af6f355a | /UVa/cpp/11799.cpp | ca274f2803edea3eac7e1168bbb72597b5c39506 | [] | no_license | eduardohmrodrigues/competitive-programming | ba7bbae6cef89c926ea2ed92417f95290a4935e1 | bc286261d7fe15cb5ac4c9b587b2f3fdef1e3e69 | refs/heads/master | 2023-08-31T04:17:45.214792 | 2023-08-15T15:11:13 | 2023-08-15T15:11:13 | 215,163,543 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 268 | cpp | #include <cstdio>
int main(){
int t, n, max, s, c = 1;
scanf("%d", &t);
while(t > 0){
max = 0;
scanf("%d", &n);
for(int i=0; i<n; i++){
scanf("%d", &s);
max = max > s ? max : s;
}
printf("Case %d: %d\n", c, max);
++c;
--t;
}
return 0;
}
| [
"eduardohmrodrigues@gmail.com"
] | eduardohmrodrigues@gmail.com |
4d23637f53be0ff7cfb785dc4b322dbb768ba894 | 725e0762e67e767c51cd5b336a69ca0b7b8ed183 | /Thrust/Engine/D3DGraphics.h | cd816ce75ed5cb6a0ae08e21f11b908973bcf5fa | [] | no_license | TonyMalz/CPP | 5b09284f08a65cc87b5ffa1090564d183da86a7a | 89cd416ed098fddece9bca9bb887b8a5c98ba684 | refs/heads/master | 2016-08-05T07:08:07.162185 | 2014-10-19T18:36:30 | 2014-10-19T18:36:30 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,333 | h | /******************************************************************************************
* Chili DirectX Framework Version 14.03.22 *
* D3DGraphics.h *
* Copyright 2014 PlanetChili <http://www.planetchili.net> *
* *
* This file is part of The Chili DirectX Framework. *
* *
* The Chili DirectX Framework is free software: you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation, either version 3 of the License, or *
* (at your option) any later version. *
* *
* The Chili DirectX Framework is distributed in the hope that it will be useful, *
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
* GNU General Public License for more details. *
* *
* You should have received a copy of the GNU General Public License *
* along with The Chili DirectX Framework. If not, see <http://www.gnu.org/licenses/>. *
******************************************************************************************/
#pragma once
#include <d3d9.h>
#include "Vec2.h"
#include "Colors.h"
#include "DrawTarget.h"
class D3DGraphics : public DrawTarget
{
public:
D3DGraphics( HWND hWnd );
~D3DGraphics();
void Draw(Drawable& obj) override{
obj.Rasterize(*this);
}
void PutPixel( int x,int y,D3DCOLOR c );
D3DCOLOR GetPixel( int x,int y ) const;
inline void DrawLine( Vec2 pt1,Vec2 pt2,D3DCOLOR c )
{
DrawLine( (int)(pt1.x+0.5f),(int)(pt1.y+0.5f),(int)(pt2.x+0.5f),(int)(pt2.y+0.5f),c );
}
void DrawLine( int x1,int y1,int x2,int y2,D3DCOLOR c );
void DrawLineClipped(Vec2 p0,Vec2 p1,const D3DCOLOR color,const RectF& clip);
void DrawCircle(int centerX, int centerY, int radius, D3DCOLOR c);
void DrawRect(const RectF& rect, D3DCOLOR c);
void BeginFrame();
void EndFrame();
public:
static const unsigned int SCREENWIDTH = 800;
static const unsigned int SCREENHEIGHT = 600;
private:
const D3DCOLOR FILLVALUE = BLACK;
IDirect3D9* pDirect3D;
IDirect3DDevice9* pDevice;
IDirect3DSurface9* pBackBuffer;
D3DCOLOR* pSysBuffer;
}; | [
"arsch@boozr.de"
] | arsch@boozr.de |
6cb8b3a348af6886243eaede9b4395bd994c9492 | 39b049ddea9c00dc083fd6f273d068f2fca05fd7 | /Classes/StartScene.cpp | 5a5038331c40c693a9f01d6b5d00ac05ae512ebc | [] | no_license | fightTTT/detroid | 573e20a79f70d7d234e80c97a4633f34a9dfe261 | 8cca872b98a77d8f1f141ea5f7cc1dd2512a61f3 | refs/heads/master | 2020-09-15T05:34:45.253319 | 2020-01-21T19:37:05 | 2020-01-21T19:37:05 | 223,358,553 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,139 | cpp | #include "StartScene.h"
#include "GameScene.h"
cocos2d::Scene * StartScene::createScene()
{
return StartScene::create();
}
bool StartScene::init()
{
if (!Scene::init())
{
return false;
}
cocos2d::Size visibleSize = cocos2d::Director::getInstance()->getVisibleSize();
cocos2d::Vec2 origin = cocos2d::Director::getInstance()->getVisibleOrigin();
float scale = (visibleSize.height == 1024) ? 1.5f : (visibleSize.height == 576) ? 1.0f : visibleSize.height / 1024 * 1.5f;
this->scheduleOnce(CC_SCHEDULE_SELECTOR(StartScene::NextGameScene), 3);
cocos2d::Sprite* backgroundSprite = cocos2d::Sprite::create("StartBG.png");
backgroundSprite->setPosition(cocos2d::Point(visibleSize.width / 2 + origin.x, visibleSize.height / 2 + origin.y));
backgroundSprite->setScale(scale);
this->addChild(backgroundSprite);
this->scheduleUpdate();
return true;
}
void StartScene::NextGameScene(float dt)
{
cocos2d::Scene* scene = GameScene::createScene();
scene->setName("gameScene");
cocos2d::Director::getInstance()->replaceScene(cocos2d::TransitionFade::create(0.5, scene));
}
| [
"sakumeikou@icloud.com"
] | sakumeikou@icloud.com |
fdef86ae7802b3e846bf29fcd5e06a00b1075baf | 3cea356ef76eb8ff75e65afa4bd6368b7c94b064 | /Projects/VideoGameProject/NonControllableCharacter.cpp | c6e30b7bd2d793036eb47ec27a6d406c52d3182c | [] | no_license | Jacophobia/OpenGL | e6961be528d9191c2d43b6ec449e221d408ad601 | 26b906115d2e918b07001f8fd9cb9f3d326fd2c1 | refs/heads/main | 2023-08-28T22:29:50.591405 | 2021-11-02T05:18:57 | 2021-11-02T05:18:57 | 423,021,347 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 38 | cpp | #include "NonControllableCharacter.h"
| [
"jacophilia@gmail.com"
] | jacophilia@gmail.com |
d5b4d682b384599af154ea534b63a181f5489656 | 91a882547e393d4c4946a6c2c99186b5f72122dd | /Source/XPSP1/NT/admin/wmi/wbem/winmgmt/esscomp/noncom/ncprov/eventinfo.cpp | 49411e3bc719f7f6afc87cce930282352ecde4cc | [] | no_license | IAmAnubhavSaini/cryptoAlgorithm-nt5src | 94f9b46f101b983954ac6e453d0cf8d02aa76fc7 | d9e1cdeec650b9d6d3ce63f9f0abe50dabfaf9e2 | refs/heads/master | 2023-09-02T10:14:14.795579 | 2021-11-20T13:47:06 | 2021-11-20T13:47:06 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 34,770 | cpp | // EventInfo.cpp
#include "precomp.h"
#include "ProvInfo.h"
#include "EventInfo.h"
#include "NCProv.h"
#include "NCProvider.h"
#include "BlobDcdr_i.c"
#define COUNTOF(x) (sizeof(x)/sizeof(x[0]))
#define DWORD_ALIGNED(x) ((DWORD)((((x) * 8) + 31) & (~31)) / 8)
/////////////////////////////////////////////////////////////////////////////
// CEventInfo
CEventInfo::CEventInfo() :
#ifdef USE_SD
m_bufferSD(0),
#endif
m_pPropFuncs(0)
{
}
CEventInfo::~CEventInfo()
{
}
BOOL GetClassQualifier(
IWbemClassObject *pObj,
LPCWSTR szQualifier,
VARIANT *pVal)
{
IWbemQualifierSet *pSet = NULL;
BOOL bRet = FALSE;
if (SUCCEEDED(pObj->GetQualifierSet(&pSet)))
{
if (SUCCEEDED(pSet->Get(szQualifier, 0, pVal, NULL)))
bRet = TRUE;
pSet->Release();
}
return bRet;
}
BOOL GetClassPropertyQualifier(
IWbemClassObject *pObj,
LPCWSTR szProperty,
LPCWSTR szQualifier,
VARIANT *pVal)
{
IWbemQualifierSet *pSet = NULL;
BOOL bRet = FALSE;
if (SUCCEEDED(pObj->GetPropertyQualifierSet(szProperty, &pSet)))
{
if (SUCCEEDED(pSet->Get(szQualifier, 0, pVal, NULL)))
bRet = TRUE;
pSet->Release();
}
return bRet;
}
BOOL CEventInfo::InitFromBuffer(CClientInfo *pInfo, CBuffer *pBuffer)
{
WCHAR *pszEvent;
DWORD nProps,
dwStrSize;
BOOL bRet = FALSE;
m_pInfo = pInfo;
// Get the number of properties for this event layout.
nProps = pBuffer->ReadDWORD();
pszEvent = pBuffer->ReadAlignedLenString(&dwStrSize);
// See if this is the generic class.
m_type = _wcsicmp(pszEvent, GENERIC_CLASS_NAME) ? TYPE_NORMAL :
TYPE_GENERIC;
// Prepare the array of property functions.
m_pPropFuncs.Init(nProps);
if (IsNormal())
{
LPWSTR *pszProps = new LPWSTR[nProps];
if (pszProps)
{
for (DWORD i = 0; i < nProps; i++)
{
DWORD type = pBuffer->ReadDWORD();
DWORD dwSize;
LPCWSTR szProp = pBuffer->ReadAlignedLenString(&dwSize);
PROP_FUNC pFunc = TypeToPropFunc(type);
m_pPropFuncs.AddVal(TypeToPropFunc(type));
pszProps[i] = (BSTR) szProp;
}
bRet =
Init(
pInfo->m_pProvider->m_pProv->GetNamespace(),
pszEvent,
(LPCWSTR*) pszProps,
nProps,
FAILED_PROP_TRY_ARRAY);
delete pszProps;
}
}
else
{
// This event is using the generic class. Create the param names.
_variant_t vParamNames;
SAFEARRAYBOUND bound = { nProps, 0 };
if ((V_ARRAY(&vParamNames) = SafeArrayCreate(VT_BSTR, 1, &bound))
!= NULL)
{
BSTR *pNames = (BSTR*) vParamNames.parray->pvData;
vParamNames.vt = VT_BSTR | VT_ARRAY;
for (DWORD i = 0; i < nProps; i++)
{
DWORD type = pBuffer->ReadDWORD();
DWORD dwSize;
LPCWSTR szProp = pBuffer->ReadAlignedLenString(&dwSize);
pNames[i] = SysAllocString((BSTR) szProp);
m_pPropFuncs.AddVal(GenTypeToPropFunc(type));
}
bRet =
Init(
pInfo->m_pProvider->m_pProv->GetNamespace(),
pszEvent,
NULL,
0,
FAILED_PROP_FAIL);
// If everything's OK, Put() the param names along with the
// provider name.
if (bRet)
{
m_pObj->Put(
L"PropertyNames",
0,
&vParamNames,
0);
_variant_t vProviderName = pInfo->m_pProvider->m_pProv->m_strName;
m_pObj->Put(
L"ProviderName",
0,
&vProviderName,
0);
}
}
}
return bRet;
}
BOOL CEventInfo::SetPropsWithBuffer(CBuffer *pBuffer)
{
if (!m_pObj)
return FALSE;
DWORD nProps = m_pPropFuncs.GetCount();
BOOL bRet = TRUE;
DWORD *pNullTable = (DWORD*) pBuffer->m_pCurrent;
//pBuffer->m_pCurrent = pPropTable + nProps * sizeof(DWORD);
// We need this as the offsets are relative from the beginning
// of the object packet (including the 2 DWORDs of header stuff).
m_pBitsBase = (LPBYTE) (pNullTable - 3);
m_pdwPropTable = pNullTable + (nProps / 32 + ((nProps % 32) != 0));
// If this is a generic event we have some setup to do.
if (IsGeneric())
{
SAFEARRAYBOUND bound = { nProps, 0 };
// We need to prepare the array of values.
V_ARRAY(&m_vParamValues) = SafeArrayCreate(VT_BSTR, 1, &bound);
// Out of memory?
if (V_ARRAY(&m_vParamValues) == NULL)
return FALSE;
m_vParamValues.vt = VT_BSTR | VT_ARRAY;
// Save off a pointer to the param values as an optimization.
m_pValues = (BSTR*) m_vParamValues.parray->pvData;
}
// Save this off for our processing functions.
//m_pBuffer = pBuffer;
for (m_iCurrentVar = 0;
m_iCurrentVar < nProps && bRet;
m_iCurrentVar++)
{
if ((pNullTable[m_iCurrentVar / 32] & (1 << (m_iCurrentVar % 32))))
{
PROP_FUNC pFunc = m_pPropFuncs[m_iCurrentVar];
bRet = (this->*pFunc)();
_ASSERT(bRet);
}
#ifdef NO_WINMGMT
else
WriteNULL(m_iCurrentVar);
#endif
}
if (bRet && IsGeneric())
{
m_pObj->Put(
L"PropertyValues",
0,
&m_vParamValues,
0);
// Free the value strings since we don't need them anymore.
m_vParamValues.Clear();
}
return bRet;
}
PROP_FUNC CEventInfo::TypeToPropFunc(DWORD type)
{
PROP_FUNC pRet;
BOOL bNonArray = (type & CIM_FLAG_ARRAY) == 0;
switch(type & ~CIM_FLAG_ARRAY)
{
case CIM_STRING:
case CIM_REFERENCE:
case CIM_DATETIME:
pRet = bNonArray ? ProcessString : ProcessStringArray;
break;
case CIM_UINT32:
case CIM_SINT32:
case CIM_REAL32:
pRet = bNonArray ? ProcessDWORD : ProcessArray4;
break;
case CIM_UINT16:
case CIM_SINT16:
case CIM_CHAR16:
case CIM_BOOLEAN:
pRet = bNonArray ? ProcessWORD : ProcessArray2;
break;
case CIM_SINT8:
case CIM_UINT8:
pRet = bNonArray ? ProcessBYTE : ProcessArray1;
break;
case CIM_SINT64:
case CIM_UINT64:
case CIM_REAL64:
pRet = bNonArray ? ProcessDWORD64 : ProcessArray8;
break;
case CIM_OBJECT:
pRet = bNonArray ? ProcessObject : ProcessObjectArray;
break;
// We'll use this for _IWmiObjects.
case CIM_IUNKNOWN:
pRet = bNonArray ? ProcessWmiObject : ProcessWmiObjectArray;
break;
default:
// Bad type!
_ASSERT(FALSE);
pRet = NULL;
}
return pRet;
}
PROP_FUNC CEventInfo::GenTypeToPropFunc(DWORD type)
{
PROP_FUNC pRet;
BOOL bNonArray = (type & CIM_FLAG_ARRAY) == 0;
switch(type & ~CIM_FLAG_ARRAY)
{
case CIM_STRING:
case CIM_REFERENCE:
case CIM_DATETIME:
pRet = bNonArray ? GenProcessString : GenProcessStringArray;
break;
case CIM_UINT32:
pRet = bNonArray ? GenProcessUint32 : GenProcessUint32Array;
break;
case CIM_SINT32:
pRet = bNonArray ? GenProcessSint32 : GenProcessSint32Array;
break;
case CIM_CHAR16:
case CIM_UINT16:
pRet = bNonArray ? GenProcessUint16 : GenProcessUint16Array;
break;
case CIM_SINT16:
pRet = bNonArray ? GenProcessSint16 : GenProcessSint16Array;
break;
case CIM_BOOLEAN:
pRet = bNonArray ? GenProcessBool : GenProcessBoolArray;
break;
case CIM_SINT8:
pRet = bNonArray ? GenProcessSint8 : GenProcessSint8Array;
break;
case CIM_UINT8:
pRet = bNonArray ? GenProcessUint8 : GenProcessUint8Array;
break;
case CIM_SINT64:
pRet = bNonArray ? GenProcessSint64 : GenProcessSint64Array;
break;
case CIM_UINT64:
pRet = bNonArray ? GenProcessUint64 : GenProcessUint64Array;
break;
case CIM_REAL32:
pRet = bNonArray ? GenProcessReal32 : GenProcessReal32Array;
break;
case CIM_REAL64:
pRet = bNonArray ? GenProcessReal64 : GenProcessReal64Array;
break;
case CIM_OBJECT:
pRet = bNonArray ? GenProcessObject : GenProcessObjectArray;
break;
default:
// Bad type!
_ASSERT(FALSE);
pRet = NULL;
}
return pRet;
}
BOOL CEventInfo::ProcessString()
{
LPBYTE pData = GetPropDataPointer(m_iCurrentVar);
DWORD dwSize = *(DWORD*) pData;
BOOL bRet;
#ifndef NO_WINMGMT
bRet = WriteData(m_iCurrentVar, pData + sizeof(DWORD), dwSize);
#else
bRet = TRUE;
#endif
return bRet;
}
BOOL CEventInfo::ProcessStringArray()
{
LPBYTE pData = GetPropDataPointer(m_iCurrentVar);
DWORD nStrings = *(DWORD*) pData;
BOOL bRet;
VARIANT vValue;
SAFEARRAYBOUND sabound;
sabound.lLbound = 0;
sabound.cElements = nStrings;
pData += sizeof(DWORD);
if ((V_ARRAY(&vValue) = SafeArrayCreate(VT_BSTR, 1, &sabound)) != NULL)
{
BSTR *pStrings = (BSTR*) vValue.parray->pvData;
LPBYTE pCurrent = pData;
vValue.vt = VT_BSTR | VT_ARRAY;
for (DWORD i = 0; i < nStrings; i++)
{
//pStrings[i] = (BSTR) pCurrent;
pStrings[i] = SysAllocString((BSTR) (pCurrent + sizeof(DWORD)));
pCurrent += DWORD_ALIGNED(*(DWORD*) pCurrent) + sizeof(DWORD);
}
//m_pBuffer->m_pCurrent = (LPBYTE) pCurrent;
#ifndef NO_WINMGMT
HRESULT hr;
hr =
m_pObj->Put(
m_pProps[m_iCurrentVar].m_strName,
0,
&vValue,
0);
bRet = SUCCEEDED(hr);
if (!bRet)
bRet = TRUE;
#else
bRet = TRUE;
#endif
// Cleanup the safe array.
// Do this so SafeArrayDestroy doesn't try to free our BSTRs we got
// off of the buffer.
//ZeroMemory(vValue.parray->pvData, sizeof(BSTR) * nStrings);
SafeArrayDestroy(V_ARRAY(&vValue));
}
else
bRet = FALSE;
return bRet;
}
BOOL CEventInfo::ProcessDWORD()
{
#ifndef NO_WINMGMT
return WriteDWORD(m_iCurrentVar, m_pdwPropTable[m_iCurrentVar]);
#else
//m_pBuffer->ReadDWORD();
return TRUE;
#endif
}
BOOL CEventInfo::ProcessBYTE()
{
BYTE cData = m_pdwPropTable[m_iCurrentVar];
#ifndef NO_WINMGMT
return WriteData(m_iCurrentVar, &cData, sizeof(cData));
#else
return TRUE;
#endif
}
BOOL CEventInfo::ProcessDWORD64()
{
DWORD64 *pdwData = (DWORD64*) GetPropDataPointer(m_iCurrentVar);
#ifndef NO_WINMGMT
return WriteData(m_iCurrentVar, pdwData, sizeof(*pdwData));
#else
return TRUE;
#endif
}
BOOL CEventInfo::ProcessWORD()
{
WORD wData = m_pdwPropTable[m_iCurrentVar];
#ifndef NO_WINMGMT
return WriteData(m_iCurrentVar, &wData, sizeof(wData));
#else
return TRUE;
#endif
}
BOOL CEventInfo::ProcessScalarArray(DWORD dwItemSize)
{
LPBYTE pBits = GetPropDataPointer(m_iCurrentVar);
// DWORD dwItems = (DWORD*) pBits,
// dwSize = dwItems * dwItemSize;
BOOL bRet;
#ifndef NO_WINMGMT
bRet = WriteArrayData(m_iCurrentVar, pBits, dwItemSize);
#else
bRet = TRUE;
#endif
//m_pBuffer->m_pCurrent += dwSize;
return bRet;
}
BOOL CEventInfo::ProcessArray1()
{
return ProcessScalarArray(1);
}
BOOL CEventInfo::ProcessArray2()
{
return ProcessScalarArray(2);
}
BOOL CEventInfo::ProcessArray4()
{
return ProcessScalarArray(4);
}
BOOL CEventInfo::ProcessArray8()
{
return ProcessScalarArray(8);
}
// Digs out an embedded object from the current buffer.
BOOL CEventInfo::GetEmbeddedObject(IUnknown **ppObj, LPBYTE pBits)
{
CEventInfo *pEvent = new CEventInfo;
BOOL bRet = FALSE;
if (pEvent)
{
DWORD dwSize = *(DWORD*) pBits;
CBuffer bufferObj(pBits + sizeof(DWORD), dwSize, CBuffer::ALIGN_NONE);
bRet =
pEvent->InitFromBuffer(m_pInfo, &bufferObj) &&
pEvent->SetPropsWithBuffer(&bufferObj);
if (bRet)
{
bRet =
SUCCEEDED(pEvent->m_pObj->QueryInterface(
IID_IUnknown, (LPVOID*) ppObj));
}
delete pEvent;
}
return bRet;
}
BOOL CEventInfo::ProcessObject()
{
_variant_t vObj;
BOOL bRet = FALSE;
LPBYTE pObjBegin = m_pBitsBase + m_pdwPropTable[m_iCurrentVar];
if (GetEmbeddedObject(&vObj.punkVal, pObjBegin))
{
vObj.vt = VT_UNKNOWN;
bRet =
SUCCEEDED(m_pObj->Put(
m_pProps[m_iCurrentVar].m_strName,
0,
&vObj,
0));
}
return bRet;
}
BOOL CEventInfo::ProcessObjectArray()
{
LPBYTE pBits = m_pBitsBase + m_pdwPropTable[m_iCurrentVar];
DWORD nObjects = *(DWORD*) pBits;
BOOL bRet = FALSE;
VARIANT vValue;
SAFEARRAYBOUND sabound;
sabound.lLbound = 0;
sabound.cElements = nObjects;
if ((V_ARRAY(&vValue) = SafeArrayCreate(VT_UNKNOWN, 1, &sabound)) != NULL)
{
IUnknown **pUnks = (IUnknown**) vValue.parray->pvData;
vValue.vt = VT_UNKNOWN | VT_ARRAY;
bRet = TRUE;
// Get past the # of elements.
pBits += sizeof(DWORD);
for (DWORD i = 0; i < nObjects && bRet; i++)
{
DWORD dwSize = *(DWORD*) pBits;
bRet = GetEmbeddedObject(&pUnks[i], pBits);
pBits += DWORD_ALIGNED(dwSize) + sizeof(DWORD);
}
if (bRet)
{
#ifndef NO_WINMGMT
bRet =
SUCCEEDED(m_pObj->Put(
m_pProps[m_iCurrentVar].m_strName,
0,
&vValue,
0));
#endif
}
}
return bRet;
}
// Digs out an embedded object from the current buffer.
BOOL CEventInfo::GetWmiObject(_IWmiObject **ppObj, LPBYTE pBits)
{
if (m_pObjSpawner == NULL)
{
HRESULT hr;
hr =
m_pInfo->m_pProvider->m_pProv->GetNamespace()->GetObject(
L"__NAMESPACE",
0,
NULL,
(IWbemClassObject**) (_IWmiObject**) &m_pObjSpawner,
NULL);
if (FAILED(hr))
return FALSE;
}
BOOL bRet = FALSE;
_IWmiObject *pObjTemp = NULL;
if (SUCCEEDED(m_pObjSpawner->SpawnInstance(0, (IWbemClassObject**) &pObjTemp)))
{
DWORD dwSize = *(DWORD*) pBits;
LPVOID pMem = CoTaskMemAlloc(dwSize);
if (pMem)
{
memcpy(pMem, pBits + sizeof(DWORD), dwSize);
if (SUCCEEDED(pObjTemp->SetObjectMemory(pMem, dwSize)))
{
*ppObj = pObjTemp;
bRet = TRUE;
}
}
}
return bRet;
}
BOOL CEventInfo::ProcessWmiObject()
{
BOOL bRet;
LPBYTE pObjBegin = m_pBitsBase + m_pdwPropTable[m_iCurrentVar];
_IWmiObject *pObj = NULL;
if (GetWmiObject(&pObj, pObjBegin))
{
CProp &prop = m_pProps[m_iCurrentVar];
HRESULT hr;
hr =
m_pWmiObj->SetPropByHandle(
prop.m_lHandle,
0,
sizeof(_IWmiObject*),
&pObj);
pObj->Release();
bRet = SUCCEEDED(hr);
}
else
bRet = FALSE;
return bRet;
}
BOOL CEventInfo::ProcessWmiObjectArray()
{
return FALSE; // not supported.
/*
LPBYTE pBits = m_pBitsBase + m_pdwPropTable[m_iCurrentVar];
int nObjects = *(int*) pBits;
BOOL bRet = TRUE;
_IWmiObject **pObjs = new _IWmiObject*[nObjects];
if (!pObjs)
return FALSE;
memset(pObjs, 0, sizeof(_IWmiObject*) * nObjects);
// Get past the # of elements.
pBits += sizeof(DWORD);
for (int i = 0; i < nObjects && bRet; i++)
{
DWORD dwSize = *(DWORD*) pBits;
if (dwSize)
bRet = GetWmiObject(&pObjs[i], pBits);
pBits += DWORD_ALIGNED(dwSize) + sizeof(DWORD);
}
if (bRet)
{
bRet =
WriteNonPackedArrayData(
m_iCurrentVar,
pObjs,
nObjects,
sizeof(_IWmiObject*) * nObjects);
}
for (int j = 0; j < i; j++)
{
if (pObjs[j])
pObjs[j]->Release();
}
delete [] pObjs;
return bRet;
*/
}
BOOL CEventInfo::GenProcessString()
{
LPBYTE pData = GetPropDataPointer(m_iCurrentVar) + sizeof(DWORD);
m_pValues[m_iCurrentVar] = SysAllocString((BSTR) pData);
return TRUE;
}
BOOL CEventInfo::GenProcessStringArray()
{
LPBYTE pData = GetPropDataPointer(m_iCurrentVar);
DWORD nStrings = *(DWORD*) pData;
BOOL bRet = FALSE;
LPBYTE pCurrent = pData + sizeof(DWORD);
DWORD dwTotalLen = 0;
// First see how much of a buffer we'll need.
for (DWORD i = 0; i < nStrings; i++)
{
DWORD dwLen = wcslen((LPCWSTR) (pCurrent + sizeof(DWORD)));
dwTotalLen += dwLen + 2; // 2 for the comma and space.
pCurrent += sizeof(DWORD) + *(DWORD*) pCurrent;
}
BSTR pValue = SysAllocStringByteLen(NULL, dwTotalLen * sizeof(WCHAR));
m_pValues[m_iCurrentVar] = pValue;
if (pValue)
{
// Point back to the first string.
pCurrent = pData + sizeof(DWORD);
dwTotalLen = 0;
for (i = 0; i < nStrings; i++)
{
DWORD dwLen = wcslen((LPCWSTR) (pCurrent + sizeof(DWORD)));
// Add a comma and space before the next value.
if (i != 0)
{
memcpy(
&pValue[dwTotalLen],
L", ",
sizeof(L", ") - sizeof(WCHAR));
dwTotalLen += 2;
}
// Add the current value.
memcpy(
&pValue[dwTotalLen],
pCurrent + sizeof(DWORD),
dwLen * sizeof(WCHAR));
// Increase our position in the big value.
dwTotalLen += dwLen;
// Move to the next string.
pCurrent += sizeof(DWORD) + *(DWORD*) pCurrent;
}
// Add the final null.
pValue[dwTotalLen] = 0;
bRet = TRUE;
}
return bRet;
}
BOOL CEventInfo::GenProcessSint8()
{
BYTE cData = GetPropDataValue(m_iCurrentVar);
return GenProcessInt(cData);
}
BOOL CEventInfo::GenProcessSint8Array()
{
return GenProcessArray8(TRUE);
}
BOOL CEventInfo::GenProcessArray8(BOOL bSigned)
{
LPBYTE pData = GetPropDataPointer(m_iCurrentVar);
DWORD nItems = *(DWORD*) pData;
BOOL bRet = FALSE;
BSTR pValue = SysAllocStringByteLen(NULL, nItems * 7 * sizeof(WCHAR));
LPCWSTR szFormat = bSigned ? L"%d" : L"%u";
m_pValues[m_iCurrentVar] = pValue;
pData += sizeof(DWORD);
if (pValue)
{
*pValue = 0;
for (DWORD i = 0; i < nItems; i++)
{
WCHAR szItem[5];
if (i != 0)
wcscat(pValue, L", ");
swprintf(szItem, szFormat, pData[i]);
wcscat(pValue, szItem);
}
bRet = TRUE;
}
return bRet;
}
BOOL CEventInfo::GenProcessArray16(BOOL bSigned)
{
LPWORD pData = (LPWORD) GetPropDataPointer(m_iCurrentVar);
DWORD nItems = *(DWORD*) pData;
BOOL bRet = FALSE;
BSTR pValue = SysAllocStringByteLen(NULL, nItems * 10 * sizeof(WCHAR));
LPCWSTR szFormat = bSigned ? L"%d" : L"%u";
m_pValues[m_iCurrentVar] = pValue;
// Get past the first DWORD.
pData += 2;
if (pValue)
{
*pValue = 0;
for (DWORD i = 0; i < nItems; i++)
{
WCHAR szItem[10];
if (i != 0)
wcscat(pValue, L", ");
swprintf(szItem, szFormat, pData[i]);
wcscat(pValue, szItem);
}
bRet = TRUE;
}
return bRet;
}
BOOL CEventInfo::GenProcessArray32(BOOL bSigned)
{
LPDWORD pData = (LPDWORD) GetPropDataPointer(m_iCurrentVar);
DWORD nItems = *(DWORD*) pData;
BOOL bRet = FALSE;
BSTR pValue = SysAllocStringByteLen(NULL, nItems * 15 * sizeof(WCHAR));
LPCWSTR szFormat = bSigned ? L"%d" : L"%u";
m_pValues[m_iCurrentVar] = pValue;
// Get past the number of items.
pData++;
if (pValue)
{
*pValue = 0;
for (DWORD i = 0; i < nItems; i++)
{
WCHAR szItem[15];
if (i != 0)
wcscat(pValue, L", ");
swprintf(szItem, szFormat, pData[i]);
wcscat(pValue, szItem);
}
bRet = TRUE;
}
return bRet;
}
BOOL CEventInfo::GenProcessArray64(BOOL bSigned)
{
LPBYTE pData = (LPBYTE) GetPropDataPointer(m_iCurrentVar);
DWORD nItems = *(DWORD*) pData;
BOOL bRet = FALSE;
BSTR pValue = SysAllocStringByteLen(NULL, nItems * 30 * sizeof(WCHAR));
LPCWSTR szFormat = bSigned ? L"%I64d" : L"%I64u";
m_pValues[m_iCurrentVar] = pValue;
if (pValue)
{
*pValue = 0;
DWORD64 *pVals = (DWORD64*) (pData + sizeof(DWORD));
for (DWORD i = 0; i < nItems; i++)
{
WCHAR szItem[30];
if (i != 0)
wcscat(pValue, L", ");
// TODO: We need to find out how to mark pVals as unaligned.
swprintf(szItem, szFormat, pVals[i]);
wcscat(pValue, szItem);
}
bRet = TRUE;
}
return bRet;
}
BOOL CEventInfo::GenProcessUint8()
{
BYTE cData = GetPropDataValue(m_iCurrentVar);
return GenProcessDWORD(cData);
}
BOOL CEventInfo::GenProcessUint8Array()
{
return GenProcessArray8(FALSE);
}
BOOL CEventInfo::GenProcessSint16()
{
WORD wData = GetPropDataValue(m_iCurrentVar);
return GenProcessInt(wData);
}
BOOL CEventInfo::GenProcessSint16Array()
{
return GenProcessArray16(TRUE);
}
BOOL CEventInfo::GenProcessUint16()
{
WORD wData = GetPropDataValue(m_iCurrentVar);
return GenProcessDWORD(wData);
}
BOOL CEventInfo::GenProcessUint16Array()
{
return GenProcessArray16(FALSE);
}
BOOL CEventInfo::GenProcessSint32()
{
DWORD dwData = GetPropDataValue(m_iCurrentVar);
return GenProcessInt(dwData);
}
BOOL CEventInfo::GenProcessSint32Array()
{
return GenProcessArray32(TRUE);
}
BOOL CEventInfo::GenProcessUint32()
{
DWORD dwData = GetPropDataValue(m_iCurrentVar);
return GenProcessDWORD(dwData);
}
BOOL CEventInfo::GenProcessUint32Array()
{
return GenProcessArray32(FALSE);
}
BOOL CEventInfo::GenProcessSint64()
{
DWORD64 *pdwData = (DWORD64*) GetPropDataPointer(m_iCurrentVar);
return GenProcessInt64(*pdwData);
}
BOOL CEventInfo::GenProcessSint64Array()
{
return GenProcessArray64(TRUE);
}
BOOL CEventInfo::GenProcessUint64()
{
DWORD64 *pdwData = (DWORD64*) GetPropDataPointer(m_iCurrentVar);
return GenProcessDWORD64(*pdwData);
}
BOOL CEventInfo::GenProcessUint64Array()
{
return GenProcessArray16(FALSE);
}
BOOL CEventInfo::GenProcessReal32()
{
return GenProcessDouble(*(float*) &m_pdwPropTable[m_iCurrentVar]);
}
BOOL CEventInfo::GenProcessReal32Array()
{
float *pData = (float*) GetPropDataPointer(m_iCurrentVar);
DWORD nItems = *(DWORD*) pData;
BOOL bRet = FALSE;
BSTR pValue = SysAllocStringByteLen(NULL, nItems * 30 * sizeof(WCHAR));
LPCWSTR szFormat = L"%.4f";
m_pValues[m_iCurrentVar] = pValue;
pData++;
if (pValue)
{
*pValue = 0;
for (DWORD i = 0; i < nItems; i++)
{
WCHAR szItem[30];
if (i != 0)
wcscat(pValue, L", ");
swprintf(szItem, szFormat, pData[i]);
wcscat(pValue, szItem);
}
bRet = TRUE;
}
return bRet;
}
BOOL CEventInfo::GenProcessReal64()
{
double *pfData = (double*) GetPropDataPointer(m_iCurrentVar);
return GenProcessDouble(*pfData);
}
BOOL CEventInfo::GenProcessReal64Array()
{
LPBYTE pData = (LPBYTE) GetPropDataPointer(m_iCurrentVar);
DWORD nItems = *(DWORD*) pData;
BOOL bRet = FALSE;
BSTR pValue = SysAllocStringByteLen(NULL, nItems * 30 * sizeof(WCHAR));
LPCWSTR szFormat = L"%.4f";
m_pValues[m_iCurrentVar] = pValue;
if (pValue)
{
*pValue = 0;
double *pVals = (double*) (pData + sizeof(DWORD));
for (DWORD i = 0; i < nItems; i++)
{
WCHAR szItem[30];
if (i != 0)
wcscat(pValue, L", ");
// TODO: Mark as unaligned.
swprintf(szItem, szFormat, pVals[i]);
wcscat(pValue, szItem);
}
bRet = TRUE;
}
return bRet;
}
BOOL CEventInfo::GenProcessObject()
{
return FALSE;
}
BOOL CEventInfo::GenProcessObjectArray()
{
return FALSE;
}
BOOL CEventInfo::GenProcessBool()
{
DWORD wData = GetPropDataValue(m_iCurrentVar);
return GenProcessDWORD(wData ? 1 : 0);
}
BOOL CEventInfo::GenProcessBoolArray()
{
DWORD *pData = (DWORD*) GetPropDataPointer(m_iCurrentVar);
DWORD nItems = *(DWORD*) pData;
BOOL bRet = FALSE;
BSTR pValue = SysAllocStringByteLen(NULL, nItems * 3 * sizeof(WCHAR));
m_pValues[m_iCurrentVar] = pValue;
if (pValue)
{
*pValue = 0;
for (DWORD i = 0; i < nItems; i++)
{
if (i != 0)
wcscat(pValue, L", ");
wcscat(pValue, pData[i] ? L"1" : L"0");
}
bRet = TRUE;
}
return bRet;
}
BOOL CEventInfo::GenProcessDWORD(DWORD dwValue)
{
WCHAR szTemp[100];
swprintf(szTemp, L"%u", dwValue);
m_pValues[m_iCurrentVar] = SysAllocString(szTemp);
return TRUE;
}
BOOL CEventInfo::GenProcessInt(DWORD dwValue)
{
WCHAR szTemp[100];
swprintf(szTemp, L"%d", dwValue);
m_pValues[m_iCurrentVar] = SysAllocString(szTemp);
return TRUE;
}
BOOL CEventInfo::GenProcessDWORD64(DWORD64 dwValue)
{
WCHAR szTemp[100];
swprintf(szTemp, L"%I64u", dwValue);
m_pValues[m_iCurrentVar] = SysAllocString(szTemp);
return TRUE;
}
BOOL CEventInfo::GenProcessInt64(DWORD64 dwValue)
{
WCHAR szTemp[100];
swprintf(szTemp, L"%I64i", dwValue);
m_pValues[m_iCurrentVar] = SysAllocString(szTemp);
return TRUE;
}
BOOL CEventInfo::GenProcessDouble(double fValue)
{
WCHAR szTemp[100];
swprintf(szTemp, L"%.4f", fValue);
m_pValues[m_iCurrentVar] = SysAllocString(szTemp);
return TRUE;
}
#ifdef USE_SD
void CEventInfo::SetSD(LPBYTE pSD, DWORD dwLen)
{
m_bufferSD.Reset(dwLen);
m_bufferSD.Write(pSD, dwLen);
}
#endif
/////////////////////////////////////////////////////////////////////////////
// CBlobEventInfo
CBlobEventInfo::CBlobEventInfo() :
m_pPropHandles(0)
{
}
BOOL CBlobEventInfo::InitFromName(CClientInfo *pInfo, LPCWSTR szClassName)
{
IWbemClassObject *pClass = NULL;
BOOL bRet = FALSE;
m_pInfo = pInfo;
// Get the class.
if (SUCCEEDED(pInfo->m_pProvider->m_pProv->GetNamespace()->GetObject(
_bstr_t(szClassName),
0,
NULL,
&pClass,
NULL)))
{
SAFEARRAY *pArrNames;
// Get the property names.
if (SUCCEEDED(pClass->GetNames(
NULL,
WBEM_FLAG_NONSYSTEM_ONLY,
NULL,
&pArrNames)))
{
DWORD nItems = pArrNames->rgsabound[0].cElements;
BSTR *pNames = (BSTR*) pArrNames->pvData;
CArray<CIMTYPE> pTypes(nItems);
bRet =
// Prepare the array of property functions.
m_pPropFuncs.Init(nItems) &&
// We'll use these to talk to the blob decoder.
m_pPropHandles.Init(nItems);
for (DWORD i = 0; i < nItems && bRet; i++)
{
CIMTYPE type;
// Get the property type.
bRet =
SUCCEEDED(pClass->Get(
pNames[i],
0,
NULL,
&type,
NULL));
// Save the type for later.
pTypes[i] = type;
PROP_FUNC pFunc = TypeToPropFunc(type);
int iSize = sizeof(pFunc);
// Get the function used to decode this type.
m_pPropFuncs[i] = pFunc;
bRet =
GetClassPropertyQualifier(
pClass,
pNames[i],
L"DecodeHandle",
&m_pPropHandles[i]);
}
// Now init our CObjAccess
bRet =
Init(
pInfo->m_pProvider->m_pProv->GetNamespace(),
szClassName,
(LPCWSTR*) pNames,
nItems,
FAILED_PROP_TRY_ARRAY);
// Load the property decoder for this event.
if (bRet)
{
_variant_t vCLSID;
CLSID clsidDecoder;
bRet =
GetClassQualifier(
pClass,
L"DecodeCLSID",
&vCLSID);
if (bRet &&
CLSIDFromString(V_BSTR(&vCLSID), &clsidDecoder) == 0)
{
bRet =
SUCCEEDED(CoCreateInstance(
clsidDecoder,
NULL,
CLSCTX_ALL,
IID_IBlobDecoder,
(LPVOID*) &m_pDecoder));
}
}
}
}
return bRet;
}
BOOL CBlobEventInfo::SetBlobPropsWithBuffer(CBuffer *pBuffer)
{
BYTE* cBuffer = new BYTE[4096];
if (cBuffer == NULL)
return FALSE;
DWORD dwPropTable = 0; // This is the offset of the data from cBuffer,
// which is always 0.
CBuffer buffer(cBuffer, sizeof(cBuffer), CBuffer::ALIGN_DWORD_PTR);
int nProps = m_pPropFuncs.GetSize();
BOOL bRet = TRUE;
DWORD dwBlobSize = pBuffer->ReadDWORD();
LPBYTE pBlob = pBuffer->m_pCurrent;
// Save this off for our processing functions.
//m_pBuffer = &buffer;
m_pBitsBase = cBuffer;
// Always 0 since all the funcs need to always index to the first member
// of the m_pdwPropTable array to get the data.
m_iCurrentVar = 0;
for (m_iCurrentVar = 0;
m_iCurrentVar < nProps && bRet;
m_iCurrentVar++)
{
CIMTYPE type;
DWORD dwBytesRead = 0;
if (SUCCEEDED(
m_pDecoder->DecodeProperty(
&m_pPropHandles[m_iCurrentVar],
&type,
pBlob,
dwBlobSize,
cBuffer,
sizeof(cBuffer),
&dwBytesRead)) && dwBytesRead > 0)
{
PROP_FUNC pFunc = m_pPropFuncs[m_iCurrentVar];
// If the number of bytes read is greater than 4, m_pdwPropTable
// must point at 0 (data is 0 bytes offset from cBuffer).
// If the number is 4 or less, m_pdwPropTable should point to
// cBuffer, since that's where the real data is.
m_pdwPropTable =
dwBytesRead > 4 ? (&dwPropTable - m_iCurrentVar) :
((DWORD*) cBuffer) - m_iCurrentVar;
bRet = (this->*pFunc)();
_ASSERT(bRet);
}
else
WriteNULL(m_iCurrentVar);
}
delete[] cBuffer;
// don't want to leave this pointing at a buffer that no longer exists!
m_pBitsBase = NULL;
return bRet;
}
/////////////////////////////////////////////////////////////////////////////
// CEventInfoMap
CEventInfoMap::~CEventInfoMap()
{
while (m_mapNormalEvents.size())
{
CNormalInfoMapIterator item = m_mapNormalEvents.begin();
delete (*item).second;
m_mapNormalEvents.erase(item);
}
while (m_mapBlobEvents.size())
{
CBlobInfoMapIterator item = m_mapBlobEvents.begin();
CEventInfo *pEvent = (*item).second;
delete pEvent;
m_mapBlobEvents.erase(item);
}
}
CEventInfo *CEventInfoMap::GetNormalEventInfo(DWORD dwIndex)
{
CEventInfo *pInfo;
CNormalInfoMapIterator item = m_mapNormalEvents.find(dwIndex);
if (item != m_mapNormalEvents.end())
pInfo = (*item).second;
else
pInfo = NULL;
return pInfo;
}
CEventInfo *CEventInfoMap::GetBlobEventInfo(LPCWSTR szClassName)
{
CEventInfo *pInfo;
CBlobInfoMapIterator item = m_mapBlobEvents.find(szClassName);
if (item != m_mapBlobEvents.end())
pInfo = (*item).second;
else
pInfo = NULL;
return pInfo;
}
BOOL CEventInfoMap::AddNormalEventInfo(DWORD dwIndex, CEventInfo *pInfo)
{
m_mapNormalEvents[dwIndex] = pInfo;
return TRUE;
}
BOOL CEventInfoMap::AddBlobEventInfo(LPCWSTR szClassName, CEventInfo *pInfo)
{
m_mapBlobEvents[szClassName] = pInfo;
return TRUE;
}
long lTemp = 0;
HRESULT CEventInfo::Indicate()
{
HRESULT hr;
#ifndef USE_SD
hr = m_pSink->Indicate(1, &m_pObj);
#else
if (m_bufferSD.m_dwSize == 0)
hr = m_pSink->Indicate(1, &m_pObj);
else
hr = m_pSink->IndicateWithSD(1, (IUnknown**) &m_pObj, m_bufferSD.m_dwSize,
m_bufferSD.m_pBuffer);
#endif
return hr;
}
| [
"support@cryptoalgo.cf"
] | support@cryptoalgo.cf |
9df19ce78080458bbf07b279adf662ba15f446a5 | 0b2ce7d9f01210f7fd8f4cdbff01a83625c9f5e2 | /8/8.cpp | 888f349a19525bcf83172ff768fee63ce6ecf80b | [] | no_license | Leonid0208/CPP | f8b53db0696a3de1bc9f4b3a33a909f9145ad521 | 7aa3619faaa26a62533c5b6b123e434e7bc96966 | refs/heads/master | 2020-08-01T02:21:24.326385 | 2020-06-17T07:49:41 | 2020-06-17T07:49:41 | 210,822,946 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 671 | cpp |
#include <iostream>
using namespace std;
int main()
{
setlocale(LC_ALL, "Russian");
while (true) {
double a, b;
char do_it, space;
cout << "Введите пример в формате 'x + y', где '+' - может быть '+', '-', '*', '/'." << endl;
cin >> a >> do_it >> b;
switch (do_it)
{
case '+': cout << a + b << endl; break;
case '-': cout << a - b << endl; break;
case '*': cout << a * b << endl; break;
case '/':
if (b == 0) cout << "На ноль делить нельзя";
else cout << a / b << endl;
break;
default:
cout << "Недопустимое значение знака" << endl;
break;
}
}
}
| [
"themusik.batbka@gmail.com"
] | themusik.batbka@gmail.com |
75d5d3deeb60f17d48df852a26508502f35b1e7a | 0bbbcd13770b48c97766c7bb7e04f580035ffa52 | /ShmDataFrame/linuxShm.h | 281efca80ec2656836c3d89ff5d50b0519898142 | [] | no_license | cccoast/cpp_utils | 9d8899ef7e003f7cfff2d435a8907d3f62c7d17e | aeab9b174fadd3fb41521512ed9b222bb2f07d2a | refs/heads/master | 2021-10-20T22:16:31.296458 | 2019-03-02T11:47:08 | 2019-03-02T11:47:08 | 93,930,861 | 1 | 1 | null | 2019-01-12T16:08:07 | 2017-06-10T10:01:53 | C++ | UTF-8 | C++ | false | false | 5,989 | h | ///@author xudi
///This file is used for map file to memory
///Base library for ShareMemory
#ifndef __LINUX_SHM__
#define __LINUX_SHM__
#include <iostream>
#include <string>
#include <memory>
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <unistd.h>
#include <sys/ipc.h>
#include <sys/shm.h>
#include <sys/types.h>
#include <sys/fcntl.h>
#include <sys/stat.h>
#include <sys/mman.h>
using namespace std;
static bool createFixedSizeFile(string fileName, size_t reqSize)
{
FILE* fd = fopen(fileName.c_str(), "w+");
if (fd == NULL)
{
return false;
}
fseek(fd, reqSize, 0);
char a = EOF;
size_t ret = fwrite((void*)&a, sizeof(char),1,fd);
fclose(fd);
return (ret == sizeof(char));
}
static void fileSeek (FILE* fd, long long distance)
{
fseek(fd, distance, SEEK_CUR);
}
static size_t getFileSizeSysCall(string fileName)
{
struct stat sb;
int fd = open(fileName.c_str(),O_RDONLY);
if (fstat(fd, &sb) == -1)
{
close(fd);
return -1;
}
close(fd);
return sb.st_size;
}
static size_t getFileSize(string fileName)
{
#if (0)
FILE* fd = fopen(fileName.c_str(), "rb");
if (fd == NULL)
{
return false;
}
fseek(fd, 0, SEEK_END);
size_t fsize = ftell(fd);
fclose(fd);
return fsize;
#else
return getFileSizeSysCall(fileName);
#endif
}
static bool deleteShm(string& key)
{
#if (1)
int shmid;
long long ipc_key = stoll(key,0,16);
shmid = shmget(ipc_key, 0, 0);
struct shmid_ds shmds;
size_t ret = shmctl(shmid, IPC_STAT, &shmds);
if (shmid >= 0 && ret != -1)
{
if (shmds.shm_nattch != 0)
{
cerr << "cann't delete shm, nattach more the one" << endl;
return false;
}
int ret = shmctl(shmid, IPC_RMID, 0);
return (ret == 0);
}
else
{
return false;
}
#else
boost::format s("ipcrm -M %1%");
char buff[1024] = {0};
s % key;
FILE* fd = popen(s.str().c_str(),"r");
fgets(buff,1023,fd);
fclose(fd);
return (atoi(buff) == 0);
#endif
}
class LinuxMMap
{
private:
string file_name;
size_t fsize;
void* start_addr;
int fd;
public:
LinuxMMap(string fname):file_name(fname),fsize(0),start_addr(NULL),fd(-1)
{
fsize = getFileSize(fname);
}
~LinuxMMap()
{
if(start_addr)
{
munmap(start_addr,fsize);
start_addr = NULL;
}
if(fd > 0) close(fd);
}
void* get_start_addr()
{
return start_addr;
}
int create_handler()
{
if(fd < 0)
{
fd = open(file_name.c_str(),O_RDWR);
}
return fd;
}
void* create_start_addr()
{
if(fd < 0) this->create_handler();
if(fd > 0)
{
start_addr = mmap(0, fsize, PROT_READ|PROT_WRITE, MAP_SHARED, fd, 0);
return start_addr;
}
return NULL;
}
bool flush()
{
if(start_addr)
{
return ( msync(start_addr,fsize,MS_SYNC) == 0 );
}
return false;
}
void close_file()
{
if(start_addr)
{
munmap(start_addr,fsize);
start_addr = NULL;
close(fd);
fd = -1;
}
}
};
class LinuxShmAdaptor
{
string key;
long long int_key;
void* start_addr;
int handler;
public:
LinuxShmAdaptor(string _key)
{
key = _key;
int_key = stoll(_key,0,16);
start_addr = NULL;
handler = -1;
}
~LinuxShmAdaptor()
{
}
string get_key()
{
return key;
}
long long get_int_key()
{
return int_key;
}
int get_mem_handler()
{
return handler;
}
void set_mem_handler(int _handler)
{
handler = _handler;
}
int create_mem_handler()
{
if (handler >= 0)
{
return handler;
}
else
{
if(this->key.length() > 0)
{
handler = shmget(int_key,0,0);
}
return handler;
}
}
void* get_start_addr()
{
return start_addr;
}
void* create_start_addr()
{
if (start_addr != NULL)
{
return start_addr;
}
else
{
if(handler < 0)
{
this->create_mem_handler();
}
if(handler >= 0)
{
start_addr = shmat(handler,NULL,0);
return start_addr;
}
else
{
return NULL;
}
}
}
};
/// This Creator is used to create ipc Key only once
/// If Key already exits, return -1
class LinuxShmCreator:public LinuxShmAdaptor
{
private:
unsigned long long shm_size;
public:
LinuxShmCreator(string key):LinuxShmAdaptor(key) {}
int create_memory(unsigned long long _size)
{
this->shm_size = _size;
if( (this->get_mem_handler() < 0) && _size > 0)
{
if(shmget(this->get_int_key(), 0, 0) < 0)
{
//cout << "not exist!" << endl;
this->set_mem_handler( shmget(this->get_int_key(), _size, IPC_CREAT | 0666) );
}
else
{
//cout << "exist!" << endl;
this->set_mem_handler(-1);
return -1;
}
}
else
{
return -1;
}
if(this->get_mem_handler() < 0)
{
this->set_mem_handler(-1);
}
return this->get_mem_handler();
}
bool delete_memory()
{
string s = this->get_key();
bool ret = deleteShm(s);
if( ret )
{
this->set_mem_handler(-1);
return true;
}
else return false;
}
};
#endif
| [
"xudi1989@ruc.edu.cn"
] | xudi1989@ruc.edu.cn |
a85b5055b536887ccee005033ae116a63cdc2931 | 2b631cb14b185044e4201c9cc8be8219c5ab7556 | /ml/nn/runtime/test/generated/vts_models/local_response_norm_float_2.model.cpp | 42a36fe67f9f98a2337f683c47c7d55626976b8a | [
"Apache-2.0"
] | permissive | yuchuangu85/Android-framework-code | 59837ba3e41ebdda7de74ce82e1af2d0367610ce | fb27715328b4b0064b0f4e7b499b8c0f2e728d61 | refs/heads/master | 2020-09-03T09:00:20.642461 | 2019-11-04T16:21:25 | 2019-11-04T16:21:25 | 219,429,555 | 2 | 3 | null | null | null | null | UTF-8 | C++ | false | false | 5,706 | cpp | // clang-format off
// Generated file (from: local_response_norm_float_2.mod.py). Do not edit
// Create the model
Model createTestModel() {
const std::vector<Operand> operands = {
{
.type = OperandType::TENSOR_FLOAT32,
.dimensions = {1, 1, 1, 6},
.numberOfConsumers = 1,
.scale = 0.0f,
.zeroPoint = 0,
.lifetime = OperandLifeTime::MODEL_INPUT,
.location = {.poolIndex = 0, .offset = 0, .length = 0},
},
{
.type = OperandType::INT32,
.dimensions = {},
.numberOfConsumers = 1,
.scale = 0.0f,
.zeroPoint = 0,
.lifetime = OperandLifeTime::CONSTANT_COPY,
.location = {.poolIndex = 0, .offset = 0, .length = 4},
},
{
.type = OperandType::FLOAT32,
.dimensions = {},
.numberOfConsumers = 1,
.scale = 0.0f,
.zeroPoint = 0,
.lifetime = OperandLifeTime::CONSTANT_COPY,
.location = {.poolIndex = 0, .offset = 4, .length = 4},
},
{
.type = OperandType::FLOAT32,
.dimensions = {},
.numberOfConsumers = 1,
.scale = 0.0f,
.zeroPoint = 0,
.lifetime = OperandLifeTime::CONSTANT_COPY,
.location = {.poolIndex = 0, .offset = 8, .length = 4},
},
{
.type = OperandType::FLOAT32,
.dimensions = {},
.numberOfConsumers = 1,
.scale = 0.0f,
.zeroPoint = 0,
.lifetime = OperandLifeTime::CONSTANT_COPY,
.location = {.poolIndex = 0, .offset = 12, .length = 4},
},
{
.type = OperandType::TENSOR_FLOAT32,
.dimensions = {1, 1, 1, 6},
.numberOfConsumers = 0,
.scale = 0.0f,
.zeroPoint = 0,
.lifetime = OperandLifeTime::MODEL_OUTPUT,
.location = {.poolIndex = 0, .offset = 0, .length = 0},
}
};
const std::vector<Operation> operations = {
{
.type = OperationType::LOCAL_RESPONSE_NORMALIZATION,
.inputs = {0, 1, 2, 3, 4},
.outputs = {5},
}
};
const std::vector<uint32_t> inputIndexes = {0};
const std::vector<uint32_t> outputIndexes = {5};
std::vector<uint8_t> operandValues = {
20, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 63, 0, 0, 0, 63
};
const std::vector<hidl_memory> pools = {};
return {
.operands = operands,
.operations = operations,
.inputIndexes = inputIndexes,
.outputIndexes = outputIndexes,
.operandValues = operandValues,
.pools = pools,
};
}
inline bool is_ignored(int i) {
static std::set<int> ignore = {};
return ignore.find(i) != ignore.end();
}
// Create the model
Model createTestModel_dynamic_output_shape() {
const std::vector<Operand> operands = {
{
.type = OperandType::TENSOR_FLOAT32,
.dimensions = {1, 1, 1, 6},
.numberOfConsumers = 1,
.scale = 0.0f,
.zeroPoint = 0,
.lifetime = OperandLifeTime::MODEL_INPUT,
.location = {.poolIndex = 0, .offset = 0, .length = 0},
},
{
.type = OperandType::INT32,
.dimensions = {},
.numberOfConsumers = 1,
.scale = 0.0f,
.zeroPoint = 0,
.lifetime = OperandLifeTime::CONSTANT_COPY,
.location = {.poolIndex = 0, .offset = 0, .length = 4},
},
{
.type = OperandType::FLOAT32,
.dimensions = {},
.numberOfConsumers = 1,
.scale = 0.0f,
.zeroPoint = 0,
.lifetime = OperandLifeTime::CONSTANT_COPY,
.location = {.poolIndex = 0, .offset = 4, .length = 4},
},
{
.type = OperandType::FLOAT32,
.dimensions = {},
.numberOfConsumers = 1,
.scale = 0.0f,
.zeroPoint = 0,
.lifetime = OperandLifeTime::CONSTANT_COPY,
.location = {.poolIndex = 0, .offset = 8, .length = 4},
},
{
.type = OperandType::FLOAT32,
.dimensions = {},
.numberOfConsumers = 1,
.scale = 0.0f,
.zeroPoint = 0,
.lifetime = OperandLifeTime::CONSTANT_COPY,
.location = {.poolIndex = 0, .offset = 12, .length = 4},
},
{
.type = OperandType::TENSOR_FLOAT32,
.dimensions = {0, 0, 0, 0},
.numberOfConsumers = 0,
.scale = 0.0f,
.zeroPoint = 0,
.lifetime = OperandLifeTime::MODEL_OUTPUT,
.location = {.poolIndex = 0, .offset = 0, .length = 0},
}
};
const std::vector<Operation> operations = {
{
.type = OperationType::LOCAL_RESPONSE_NORMALIZATION,
.inputs = {0, 1, 2, 3, 4},
.outputs = {5},
}
};
const std::vector<uint32_t> inputIndexes = {0};
const std::vector<uint32_t> outputIndexes = {5};
std::vector<uint8_t> operandValues = {
20, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 63, 0, 0, 0, 63
};
const std::vector<hidl_memory> pools = {};
return {
.operands = operands,
.operations = operations,
.inputIndexes = inputIndexes,
.outputIndexes = outputIndexes,
.operandValues = operandValues,
.pools = pools,
};
}
inline bool is_ignored_dynamic_output_shape(int i) {
static std::set<int> ignore = {};
return ignore.find(i) != ignore.end();
}
| [
"yuchuangu85@gmail.com"
] | yuchuangu85@gmail.com |
f9f3a106595c56cb34a05c0b5f7f19e981731994 | 9d774a63b6f0959a1b33b3b1889b44f424ad0844 | /src/Delegate.h | c7157d71629b43f7bb1e1105b8f2773608e2713f | [
"Unlicense"
] | permissive | N1kla3/EventSystem | 85ba158f17dbc009dbbdd8a6ec7d17dea4701354 | 6a458fcd8f4b273d0a860de72bfcfeda90d9802d | refs/heads/master | 2023-07-15T07:34:56.359976 | 2021-08-22T15:22:17 | 2021-08-22T15:22:17 | 391,685,927 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,325 | h | //
// Created by kolya on 8/1/2021.
//
#pragma once
#include <any>
#include <functional>
#include <iostream>
template<typename ...Args>
class MemberFunctionHolderBase
{
public:
virtual void Invoke(Args...) = 0;
virtual ~MemberFunctionHolderBase() = default;
};
template<typename Object, typename ...Args>
class MemberFunctionHolder : public MemberFunctionHolderBase<Args...>
{
typedef typename std::function<void(Object&, Args...)> ObjectFunction;
public:
void StoreObject(const std::shared_ptr<Object>& inObj, ObjectFunction& inFunction)
{
if (inObj && inFunction)
{
m_Object = inObj;
m_Function = inFunction;
}
}
virtual void Invoke(Args... args) override
{
if (!m_Object.expired())
{
m_Function(*m_Object.lock(), args...);
}
}
virtual ~MemberFunctionHolder() = default;
private:
std::weak_ptr<Object> m_Object;
ObjectFunction m_Function;
};
template<typename ...Args>
class Delegate
{
typedef typename std::function<void(Args...)> Function;
public:
template<typename Object>
void AddMemberFunction(const std::shared_ptr<Object>& obj, std::function<void(Object&, Args...)> inFunction)
{
typedef typename std::function<void(Object&, Args...)> MemberFunction;
if (obj)
{
auto* member_function = new MemberFunctionHolder<Object, Args...>;
member_function->StoreObject(obj, inFunction);
m_MemberFunction.reset(member_function);
}
else
{
RemoveAll();
}
}
void Add(const Function& Func)
{
m_Internal = Func;
}
void Invoke(Args... args) const
{
if (m_Internal)
{
m_Internal(args...);
}
else if (m_MemberFunction)
{
m_MemberFunction->Invoke(args...);
}
}
void RemoveAll()
{
m_Internal = nullptr;
m_MemberFunction.release();
}
Delegate() = default;
Delegate(Delegate&& delegate) noexcept = default;
Delegate(const Delegate& delegate) = delete;
virtual ~Delegate()
= default;
protected:
private:
Function m_Internal = nullptr;
std::unique_ptr<MemberFunctionHolderBase<Args...>> m_MemberFunction;
};
| [
"kolya.vladimirsky@gmail.com"
] | kolya.vladimirsky@gmail.com |
07c099057f133b8067d862835273bd63c3f4b062 | d6fc2ee2922f87917e7b734fac9bdcd819fba417 | /src/qt/reeccoin/settings/settingsbittoolwidget.cpp | 58e74548c51508d5da4307efe0bb50c637acf52c | [
"MIT"
] | permissive | reeccoin/REEC | 4b8b7ae4ef333f5e14083a09c570269400c5c5b2 | eb388d692aa7039dfe78247c829e4d348ff1f631 | refs/heads/main | 2023-01-20T01:43:03.427006 | 2020-11-30T15:59:44 | 2020-11-30T15:59:44 | 305,126,788 | 2 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 11,993 | cpp | // Copyright (c) 2019-2020 The PIVX developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "qt/reeccoin/settings/settingsbittoolwidget.h"
#include "qt/reeccoin/settings/forms/ui_settingsbittoolwidget.h"
#include "qt/reeccoin/qtutils.h"
#include "guiutil.h"
#include "walletmodel.h"
#include "base58.h"
#include "bip38.h"
#include "init.h"
#include "wallet/wallet.h"
#include "askpassphrasedialog.h"
#include <string>
#include <vector>
SettingsBitToolWidget::SettingsBitToolWidget(REECCOINGUI* _window, QWidget *parent) :
PWidget(_window, parent),
ui(new Ui::SettingsBitToolWidget)
{
ui->setupUi(this);
this->setStyleSheet(parent->styleSheet());
/* Containers */
setCssProperty(ui->left, "container");
ui->left->setContentsMargins(10,10,10,10);
/* Title */
setCssTitleScreen(ui->labelTitle);
//Button Group
setCssProperty(ui->pushLeft, "btn-check-left");
setCssProperty(ui->pushRight, "btn-check-right");
ui->pushLeft->setChecked(true);
// Subtitle
setCssSubtitleScreen(ui->labelSubtitle1);
// Key
setCssProperty(ui->labelSubtitleKey, "text-title");
initCssEditLine(ui->lineEditKey);
// Passphrase
setCssProperty(ui->labelSubtitlePassphrase, "text-title");
initCssEditLine(ui->lineEditPassphrase);
// Decrypt controls
setCssProperty(ui->labelSubtitleDecryptResult, "text-title");
ui->lineEditDecryptResult->setAttribute(Qt::WA_MacShowFocusRect, 0);
ui->lineEditDecryptResult->setReadOnly(true);
initCssEditLine(ui->lineEditDecryptResult);
// Buttons
setCssBtnPrimary(ui->pushButtonDecrypt);
setCssProperty(ui->pushButtonImport, "btn-text-primary");
ui->pushButtonImport->setVisible(false);
connect(ui->pushLeft, &QPushButton::clicked, [this](){onEncryptSelected(true);});
connect(ui->pushRight, &QPushButton::clicked, [this](){onEncryptSelected(false);});
// Encrypt
// Address
setCssProperty(ui->labelSubtitleAddress, "text-title");
setCssProperty(ui->addressIn_ENC, "edit-primary-multi-book");
ui->addressIn_ENC->setAttribute(Qt::WA_MacShowFocusRect, 0);
setShadow(ui->addressIn_ENC);
// Message
setCssProperty(ui->labelSubtitleMessage, "text-title");
setCssProperty(ui->passphraseIn_ENC, "edit-primary");
setShadow(ui->passphraseIn_ENC);
ui->passphraseIn_ENC->setAttribute(Qt::WA_MacShowFocusRect, 0);
// Encrypted Key
setCssProperty(ui->labelSubtitleEncryptedKey, "text-title");
ui->encryptedKeyOut_ENC->setAttribute(Qt::WA_MacShowFocusRect, 0);
ui->encryptedKeyOut_ENC->setReadOnly(true);
initCssEditLine(ui->encryptedKeyOut_ENC);
btnContact = ui->addressIn_ENC->addAction(QIcon("://ic-contact-arrow-down"), QLineEdit::TrailingPosition);
setCssBtnPrimary(ui->pushButtonEncrypt);
setCssBtnSecondary(ui->pushButtonClear);
setCssBtnSecondary(ui->pushButtonDecryptClear);
ui->statusLabel_ENC->setStyleSheet("QLabel { color: transparent; }");
ui->statusLabel_DEC->setStyleSheet("QLabel { color: transparent; }");
connect(ui->pushButtonEncrypt, &QPushButton::clicked, this, &SettingsBitToolWidget::onEncryptKeyButtonENCClicked);
connect(ui->pushButtonDecrypt, &QPushButton::clicked, this, &SettingsBitToolWidget::onDecryptClicked);
connect(ui->pushButtonImport, &QPushButton::clicked, this, &SettingsBitToolWidget::importAddressFromDecKey);
connect(btnContact, &QAction::triggered, this, &SettingsBitToolWidget::onAddressesClicked);
connect(ui->pushButtonClear, &QPushButton::clicked, this, &SettingsBitToolWidget::onClearAll);
connect(ui->pushButtonDecryptClear, &QPushButton::clicked, this, &SettingsBitToolWidget::onClearDecrypt);
}
void SettingsBitToolWidget::setAddress_ENC(const QString& address)
{
ui->addressIn_ENC->setText(address);
ui->passphraseIn_ENC->setFocus();
}
void SettingsBitToolWidget::onEncryptSelected(bool isEncr)
{
ui->stackedWidget->setCurrentIndex(isEncr);
}
QString specialChar = "\"@!#$%&'()*+,-./:;<=>?`{|}~^_[]\\";
QString validChar = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz" + specialChar;
bool isValidPassphrase(QString strPassphrase, QString& strInvalid)
{
for (int i = 0; i < strPassphrase.size(); i++) {
if (!validChar.contains(strPassphrase[i], Qt::CaseSensitive)) {
if (QString("\"'").contains(strPassphrase[i]))
continue;
strInvalid = strPassphrase[i];
return false;
}
}
return true;
}
void SettingsBitToolWidget::onEncryptKeyButtonENCClicked()
{
if (!walletModel)
return;
QString qstrPassphrase = ui->passphraseIn_ENC->text();
QString strInvalid;
if (!isValidPassphrase(qstrPassphrase, strInvalid)) {
ui->statusLabel_ENC->setStyleSheet("QLabel { color: red; }");
ui->statusLabel_ENC->setText(tr("The entered passphrase is invalid. ") + strInvalid + QString(" is not valid") + QString(" ") + tr("Allowed: 0-9,a-z,A-Z,") + specialChar);
return;
}
CTxDestination dest = DecodeDestination(ui->addressIn_ENC->text().toStdString());
if (!IsValidDestination(dest)) {
ui->statusLabel_ENC->setStyleSheet("QLabel { color: red; }");
ui->statusLabel_ENC->setText(tr("The entered address is invalid.") + QString(" ") + tr("Please check the address and try again."));
return;
}
CKeyID keyID = *boost::get<CKeyID>(&dest);
if (!keyID) {
//ui->addressIn_ENC->setValid(false);
ui->statusLabel_ENC->setStyleSheet("QLabel { color: red; }");
ui->statusLabel_ENC->setText(tr("The entered address does not refer to a key.") + QString(" ") + tr("Please check the address and try again."));
return;
}
WalletModel::UnlockContext ctx(walletModel->requestUnlock());
if (!ctx.isValid()) {
ui->statusLabel_ENC->setStyleSheet("QLabel { color: red; }");
ui->statusLabel_ENC->setText(tr("Wallet unlock was cancelled."));
return;
}
CKey key;
if (!pwalletMain->GetKey(keyID, key)) {
ui->statusLabel_ENC->setStyleSheet("QLabel { color: red; }");
ui->statusLabel_ENC->setText(tr("Private key for the entered address is not available."));
return;
}
std::string encryptedKey = BIP38_Encrypt(EncodeDestination(dest), qstrPassphrase.toStdString(), key.GetPrivKey_256(), key.IsCompressed());
ui->encryptedKeyOut_ENC->setText(QString::fromStdString(encryptedKey));
ui->statusLabel_ENC->setStyleSheet("QLabel { color: green; }");
ui->statusLabel_ENC->setText(QString("<nobr>") + tr("Address encrypted.") + QString("</nobr>"));
}
void SettingsBitToolWidget::onClearAll()
{
ui->addressIn_ENC->clear();
ui->passphraseIn_ENC->clear();
ui->encryptedKeyOut_ENC->clear();
ui->statusLabel_ENC->clear();
ui->addressIn_ENC->setFocus();
}
void SettingsBitToolWidget::onAddressesClicked()
{
int addressSize = walletModel->getAddressTableModel()->sizeRecv();
if (addressSize == 0) {
inform(tr("No addresses available, you can go to the receive screen and add some there!"));
return;
}
int height = (addressSize <= 2) ? ui->addressIn_ENC->height() * ( 2 * (addressSize + 1 )) : ui->addressIn_ENC->height() * 4;
int width = ui->containerAddressEnc->width();
if (!menuContacts) {
menuContacts = new ContactsDropdown(
width,
height,
this
);
menuContacts->setWalletModel(walletModel, AddressTableModel::Receive);
connect(menuContacts, &ContactsDropdown::contactSelected, [this](QString address, QString label){
setAddress_ENC(address);
});
}
if (menuContacts->isVisible()) {
menuContacts->hide();
return;
}
menuContacts->resizeList(width, height);
menuContacts->setStyleSheet(this->styleSheet());
menuContacts->adjustSize();
QPoint pos = ui->containerAddressEnc->rect().bottomLeft();
pos.setY(pos.y() + ui->containerAddressEnc->height());
pos.setX(pos.x() + 10);
menuContacts->move(pos);
menuContacts->show();
}
void SettingsBitToolWidget::resizeMenu()
{
if (menuContacts && menuContacts->isVisible()) {
int width = ui->containerAddress->width();
menuContacts->resizeList(width, menuContacts->height());
menuContacts->resize(width, menuContacts->height());
QPoint pos = ui->containerAddressEnc->rect().bottomLeft();
pos.setY(pos.y() + ui->containerAddressEnc->height());
pos.setX(pos.x() + 10);
menuContacts->move(pos);
}
}
void SettingsBitToolWidget::onClearDecrypt()
{
ui->lineEditKey->clear();
ui->lineEditDecryptResult->clear();
ui->lineEditPassphrase->clear();
ui->pushButtonImport->setVisible(false);
key = CKey();
}
void SettingsBitToolWidget::onDecryptClicked()
{
std::string strPassphrase = ui->lineEditPassphrase->text().toStdString();
std::string strKey = ui->lineEditKey->text().toStdString();
uint256 privKey;
bool fCompressed;
if (!BIP38_Decrypt(strPassphrase, strKey, privKey, fCompressed)) {
ui->statusLabel_DEC->setStyleSheet("QLabel { color: red; }");
ui->statusLabel_DEC->setText(tr("Failed to decrypt.") + QString(" ") + tr("Please check the key and passphrase and try again."));
return;
}
key.Set(privKey.begin(), privKey.end(), fCompressed);
CPubKey pubKey = key.GetPubKey();
ui->lineEditDecryptResult->setText(QString::fromStdString(EncodeDestination(pubKey.GetID())));
ui->pushButtonImport->setVisible(true);
}
void SettingsBitToolWidget::importAddressFromDecKey()
{
WalletModel::UnlockContext ctx(walletModel->requestUnlock());
if (!ctx.isValid()) {
ui->statusLabel_DEC->setStyleSheet("QLabel { color: red; }");
ui->statusLabel_DEC->setText(tr("Wallet unlock was cancelled."));
return;
}
CTxDestination dest = DecodeDestination(ui->lineEditDecryptResult->text().toStdString());
CPubKey pubkey = key.GetPubKey();
if (!IsValidDestination(dest) || !key.IsValid() || EncodeDestination(pubkey.GetID()) != EncodeDestination(dest)) {
ui->statusLabel_DEC->setStyleSheet("QLabel { color: red; }");
ui->statusLabel_DEC->setText(tr("Data Not Valid.") + QString(" ") + tr("Please try again."));
return;
}
CKeyID vchAddress = pubkey.GetID();
{
ui->statusLabel_DEC->setStyleSheet("QLabel { color: red; }");
ui->statusLabel_DEC->setText(tr("Please wait while key is imported"));
pwalletMain->MarkDirty();
pwalletMain->SetAddressBook(vchAddress, "", AddressBook::AddressBookPurpose::RECEIVE);
// Don't throw error in case a key is already there
if (pwalletMain->HaveKey(vchAddress)) {
ui->statusLabel_DEC->setStyleSheet("QLabel { color: red; }");
ui->statusLabel_DEC->setText(tr("Cannot import address, key already held by the wallet"));
return;
}
pwalletMain->mapKeyMetadata[vchAddress].nCreateTime = 1;
if (!pwalletMain->AddKeyPubKey(key, pubkey)) {
ui->statusLabel_DEC->setStyleSheet("QLabel { color: red; }");
ui->statusLabel_DEC->setText(tr("Error adding key to the wallet"));
return;
}
// whenever a key is imported, we need to scan the whole chain
pwalletMain->nTimeFirstKey = 1; // 0 would be considered 'no value'
pwalletMain->ScanForWalletTransactions(chainActive.Genesis(), true);
}
ui->statusLabel_DEC->setStyleSheet("QLabel { color: green; }");
ui->statusLabel_DEC->setText(tr("Successfully added private key to the wallet"));
}
void SettingsBitToolWidget::resizeEvent(QResizeEvent *event)
{
resizeMenu();
QWidget::resizeEvent(event);
}
SettingsBitToolWidget::~SettingsBitToolWidget()
{
delete ui;
}
| [
"69335017+reeccoin@users.noreply.github.com"
] | 69335017+reeccoin@users.noreply.github.com |
6833a8f21508092474932e4c41b1b4cc38c12d9c | 13b14c9c75143bf2eda87cb4a41006a52dd6f02b | /Uva/Uva2008/820/820.cpp | 8d29813c34921af58a0bbf4e88feb8746a22eafe | [] | no_license | yutaka-watanobe/problem-solving | 2c311ac856c79c20aef631938140118eb3bc3835 | f0b92125494fbd3c8d203989ec9fef53f52ad4b4 | refs/heads/master | 2021-06-03T12:58:39.881107 | 2020-12-16T14:34:16 | 2020-12-16T14:34:16 | 94,963,754 | 0 | 1 | null | null | null | null | UTF-8 | C++ | false | false | 3,042 | cpp | #include<iostream>
#include<vector>
#include<queue>
#include<algorithm>
using namespace std;
//#define REP(i, e) for ( int i = 0; i < (int)e; i++ )
#define MAX 1000
// source = node 0
// sink = node size-1
class Network{
public:
int size, flow[MAX][MAX], capacity[MAX][MAX];
vector<int> adjLists[MAX];
vector<int>::iterator it[MAX];
Network(){}
Network( int size ): size(size){
for ( int i = 0; i < size; i++ ){
for ( int j = 0; j < size; j++ ){
flow[i][j] = capacity[i][j] = 0;
}
}
}
int next( int node ){
if ( it[node] != adjLists[node].end() ) return *it[node]++;
else return -1;
}
void insert( int source, int target, int cap ){
if ( cap <= 0 ) return;
if ( capacity[source][target] == 0 ){
adjLists[source].push_back( target );
adjLists[target].push_back( source );
capacity[source][target] = cap;
capacity[target][source] = cap;
} else {
capacity[source][target] += cap;
capacity[target][source] += cap;
}
}
void reset( int node ){
it[node] = adjLists[node].begin();
}
void reset(){
for ( int node = 0; node < size; node++ ) reset(node);
}
};
bool bfs( Network &network, int pi[], int source, int target ){
bool visited[MAX];
queue<int> Q;
for ( int i = 0; i < network.size; i++ ) {
visited[i] = false;
pi[i] = -1;
}
int u, v;
Q.push( source );
visited[source] = true;
network.reset();
while( !Q.empty() ){
u = Q.front(); Q.pop();
if ( u == target ) return true;
while ( ( v = network.next(u) ) != -1 ){
if ( visited[v] ) continue;
if ( network.capacity[u][v] > network.flow[u][v] ){
pi[v] = u;
visited[v] = true;
Q.push(v);
}
}
}
return false;
}
int edmonds_karp( Network &network, int source, int target ){
if ( source == target ) return 0;
int flow;
int pi[MAX];
while ( bfs( network, pi, source, target ) ){
flow = INT_MAX;
for ( int v = network.size-1; v != 0; v = pi[v] ){
int u = pi[v];
flow = min( flow, network.capacity[u][v] - network.flow[u][v]);
}
for ( int v = network.size-1; v != 0; v = pi[v] ){
int u = pi[v];
network.flow[u][v] += flow;
network.flow[v][u] = -network.flow[u][v];
}
}
int v;
network.reset(0);
for ( flow = 0; (v=network.next(0)) != -1; flow += network.flow[0][v] );
return flow;
}
Network network;
int size, source, target;
void input(){
int s, t, c, cap;
cin >> source >> target >> c;
// if ( source > target ) swap(source, target );
network = Network(size+2);
for ( int i = 0; i < c; i++ ){
cin >> s >> t >> cap;
if ( s == source ) s = 0;
if ( s == target ) s = size+1;
if ( t == source ) t = 0;
if ( t == target ) t = size+1;
network.insert( s, t, cap );
}
}
int main(){
int tcase = 1;
while(cin >> size && size ){
cout << "Network " << tcase++ << endl;
input();
cout << "The bandwidth is " << edmonds_karp( network, 0, size+1 ) << "." << endl;
cout << endl;
}
return 0;
}
| [
"y.watanobe@gmail.com"
] | y.watanobe@gmail.com |
ab2dd5999cd2637a5c56bda87c60fc63176a65e6 | 58549d2d1dfd7bdafa188d8f3e1924686a7a4fa6 | /Lab/2/GArray.h | f119ad23370eedd25fab97a3f270d3e7895cdf3a | [] | no_license | cptalpdeniz/CPSC2150 | 492f0ee272e8185139fcdd3e60bcc1e288744b3a | bc7a8f0e1cfd7824f95355e00eb11a30d8aaac37 | refs/heads/master | 2023-01-28T19:24:47.691979 | 2020-12-09T18:19:48 | 2020-12-09T18:19:48 | 295,884,595 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,576 | h | #ifndef GARRAY_H
#define GARRAY_H
/*
Name: Alp Deniz Senyurt
Student Number: 100342433
defined by Gladys Monagan
A growing array
*/
#include <string>
using std::string;
class GArray {
public:
// create an empty array
GArray();
// return if the array is empty, false otherwise
bool isEmpty() const;
// append x to the end of the array
// precondition: there is enough heap memory
// postcondition: x is placed as the last element and the length grows
void append(int x);
// return the number of elements in the array
int length() const;
// determine if x is in the array
// postcondition: return true if in array, false otherwise
bool search(int x) const;
// return the first element of the array and GArray::NADA if the array is empty
int first() const;
// return the last element of the array and GArray::NADA if the array is empty
int last() const;
// mutator method (function) that reverses the array
void reverse();
// return a string consisting of
// {
// ' '
// a1
// ' '
// a2
// ' '
// ...
// an
// ' '
// }
// all the elements of the array separated by blanks
// e.g. a string of 3 elements "{ 41 36 999 }"
string toString() const;
// return true if the lfSide is equal to the rtSide
// meaning that the elements of both arrays are equal and in the same order
friend bool operator == (const GArray& lfSide, const GArray& rtSide);
// copy constructor
// we assuming that there is enough heap memory to make a copy
GArray(const GArray&);
// overloaded assignment operator
// we assuming that there is enough heap memory to make a copy
GArray& operator = (const GArray&);
// destructor
~GArray();
// value returned when the array is empty and first() or last() is called
static const int NADA;
private:
struct Array {
int n; // the number of elements in the array
int* items; // the elements
int capacity; // the size of items namely
// how many elements were
// allocated in the last array memory allocation
};
Array A;
// return true when all the elements of a are identical to the elements of b
// false otherwise
static bool equalArrays(const Array&, const Array&);
// make a deep, proper copy of the array from and return the copy
Array copyArray(const Array& from);
// deallocate the dynamically allocated memory of array
void deleteArray(Array& array);
};
#endif
| [
"something@something.local"
] | something@something.local |
d953cdd0c716750abe912c0622be127dc52de4f3 | af69e335fc0ff9632964d061833713b672abad01 | /Temp/StagingArea/Data/il2cppOutput/mscorlib_System_Collections_Generic_GenericEqualit3314418425.h | 22a8fe028c2e2e892711fc1b2c7f75da4736afda | [] | no_license | PruthvishMShirur/Solar-System | ca143ab38cef582705f0beb76f7fef8b28e25ef9 | 5cf3eaa66949801aa9a34cd3cf80eeefa64d2342 | refs/heads/master | 2023-05-26T17:53:37.489349 | 2021-06-16T19:56:48 | 2021-06-16T19:56:48 | 377,611,177 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 614 | h | #pragma once
#include "il2cpp-config.h"
#ifndef _MSC_VER
# include <alloca.h>
#else
# include <malloc.h>
#endif
#include <stdint.h>
#include "mscorlib_System_Collections_Generic_EqualityCompar1249878500.h"
#ifdef __clang__
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Winvalid-offsetof"
#pragma clang diagnostic ignored "-Wunused-variable"
#endif
// System.Collections.Generic.GenericEqualityComparer`1<System.Object>
struct GenericEqualityComparer_1_t3314418425 : public EqualityComparer_1_t1249878500
{
public:
public:
};
#ifdef __clang__
#pragma clang diagnostic pop
#endif
| [
"42893637+PruthvishMShirur@users.noreply.github.com"
] | 42893637+PruthvishMShirur@users.noreply.github.com |
7a0b2753ebca1522ac2890ea95c1f874fe3e9d46 | 5ebf97b310e56bdf93125ffa42779f473537a10c | /Project_MemoryManagement_Test/stdafx.cpp | 38a4900cb2abe767f5c7266d22125c1f0c86c78a | [] | no_license | gregkalapos/MarkAndSweepGC | bd22f4807be5e5d2f1fb0e4b460ae6dbf2beb5ce | e50ad212aca4761fc6fc950d54b7d3ba76753cfb | refs/heads/master | 2021-01-15T16:17:35.400549 | 2015-03-26T19:05:25 | 2015-03-26T19:05:25 | 32,946,432 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 308 | cpp | // stdafx.cpp : source file that includes just the standard includes
// Project_MemoryManagement_Test.pch will be the pre-compiled header
// stdafx.obj will contain the pre-compiled type information
#include "stdafx.h"
// TODO: reference any additional headers you need in STDAFX.H
// and not in this file
| [
"gergo@kalapos.net"
] | gergo@kalapos.net |
e3d52397056bdbceb2646db0918a82a050550a97 | cba8737b4d2accc0866b48f51944651c0b86e858 | /ProyeccionMarcas/include/levenberg.h | 786dfa7da0c6f98f280cc2580f691b34dc9e782d | [] | no_license | Rajiv91/Tesis_completa_Rajiv | d4510620257988b43397a9d69c4e6a6443dabde8 | 25f8ff4d76059eca94277f66da61d587c7d0616a | refs/heads/master | 2021-01-20T16:51:05.425690 | 2017-09-27T23:53:15 | 2017-09-27T23:53:15 | 82,830,564 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 14,112 | h | #ifndef __LEVENBERG__
#define __LEVENBERG__
#include <cv.h>
#include <highgui.h>
#include <iostream>
#include "opencv2/opencv.hpp"
#include "opencv2/highgui/highgui.hpp"
#include <vector>
#include <cstdlib>
#include <cstdio>
#include "tools.h"
using namespace std;
using namespace cv;
// funciones y parametros globales
unsigned numFunEval = 0; // contador de llamadas a funcion
void evalFunc( void* param, double* X, double *F, Mat& Xscn, Mat& Ximg, Mat& R, Mat& Tr, Point3d& Nplane, double& D)
{
cout<<endl<<endl<<"Entrando a evalFunc"<<endl;
double *val = (double*) param;
int M, col, iters, nColN;
double cosw, sinw, Dtemp, rtemp, fx, fy, fz;
Mat scPt, Rtemp, Ttemp, Column;
Point3d Ximgi, Xscni, Ximg1, Ntemp, firstC, secondC, thirdC, scPt2;
M=int(val[1]);
iters=M/3;//son 3 coordenadas por cada punto
cosw=(1-cos(X[6]));
cout<<"normw= "<<X[6]<<endl;
sinw=sin(X[6]);
col=0;
firstC=Point3d((X[0]*X[0]-1)*cosw+1,
(X[2]*sinw+X[0]*X[1]*cosw),
X[0]*X[2]*cosw-X[1]*sinw);
secondC=Point3d((X[0]*X[1]*cosw)-(X[2]*sinw),
((X[1]*X[1]-1)*cosw)+1,
X[0]*sinw+X[1]*X[2]*cosw);
thirdC=Point3d(X[1]*sinw+X[0]*X[2]*cosw,
(-X[0]*sinw)+X[1]*X[2]*cosw,
((X[2]*X[2]-1)*cosw)+1);
Ntemp=thirdC;//N es la última columna de la matriz de rotación
Rtemp=(Mat_<double>(3,3)<<firstC.x, secondC.x, thirdC.x,
firstC.y, secondC.y, thirdC.y,
firstC.z, secondC.z, thirdC.z);//Creamos una matriz temporal de Rot para hallar la "d" de la ec. del plano
Ttemp=(Mat_<double>(3,1)<<X[3],
X[4],
X[5]);
cout<<"R="<<Rtemp<<endl<<"T="<<Ttemp<<endl;
R=Rtemp.clone();
Tr=Ttemp.clone();
nColN=0;
Column=(Mat_<double>(3,1)<<Xscn.at<double>(0,nColN),
Xscn.at<double>(1,nColN),
Xscn.at<double>(2,nColN));
//Column=Xscn(Rect(0,0,1,3));
//Column = Xscn(Rect(0,0,1,3));
scPt=Rtemp * Column;
scPt+=Ttemp;
//scPt=Rtemp*Xscn(Rect(11,0,1,3))+Ttemp;//
scPt2=Point3d(scPt.at<double>(0,nColN),
scPt.at<double>(1,nColN),
scPt.at<double>(2,nColN));
Dtemp=Ntemp.dot(scPt2);
Nplane=Ntemp;
D=Dtemp;
rtemp=0;
//Hasta este punto ya obtuvimos la nueva R, T, N y D que estamos optimizando
// salida de la funcion
for(int i=0; i<144; i+=3, col++)
//for(int i=0; i<iters; i+=3, col++)
{
Xscni=Point3d(Xscn.at<double>(0, col),
Xscn.at<double>(1, col),
Xscn.at<double>(2, col));
Ximgi=Point3d(Ximg.at<double>(0, col),
Ximg.at<double>(1, col),
Ximg.at<double>(2, col));
rtemp=Dtemp/(Ntemp.dot(Ximgi));
fx=(firstC.x*Xscni.x+secondC.x*Xscni.y+thirdC.x*Xscni.z+X[3])-(rtemp*Ximgi.x);
fy=(firstC.y*Xscni.x+secondC.y*Xscni.y+thirdC.y*Xscni.z+X[4])-(rtemp*Ximgi.y);
fz=(firstC.z*Xscni.x+secondC.z*Xscni.y+thirdC.z*Xscni.z+X[5])-(rtemp*Ximgi.z);
F[col]=fx*fx+fy*fy+fz*fz;
cout<<"f["<<col<<"]="<<F[col]<<", "<<endl;
/*
F[i]=pow((firstC.x*Xscni.x+secondC.x*Xscni.y+thirdC.x*Xscni.z+X[3])-(rtemp*Ximgi.x),2);
F[i+1]=pow((firstC.y*Xscni.x+secondC.y*Xscni.y+thirdC.y*Xscni.z+X[4])-(rtemp*Ximgi.y),2);
F[i+2]=pow((firstC.z*Xscni.x+secondC.z*Xscni.y+thirdC.z*Xscni.z+X[5])-(rtemp*Ximgi.z),2);
cout<<"f["<<i<<"]="<<F[i]<<", "<<
"f["<<i+1<<"]="<<F[i+1]<<", "<<
"f["<<i+2<<"]="<<F[i+2]<<", "<<endl;*/
}
// llamadas a la evaluacion
numFunEval++;
}
void Func( void* param, double* x, double *f, double* J, Mat& Xscn, Mat& Ximg, Mat& R, Mat& Tr , Point3d& Nplane, double& D)
{
// obtiene parametros del problema
double *val = (double*) param;
int N = int(val[0]);
int M = int(val[1]);
// salida de la funcion
//cout << "A" << endl; cout.flush();
evalFunc(param,x,f, Xscn, Ximg, R, Tr, Nplane, D);
//cout << "B" << endl; cout.flush();
#if 1
// calcula el gradiente
const double EPS=sqrt(DBL_EPSILON);
volatile double temp;
for(int r=0; r<N; r++)
{
// Encontrar el tamaño de h adecuado
temp=x[r]; // guarda valor original
double h=EPS*fabs(temp);
if(h<EPS)
h=EPS;
x[r]=temp+h; //Trick to reduce finite precision error
h=x[r]-temp;
evalFunc(param,x,&J[r*M], Xscn, Ximg, R, Tr, Nplane, D);
daxpy_(M,-1.0,f,1, &J[r*M],1);
dscal_(M,1.0/h,&J[r*M],1); //Usar este o el siguiente for
//~ for (int c=0; c<M; c++) //Usar este o el dscal anterior
//~ J[c+r*M]/=h;
x[r]=temp;
//break;//Debugeando..
}
#endif
// llamadas a la evaluacion
//numFunEval++;
}
void setW(Point3d& W, double Wnorm, Mat& R)
{
W=Point3d(R.at<double>(2,1)-R.at<double>(1, 2),
R.at<double>(0,2)-R.at<double>(2, 0),
R.at<double>(1,0)-R.at<double>(0, 1));
//cout<<"(2, 1): "<<R.at<double>(2,1)<<endl;
//W=W*(Wnorm/(2*sin(Wnorm)));
W=W*(1/(2*sin(Wnorm)));//Normalizado
}
void levenbergMain(Mat& R, Mat& Tr, Mat& K, Mat& frame, Mat& Ximg, Mat& scnPts, vector<Point2d>& P)
{
Mat marcas3d, marcas2d, mDummy, Xscn, frameCopy;
Size_<int> sizeG(4,4);
Mat G(sizeG, R.type());
Point3d Nplane;
Point3f Nplanef;
double D;
Scalar_<double> traza2;
traza2=trace(R);//Traza de R
double traza=traza2[0];
double Wnorm=acos((traza-1)/2);
Point3d W;
setW(W,Wnorm, R);
cout<<"W="<<endl<<W<<endl;
int nP=Ximg.cols;//número de puntos con los que se trabajará!!!!!!!!!!!!!!!!!!
Mat Id=Mat::eye(R.size(), R.type());
Mat wg=(Mat_<double>(3,3)<<0, -W.z, W.y,
W.z, 0, -W.x,
-W.y, W.x, 0);
Mat wg2=(Mat_<double>(3,3)<<W.x*W.x-1,W.x*W.y, W.x*W.z,
W.x*W.y, W.y*W.y-1, W.y*W.z,
W.x*W.z, W.y*W.z, W.z*W.z-1);
Xscn=scnPts(Rect(0,0,nP,3));
mDummy=(Mat_<double>(3, 4)<<1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0);
vector<Point2f>vps2d;
for(int i=0; i<nP; i++)
vps2d.push_back(Point2f(0,0));
//cout<<"wnorm="<<Wnorm<<endl<<"Id= "<<Id<<endl<<"wg = "<<wg<<endl<<"wg2="<<wg2<<endl;
//Número de parámetros a optimizar
const int N = 7;//Wx, Wy, Wz, Tx, Ty, Tz, Wnorm, Wnorm es necesario optimizarlo porque W depende de él
//const int M = nP*Xscn.rows;
const int M = nP;
// double parametros[] = {1.0, 100.0,double(N)}; // example 4.3
double parametros[] = {double(N),double(M)}; // ecaucion (5.5)
void *dummy = parametros;
// declara variables de computo
double* x = (double*) vectorr(N,sizeof(double));
double* xw = (double*) vectorr(N,sizeof(double));
double* g = (double*) vectorr(N,sizeof(double));
//double* go = (double*) vectorr(N,sizeof(double));
double* h = (double*) vectorr(N,sizeof(double));
//double* v = (double*) vectorr(N,sizeof(double));
double* A = (double*) vectorr(N*N,sizeof(double));
//double* D = (double*) vectorr(N*N,sizeof(double));
double* B = (double*) vectorr(N*M,sizeof(double));
double* Jw = (double*) vectorr(N*M,sizeof(double));
double* J = (double*) vectorr(N*M,sizeof(double));
double* f = (double*) vectorr(M,sizeof(double));//función
double* fw = (double*) vectorr(M,sizeof(double));
double* I = (double*) vectorr(N*N,sizeof(double));
double mu, nu=2;
double tao=1.0e-3;
// valores iniciales
double xo[N] = {W.x, W.y, W.z, Tr.at<double>(0,0), Tr.at<double>(1,0), Tr.at<double>(2,0), Wnorm};
double epsilon1 = 1.0e-10, epsilon2 = 1.0e-10, normG;
int pos,info,kmax=1000,k=0;
//inicializa variables de cómputo
dcopy_( N, xo, 1, x, 1 ); //posicion inicial
Func(dummy,x,f,B, Xscn, Ximg, R, Tr, Nplane, D); //valores iniciales
cout<< " F(X) : " << (0.5*ddot_(M,f,1,f,1)) << endl; cout.flush();
//Antes del for
cout<<"Antes del for(;;)"<<endl;
buildG(G, R, Tr);//Se actualiza la matriz G
marcas3d=G*scnPts;//Rotamos y trasladamos los puntos 3d
marcas2d=K*mDummy*marcas3d;//Los proyectamos en la imagen
//Deshomoge...
for (int i=0;i<marcas2d.cols;++i)
marcas2d(Rect(i, 0, 1, 3)) /= marcas2d.at<double>(2, i);
pointsSelect3dTo2D(P, vps2d, K, Nplanef, D, mDummy);//Con los puntos seleccionados del tablero se halla la intersección en el plano y se proyectan en 2D
frameCopy=frame.clone();
//Se pintan los resultados de los dos métodos: intersección con el plano y rot+tr
for(int j=0; j<marcas2d.cols; j++)
{
for(int i=0; i<vps2d.size(); i++)
circle(frameCopy, vps2d[i],1, Scalar(0, 0, 200) ,2);//Se pintan los puntos de las intersecciones
Point tempPoint(marcas2d.at<double>(0, j), marcas2d.at<double>(1, j));
circle(frameCopy, tempPoint,1, Scalar(0, 200, 0) ,2);//Se pintan los puntos rotados y trasladados
}
imshow("frame", frameCopy);
waitKey();
//**************************Despliegue*****************
cout<<"Fin"<<endl;
dscal_(N*N,0.0,I,1); //matriz I
for(int r=0;r<N;r++)
I[r*N+r]=1.0;
const char U='U';
const char T='T';
dsyrk_(U,T,N,M,1.0,B,M,0.0,A,N); //matriz A=B'B=J'J
dgemv_(&T,M,N,1.0,B,M,f,1.0,0.0,g,1); //g=B'f
pos=idamax_(N,g,1)-1; //norma INF de g
normG=fabs(g[pos]);
pos=idamax_(N,A,N); //amortiguamiento inicial
mu=tao*fabs(A[pos*N+pos]);
dcopy_( N*M, B, 1, J, 1 );
//inicia iteraciones
bool found=(normG<=epsilon1);
cvNamedWindow("frame",WINDOW_NORMAL );
Mat frameDummy=Mat::zeros(R.size(), CV_8UC1);
while(!found && (k<kmax))
{
//obtiene paso Gauss-Newton
dcopy_(N*N,I,1,A,1);//I->A
//cout<<"A antes: "<<A[0]<<", "<<A[1]<<", "<<A[2]<<", "<<A[3]<<endl;
dsyrk_(U,T,N,M,1.0,J,M,mu,A,N); //matriz A=(J'J + muI).
dcopy_(N,g,1,h,1);
dscal_(N,-1.0,h,1);
dposv_(U,N,1,A,N,h,N,info); //resuelve el sistema Ah=-g
if(info > 0)
{
cout << "\n\nError en la funcion de LAPACK...!!!\n";
}
//prueba criterios de paro
if(dnrm2_(N,h,1)<=epsilon2*(dnrm2_(N,x,1)+epsilon2))
found=true;
else
{
//estima nueva posicion y valores
dcopy_(N,x,1,xw,1);
daxpy_(N,1.0,h,1,xw,1);
Func(dummy,xw,fw,Jw, Xscn, Ximg, R, Tr, Nplane, D);
Nplanef.x=Nplane.x;
Nplanef.y=Nplane.y;
Nplanef.z=Nplane.z;
double ro=(ddot_(M,f,1,f,1)-ddot_(M,fw,1,fw,1))/(mu*ddot_(N,h,1,h,1)-ddot_(N,h,1,g,1));
//double ro=(ddot_(M,f,1,f,1)-ddot_(M,fw,1,fw,1))/(1.0/3.0)*(mu*ddot_(N,h,1,h,1)-ddot_(N,g,1,g,1));
if(ro>0.0)
{
//actualiza valores
dcopy_(N,xw,1,x,1);
dcopy_(M,fw,1,f,1);
dcopy_(M*N,Jw,1,J,1);
//dsyrk_(U,T,N,M,1.0,B,M,0.0,A,N);
dgemv_("T",M,N,1.0,J,M,f,1.0,0.0,g,1); //vector g=J'f
//actualiza parametro de amortiguamiento
double v1=1.0/3.0;
double v2=1.0-pow(2.0*ro-1.0,3.0);
mu*=((v1>v2) ? v1:v2);
nu=2.0;
}
else
{
mu*=nu;
nu*=2.0;
}
pos=idamax_(N,g,1)-1; //norma INF de g
normG=fabs(g[pos]);
found=(normG<=epsilon1);
}
k++; //contador
buildG(G, R, Tr);//Se actualiza la matriz G
marcas3d=G*scnPts;//Rotamos y trasladamos los puntos 3d
marcas2d=K*mDummy*marcas3d;//Los proyectamos en la imagen
//Deshomoge...
for (int i=0;i<marcas2d.cols;++i)
marcas2d(Rect(i, 0, 1, 3)) /= marcas2d.at<double>(2, i);
pointsSelect3dTo2D(P, vps2d, K, Nplanef, D, mDummy);//Con los puntos seleccionados del tablero se halla la intersección en el plano y se proyectan en 2D
frameCopy=frame.clone();
//Se pintan los resultados de los dos métodos: intersección con el plano y rot+tr
for(int j=0; j<marcas2d.cols; j++)
{
for(int i=0; i<vps2d.size(); i++)
circle(frameCopy, vps2d[i],1, Scalar(0, 0, 200) ,2);//Se pintan los puntos de las intersecciones
Point tempPoint(marcas2d.at<double>(0, j), marcas2d.at<double>(1, j));
circle(frameCopy, tempPoint,1, Scalar(0, 200, 0) ,2);//Se pintan los puntos rotados y trasladados
}
imshow("frame", frameCopy);
cout<< " F(X) : " << (0.5*ddot_(M,f,1,f,1)) << endl; cout.flush();
waitKey(10);
}
// despliega valores
cout << endl << "Valores finales" << endl
<< " num. iteraciones : " << k << endl
<< " num. eval. func. : " << numFunEval << endl
<< scientific
<< " F(X) : " << (0.5*ddot_(M,f,1,f,1)) << endl
<< " ||g|| : " << normG << endl
<< endl;
cout<<endl<<"posicion optima"<<endl<<"x=["<<endl;
for(int r=0;r<N;r++)
cout<<" "<<x[r]<<endl;
cout<<"]"<<endl<<endl;
//cout<<"K="<<K<<endl;
cout<<"R="<<R<<endl<<"T = "<<Tr<<endl;
cout<<"N = "<<Nplanef<<endl<<"D = "<<D<<endl;
//última pintada
buildG(G, R, Tr);//Se actualiza la matriz G
marcas3d=G*scnPts;//Rotamos y trasladamos los puntos 3d
marcas2d=K*mDummy*marcas3d;//Los proyectamos en la imagen
//Deshomoge...
for (int i=0;i<marcas2d.cols;++i)
marcas2d(Rect(i, 0, 1, 3)) /= marcas2d.at<double>(2, i);
pointsSelect3dTo2D(P, vps2d, K, Nplanef, D, mDummy);//Con los puntos seleccionados del tablero se halla la intersección en el plano y se proyectan en 2D
frameCopy=frame.clone();
//Se pintan los resultados de los dos métodos: intersección con el plano y rot+tr
for(int j=0; j<marcas2d.cols; j++)
{
for(int i=0; i<vps2d.size(); i++)
circle(frameCopy, vps2d[i],1, Scalar(0, 0, 200) ,2);//Se pintan los puntos de las intersecciones
Point tempPoint(marcas2d.at<double>(0, j), marcas2d.at<double>(1, j));
circle(frameCopy, tempPoint,1, Scalar(0, 200, 0) ,2);//Se pintan los puntos rotados y trasladados
}
imshow("frame", frameCopy);
waitKey();
// free memory
free_vectorr( (void*) x );
free_vectorr( (void*) f );
free_vectorr( (void*) B );
free_vectorr( (void*) xw );
free_vectorr( (void*) fw );
free_vectorr( (void*) g );
free_vectorr( (void*) h );
free_vectorr( (void*) A );
free_vectorr( (void*) I );
}
#endif
| [
"rajivgg91@gmail.com"
] | rajivgg91@gmail.com |
2ad76f43c77e1751060da7f5eeb7a752db03083a | 69bb0c69e4883c8887bd6282990c89739f8f2236 | /LineFollow/LineFollow.ino | 3b7a83a0d8f04f5f91145810dad5009836fa539d | [] | no_license | tnovak-olin/POELIneFollow | 80cc574c723498c69448af69ae25b8ae0a1ec06d | 9e493a327cc3c3042945e2e842bf0f278dc687cf | refs/heads/master | 2020-08-14T15:19:16.682370 | 2019-10-15T02:40:37 | 2019-10-15T02:40:37 | 215,189,867 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 3,227 | ino | //MARK: import libraries
#include <Wire.h>
#include <Adafruit_MotorShield.h>
//MARK: initalize variables
//left sensor value at port A1
int leftSensorValue;
//right sensor value at port A0
int rightSensorValue;
//the sensor reading which corrosponds to the sensor being on or off the line
int offL;
int onL;
int offR;
int onR;
//a number describing what percent of the maximum speed the fast wheel should hit
float spd;
//the motor speed component variables
float wheelSpd;
//the motor speed variables
float leftWheelSpeed;
float rightWheelSpeed;
//calibration variables
float leftMultiple;
//serial input variables
char character;
String string;
// Create the motor shield object with the default I2C address
Adafruit_MotorShield AFMS = Adafruit_MotorShield();
//set up the motors
Adafruit_DCMotor *leftWheel = AFMS.getMotor(1);
Adafruit_DCMotor *rightWheel = AFMS.getMotor(2);
void setup() {
//the sensor reading which corrosponds to the sensor being on or off the line
offL = 810;
onL = 900;
offR = 435;
onR = 745;
//a multiplier to slow down the left wheel to track at the same speed as the right wheel. (determined experimentally)
leftMultiple = .6;
//set default string and character values
character = 0;
string = "";
//begin serial and motor controller
Serial.begin(9600);
AFMS.begin();
}
void loop() {
//update the variable values
//if a character is available in the serial window
if (Serial.available() > 0) {
// get the character
character = Serial.read();
//if the character is not newline character
if (character != '\n') {
//append to the string
string += character;
}
else {
//update the speed
spd = string.toFloat();
string = "";
}
}
//MARK: update variables
wheelSpd = spd * 110.0 * (255.0/100.0);
//MARK: read the sensor values
leftSensorValue = analogRead(A5);
rightSensorValue = analogRead(A0);
//MARK: line following decision tree.
if (leftSensorValue >= onL && rightSensorValue <= offR){
//turnLeft
//start the wheels driving the right forward and the left backwards
leftWheel->run(FORWARD);
rightWheel->run(BACKWARD);
}
else if (leftSensorValue <= offL && rightSensorValue >= onR){
//turnleft
//start the wheels driving the right backwards and the left forward
leftWheel->run(BACKWARD);
rightWheel->run(FORWARD);
}
else{
//go straight
//start the wheels driving both wheels forward
leftWheel->run(BACKWARD);
rightWheel->run(BACKWARD);
wheelSpd = spd * 65.5 * (255.0/100.0);
}
leftWheelSpeed = wheelSpd*leftMultiple;
rightWheelSpeed = wheelSpd;
leftWheel->setSpeed(leftWheelSpeed);
rightWheel->setSpeed(rightWheelSpeed);
Serial.print(" LW: ");
Serial.print(leftWheelSpeed);
Serial.print(" LS: ");
Serial.print(leftSensorValue);
Serial.print(" RW: ");
Serial.print(rightWheelSpeed);
Serial.print(" RS: ");
Serial.println(rightSensorValue);
//send the signal to the wheel
leftWheel->run(RELEASE);
rightWheel->run(RELEASE);
}
| [
"tnovak@olin.edu"
] | tnovak@olin.edu |
1affc80d0bd44128ca1e29e4ad9257cb4214c7ed | cea74570a5a2511e68e4ba968220cd4bbb13c516 | /OpenSauce/Halo2/Halo2_Xbox/Game/Director.hpp | d71d82feddeb8dcdc17c65013764d39a1d4d0cb2 | [] | no_license | Dwood15/OpenSauce_Upgrade | 80bbc88fbf34340323d28ccd03623a103a27e714 | d48cf4819ed371beb4f6e9426f8ab8bcd67fe2b3 | refs/heads/master | 2021-05-04T18:35:39.132266 | 2018-02-18T01:26:48 | 2018-02-18T01:26:48 | 120,191,658 | 5 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 9,901 | hpp | /*
Yelo: Open Sauce SDK
Halo 2 (Xbox) Edition
See license\OpenSauce\Halo2_Xbox for specific license information
*/
#pragma once
#include <blamlib/Halo2/interface/user_interface.hpp>
namespace Yelo
{
namespace Enums
{
enum director_mode
{
_director_mode_none,
_director_mode_scripted,
_director_mode_first_person,
_director_mode_following,
_director_mode_editor,
_director_mode_dead,
_director_mode,
_director_mode_third_person, // this is CUSTOM mode.
_director_mode_debug, // this is a CUSTOM mode
_director_mode_static, // this is a CUSTOM mode (aka stillcam)
};
enum resistance_function
{
// resistance is directly proportional to velocity
_resistance_function_linear,
// resistance exponentially increases with velocity
_resistance_function_exponential,
// resistance increases with velocity but gradually slows the rate at which it increases
_resistance_function_logarithmic,
_resistance_function,
};
};
namespace GameState
{
struct s_camera_command
{
byte_flags flags;
PAD24;
real_point3d position; // 0x4
real_point3d offset; // 0x10
real depth; // 0x1C
real fov; // 0x20
UNKNOWN_TYPE(real); // 0x24
UNKNOWN_TYPE(real); // 0x28, seems to be another fov value
real_vector3d forward; // 0x2C
real_vector3d up; // 0x38
real_vector3d vector; // 0x44
real_matrix4x3 matrix; // 0x50
UNKNOWN_TYPE(int32); // 0x84
UNKNOWN_TYPE(int32); // 0x88
byte_flags command_flags[6]; // 0x8C
PAD16;
real commands[6]; // 0x94
}; BOOST_STATIC_ASSERT( sizeof(s_camera_command) == 0xAC );
};
namespace Camera
{
typedef void (API_FUNC* camera_update_proc)(GameState::s_camera_command* camera, datum_index* player_index, GameState::s_camera_command* result);
struct s_director_camera // TODO: Alpha is a bit different from retail (s_camera_command?)
{
UNKNOWN_TYPE(int32);
UNKNOWN_TYPE(real);
UNKNOWN_TYPE(int32);
camera_update_proc UpdateProc;
//////////////////////////////////////////////////////////////////////////
// union here...data is dependent on the director mode
TAG_PAD(int32, 19);
//////////////////////////////////////////////////////////////////////////
GameState::s_camera_command UpdateResult; // 0x5C
UNKNOWN_TYPE(bool); // 0x108
PAD24;
UNKNOWN_TYPE(real); // 0x10C
TAG_PAD(int32, 12); // 0x110
}; BOOST_STATIC_ASSERT( sizeof(s_director_camera) == PLATFORM_VALUE(0x140, 0x140, 0x134) );
struct s_director_globals
{
UNKNOWN_TYPE(real);
UNKNOWN_TYPE(long_enum); // Enums::director_mode
UNKNOWN_TYPE(bool);
PAD24;
s_director_camera Directors[Enums::k_number_of_users]; // director for each local player
}; BOOST_STATIC_ASSERT( sizeof(s_director_globals) == 0x50C );
void Initialize();
void Dispose();
void Update();
camera_update_proc DirectorModeProc(_enum mode);
};
namespace GameState
{
Camera::s_director_globals* _DirectorGlobals();
struct s_observer
{
struct s_calculated_result
{
real_point3d position; // 0x0
s_scenario_location location; // 0xC
real_vector3d velocity; // 0x14
real_vector3d forward; // 0x20
real_euler_angles3d up; // 0x2C
real fov; // 0x38
UNKNOWN_TYPE(int32); // 0x3C, i'm not sure what this field's type is...
UNKNOWN_TYPE(real); // 0x40
UNKNOWN_TYPE(real); // 0x44
}; BOOST_STATIC_ASSERT( sizeof(s_calculated_result) == 0x48 );
// focus. this structure isn't a real structure in the game's code (these fields are part of s_observer)
struct s_calculated_origin
{
real_point3d position; // 0x0
real_point3d offset; // 0xC
real_point2d look_offset; // 0x18
real depth; // 0x20 distance
real fov; // 0x24
real_vector3d forward; // 0x28 Direction
real_vector3d up; // 0x34 Rotation
}; BOOST_STATIC_ASSERT( sizeof(s_calculated_origin) == 0x40 );
tag header_signature; // 0x0
s_camera_command* command_update; // 0x4
s_camera_command command; // 0x8
bool updated_for_frame; // 0xB4
UNKNOWN_TYPE(bool);
UNKNOWN_TYPE(bool);
PAD8;
s_calculated_result result; // 0xB8
UNKNOWN_TYPE(int32); UNKNOWN_TYPE(int32); UNKNOWN_TYPE(int32); // 12 bytes in between
s_calculated_origin origin; // 0x10C
real_matrix4x3 matrix; // 0x14C
real_matrix4x3 matrix0; // 0x180
real_matrix4x3 matrix1; // 0x1B4
real_matrix4x3 matrix2; // 0x1E8
real_matrix4x3 matrix3; // 0x21C
real_matrix4x3 matrix4; // 0x250
real_matrix4x3 matrix5; // 0x284
real_matrix4x3 matrix6; // 0x2B8
real_matrix4x3 matrix7; // 0x2EC
real_matrix4x3 matrix8; // 0x320
tag trailer_signature; // 0x354
}; BOOST_STATIC_ASSERT( sizeof(s_observer) == 0x358 );
s_observer* _Observers();
struct s_camera_globals
{
bool Active;
PAD24;
};
s_camera_globals* _CameraGlobals();
struct s_scripted_camera_globals
{
bool Initialized; // 0x0
bool Enabled; // 0x1
_enum Mode; // 0x2
real Time; // 0x4
struct {
uint32 FovTime; // 0x8
real FovOld; // 0xC
real Fov; // 0x10
uint32 Ticks; // 0x14
real_point3d Position; // 0x18
real_vector3d Forward; // 0x24
real_euler_angles3d Up; // 0x30
datum_index ObjectIndex; // 0x3C
}Unit;
struct {
uint32 StartTick; // 0x40
datum_index TagDefinition; // 0x44
string_id Name; // 0x48
int16 NextCameraPoint; // 0x4C
PAD16;
}Animation;
real_point3d UNKNOWN(0); // 0x50
TAG_PAD(int32, 7);
};
s_scripted_camera_globals* _ScriptedCameraGlobals();
struct s_observer_globals
{
int32 BspIndex; // 0x0
uint32 UNKNOWN(0)[4]; // index of the block at [structure_bsp+0xAC]
};
s_observer_globals* _ObserverGlobals();
struct s_cinematic_globals
{
real Time; // 0x0
bool ShowLetterbox; // 0x4
bool InProgress; // 0x5
bool SkipStart; // 0x6
PAD8;
struct _Titles
{
int16 BlockIndex;
int16 DelayTime;
}Titles[4]; // 0x8
struct {
string_id Id; // 0x18
real Volume; // 0x1C, idk where I got the name 'volume' so feel free to kiss my ass...i think it's 'up time'
}Subtitle;
int16 UNKNOWN(0); // 0x20
bool UNKNOWN(1); // 0x22
PAD8;
};
s_cinematic_globals* _CinematicGlobals();
};
namespace Camera
{
class c_yelo_camera
{
public:
// hooks the game code to get the camera code to do our debug bidding
static void DebugInitialize();
static void DebugDispose();
private:
// is there a debug camera in use? holds the count of how many c_yelo_cameras are debug cameras
static int32 DebugInUse;
// Table to use to figure out which cameras are the ones in
// debug mode for easy lookups
static bool DebugInUseList[Enums::k_number_of_users];
// Hack hook function for debug camera
static void UpdateAngleHoriz();
// Hack hook function for debug camera
static void UpdateAngleVert();
// Hack hook function for cameras
static void UpdateObserverPositions();
// Local machine's player this camera is attached to
int16 UserIndex;
// Are we tracking this camera's movements?
bool TrackMovement;
PAD8;
// Game valid mode state
_enum DirectorMode;
// Yelo only mode state
_enum DirectorModeInternal;
real_vector3d MoveForce; // external force acting on the camera
real_vector3d MoveVelocity;
real_vector3d LookVelocity;
GameState::s_observer::s_calculated_origin* ObserverOrigin;
real_point2d* ControlLookAngle;// should point to the player's control global's look angle
public:
// Attach this camera to a player
void Initialize(int16 user_index, _enum mode);
// Detach and dispose of this camera
void Dispose();
// Update this camera for game state changes
void Update();
private:
// Checks to see if the camera has become out of sync with the
// game state and forces our shit to take charge once again
// This can happen if the player died or re-spawned
void UpdateOnOutOfSync();
// Updates the game state pointers in this object
void UpdateReferences();
// Updates the camera look vector based on the current horizontal and vertical look angles of the player
void UpdateLookVector();
// Updates the look direction of this camera
void UpdateLookDirection();
// Updates the movement of this camera
void UpdateMovement();
// Figures out the enumeration for to return based on the current
// player's perspective (useful when reconnecting to the player and we
// don't know explicitly what state they are in or were left in)
_enum GetPerspectiveFromGame() const;
// Handles setting the director mode
// Also handles debug camera code enabling and disabling
// Note: use [_director_mode] to set to current perspective
// the GAME is using
void ChangePerspectiveInternal(_enum mode);
public:
// Changes the director mode the camera is using
void ChangePerspective(_enum mode);
// Get the resistance fraction based on a mode and a velocity
real GetResistance(_enum resistance, real velocity) const;
// Invalidates the camera so it can't be used without being
// initialized
void Invalidate();
// Turn the tracking of camera movement on or off
void ToggleTrackMovement();
private:
static c_yelo_camera Cameras[Enums::k_number_of_users];
public:
// Determines if the controller index is valid for camera operations
// remarks: SHOULD return false if the controller was unplugged
// during game play
static bool IsValid(int32 controller_index = 0);
// Determines if the camera attached to this controller
// index is ready to be used
static bool IsReady(int32 controller_index = 0);
// Gets the yelo camera associated to the controller
static c_yelo_camera& Get(int32 controller_index = 0);
};
};
}; | [
"Dwood15@users.noreply.github.com"
] | Dwood15@users.noreply.github.com |
a61b478cae7be9a4f5e0fd9c16ff57f9abdcb5a7 | 781f351347692832c17ebd43bb90accd1036572d | /Sources/Library/CorbaLib/Src/KDataManage.h | 5839250da18998dff379ac291d8aa5af2dfac76f | [] | no_license | fcccode/Jx | 71f9a549c7c6bbd1d00df5ad3e074a7c1c665bd1 | 4b436851508d76dd626779522a080b35cf8edc14 | refs/heads/master | 2020-04-14T07:59:12.814607 | 2017-05-23T07:57:15 | 2017-05-23T07:57:15 | null | 0 | 0 | null | null | null | null | GB18030 | C++ | false | false | 1,252 | h | #ifndef KDATAMANAGER_H
#define KDATAMANAGER_H
#include "SynDataSets.h"
#include "Kengine.h"
#include "KThread.h"
#include "KNode.h"
#include "KList.h"
class TSynData:public KNode
{
public:
long Id;
long index;
};
#define MAXNUM 100
//客户端 调用,锁定、反锁;取值、赋值
class KDataManage
{
public:
KDataManage();
virtual ~KDataManage();
SynDataSets_ptr m_pCorbaDataSets;
KList m_LockList;
KThread *m_pLockThread;
long Lock(CORBA::Long MapId, CORBA::Long StyleId, long id);
long UnLock(CORBA::Long MapId, CORBA::Long StyleId, long id, long index);
CORBA::Any* GetData(CORBA::Long MapId, CORBA::Long StyleId, long id);
long SetData(CORBA::Long MapId, CORBA::Long StyleId,long id, const CORBA::Any& data) ;
//获得数据,并锁住数据
CORBA::Any* GetDataWithLock(CORBA::Long MapId, CORBA::Long StyleId,long id) ;
CORBA::Long SetDataWithLock(CORBA::Long MapId, CORBA::Long StyleId,CORBA::Long id, const CORBA::Any& data) ;
CORBA::Any* GetDataWithOnce(CORBA::Long MapId, CORBA::Long StyleId,CORBA::Long id);
CORBA::Long SetDataWithOnce(CORBA::Long MapId, CORBA::Long StyleId,CORBA::Long id, const CORBA::Any& data) ;
char m_ServerObjName[30];
void GetReqInfo(){};
};
#endif // KDATAMANAGER_H
| [
"tuan.n0s0und@gmail.com"
] | tuan.n0s0und@gmail.com |
b4b6770bb2b280ca372bcdb900778049345f24bd | 81058e6476eef1575a34a475127daeba62ae4d3f | /Uppgift43/uppgift43.cpp | 4316454b43787add7425dda7d50dde7107ba9ff6 | [] | no_license | FransW02/programering-1 | fa421d246a4d3f15158ab853029afac65a7dc8aa | 79ee4bf96a114ca533f25953c7312ef37a57b456 | refs/heads/master | 2020-04-24T03:56:48.168063 | 2019-06-10T12:43:10 | 2019-06-10T12:43:10 | 171,686,779 | 0 | 0 | null | null | null | null | ISO-8859-1 | C++ | false | false | 824 | cpp | #include <iostream>
#include <cstdlib>
#include <ctime>
/* run this program using the console pauser or add your own getch, system("pause") or input loop */
using namespace std;
int main(int argc, char** argv) {
bool cool = true;
while(cool == true){
int a,c;
int tiden = time(0);
srand(tiden);
c = rand()%100 + 1;
cout<<"Gissa på ett nummer mellan 1-100"<<endl;
cin>>a;
for(int i = 4; i > 0;i--){
if(a < c){
cout<<"Du gissade för lågt"<<endl;
}
if(a > c){
cout<<"Du gissade för högt"<<endl;
}
if(a == c){
cout<<"Du gissade rätt";
return 0;
}
cout<<"du har "<<i<<" försök kvar"<<endl;
cin>>a;
}
cout<<c;
string input;
cout<<"Vill du avsluta programmet"<<endl;
cin>>input;
if(input == "ja"){
cool = false;
}
if(input == "nej"){
cool = true;
}
}
return 0;
}
| [
"18frwenn@mg.lan"
] | 18frwenn@mg.lan |
b005585b1443208a7a0e701795265bfd123171ae | 09587f7e26530519d93b742b30a43b76888150a1 | /RecProb5.cpp | 90e1bc1e1b8fed1ad9cb314e9e5280bb34ae53a8 | [] | no_license | abhinav0310/Programming_Cpp | 00aa7aa44db623d0151cd033283c4cf61d65d57f | 46693aefa9add93e1ffcfdc5f4377d48aa5f6421 | refs/heads/main | 2023-07-23T10:51:41.820955 | 2021-09-04T16:47:13 | 2021-09-04T16:47:13 | 403,108,236 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 365 | cpp | //Replace pi with 3.14 in string
#include<iostream>
using namespace std;
void replace(string s){
if(s.length()==0)
return ;
if(s[0]=='p' && s[1]=='i'){
cout<<"3.14"<<"";
replace(s.substr(2));
}
else{
cout<<s[0]<<"";
replace(s.substr(1));
}
}
int main(){
string s;
cin>>s;
replace(s);
return 0;
} | [
"noreply@github.com"
] | noreply@github.com |
3034e4a02399be28bfbeb3ee9bde9ac515e23ff4 | 4d4822b29e666cea6b2d99d5b9d9c41916b455a9 | /Example/Pods/Headers/Private/GeoFeatures/boost/mpl/aux_/preprocessed/mwcw/divides.hpp | 0981408555b5648be202b6f6cdeb2ada9a9ee616 | [
"BSL-1.0",
"Apache-2.0"
] | permissive | eswiss/geofeatures | 7346210128358cca5001a04b0e380afc9d19663b | 1ffd5fdc49d859b829bdb8a9147ba6543d8d46c4 | refs/heads/master | 2020-04-05T19:45:33.653377 | 2016-01-28T20:11:44 | 2016-01-28T20:11:44 | 50,859,811 | 0 | 0 | null | 2016-02-01T18:12:28 | 2016-02-01T18:12:28 | null | UTF-8 | C++ | false | false | 86 | hpp | ../../../../../../../../../../GeoFeatures/boost/mpl/aux_/preprocessed/mwcw/divides.hpp | [
"hatter24@gmail.com"
] | hatter24@gmail.com |
1006a30e380ca0acba4181416a54776960b32f08 | 3529b55d640e0b399ccb8d49164bb2919d7814e6 | /Source/Blocks/Public/Interfaces/ControllableBlock.h | 902f3b05ef7e9d1879c4ad5de378e3473cfb7719 | [] | no_license | halbich/TauCetiF2 | f4d15962fd9138011a633a4cf0d670a46ff2200e | d29bf7d820ad5697ec4a6e6148bd82a481208ea4 | refs/heads/master | 2020-05-21T12:27:26.170348 | 2017-09-15T08:05:12 | 2017-09-15T08:05:12 | 54,737,054 | 0 | 0 | null | 2016-07-05T19:46:22 | 2016-03-25T17:59:23 | C++ | UTF-8 | C++ | false | false | 792 | h | #pragma once
#include "ControllableBlock.generated.h"
class ABlock;
UINTERFACE(BlueprintType)
class BLOCKS_API UControllableBlock : public UInterface
{
GENERATED_UINTERFACE_BODY()
};
class BLOCKS_API IControllableBlock
{
GENERATED_IINTERFACE_BODY()
public:
UFUNCTION(BlueprintNativeEvent, BlueprintCallable, Category = "TCF2 | ControllableBlock")
void SetControlState(bool isOn);
UFUNCTION(BlueprintNativeEvent, BlueprintCallable, Category = "TCF2 | ControllableBlock")
void SetOutputPowerPercentage(float percentage);
UFUNCTION(BlueprintNativeEvent, BlueprintCallable, Category = "TCF2 | ControllableBlock")
void SetController(ABlock* controller);
UFUNCTION(BlueprintNativeEvent, BlueprintCallable, Category = "TCF2 | ControllableBlock")
ABlock* GetController();
}; | [
"halbich.p@hotmail.com"
] | halbich.p@hotmail.com |
e6d58c0a6da34f9a61c76bcc97a8604d69965188 | c6e9d28c76324cc79d913b4777aee2138a6287ec | /OpenGL5_Transformations/OpenGL1/Shader.h | a198ce6f0a5934c53a615cb4898e1978ab42ba6c | [] | no_license | SpasPandev/UNI-ComputerGraphicsCourse | c852e64f6a2007f5d8c69a99ed90b04569b07518 | 2bde5a6cf4b902bd54563b86b6e668a3d6a56a22 | refs/heads/main | 2023-07-25T11:04:22.731290 | 2021-09-05T13:04:57 | 2021-09-05T13:04:57 | 403,303,342 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 753 | h | #ifndef SHADER_H
#define SHADER_H
#include <glad/glad.h> // include glad to get all the required OpenGL headers
#include <string>
#include <fstream>
#include <sstream>
#include <iostream>
#include <glm/gtc/matrix_transform.hpp>
class Shader
{
public:
// the program ID
unsigned int ID;
// constructor reads and builds the shader
Shader(const char* vertexPath, const char* fragmentPath);
// use/activate the shader
void use();
// utility uniform functions
void setBool(const std::string& name, bool value) const;
void setInt(const std::string& name, int value) const;
void setFloat(const std::string& name, float value) const;
void setFloatMat4(const std::string& name, glm::mat4 value) const;
};
#endif | [
"sppan@abv.bg"
] | sppan@abv.bg |
2421269c143142000b9995e02f3f530647022682 | 5d83739af703fb400857cecc69aadaf02e07f8d1 | /Archive2/52/44a59ca673d26c/main.cpp | e02c5c1de797efa6199c2dfc34e28d35e108bbfe | [] | no_license | WhiZTiM/coliru | 3a6c4c0bdac566d1aa1c21818118ba70479b0f40 | 2c72c048846c082f943e6c7f9fa8d94aee76979f | refs/heads/master | 2021-01-01T05:10:33.812560 | 2015-08-24T19:09:22 | 2015-08-24T19:09:22 | 56,789,706 | 3 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 803 | cpp | #include <vector>
#include <string>
template<typename T>
class bar;
template<typename Derived, typename ValType>
class foo
{
public:
template<typename R>
bar<typename std::vector<R>::const_iterator> select()
{
std::vector<R> translation;
return bar<typename std::vector<R>::const_iterator>(std::move(translation));
}
};
template<typename T>
class bar
: public foo<bar<T>, typename std::iterator_traits<T>::value_type>
{
public:
bar(std::vector<typename std::iterator_traits<T>::value_type>&& vec)
{
}
};
int main()
{
std::vector<int> enumerable_vector;
enumerable_vector.push_back(1);
enumerable_vector.push_back(2);
bar<typename std::vector<int>::const_iterator> baz(std::move(enumerable_vector));
baz.select<std::string>();
}
| [
"francis.rammeloo@36614edc-3e3a-acb8-9062-c8ae0e4185df"
] | francis.rammeloo@36614edc-3e3a-acb8-9062-c8ae0e4185df |
26f69fa82d63728c048aca33263a0d61e1babb5b | c7f7437094bbce1b7ef4e3c3999adc462c4cc683 | /Development/nmos/resource.cpp | 388b668e22cc98d54625ab1a9bb4591b7f864bd9 | [
"Apache-2.0",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | OfficePop/nmos-cpp | 22bd8a8765b8c81abcfeb75c7738755390adc30e | 806c10fb341605cbe0a1c0a70c8751f2c227a50f | refs/heads/master | 2020-05-26T04:21:23.191164 | 2019-07-12T19:59:21 | 2019-07-12T19:59:21 | 188,104,757 | 0 | 0 | Apache-2.0 | 2019-07-12T19:59:22 | 2019-05-22T19:56:10 | C++ | UTF-8 | C++ | false | false | 762 | cpp | #include "nmos/resource.h"
#include "nmos/version.h"
namespace nmos
{
namespace details
{
// See https://github.com/AMWA-TV/nmos-discovery-registration/blob/v1.2/APIs/schemas/resource_core.json
web::json::value make_resource_core(const nmos::id& id, const nmos::settings& settings)
{
using web::json::value;
const auto label = value::string(nmos::experimental::fields::label(settings));
value data;
data[U("id")] = value::string(id);
data[U("version")] = value::string(nmos::make_version());
data[U("label")] = label;
data[U("description")] = label;
data[U("tags")] = value::object();
return data;
}
}
}
| [
"gareth.sylvester-bradley@eu.sony.com"
] | gareth.sylvester-bradley@eu.sony.com |
a478eba622f5e2596021e401d264ee626b7544d2 | b012b15ec5edf8a52ecf3d2f390adc99633dfb82 | /releases/moos-ivp-13.5/ivp/src/uFldHazardSensor/PostingQueue.h | 34141efac0e0fa46604292dc46d86e9804c7b95b | [] | no_license | crosslore/moos-ivp-aro | cbe697ba3a842961d08b0664f39511720102342b | cf2f1abe0e27ccedd0bbc66e718be950add71d9b | refs/heads/master | 2022-12-06T08:14:18.641803 | 2020-08-18T06:39:14 | 2020-08-18T06:39:14 | 263,586,714 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,958 | h | /*****************************************************************/
/* NAME: Michael Benjamin, Henrik Schmidt, and John Leonard */
/* ORGN: Dept of Mechanical Eng / CSAIL, MIT Cambridge MA */
/* FILE: PostingQueue.h */
/* DATE: March 15th, 2013 */
/* */
/* This program is free software; you can redistribute it and/or */
/* modify it under the terms of the GNU General Public License */
/* as published by the Free Software Foundation; either version */
/* 2 of the License, or (at your option) any later version. */
/* */
/* This program is distributed in the hope that it will be */
/* useful, but WITHOUT ANY WARRANTY; without even the implied */
/* warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR */
/* PURPOSE. See the GNU General Public License for more details. */
/* */
/* You should have received a copy of the GNU General Public */
/* License along with this program; if not, write to the Free */
/* Software Foundation, Inc., 59 Temple Place - Suite 330, */
/* Boston, MA 02111-1307, USA. */
/*****************************************************************/
#ifndef POSTING_PRIORITY_QUEUE
#define POSTING_PRIORITY_QUEUE
#include "VarDataPair.h"
#include <vector>
#include <queue>
class PostingQueue {
public:
PostingQueue();
virtual ~PostingQueue() {};
void push(VarDataPair pair);
VarDataPair pop();
bool empty() const {return(m_pqueue.empty());}
bool size() const {return(m_pqueue.size());}
std::priority_queue<VarDataPair, std::vector<VarDataPair>, std::less<std::vector<VarDataPair>::value_type> > m_pqueue;
unsigned int m_total_entries_ever;
};
#endif
| [
"zouxueson@hotmail.com"
] | zouxueson@hotmail.com |
1f9dce040dd096549b603ad7291478d94b541317 | 352eef7faeceebbe54741cc6fa7f698390e12751 | /Source/Game2/Car.h | 29232798cce03a504394d03c822ec79c17c64f79 | [] | no_license | ElToChetao/GameEngineRepo | 51f0d49cfc4f740008d67632a976987ed2626007 | 0ac28e7702a774cf988f4693b230a972254c32e8 | refs/heads/main | 2023-02-25T16:07:21.887133 | 2021-02-01T04:04:26 | 2021-02-01T04:04:26 | 329,047,840 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 539 | h | #pragma once
#include "ManagerOfManagers.h"
#include "LeafManager.h"
#include "Leaf.h"
#include "Fuel.h"
#include "Text.h"
using namespace std;
class Car :public GameObject
{
public:
Text fuel = Text(Vector2(RenderManager::GetInstance().GetScreenAdaptedPosition(0.5, 0.95)), "100 %", {255, 0, 0});
float currentFuel;
float maxFuel;
float currentForce;
float maxForce;
LeafManager* leafManager;
Car();
~Car();
void update() override;
void updatePosition(float dt);
void onCollisionEnter(GameObject*) override;
}; | [
"dprieto971@gmail.com"
] | dprieto971@gmail.com |
1b79c5c70faaa99bb325fe465a5301c1af2a9c39 | 03d3231478373089a3de04db162f61b79a388fd3 | /lib/directX/xnamathvector.inl | d4fa6f52a7e43a4dfd47a56403985c3828186449 | [] | no_license | minlexx/l2-unlegits | f4b0e9d70afe2a0a26f81daa16123eb2fe31cc13 | fc189ca35edf14439a5eeac81359b30112496b80 | refs/heads/master | 2021-01-17T05:35:09.738039 | 2015-06-28T09:16:13 | 2015-06-28T09:16:13 | 38,192,499 | 6 | 3 | null | null | null | null | UTF-8 | C++ | false | false | 382,862 | inl | /*++
Copyright (c) Microsoft Corporation. All rights reserved.
Module Name:
xnamathvector.inl
Abstract:
XNA math library for Windows and Xbox 360: Vector functions
--*/
#if defined(_MSC_VER) && (_MSC_VER > 1000)
#pragma once
#endif
#ifndef __XNAMATHVECTOR_INL__
#define __XNAMATHVECTOR_INL__
#if defined(_XM_NO_INTRINSICS_)
#define XMISNAN(x) ((*(UINT*)&(x) & 0x7F800000) == 0x7F800000 && (*(UINT*)&(x) & 0x7FFFFF) != 0)
#define XMISINF(x) ((*(UINT*)&(x) & 0x7FFFFFFF) == 0x7F800000)
#endif
/****************************************************************************
*
* General Vector
*
****************************************************************************/
//------------------------------------------------------------------------------
// Assignment operations
//------------------------------------------------------------------------------
//------------------------------------------------------------------------------
// Return a vector with all elements equaling zero
XMFINLINE XMVECTOR XMVectorZero()
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR vResult = {0.0f,0.0f,0.0f,0.0f};
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_setzero_ps();
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Initialize a vector with four floating point values
XMFINLINE XMVECTOR XMVectorSet
(
FLOAT x,
FLOAT y,
FLOAT z,
FLOAT w
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTORF32 vResult = {x,y,z,w};
return vResult.v;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_set_ps( w, z, y, x );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Initialize a vector with four integer values
XMFINLINE XMVECTOR XMVectorSetInt
(
UINT x,
UINT y,
UINT z,
UINT w
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTORU32 vResult = {x,y,z,w};
return vResult.v;
#elif defined(_XM_SSE_INTRINSICS_)
__m128i V = _mm_set_epi32( w, z, y, x );
return reinterpret_cast<__m128 *>(&V)[0];
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Initialize a vector with a replicated floating point value
XMFINLINE XMVECTOR XMVectorReplicate
(
FLOAT Value
)
{
#if defined(_XM_NO_INTRINSICS_) || defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
XMVECTORF32 vResult = {Value,Value,Value,Value};
return vResult.v;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_set_ps1( Value );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Initialize a vector with a replicated floating point value passed by pointer
XMFINLINE XMVECTOR XMVectorReplicatePtr
(
CONST FLOAT *pValue
)
{
#if defined(_XM_NO_INTRINSICS_) || defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
FLOAT Value = pValue[0];
XMVECTORF32 vResult = {Value,Value,Value,Value};
return vResult.v;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_load_ps1( pValue );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Initialize a vector with a replicated integer value
XMFINLINE XMVECTOR XMVectorReplicateInt
(
UINT Value
)
{
#if defined(_XM_NO_INTRINSICS_) || defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
XMVECTORU32 vResult = {Value,Value,Value,Value};
return vResult.v;
#elif defined(_XM_SSE_INTRINSICS_)
__m128i vTemp = _mm_set1_epi32( Value );
return reinterpret_cast<const __m128 *>(&vTemp)[0];
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Initialize a vector with a replicated integer value passed by pointer
XMFINLINE XMVECTOR XMVectorReplicateIntPtr
(
CONST UINT *pValue
)
{
#if defined(_XM_NO_INTRINSICS_) || defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
UINT Value = pValue[0];
XMVECTORU32 vResult = {Value,Value,Value,Value};
return vResult.v;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_load_ps1(reinterpret_cast<const float *>(pValue));
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Initialize a vector with all bits set (true mask)
XMFINLINE XMVECTOR XMVectorTrueInt()
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTORU32 vResult = {0xFFFFFFFFU,0xFFFFFFFFU,0xFFFFFFFFU,0xFFFFFFFFU};
return vResult.v;
#elif defined(_XM_SSE_INTRINSICS_)
__m128i V = _mm_set1_epi32(-1);
return reinterpret_cast<__m128 *>(&V)[0];
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Initialize a vector with all bits clear (false mask)
XMFINLINE XMVECTOR XMVectorFalseInt()
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR vResult = {0.0f,0.0f,0.0f,0.0f};
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_setzero_ps();
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Replicate the x component of the vector
XMFINLINE XMVECTOR XMVectorSplatX
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR vResult;
vResult.x = V.x;
vResult.y = V.x;
vResult.z = V.x;
vResult.w = V.x;
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_shuffle_ps( V, V, _MM_SHUFFLE(0, 0, 0, 0) );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Replicate the y component of the vector
XMFINLINE XMVECTOR XMVectorSplatY
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR vResult;
vResult.x = V.y;
vResult.y = V.y;
vResult.z = V.y;
vResult.w = V.y;
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_shuffle_ps( V, V, _MM_SHUFFLE(1, 1, 1, 1) );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Replicate the z component of the vector
XMFINLINE XMVECTOR XMVectorSplatZ
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR vResult;
vResult.x = V.z;
vResult.y = V.z;
vResult.z = V.z;
vResult.w = V.z;
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_shuffle_ps( V, V, _MM_SHUFFLE(2, 2, 2, 2) );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Replicate the w component of the vector
XMFINLINE XMVECTOR XMVectorSplatW
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR vResult;
vResult.x = V.w;
vResult.y = V.w;
vResult.z = V.w;
vResult.w = V.w;
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_shuffle_ps( V, V, _MM_SHUFFLE(3, 3, 3, 3) );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Return a vector of 1.0f,1.0f,1.0f,1.0f
XMFINLINE XMVECTOR XMVectorSplatOne()
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR vResult;
vResult.x = 1.0f;
vResult.y = 1.0f;
vResult.z = 1.0f;
vResult.w = 1.0f;
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
return g_XMOne;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Return a vector of INF,INF,INF,INF
XMFINLINE XMVECTOR XMVectorSplatInfinity()
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR vResult;
vResult.u[0] = 0x7F800000;
vResult.u[1] = 0x7F800000;
vResult.u[2] = 0x7F800000;
vResult.u[3] = 0x7F800000;
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
return g_XMInfinity;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Return a vector of Q_NAN,Q_NAN,Q_NAN,Q_NAN
XMFINLINE XMVECTOR XMVectorSplatQNaN()
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR vResult;
vResult.u[0] = 0x7FC00000;
vResult.u[1] = 0x7FC00000;
vResult.u[2] = 0x7FC00000;
vResult.u[3] = 0x7FC00000;
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
return g_XMQNaN;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Return a vector of 1.192092896e-7f,1.192092896e-7f,1.192092896e-7f,1.192092896e-7f
XMFINLINE XMVECTOR XMVectorSplatEpsilon()
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR vResult;
vResult.u[0] = 0x34000000;
vResult.u[1] = 0x34000000;
vResult.u[2] = 0x34000000;
vResult.u[3] = 0x34000000;
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
return g_XMEpsilon;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Return a vector of -0.0f (0x80000000),-0.0f,-0.0f,-0.0f
XMFINLINE XMVECTOR XMVectorSplatSignMask()
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR vResult;
vResult.u[0] = 0x80000000U;
vResult.u[1] = 0x80000000U;
vResult.u[2] = 0x80000000U;
vResult.u[3] = 0x80000000U;
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
__m128i V = _mm_set1_epi32( 0x80000000 );
return reinterpret_cast<__m128*>(&V)[0];
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Return a floating point value via an index. This is not a recommended
// function to use due to performance loss.
XMFINLINE FLOAT XMVectorGetByIndex(FXMVECTOR V,UINT i)
{
XMASSERT( i <= 3 );
#if defined(_XM_NO_INTRINSICS_)
return V.v[i];
#elif defined(_XM_SSE_INTRINSICS_)
return V.m128_f32[i];
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Return the X component in an FPU register.
// This causes Load/Hit/Store on VMX targets
XMFINLINE FLOAT XMVectorGetX(FXMVECTOR V)
{
#if defined(_XM_NO_INTRINSICS_)
return V.x;
#elif defined(_XM_SSE_INTRINSICS_)
#if defined(_MSC_VER) && (_MSC_VER>=1500)
return _mm_cvtss_f32(V);
#else
return V.m128_f32[0];
#endif
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Return the Y component in an FPU register.
// This causes Load/Hit/Store on VMX targets
XMFINLINE FLOAT XMVectorGetY(FXMVECTOR V)
{
#if defined(_XM_NO_INTRINSICS_)
return V.y;
#elif defined(_XM_SSE_INTRINSICS_)
#if defined(_MSC_VER) && (_MSC_VER>=1500)
XMVECTOR vTemp = _mm_shuffle_ps(V,V,_MM_SHUFFLE(1,1,1,1));
return _mm_cvtss_f32(vTemp);
#else
return V.m128_f32[1];
#endif
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Return the Z component in an FPU register.
// This causes Load/Hit/Store on VMX targets
XMFINLINE FLOAT XMVectorGetZ(FXMVECTOR V)
{
#if defined(_XM_NO_INTRINSICS_)
return V.z;
#elif defined(_XM_SSE_INTRINSICS_)
#if defined(_MSC_VER) && (_MSC_VER>=1500)
XMVECTOR vTemp = _mm_shuffle_ps(V,V,_MM_SHUFFLE(2,2,2,2));
return _mm_cvtss_f32(vTemp);
#else
return V.m128_f32[2];
#endif
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Return the W component in an FPU register.
// This causes Load/Hit/Store on VMX targets
XMFINLINE FLOAT XMVectorGetW(FXMVECTOR V)
{
#if defined(_XM_NO_INTRINSICS_)
return V.w;
#elif defined(_XM_SSE_INTRINSICS_)
#if defined(_MSC_VER) && (_MSC_VER>=1500)
XMVECTOR vTemp = _mm_shuffle_ps(V,V,_MM_SHUFFLE(3,3,3,3));
return _mm_cvtss_f32(vTemp);
#else
return V.m128_f32[3];
#endif
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Store a component indexed by i into a 32 bit float location in memory.
// This causes Load/Hit/Store on VMX targets
XMFINLINE VOID XMVectorGetByIndexPtr(FLOAT *f,FXMVECTOR V,UINT i)
{
XMASSERT( f != 0 );
XMASSERT( i < 4 );
#if defined(_XM_NO_INTRINSICS_)
*f = V.v[i];
#elif defined(_XM_SSE_INTRINSICS_)
*f = V.m128_f32[i];
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Store the X component into a 32 bit float location in memory.
XMFINLINE VOID XMVectorGetXPtr(FLOAT *x,FXMVECTOR V)
{
XMASSERT( x != 0 );
#if defined(_XM_NO_INTRINSICS_)
*x = V.x;
#elif defined(_XM_SSE_INTRINSICS_)
_mm_store_ss(x,V);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Store the Y component into a 32 bit float location in memory.
XMFINLINE VOID XMVectorGetYPtr(FLOAT *y,FXMVECTOR V)
{
XMASSERT( y != 0 );
#if defined(_XM_NO_INTRINSICS_)
*y = V.y;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(1,1,1,1));
_mm_store_ss(y,vResult);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Store the Z component into a 32 bit float location in memory.
XMFINLINE VOID XMVectorGetZPtr(FLOAT *z,FXMVECTOR V)
{
XMASSERT( z != 0 );
#if defined(_XM_NO_INTRINSICS_)
*z = V.z;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(2,2,2,2));
_mm_store_ss(z,vResult);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Store the W component into a 32 bit float location in memory.
XMFINLINE VOID XMVectorGetWPtr(FLOAT *w,FXMVECTOR V)
{
XMASSERT( w != 0 );
#if defined(_XM_NO_INTRINSICS_)
*w = V.w;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(3,3,3,3));
_mm_store_ss(w,vResult);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Return an integer value via an index. This is not a recommended
// function to use due to performance loss.
XMFINLINE UINT XMVectorGetIntByIndex(FXMVECTOR V, UINT i)
{
XMASSERT( i < 4 );
#if defined(_XM_NO_INTRINSICS_)
return V.u[i];
#elif defined(_XM_SSE_INTRINSICS_)
#if defined(_MSC_VER) && (_MSC_VER<1400)
XMVECTORU32 tmp;
tmp.v = V;
return tmp.u[i];
#else
return V.m128_u32[i];
#endif
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Return the X component in an integer register.
// This causes Load/Hit/Store on VMX targets
XMFINLINE UINT XMVectorGetIntX(FXMVECTOR V)
{
#if defined(_XM_NO_INTRINSICS_)
return V.u[0];
#elif defined(_XM_SSE_INTRINSICS_)
return static_cast<UINT>(_mm_cvtsi128_si32(reinterpret_cast<const __m128i *>(&V)[0]));
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Return the Y component in an integer register.
// This causes Load/Hit/Store on VMX targets
XMFINLINE UINT XMVectorGetIntY(FXMVECTOR V)
{
#if defined(_XM_NO_INTRINSICS_)
return V.u[1];
#elif defined(_XM_SSE_INTRINSICS_)
__m128i vResulti = _mm_shuffle_epi32(reinterpret_cast<const __m128i *>(&V)[0],_MM_SHUFFLE(1,1,1,1));
return static_cast<UINT>(_mm_cvtsi128_si32(vResulti));
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Return the Z component in an integer register.
// This causes Load/Hit/Store on VMX targets
XMFINLINE UINT XMVectorGetIntZ(FXMVECTOR V)
{
#if defined(_XM_NO_INTRINSICS_)
return V.u[2];
#elif defined(_XM_SSE_INTRINSICS_)
__m128i vResulti = _mm_shuffle_epi32(reinterpret_cast<const __m128i *>(&V)[0],_MM_SHUFFLE(2,2,2,2));
return static_cast<UINT>(_mm_cvtsi128_si32(vResulti));
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Return the W component in an integer register.
// This causes Load/Hit/Store on VMX targets
XMFINLINE UINT XMVectorGetIntW(FXMVECTOR V)
{
#if defined(_XM_NO_INTRINSICS_)
return V.u[3];
#elif defined(_XM_SSE_INTRINSICS_)
__m128i vResulti = _mm_shuffle_epi32(reinterpret_cast<const __m128i *>(&V)[0],_MM_SHUFFLE(3,3,3,3));
return static_cast<UINT>(_mm_cvtsi128_si32(vResulti));
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Store a component indexed by i into a 32 bit integer location in memory.
// This causes Load/Hit/Store on VMX targets
XMFINLINE VOID XMVectorGetIntByIndexPtr(UINT *x,FXMVECTOR V,UINT i)
{
XMASSERT( x != 0 );
XMASSERT( i < 4 );
#if defined(_XM_NO_INTRINSICS_)
*x = V.u[i];
#elif defined(_XM_SSE_INTRINSICS_)
#if defined(_MSC_VER) && (_MSC_VER<1400)
XMVECTORU32 tmp;
tmp.v = V;
*x = tmp.u[i];
#else
*x = V.m128_u32[i];
#endif
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Store the X component into a 32 bit integer location in memory.
XMFINLINE VOID XMVectorGetIntXPtr(UINT *x,FXMVECTOR V)
{
XMASSERT( x != 0 );
#if defined(_XM_NO_INTRINSICS_)
*x = V.u[0];
#elif defined(_XM_SSE_INTRINSICS_)
_mm_store_ss(reinterpret_cast<float *>(x),V);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Store the Y component into a 32 bit integer location in memory.
XMFINLINE VOID XMVectorGetIntYPtr(UINT *y,FXMVECTOR V)
{
XMASSERT( y != 0 );
#if defined(_XM_NO_INTRINSICS_)
*y = V.u[1];
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(1,1,1,1));
_mm_store_ss(reinterpret_cast<float *>(y),vResult);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Store the Z component into a 32 bit integer locaCantion in memory.
XMFINLINE VOID XMVectorGetIntZPtr(UINT *z,FXMVECTOR V)
{
XMASSERT( z != 0 );
#if defined(_XM_NO_INTRINSICS_)
*z = V.u[2];
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(2,2,2,2));
_mm_store_ss(reinterpret_cast<float *>(z),vResult);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Store the W component into a 32 bit integer location in memory.
XMFINLINE VOID XMVectorGetIntWPtr(UINT *w,FXMVECTOR V)
{
XMASSERT( w != 0 );
#if defined(_XM_NO_INTRINSICS_)
*w = V.u[3];
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(3,3,3,3));
_mm_store_ss(reinterpret_cast<float *>(w),vResult);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Set a single indexed floating point component
// This causes Load/Hit/Store on VMX targets
XMFINLINE XMVECTOR XMVectorSetByIndex(FXMVECTOR V, FLOAT f,UINT i)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR U;
XMASSERT( i <= 3 );
U = V;
U.v[i] = f;
return U;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT( i <= 3 );
XMVECTOR U = V;
U.m128_f32[i] = f;
return U;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Sets the X component of a vector to a passed floating point value
// This causes Load/Hit/Store on VMX targets
XMFINLINE XMVECTOR XMVectorSetX(FXMVECTOR V, FLOAT x)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR U;
U.v[0] = x;
U.v[1] = V.v[1];
U.v[2] = V.v[2];
U.v[3] = V.v[3];
return U;
#elif defined(_XM_SSE_INTRINSICS_)
#if defined(_XM_ISVS2005_)
XMVECTOR vResult = V;
vResult.m128_f32[0] = x;
return vResult;
#else
XMVECTOR vResult = _mm_set_ss(x);
vResult = _mm_move_ss(V,vResult);
return vResult;
#endif // _XM_ISVS2005_
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Sets the Y component of a vector to a passed floating point value
// This causes Load/Hit/Store on VMX targets
XMFINLINE XMVECTOR XMVectorSetY(FXMVECTOR V, FLOAT y)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR U;
U.v[0] = V.v[0];
U.v[1] = y;
U.v[2] = V.v[2];
U.v[3] = V.v[3];
return U;
#elif defined(_XM_SSE_INTRINSICS_)
#if defined(_XM_ISVS2005_)
XMVECTOR vResult = V;
vResult.m128_f32[1] = y;
return vResult;
#else
// Swap y and x
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(3,2,0,1));
// Convert input to vector
XMVECTOR vTemp = _mm_set_ss(y);
// Replace the x component
vResult = _mm_move_ss(vResult,vTemp);
// Swap y and x again
vResult = _mm_shuffle_ps(vResult,vResult,_MM_SHUFFLE(3,2,0,1));
return vResult;
#endif // _XM_ISVS2005_
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Sets the Z component of a vector to a passed floating point value
// This causes Load/Hit/Store on VMX targets
XMFINLINE XMVECTOR XMVectorSetZ(FXMVECTOR V, FLOAT z)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR U;
U.v[0] = V.v[0];
U.v[1] = V.v[1];
U.v[2] = z;
U.v[3] = V.v[3];
return U;
#elif defined(_XM_SSE_INTRINSICS_)
#if defined(_XM_ISVS2005_)
XMVECTOR vResult = V;
vResult.m128_f32[2] = z;
return vResult;
#else
// Swap z and x
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(3,0,1,2));
// Convert input to vector
XMVECTOR vTemp = _mm_set_ss(z);
// Replace the x component
vResult = _mm_move_ss(vResult,vTemp);
// Swap z and x again
vResult = _mm_shuffle_ps(vResult,vResult,_MM_SHUFFLE(3,0,1,2));
return vResult;
#endif // _XM_ISVS2005_
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Sets the W component of a vector to a passed floating point value
// This causes Load/Hit/Store on VMX targets
XMFINLINE XMVECTOR XMVectorSetW(FXMVECTOR V, FLOAT w)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR U;
U.v[0] = V.v[0];
U.v[1] = V.v[1];
U.v[2] = V.v[2];
U.v[3] = w;
return U;
#elif defined(_XM_SSE_INTRINSICS_)
#if defined(_XM_ISVS2005_)
XMVECTOR vResult = V;
vResult.m128_f32[3] = w;
return vResult;
#else
// Swap w and x
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(0,2,1,3));
// Convert input to vector
XMVECTOR vTemp = _mm_set_ss(w);
// Replace the x component
vResult = _mm_move_ss(vResult,vTemp);
// Swap w and x again
vResult = _mm_shuffle_ps(vResult,vResult,_MM_SHUFFLE(0,2,1,3));
return vResult;
#endif // _XM_ISVS2005_
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Sets a component of a vector to a floating point value passed by pointer
// This causes Load/Hit/Store on VMX targets
XMFINLINE XMVECTOR XMVectorSetByIndexPtr(FXMVECTOR V,CONST FLOAT *f,UINT i)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR U;
XMASSERT( f != 0 );
XMASSERT( i <= 3 );
U = V;
U.v[i] = *f;
return U;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT( f != 0 );
XMASSERT( i <= 3 );
XMVECTOR U = V;
U.m128_f32[i] = *f;
return U;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Sets the X component of a vector to a floating point value passed by pointer
XMFINLINE XMVECTOR XMVectorSetXPtr(FXMVECTOR V,CONST FLOAT *x)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR U;
XMASSERT( x != 0 );
U.v[0] = *x;
U.v[1] = V.v[1];
U.v[2] = V.v[2];
U.v[3] = V.v[3];
return U;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT( x != 0 );
XMVECTOR vResult = _mm_load_ss(x);
vResult = _mm_move_ss(V,vResult);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Sets the Y component of a vector to a floating point value passed by pointer
XMFINLINE XMVECTOR XMVectorSetYPtr(FXMVECTOR V,CONST FLOAT *y)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR U;
XMASSERT( y != 0 );
U.v[0] = V.v[0];
U.v[1] = *y;
U.v[2] = V.v[2];
U.v[3] = V.v[3];
return U;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT( y != 0 );
// Swap y and x
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(3,2,0,1));
// Convert input to vector
XMVECTOR vTemp = _mm_load_ss(y);
// Replace the x component
vResult = _mm_move_ss(vResult,vTemp);
// Swap y and x again
vResult = _mm_shuffle_ps(vResult,vResult,_MM_SHUFFLE(3,2,0,1));
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Sets the Z component of a vector to a floating point value passed by pointer
XMFINLINE XMVECTOR XMVectorSetZPtr(FXMVECTOR V,CONST FLOAT *z)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR U;
XMASSERT( z != 0 );
U.v[0] = V.v[0];
U.v[1] = V.v[1];
U.v[2] = *z;
U.v[3] = V.v[3];
return U;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT( z != 0 );
// Swap z and x
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(3,0,1,2));
// Convert input to vector
XMVECTOR vTemp = _mm_load_ss(z);
// Replace the x component
vResult = _mm_move_ss(vResult,vTemp);
// Swap z and x again
vResult = _mm_shuffle_ps(vResult,vResult,_MM_SHUFFLE(3,0,1,2));
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Sets the W component of a vector to a floating point value passed by pointer
XMFINLINE XMVECTOR XMVectorSetWPtr(FXMVECTOR V,CONST FLOAT *w)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR U;
XMASSERT( w != 0 );
U.v[0] = V.v[0];
U.v[1] = V.v[1];
U.v[2] = V.v[2];
U.v[3] = *w;
return U;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT( w != 0 );
// Swap w and x
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(0,2,1,3));
// Convert input to vector
XMVECTOR vTemp = _mm_load_ss(w);
// Replace the x component
vResult = _mm_move_ss(vResult,vTemp);
// Swap w and x again
vResult = _mm_shuffle_ps(vResult,vResult,_MM_SHUFFLE(0,2,1,3));
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Sets a component of a vector to an integer passed by value
// This causes Load/Hit/Store on VMX targets
XMFINLINE XMVECTOR XMVectorSetIntByIndex(FXMVECTOR V, UINT x, UINT i)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR U;
XMASSERT( i <= 3 );
U = V;
U.u[i] = x;
return U;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT( i <= 3 );
XMVECTORU32 tmp;
tmp.v = V;
tmp.u[i] = x;
return tmp;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Sets the X component of a vector to an integer passed by value
// This causes Load/Hit/Store on VMX targets
XMFINLINE XMVECTOR XMVectorSetIntX(FXMVECTOR V, UINT x)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR U;
U.u[0] = x;
U.u[1] = V.u[1];
U.u[2] = V.u[2];
U.u[3] = V.u[3];
return U;
#elif defined(_XM_SSE_INTRINSICS_)
#if defined(_XM_ISVS2005_)
XMVECTOR vResult = V;
vResult.m128_i32[0] = x;
return vResult;
#else
__m128i vTemp = _mm_cvtsi32_si128(x);
XMVECTOR vResult = _mm_move_ss(V,reinterpret_cast<const __m128 *>(&vTemp)[0]);
return vResult;
#endif // _XM_ISVS2005_
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Sets the Y component of a vector to an integer passed by value
// This causes Load/Hit/Store on VMX targets
XMFINLINE XMVECTOR XMVectorSetIntY(FXMVECTOR V, UINT y)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR U;
U.u[0] = V.u[0];
U.u[1] = y;
U.u[2] = V.u[2];
U.u[3] = V.u[3];
return U;
#elif defined(_XM_SSE_INTRINSICS_)
#if defined(_XM_ISVS2005_)
XMVECTOR vResult = V;
vResult.m128_i32[1] = y;
return vResult;
#else // Swap y and x
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(3,2,0,1));
// Convert input to vector
__m128i vTemp = _mm_cvtsi32_si128(y);
// Replace the x component
vResult = _mm_move_ss(vResult,reinterpret_cast<const __m128 *>(&vTemp)[0]);
// Swap y and x again
vResult = _mm_shuffle_ps(vResult,vResult,_MM_SHUFFLE(3,2,0,1));
return vResult;
#endif // _XM_ISVS2005_
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Sets the Z component of a vector to an integer passed by value
// This causes Load/Hit/Store on VMX targets
XMFINLINE XMVECTOR XMVectorSetIntZ(FXMVECTOR V, UINT z)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR U;
U.u[0] = V.u[0];
U.u[1] = V.u[1];
U.u[2] = z;
U.u[3] = V.u[3];
return U;
#elif defined(_XM_SSE_INTRINSICS_)
#if defined(_XM_ISVS2005_)
XMVECTOR vResult = V;
vResult.m128_i32[2] = z;
return vResult;
#else
// Swap z and x
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(3,0,1,2));
// Convert input to vector
__m128i vTemp = _mm_cvtsi32_si128(z);
// Replace the x component
vResult = _mm_move_ss(vResult,reinterpret_cast<const __m128 *>(&vTemp)[0]);
// Swap z and x again
vResult = _mm_shuffle_ps(vResult,vResult,_MM_SHUFFLE(3,0,1,2));
return vResult;
#endif // _XM_ISVS2005_
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Sets the W component of a vector to an integer passed by value
// This causes Load/Hit/Store on VMX targets
XMFINLINE XMVECTOR XMVectorSetIntW(FXMVECTOR V, UINT w)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR U;
U.u[0] = V.u[0];
U.u[1] = V.u[1];
U.u[2] = V.u[2];
U.u[3] = w;
return U;
#elif defined(_XM_SSE_INTRINSICS_)
#if defined(_XM_ISVS2005_)
XMVECTOR vResult = V;
vResult.m128_i32[3] = w;
return vResult;
#else
// Swap w and x
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(0,2,1,3));
// Convert input to vector
__m128i vTemp = _mm_cvtsi32_si128(w);
// Replace the x component
vResult = _mm_move_ss(vResult,reinterpret_cast<const __m128 *>(&vTemp)[0]);
// Swap w and x again
vResult = _mm_shuffle_ps(vResult,vResult,_MM_SHUFFLE(0,2,1,3));
return vResult;
#endif // _XM_ISVS2005_
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Sets a component of a vector to an integer value passed by pointer
// This causes Load/Hit/Store on VMX targets
XMFINLINE XMVECTOR XMVectorSetIntByIndexPtr(FXMVECTOR V, CONST UINT *x,UINT i)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR U;
XMASSERT( x != 0 );
XMASSERT( i <= 3 );
U = V;
U.u[i] = *x;
return U;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT( x != 0 );
XMASSERT( i <= 3 );
XMVECTORU32 tmp;
tmp.v = V;
tmp.u[i] = *x;
return tmp;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Sets the X component of a vector to an integer value passed by pointer
XMFINLINE XMVECTOR XMVectorSetIntXPtr(FXMVECTOR V,CONST UINT *x)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR U;
XMASSERT( x != 0 );
U.u[0] = *x;
U.u[1] = V.u[1];
U.u[2] = V.u[2];
U.u[3] = V.u[3];
return U;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT( x != 0 );
XMVECTOR vTemp = _mm_load_ss(reinterpret_cast<const float *>(x));
XMVECTOR vResult = _mm_move_ss(V,vTemp);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Sets the Y component of a vector to an integer value passed by pointer
XMFINLINE XMVECTOR XMVectorSetIntYPtr(FXMVECTOR V,CONST UINT *y)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR U;
XMASSERT( y != 0 );
U.u[0] = V.u[0];
U.u[1] = *y;
U.u[2] = V.u[2];
U.u[3] = V.u[3];
return U;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT( y != 0 );
// Swap y and x
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(3,2,0,1));
// Convert input to vector
XMVECTOR vTemp = _mm_load_ss(reinterpret_cast<const float *>(y));
// Replace the x component
vResult = _mm_move_ss(vResult,vTemp);
// Swap y and x again
vResult = _mm_shuffle_ps(vResult,vResult,_MM_SHUFFLE(3,2,0,1));
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Sets the Z component of a vector to an integer value passed by pointer
XMFINLINE XMVECTOR XMVectorSetIntZPtr(FXMVECTOR V,CONST UINT *z)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR U;
XMASSERT( z != 0 );
U.u[0] = V.u[0];
U.u[1] = V.u[1];
U.u[2] = *z;
U.u[3] = V.u[3];
return U;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT( z != 0 );
// Swap z and x
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(3,0,1,2));
// Convert input to vector
XMVECTOR vTemp = _mm_load_ss(reinterpret_cast<const float *>(z));
// Replace the x component
vResult = _mm_move_ss(vResult,vTemp);
// Swap z and x again
vResult = _mm_shuffle_ps(vResult,vResult,_MM_SHUFFLE(3,0,1,2));
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
// Sets the W component of a vector to an integer value passed by pointer
XMFINLINE XMVECTOR XMVectorSetIntWPtr(FXMVECTOR V,CONST UINT *w)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR U;
XMASSERT( w != 0 );
U.u[0] = V.u[0];
U.u[1] = V.u[1];
U.u[2] = V.u[2];
U.u[3] = *w;
return U;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT( w != 0 );
// Swap w and x
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(0,2,1,3));
// Convert input to vector
XMVECTOR vTemp = _mm_load_ss(reinterpret_cast<const float *>(w));
// Replace the x component
vResult = _mm_move_ss(vResult,vTemp);
// Swap w and x again
vResult = _mm_shuffle_ps(vResult,vResult,_MM_SHUFFLE(0,2,1,3));
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Define a control vector to be used in XMVectorPermute
// operations. Visualize the two vectors V1 and V2 given
// in a permute as arranged back to back in a linear fashion,
// such that they form an array of 8 floating point values.
// The four integers specified in XMVectorPermuteControl
// will serve as indices into the array to select components
// from the two vectors. ElementIndex0 is used to select
// an element from the vectors to be placed in the first
// component of the resulting vector, ElementIndex1 is used
// to select an element for the second component, etc.
XMFINLINE XMVECTOR XMVectorPermuteControl
(
UINT ElementIndex0,
UINT ElementIndex1,
UINT ElementIndex2,
UINT ElementIndex3
)
{
#if defined(_XM_SSE_INTRINSICS_) || defined(_XM_NO_INTRINSICS_)
XMVECTORU32 vControl;
static CONST UINT ControlElement[] = {
XM_PERMUTE_0X,
XM_PERMUTE_0Y,
XM_PERMUTE_0Z,
XM_PERMUTE_0W,
XM_PERMUTE_1X,
XM_PERMUTE_1Y,
XM_PERMUTE_1Z,
XM_PERMUTE_1W
};
XMASSERT(ElementIndex0 < 8);
XMASSERT(ElementIndex1 < 8);
XMASSERT(ElementIndex2 < 8);
XMASSERT(ElementIndex3 < 8);
vControl.u[0] = ControlElement[ElementIndex0];
vControl.u[1] = ControlElement[ElementIndex1];
vControl.u[2] = ControlElement[ElementIndex2];
vControl.u[3] = ControlElement[ElementIndex3];
return vControl.v;
#else
#endif
}
//------------------------------------------------------------------------------
// Using a control vector made up of 16 bytes from 0-31, remap V1 and V2's byte
// entries into a single 16 byte vector and return it. Index 0-15 = V1,
// 16-31 = V2
XMFINLINE XMVECTOR XMVectorPermute
(
FXMVECTOR V1,
FXMVECTOR V2,
FXMVECTOR Control
)
{
#if defined(_XM_NO_INTRINSICS_)
const BYTE *aByte[2];
XMVECTOR Result;
UINT i, uIndex, VectorIndex;
const BYTE *pControl;
BYTE *pWork;
// Indices must be in range from 0 to 31
XMASSERT((Control.u[0] & 0xE0E0E0E0) == 0);
XMASSERT((Control.u[1] & 0xE0E0E0E0) == 0);
XMASSERT((Control.u[2] & 0xE0E0E0E0) == 0);
XMASSERT((Control.u[3] & 0xE0E0E0E0) == 0);
// 0-15 = V1, 16-31 = V2
aByte[0] = (const BYTE*)(&V1);
aByte[1] = (const BYTE*)(&V2);
i = 16;
pControl = (const BYTE *)(&Control);
pWork = (BYTE *)(&Result);
do {
// Get the byte to map from
uIndex = pControl[0];
++pControl;
VectorIndex = (uIndex>>4)&1;
uIndex &= 0x0F;
#if defined(_XM_X86_) || defined(_XM_X64_)
uIndex ^= 3; // Swap byte ordering on little endian machines
#endif
pWork[0] = aByte[VectorIndex][uIndex];
++pWork;
} while (--i);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
#if defined(_PREFAST_) || defined(XMDEBUG)
// Indices must be in range from 0 to 31
static const XMVECTORI32 g_PremuteTest = {0xE0E0E0E0,0xE0E0E0E0,0xE0E0E0E0,0xE0E0E0E0};
XMVECTOR vAssert = _mm_and_ps(Control,g_PremuteTest);
__m128i vAsserti = _mm_cmpeq_epi32(reinterpret_cast<const __m128i *>(&vAssert)[0],g_XMZero);
XMASSERT(_mm_movemask_ps(*reinterpret_cast<const __m128 *>(&vAsserti)) == 0xf);
#endif
// Store the vectors onto local memory on the stack
XMVECTOR Array[2];
Array[0] = V1;
Array[1] = V2;
// Output vector, on the stack
XMVECTORU8 vResult;
// Get pointer to the two vectors on the stack
const BYTE *pInput = reinterpret_cast<const BYTE *>(Array);
// Store the Control vector on the stack to access the bytes
// don't use Control, it can cause a register variable to spill on the stack.
XMVECTORU8 vControl;
vControl.v = Control; // Write to memory
UINT i = 0;
do {
UINT ComponentIndex = vControl.u[i] & 0x1FU;
ComponentIndex ^= 3; // Swap byte ordering
vResult.u[i] = pInput[ComponentIndex];
} while (++i<16);
return vResult;
#else // _XM_SSE_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Define a control vector to be used in XMVectorSelect
// operations. The four integers specified in XMVectorSelectControl
// serve as indices to select between components in two vectors.
// The first index controls selection for the first component of
// the vectors involved in a select operation, the second index
// controls selection for the second component etc. A value of
// zero for an index causes the corresponding component from the first
// vector to be selected whereas a one causes the component from the
// second vector to be selected instead.
XMFINLINE XMVECTOR XMVectorSelectControl
(
UINT VectorIndex0,
UINT VectorIndex1,
UINT VectorIndex2,
UINT VectorIndex3
)
{
#if defined(_XM_SSE_INTRINSICS_) && !defined(_XM_NO_INTRINSICS_)
// x=Index0,y=Index1,z=Index2,w=Index3
__m128i vTemp = _mm_set_epi32(VectorIndex3,VectorIndex2,VectorIndex1,VectorIndex0);
// Any non-zero entries become 0xFFFFFFFF else 0
vTemp = _mm_cmpgt_epi32(vTemp,g_XMZero);
return reinterpret_cast<__m128 *>(&vTemp)[0];
#else
XMVECTOR ControlVector;
CONST UINT ControlElement[] =
{
XM_SELECT_0,
XM_SELECT_1
};
XMASSERT(VectorIndex0 < 2);
XMASSERT(VectorIndex1 < 2);
XMASSERT(VectorIndex2 < 2);
XMASSERT(VectorIndex3 < 2);
ControlVector.u[0] = ControlElement[VectorIndex0];
ControlVector.u[1] = ControlElement[VectorIndex1];
ControlVector.u[2] = ControlElement[VectorIndex2];
ControlVector.u[3] = ControlElement[VectorIndex3];
return ControlVector;
#endif
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorSelect
(
FXMVECTOR V1,
FXMVECTOR V2,
FXMVECTOR Control
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result.u[0] = (V1.u[0] & ~Control.u[0]) | (V2.u[0] & Control.u[0]);
Result.u[1] = (V1.u[1] & ~Control.u[1]) | (V2.u[1] & Control.u[1]);
Result.u[2] = (V1.u[2] & ~Control.u[2]) | (V2.u[2] & Control.u[2]);
Result.u[3] = (V1.u[3] & ~Control.u[3]) | (V2.u[3] & Control.u[3]);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp1 = _mm_andnot_ps(Control,V1);
XMVECTOR vTemp2 = _mm_and_ps(V2,Control);
return _mm_or_ps(vTemp1,vTemp2);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorMergeXY
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result.u[0] = V1.u[0];
Result.u[1] = V2.u[0];
Result.u[2] = V1.u[1];
Result.u[3] = V2.u[1];
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_unpacklo_ps( V1, V2 );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorMergeZW
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result.u[0] = V1.u[2];
Result.u[1] = V2.u[2];
Result.u[2] = V1.u[3];
Result.u[3] = V2.u[3];
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_unpackhi_ps( V1, V2 );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Comparison operations
//------------------------------------------------------------------------------
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorEqual
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Control;
Control.u[0] = (V1.v[0] == V2.v[0]) ? 0xFFFFFFFF : 0;
Control.u[1] = (V1.v[1] == V2.v[1]) ? 0xFFFFFFFF : 0;
Control.u[2] = (V1.v[2] == V2.v[2]) ? 0xFFFFFFFF : 0;
Control.u[3] = (V1.v[3] == V2.v[3]) ? 0xFFFFFFFF : 0;
return Control;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_cmpeq_ps( V1, V2 );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorEqualR
(
UINT* pCR,
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
UINT ux, uy, uz, uw, CR;
XMVECTOR Control;
XMASSERT( pCR );
ux = (V1.x == V2.x) ? 0xFFFFFFFFU : 0;
uy = (V1.y == V2.y) ? 0xFFFFFFFFU : 0;
uz = (V1.z == V2.z) ? 0xFFFFFFFFU : 0;
uw = (V1.w == V2.w) ? 0xFFFFFFFFU : 0;
CR = 0;
if (ux&uy&uz&uw)
{
// All elements are greater
CR = XM_CRMASK_CR6TRUE;
}
else if (!(ux|uy|uz|uw))
{
// All elements are not greater
CR = XM_CRMASK_CR6FALSE;
}
*pCR = CR;
Control.u[0] = ux;
Control.u[1] = uy;
Control.u[2] = uz;
Control.u[3] = uw;
return Control;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT( pCR );
XMVECTOR vTemp = _mm_cmpeq_ps(V1,V2);
UINT CR = 0;
int iTest = _mm_movemask_ps(vTemp);
if (iTest==0xf)
{
CR = XM_CRMASK_CR6TRUE;
}
else if (!iTest)
{
// All elements are not greater
CR = XM_CRMASK_CR6FALSE;
}
*pCR = CR;
return vTemp;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Treat the components of the vectors as unsigned integers and
// compare individual bits between the two. This is useful for
// comparing control vectors and result vectors returned from
// other comparison operations.
XMFINLINE XMVECTOR XMVectorEqualInt
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Control;
Control.u[0] = (V1.u[0] == V2.u[0]) ? 0xFFFFFFFF : 0;
Control.u[1] = (V1.u[1] == V2.u[1]) ? 0xFFFFFFFF : 0;
Control.u[2] = (V1.u[2] == V2.u[2]) ? 0xFFFFFFFF : 0;
Control.u[3] = (V1.u[3] == V2.u[3]) ? 0xFFFFFFFF : 0;
return Control;
#elif defined(_XM_SSE_INTRINSICS_)
__m128i V = _mm_cmpeq_epi32( reinterpret_cast<const __m128i *>(&V1)[0],reinterpret_cast<const __m128i *>(&V2)[0] );
return reinterpret_cast<__m128 *>(&V)[0];
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorEqualIntR
(
UINT* pCR,
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Control;
XMASSERT(pCR);
Control = XMVectorEqualInt(V1, V2);
*pCR = 0;
if (XMVector4EqualInt(Control, XMVectorTrueInt()))
{
// All elements are equal
*pCR |= XM_CRMASK_CR6TRUE;
}
else if (XMVector4EqualInt(Control, XMVectorFalseInt()))
{
// All elements are not equal
*pCR |= XM_CRMASK_CR6FALSE;
}
return Control;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT(pCR);
__m128i V = _mm_cmpeq_epi32( reinterpret_cast<const __m128i *>(&V1)[0],reinterpret_cast<const __m128i *>(&V2)[0] );
int iTemp = _mm_movemask_ps(reinterpret_cast<const __m128*>(&V)[0]);
UINT CR = 0;
if (iTemp==0x0F)
{
CR = XM_CRMASK_CR6TRUE;
}
else if (!iTemp)
{
CR = XM_CRMASK_CR6FALSE;
}
*pCR = CR;
return reinterpret_cast<__m128 *>(&V)[0];
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorNearEqual
(
FXMVECTOR V1,
FXMVECTOR V2,
FXMVECTOR Epsilon
)
{
#if defined(_XM_NO_INTRINSICS_)
FLOAT fDeltax, fDeltay, fDeltaz, fDeltaw;
XMVECTOR Control;
fDeltax = V1.x-V2.x;
fDeltay = V1.y-V2.y;
fDeltaz = V1.z-V2.z;
fDeltaw = V1.w-V2.w;
fDeltax = fabsf(fDeltax);
fDeltay = fabsf(fDeltay);
fDeltaz = fabsf(fDeltaz);
fDeltaw = fabsf(fDeltaw);
Control.u[0] = (fDeltax <= Epsilon.x) ? 0xFFFFFFFFU : 0;
Control.u[1] = (fDeltay <= Epsilon.y) ? 0xFFFFFFFFU : 0;
Control.u[2] = (fDeltaz <= Epsilon.z) ? 0xFFFFFFFFU : 0;
Control.u[3] = (fDeltaw <= Epsilon.w) ? 0xFFFFFFFFU : 0;
return Control;
#elif defined(_XM_SSE_INTRINSICS_)
// Get the difference
XMVECTOR vDelta = _mm_sub_ps(V1,V2);
// Get the absolute value of the difference
XMVECTOR vTemp = _mm_setzero_ps();
vTemp = _mm_sub_ps(vTemp,vDelta);
vTemp = _mm_max_ps(vTemp,vDelta);
vTemp = _mm_cmple_ps(vTemp,Epsilon);
return vTemp;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorNotEqual
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Control;
Control.u[0] = (V1.v[0] != V2.v[0]) ? 0xFFFFFFFF : 0;
Control.u[1] = (V1.v[1] != V2.v[1]) ? 0xFFFFFFFF : 0;
Control.u[2] = (V1.v[2] != V2.v[2]) ? 0xFFFFFFFF : 0;
Control.u[3] = (V1.v[3] != V2.v[3]) ? 0xFFFFFFFF : 0;
return Control;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_cmpneq_ps( V1, V2 );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorNotEqualInt
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Control;
Control.u[0] = (V1.u[0] != V2.u[0]) ? 0xFFFFFFFFU : 0;
Control.u[1] = (V1.u[1] != V2.u[1]) ? 0xFFFFFFFFU : 0;
Control.u[2] = (V1.u[2] != V2.u[2]) ? 0xFFFFFFFFU : 0;
Control.u[3] = (V1.u[3] != V2.u[3]) ? 0xFFFFFFFFU : 0;
return Control;
#elif defined(_XM_SSE_INTRINSICS_)
__m128i V = _mm_cmpeq_epi32( reinterpret_cast<const __m128i *>(&V1)[0],reinterpret_cast<const __m128i *>(&V2)[0] );
return _mm_xor_ps(reinterpret_cast<__m128 *>(&V)[0],g_XMNegOneMask);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorGreater
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Control;
Control.u[0] = (V1.v[0] > V2.v[0]) ? 0xFFFFFFFF : 0;
Control.u[1] = (V1.v[1] > V2.v[1]) ? 0xFFFFFFFF : 0;
Control.u[2] = (V1.v[2] > V2.v[2]) ? 0xFFFFFFFF : 0;
Control.u[3] = (V1.v[3] > V2.v[3]) ? 0xFFFFFFFF : 0;
return Control;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_cmpgt_ps( V1, V2 );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorGreaterR
(
UINT* pCR,
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
UINT ux, uy, uz, uw, CR;
XMVECTOR Control;
XMASSERT( pCR );
ux = (V1.x > V2.x) ? 0xFFFFFFFFU : 0;
uy = (V1.y > V2.y) ? 0xFFFFFFFFU : 0;
uz = (V1.z > V2.z) ? 0xFFFFFFFFU : 0;
uw = (V1.w > V2.w) ? 0xFFFFFFFFU : 0;
CR = 0;
if (ux&uy&uz&uw)
{
// All elements are greater
CR = XM_CRMASK_CR6TRUE;
}
else if (!(ux|uy|uz|uw))
{
// All elements are not greater
CR = XM_CRMASK_CR6FALSE;
}
*pCR = CR;
Control.u[0] = ux;
Control.u[1] = uy;
Control.u[2] = uz;
Control.u[3] = uw;
return Control;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT( pCR );
XMVECTOR vTemp = _mm_cmpgt_ps(V1,V2);
UINT CR = 0;
int iTest = _mm_movemask_ps(vTemp);
if (iTest==0xf)
{
CR = XM_CRMASK_CR6TRUE;
}
else if (!iTest)
{
// All elements are not greater
CR = XM_CRMASK_CR6FALSE;
}
*pCR = CR;
return vTemp;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorGreaterOrEqual
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Control;
Control.u[0] = (V1.v[0] >= V2.v[0]) ? 0xFFFFFFFF : 0;
Control.u[1] = (V1.v[1] >= V2.v[1]) ? 0xFFFFFFFF : 0;
Control.u[2] = (V1.v[2] >= V2.v[2]) ? 0xFFFFFFFF : 0;
Control.u[3] = (V1.v[3] >= V2.v[3]) ? 0xFFFFFFFF : 0;
return Control;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_cmpge_ps( V1, V2 );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorGreaterOrEqualR
(
UINT* pCR,
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
UINT ux, uy, uz, uw, CR;
XMVECTOR Control;
XMASSERT( pCR );
ux = (V1.x >= V2.x) ? 0xFFFFFFFFU : 0;
uy = (V1.y >= V2.y) ? 0xFFFFFFFFU : 0;
uz = (V1.z >= V2.z) ? 0xFFFFFFFFU : 0;
uw = (V1.w >= V2.w) ? 0xFFFFFFFFU : 0;
CR = 0;
if (ux&uy&uz&uw)
{
// All elements are greater
CR = XM_CRMASK_CR6TRUE;
}
else if (!(ux|uy|uz|uw))
{
// All elements are not greater
CR = XM_CRMASK_CR6FALSE;
}
*pCR = CR;
Control.u[0] = ux;
Control.u[1] = uy;
Control.u[2] = uz;
Control.u[3] = uw;
return Control;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT( pCR );
XMVECTOR vTemp = _mm_cmpge_ps(V1,V2);
UINT CR = 0;
int iTest = _mm_movemask_ps(vTemp);
if (iTest==0xf)
{
CR = XM_CRMASK_CR6TRUE;
}
else if (!iTest)
{
// All elements are not greater
CR = XM_CRMASK_CR6FALSE;
}
*pCR = CR;
return vTemp;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorLess
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Control;
Control.u[0] = (V1.v[0] < V2.v[0]) ? 0xFFFFFFFF : 0;
Control.u[1] = (V1.v[1] < V2.v[1]) ? 0xFFFFFFFF : 0;
Control.u[2] = (V1.v[2] < V2.v[2]) ? 0xFFFFFFFF : 0;
Control.u[3] = (V1.v[3] < V2.v[3]) ? 0xFFFFFFFF : 0;
return Control;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_cmplt_ps( V1, V2 );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorLessOrEqual
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Control;
Control.u[0] = (V1.v[0] <= V2.v[0]) ? 0xFFFFFFFF : 0;
Control.u[1] = (V1.v[1] <= V2.v[1]) ? 0xFFFFFFFF : 0;
Control.u[2] = (V1.v[2] <= V2.v[2]) ? 0xFFFFFFFF : 0;
Control.u[3] = (V1.v[3] <= V2.v[3]) ? 0xFFFFFFFF : 0;
return Control;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_cmple_ps( V1, V2 );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorInBounds
(
FXMVECTOR V,
FXMVECTOR Bounds
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Control;
Control.u[0] = (V.x <= Bounds.x && V.x >= -Bounds.x) ? 0xFFFFFFFF : 0;
Control.u[1] = (V.y <= Bounds.y && V.y >= -Bounds.y) ? 0xFFFFFFFF : 0;
Control.u[2] = (V.z <= Bounds.z && V.z >= -Bounds.z) ? 0xFFFFFFFF : 0;
Control.u[3] = (V.w <= Bounds.w && V.w >= -Bounds.w) ? 0xFFFFFFFF : 0;
return Control;
#elif defined(_XM_SSE_INTRINSICS_)
// Test if less than or equal
XMVECTOR vTemp1 = _mm_cmple_ps(V,Bounds);
// Negate the bounds
XMVECTOR vTemp2 = _mm_mul_ps(Bounds,g_XMNegativeOne);
// Test if greater or equal (Reversed)
vTemp2 = _mm_cmple_ps(vTemp2,V);
// Blend answers
vTemp1 = _mm_and_ps(vTemp1,vTemp2);
return vTemp1;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorInBoundsR
(
UINT* pCR,
FXMVECTOR V,
FXMVECTOR Bounds
)
{
#if defined(_XM_NO_INTRINSICS_)
UINT ux, uy, uz, uw, CR;
XMVECTOR Control;
XMASSERT( pCR != 0 );
ux = (V.x <= Bounds.x && V.x >= -Bounds.x) ? 0xFFFFFFFFU : 0;
uy = (V.y <= Bounds.y && V.y >= -Bounds.y) ? 0xFFFFFFFFU : 0;
uz = (V.z <= Bounds.z && V.z >= -Bounds.z) ? 0xFFFFFFFFU : 0;
uw = (V.w <= Bounds.w && V.w >= -Bounds.w) ? 0xFFFFFFFFU : 0;
CR = 0;
if (ux&uy&uz&uw)
{
// All elements are in bounds
CR = XM_CRMASK_CR6BOUNDS;
}
*pCR = CR;
Control.u[0] = ux;
Control.u[1] = uy;
Control.u[2] = uz;
Control.u[3] = uw;
return Control;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT( pCR != 0 );
// Test if less than or equal
XMVECTOR vTemp1 = _mm_cmple_ps(V,Bounds);
// Negate the bounds
XMVECTOR vTemp2 = _mm_mul_ps(Bounds,g_XMNegativeOne);
// Test if greater or equal (Reversed)
vTemp2 = _mm_cmple_ps(vTemp2,V);
// Blend answers
vTemp1 = _mm_and_ps(vTemp1,vTemp2);
UINT CR = 0;
if (_mm_movemask_ps(vTemp1)==0xf) {
// All elements are in bounds
CR = XM_CRMASK_CR6BOUNDS;
}
*pCR = CR;
return vTemp1;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorIsNaN
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Control;
Control.u[0] = XMISNAN(V.x) ? 0xFFFFFFFFU : 0;
Control.u[1] = XMISNAN(V.y) ? 0xFFFFFFFFU : 0;
Control.u[2] = XMISNAN(V.z) ? 0xFFFFFFFFU : 0;
Control.u[3] = XMISNAN(V.w) ? 0xFFFFFFFFU : 0;
return Control;
#elif defined(_XM_SSE_INTRINSICS_)
// Mask off the exponent
__m128i vTempInf = _mm_and_si128(reinterpret_cast<const __m128i *>(&V)[0],g_XMInfinity);
// Mask off the mantissa
__m128i vTempNan = _mm_and_si128(reinterpret_cast<const __m128i *>(&V)[0],g_XMQNaNTest);
// Are any of the exponents == 0x7F800000?
vTempInf = _mm_cmpeq_epi32(vTempInf,g_XMInfinity);
// Are any of the mantissa's zero? (SSE2 doesn't have a neq test)
vTempNan = _mm_cmpeq_epi32(vTempNan,g_XMZero);
// Perform a not on the NaN test to be true on NON-zero mantissas
vTempNan = _mm_andnot_si128(vTempNan,vTempInf);
// If any are NaN, the signs are true after the merge above
return reinterpret_cast<const XMVECTOR *>(&vTempNan)[0];
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorIsInfinite
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Control;
Control.u[0] = XMISINF(V.x) ? 0xFFFFFFFFU : 0;
Control.u[1] = XMISINF(V.y) ? 0xFFFFFFFFU : 0;
Control.u[2] = XMISINF(V.z) ? 0xFFFFFFFFU : 0;
Control.u[3] = XMISINF(V.w) ? 0xFFFFFFFFU : 0;
return Control;
#elif defined(_XM_SSE_INTRINSICS_)
// Mask off the sign bit
__m128 vTemp = _mm_and_ps(V,g_XMAbsMask);
// Compare to infinity
vTemp = _mm_cmpeq_ps(vTemp,g_XMInfinity);
// If any are infinity, the signs are true.
return vTemp;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Rounding and clamping operations
//------------------------------------------------------------------------------
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorMin
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result.v[0] = (V1.v[0] < V2.v[0]) ? V1.v[0] : V2.v[0];
Result.v[1] = (V1.v[1] < V2.v[1]) ? V1.v[1] : V2.v[1];
Result.v[2] = (V1.v[2] < V2.v[2]) ? V1.v[2] : V2.v[2];
Result.v[3] = (V1.v[3] < V2.v[3]) ? V1.v[3] : V2.v[3];
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_min_ps( V1, V2 );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorMax
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result.v[0] = (V1.v[0] > V2.v[0]) ? V1.v[0] : V2.v[0];
Result.v[1] = (V1.v[1] > V2.v[1]) ? V1.v[1] : V2.v[1];
Result.v[2] = (V1.v[2] > V2.v[2]) ? V1.v[2] : V2.v[2];
Result.v[3] = (V1.v[3] > V2.v[3]) ? V1.v[3] : V2.v[3];
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_max_ps( V1, V2 );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorRound
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
XMVECTOR Bias;
CONST XMVECTOR Zero = XMVectorZero();
CONST XMVECTOR BiasPos = XMVectorReplicate(0.5f);
CONST XMVECTOR BiasNeg = XMVectorReplicate(-0.5f);
Bias = XMVectorLess(V, Zero);
Bias = XMVectorSelect(BiasPos, BiasNeg, Bias);
Result = XMVectorAdd(V, Bias);
Result = XMVectorTruncate(Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// To handle NAN, INF and numbers greater than 8388608, use masking
// Get the abs value
__m128i vTest = _mm_and_si128(reinterpret_cast<const __m128i *>(&V)[0],g_XMAbsMask);
// Test for greater than 8388608 (All floats with NO fractionals, NAN and INF
vTest = _mm_cmplt_epi32(vTest,g_XMNoFraction);
// Convert to int and back to float for rounding
__m128i vInt = _mm_cvtps_epi32(V);
// Convert back to floats
XMVECTOR vResult = _mm_cvtepi32_ps(vInt);
// All numbers less than 8388608 will use the round to int
vResult = _mm_and_ps(vResult,reinterpret_cast<const XMVECTOR *>(&vTest)[0]);
// All others, use the ORIGINAL value
vTest = _mm_andnot_si128(vTest,reinterpret_cast<const __m128i *>(&V)[0]);
vResult = _mm_or_ps(vResult,reinterpret_cast<const XMVECTOR *>(&vTest)[0]);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorTruncate
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result.x = (FLOAT)((INT)V.x);
Result.y = (FLOAT)((INT)V.y);
Result.z = (FLOAT)((INT)V.z);
Result.w = (FLOAT)((INT)V.w);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// To handle NAN, INF and numbers greater than 8388608, use masking
// Get the abs value
__m128i vTest = _mm_and_si128(reinterpret_cast<const __m128i *>(&V)[0],g_XMAbsMask);
// Test for greater than 8388608 (All floats with NO fractionals, NAN and INF
vTest = _mm_cmplt_epi32(vTest,g_XMNoFraction);
// Convert to int and back to float for rounding with truncation
__m128i vInt = _mm_cvttps_epi32(V);
// Convert back to floats
XMVECTOR vResult = _mm_cvtepi32_ps(vInt);
// All numbers less than 8388608 will use the round to int
vResult = _mm_and_ps(vResult,reinterpret_cast<const XMVECTOR *>(&vTest)[0]);
// All others, use the ORIGINAL value
vTest = _mm_andnot_si128(vTest,reinterpret_cast<const __m128i *>(&V)[0]);
vResult = _mm_or_ps(vResult,reinterpret_cast<const XMVECTOR *>(&vTest)[0]);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorFloor
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR vResult = {
floorf(V.x),
floorf(V.y),
floorf(V.z),
floorf(V.w)
};
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = _mm_sub_ps(V,g_XMOneHalfMinusEpsilon);
__m128i vInt = _mm_cvtps_epi32(vResult);
vResult = _mm_cvtepi32_ps(vInt);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorCeiling
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR vResult = {
ceilf(V.x),
ceilf(V.y),
ceilf(V.z),
ceilf(V.w)
};
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = _mm_add_ps(V,g_XMOneHalfMinusEpsilon);
__m128i vInt = _mm_cvtps_epi32(vResult);
vResult = _mm_cvtepi32_ps(vInt);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorClamp
(
FXMVECTOR V,
FXMVECTOR Min,
FXMVECTOR Max
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
XMASSERT(XMVector4LessOrEqual(Min, Max));
Result = XMVectorMax(Min, V);
Result = XMVectorMin(Max, Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult;
XMASSERT(XMVector4LessOrEqual(Min, Max));
vResult = _mm_max_ps(Min,V);
vResult = _mm_min_ps(vResult,Max);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorSaturate
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
CONST XMVECTOR Zero = XMVectorZero();
return XMVectorClamp(V, Zero, g_XMOne.v);
#elif defined(_XM_SSE_INTRINSICS_)
// Set <0 to 0
XMVECTOR vResult = _mm_max_ps(V,g_XMZero);
// Set>1 to 1
return _mm_min_ps(vResult,g_XMOne);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Bitwise logical operations
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorAndInt
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result.u[0] = V1.u[0] & V2.u[0];
Result.u[1] = V1.u[1] & V2.u[1];
Result.u[2] = V1.u[2] & V2.u[2];
Result.u[3] = V1.u[3] & V2.u[3];
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_and_ps(V1,V2);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorAndCInt
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result.u[0] = V1.u[0] & ~V2.u[0];
Result.u[1] = V1.u[1] & ~V2.u[1];
Result.u[2] = V1.u[2] & ~V2.u[2];
Result.u[3] = V1.u[3] & ~V2.u[3];
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
__m128i V = _mm_andnot_si128( reinterpret_cast<const __m128i *>(&V2)[0], reinterpret_cast<const __m128i *>(&V1)[0] );
return reinterpret_cast<__m128 *>(&V)[0];
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorOrInt
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result.u[0] = V1.u[0] | V2.u[0];
Result.u[1] = V1.u[1] | V2.u[1];
Result.u[2] = V1.u[2] | V2.u[2];
Result.u[3] = V1.u[3] | V2.u[3];
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
__m128i V = _mm_or_si128( reinterpret_cast<const __m128i *>(&V1)[0], reinterpret_cast<const __m128i *>(&V2)[0] );
return reinterpret_cast<__m128 *>(&V)[0];
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorNorInt
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result.u[0] = ~(V1.u[0] | V2.u[0]);
Result.u[1] = ~(V1.u[1] | V2.u[1]);
Result.u[2] = ~(V1.u[2] | V2.u[2]);
Result.u[3] = ~(V1.u[3] | V2.u[3]);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
__m128i Result;
Result = _mm_or_si128( reinterpret_cast<const __m128i *>(&V1)[0], reinterpret_cast<const __m128i *>(&V2)[0] );
Result = _mm_andnot_si128( Result,g_XMNegOneMask);
return reinterpret_cast<__m128 *>(&Result)[0];
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorXorInt
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result.u[0] = V1.u[0] ^ V2.u[0];
Result.u[1] = V1.u[1] ^ V2.u[1];
Result.u[2] = V1.u[2] ^ V2.u[2];
Result.u[3] = V1.u[3] ^ V2.u[3];
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
__m128i V = _mm_xor_si128( reinterpret_cast<const __m128i *>(&V1)[0], reinterpret_cast<const __m128i *>(&V2)[0] );
return reinterpret_cast<__m128 *>(&V)[0];
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Computation operations
//------------------------------------------------------------------------------
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorNegate
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result.v[0] = -V.v[0];
Result.v[1] = -V.v[1];
Result.v[2] = -V.v[2];
Result.v[3] = -V.v[3];
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR Z;
Z = _mm_setzero_ps();
return _mm_sub_ps( Z, V );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorAdd
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result.v[0] = V1.v[0] + V2.v[0];
Result.v[1] = V1.v[1] + V2.v[1];
Result.v[2] = V1.v[2] + V2.v[2];
Result.v[3] = V1.v[3] + V2.v[3];
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_add_ps( V1, V2 );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorAddAngles
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Mask;
XMVECTOR Offset;
XMVECTOR Result;
CONST XMVECTOR Zero = XMVectorZero();
// Add the given angles together. If the range of V1 is such
// that -Pi <= V1 < Pi and the range of V2 is such that
// -2Pi <= V2 <= 2Pi, then the range of the resulting angle
// will be -Pi <= Result < Pi.
Result = XMVectorAdd(V1, V2);
Mask = XMVectorLess(Result, g_XMNegativePi.v);
Offset = XMVectorSelect(Zero, g_XMTwoPi.v, Mask);
Mask = XMVectorGreaterOrEqual(Result, g_XMPi.v);
Offset = XMVectorSelect(Offset, g_XMNegativeTwoPi.v, Mask);
Result = XMVectorAdd(Result, Offset);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Adjust the angles
XMVECTOR vResult = _mm_add_ps(V1,V2);
// Less than Pi?
XMVECTOR vOffset = _mm_cmplt_ps(vResult,g_XMNegativePi);
vOffset = _mm_and_ps(vOffset,g_XMTwoPi);
// Add 2Pi to all entries less than -Pi
vResult = _mm_add_ps(vResult,vOffset);
// Greater than or equal to Pi?
vOffset = _mm_cmpge_ps(vResult,g_XMPi);
vOffset = _mm_and_ps(vOffset,g_XMTwoPi);
// Sub 2Pi to all entries greater than Pi
vResult = _mm_sub_ps(vResult,vOffset);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorSubtract
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result.x = V1.x - V2.x;
Result.y = V1.y - V2.y;
Result.z = V1.z - V2.z;
Result.w = V1.w - V2.w;
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_sub_ps( V1, V2 );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorSubtractAngles
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Mask;
XMVECTOR Offset;
XMVECTOR Result;
CONST XMVECTOR Zero = XMVectorZero();
// Subtract the given angles. If the range of V1 is such
// that -Pi <= V1 < Pi and the range of V2 is such that
// -2Pi <= V2 <= 2Pi, then the range of the resulting angle
// will be -Pi <= Result < Pi.
Result = XMVectorSubtract(V1, V2);
Mask = XMVectorLess(Result, g_XMNegativePi.v);
Offset = XMVectorSelect(Zero, g_XMTwoPi.v, Mask);
Mask = XMVectorGreaterOrEqual(Result, g_XMPi.v);
Offset = XMVectorSelect(Offset, g_XMNegativeTwoPi.v, Mask);
Result = XMVectorAdd(Result, Offset);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Adjust the angles
XMVECTOR vResult = _mm_sub_ps(V1,V2);
// Less than Pi?
XMVECTOR vOffset = _mm_cmplt_ps(vResult,g_XMNegativePi);
vOffset = _mm_and_ps(vOffset,g_XMTwoPi);
// Add 2Pi to all entries less than -Pi
vResult = _mm_add_ps(vResult,vOffset);
// Greater than or equal to Pi?
vOffset = _mm_cmpge_ps(vResult,g_XMPi);
vOffset = _mm_and_ps(vOffset,g_XMTwoPi);
// Sub 2Pi to all entries greater than Pi
vResult = _mm_sub_ps(vResult,vOffset);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorMultiply
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result = {
V1.x * V2.x,
V1.y * V2.y,
V1.z * V2.z,
V1.w * V2.w
};
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_mul_ps( V1, V2 );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorMultiplyAdd
(
FXMVECTOR V1,
FXMVECTOR V2,
FXMVECTOR V3
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR vResult = {
(V1.x * V2.x) + V3.x,
(V1.y * V2.y) + V3.y,
(V1.z * V2.z) + V3.z,
(V1.w * V2.w) + V3.w
};
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = _mm_mul_ps( V1, V2 );
return _mm_add_ps(vResult, V3 );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorNegativeMultiplySubtract
(
FXMVECTOR V1,
FXMVECTOR V2,
FXMVECTOR V3
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR vResult = {
V3.x - (V1.x * V2.x),
V3.y - (V1.y * V2.y),
V3.z - (V1.z * V2.z),
V3.w - (V1.w * V2.w)
};
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR R = _mm_mul_ps( V1, V2 );
return _mm_sub_ps( V3, R );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorScale
(
FXMVECTOR V,
FLOAT ScaleFactor
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR vResult = {
V.x * ScaleFactor,
V.y * ScaleFactor,
V.z * ScaleFactor,
V.w * ScaleFactor
};
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = _mm_set_ps1(ScaleFactor);
return _mm_mul_ps(vResult,V);
#elif defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorReciprocalEst
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
UINT i;
// Avoid C4701
Result.v[0] = 0.0f;
for (i = 0; i < 4; i++)
{
if (XMISINF(V.v[i]))
{
Result.v[i] = (V.v[i] < 0.0f) ? -0.0f : 0.0f;
}
else if (V.v[i] == -0.0f)
{
Result.u[i] = 0xFF800000;
}
else if (V.v[i] == 0.0f)
{
Result.u[i] = 0x7F800000;
}
else
{
Result.v[i] = 1.0f / V.v[i];
}
}
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_rcp_ps(V);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorReciprocal
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
return XMVectorReciprocalEst(V);
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_div_ps(g_XMOne,V);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Return an estimated square root
XMFINLINE XMVECTOR XMVectorSqrtEst
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Select;
// if (x == +Infinity) sqrt(x) = +Infinity
// if (x == +0.0f) sqrt(x) = +0.0f
// if (x == -0.0f) sqrt(x) = -0.0f
// if (x < -0.0f) sqrt(x) = QNaN
XMVECTOR Result = XMVectorReciprocalSqrtEst(V);
XMVECTOR Zero = XMVectorZero();
XMVECTOR VEqualsInfinity = XMVectorEqualInt(V, g_XMInfinity.v);
XMVECTOR VEqualsZero = XMVectorEqual(V, Zero);
Result = XMVectorMultiply(V, Result);
Select = XMVectorEqualInt(VEqualsInfinity, VEqualsZero);
Result = XMVectorSelect(V, Result, Select);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_sqrt_ps(V);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorSqrt
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Zero;
XMVECTOR VEqualsInfinity, VEqualsZero;
XMVECTOR Select;
XMVECTOR Result;
// if (x == +Infinity) sqrt(x) = +Infinity
// if (x == +0.0f) sqrt(x) = +0.0f
// if (x == -0.0f) sqrt(x) = -0.0f
// if (x < -0.0f) sqrt(x) = QNaN
Result = XMVectorReciprocalSqrt(V);
Zero = XMVectorZero();
VEqualsInfinity = XMVectorEqualInt(V, g_XMInfinity.v);
VEqualsZero = XMVectorEqual(V, Zero);
Result = XMVectorMultiply(V, Result);
Select = XMVectorEqualInt(VEqualsInfinity, VEqualsZero);
Result = XMVectorSelect(V, Result, Select);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_sqrt_ps(V);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorReciprocalSqrtEst
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
UINT i;
// Avoid C4701
Result.v[0] = 0.0f;
for (i = 0; i < 4; i++)
{
if (V.v[i] == 0.0f)
{
Result.u[i] = 0x7F800000;
}
else if (V.v[i] == -0.0f)
{
Result.u[i] = 0xFF800000;
}
else if (V.v[i] < 0.0f)
{
Result.u[i] = 0x7FFFFFFF;
}
else if (XMISINF(V.v[i]))
{
Result.v[i] = 0.0f;
}
else
{
Result.v[i] = 1.0f / sqrtf(V.v[i]);
}
}
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
return _mm_rsqrt_ps(V);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorReciprocalSqrt
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
return XMVectorReciprocalSqrtEst(V);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = _mm_sqrt_ps(V);
vResult = _mm_div_ps(g_XMOne,vResult);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorExpEst
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result.x = powf(2.0f, V.x);
Result.y = powf(2.0f, V.y);
Result.z = powf(2.0f, V.z);
Result.w = powf(2.0f, V.w);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = _mm_setr_ps(
powf(2.0f,XMVectorGetX(V)),
powf(2.0f,XMVectorGetY(V)),
powf(2.0f,XMVectorGetZ(V)),
powf(2.0f,XMVectorGetW(V)));
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMVECTOR XMVectorExp
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR E, S;
XMVECTOR R, R2, R3, R4;
XMVECTOR V0, V1;
XMVECTOR C0X, C0Y, C0Z, C0W;
XMVECTOR C1X, C1Y, C1Z, C1W;
XMVECTOR Result;
static CONST XMVECTOR C0 = {1.0f, -6.93147182e-1f, 2.40226462e-1f, -5.55036440e-2f};
static CONST XMVECTOR C1 = {9.61597636e-3f, -1.32823968e-3f, 1.47491097e-4f, -1.08635004e-5f};
R = XMVectorFloor(V);
E = XMVectorExpEst(R);
R = XMVectorSubtract(V, R);
R2 = XMVectorMultiply(R, R);
R3 = XMVectorMultiply(R, R2);
R4 = XMVectorMultiply(R2, R2);
C0X = XMVectorSplatX(C0);
C0Y = XMVectorSplatY(C0);
C0Z = XMVectorSplatZ(C0);
C0W = XMVectorSplatW(C0);
C1X = XMVectorSplatX(C1);
C1Y = XMVectorSplatY(C1);
C1Z = XMVectorSplatZ(C1);
C1W = XMVectorSplatW(C1);
V0 = XMVectorMultiplyAdd(R, C0Y, C0X);
V0 = XMVectorMultiplyAdd(R2, C0Z, V0);
V0 = XMVectorMultiplyAdd(R3, C0W, V0);
V1 = XMVectorMultiplyAdd(R, C1Y, C1X);
V1 = XMVectorMultiplyAdd(R2, C1Z, V1);
V1 = XMVectorMultiplyAdd(R3, C1W, V1);
S = XMVectorMultiplyAdd(R4, V1, V0);
S = XMVectorReciprocal(S);
Result = XMVectorMultiply(E, S);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
static CONST XMVECTORF32 C0 = {1.0f, -6.93147182e-1f, 2.40226462e-1f, -5.55036440e-2f};
static CONST XMVECTORF32 C1 = {9.61597636e-3f, -1.32823968e-3f, 1.47491097e-4f, -1.08635004e-5f};
// Get the integer of the input
XMVECTOR R = XMVectorFloor(V);
// Get the exponent estimate
XMVECTOR E = XMVectorExpEst(R);
// Get the fractional only
R = _mm_sub_ps(V,R);
// Get R^2
XMVECTOR R2 = _mm_mul_ps(R,R);
// And R^3
XMVECTOR R3 = _mm_mul_ps(R,R2);
XMVECTOR V0 = _mm_load_ps1(&C0.f[1]);
V0 = _mm_mul_ps(V0,R);
XMVECTOR vConstants = _mm_load_ps1(&C0.f[0]);
V0 = _mm_add_ps(V0,vConstants);
vConstants = _mm_load_ps1(&C0.f[2]);
vConstants = _mm_mul_ps(vConstants,R2);
V0 = _mm_add_ps(V0,vConstants);
vConstants = _mm_load_ps1(&C0.f[3]);
vConstants = _mm_mul_ps(vConstants,R3);
V0 = _mm_add_ps(V0,vConstants);
XMVECTOR V1 = _mm_load_ps1(&C1.f[1]);
V1 = _mm_mul_ps(V1,R);
vConstants = _mm_load_ps1(&C1.f[0]);
V1 = _mm_add_ps(V1,vConstants);
vConstants = _mm_load_ps1(&C1.f[2]);
vConstants = _mm_mul_ps(vConstants,R2);
V1 = _mm_add_ps(V1,vConstants);
vConstants = _mm_load_ps1(&C1.f[3]);
vConstants = _mm_mul_ps(vConstants,R3);
V1 = _mm_add_ps(V1,vConstants);
// R2 = R^4
R2 = _mm_mul_ps(R2,R2);
R2 = _mm_mul_ps(R2,V1);
R2 = _mm_add_ps(R2,V0);
E = _mm_div_ps(E,R2);
return E;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorLogEst
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
FLOAT fScale = (1.0f / logf(2.0f));
XMVECTOR Result;
Result.x = logf(V.x)*fScale;
Result.y = logf(V.y)*fScale;
Result.z = logf(V.z)*fScale;
Result.w = logf(V.w)*fScale;
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vScale = _mm_set_ps1(1.0f / logf(2.0f));
XMVECTOR vResult = _mm_setr_ps(
logf(XMVectorGetX(V)),
logf(XMVectorGetY(V)),
logf(XMVectorGetZ(V)),
logf(XMVectorGetW(V)));
vResult = _mm_mul_ps(vResult,vScale);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMVECTOR XMVectorLog
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
FLOAT fScale = (1.0f / logf(2.0f));
XMVECTOR Result;
Result.x = logf(V.x)*fScale;
Result.y = logf(V.y)*fScale;
Result.z = logf(V.z)*fScale;
Result.w = logf(V.w)*fScale;
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vScale = _mm_set_ps1(1.0f / logf(2.0f));
XMVECTOR vResult = _mm_setr_ps(
logf(XMVectorGetX(V)),
logf(XMVectorGetY(V)),
logf(XMVectorGetZ(V)),
logf(XMVectorGetW(V)));
vResult = _mm_mul_ps(vResult,vScale);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorPowEst
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result.x = powf(V1.x, V2.x);
Result.y = powf(V1.y, V2.y);
Result.z = powf(V1.z, V2.z);
Result.w = powf(V1.w, V2.w);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = _mm_setr_ps(
powf(XMVectorGetX(V1),XMVectorGetX(V2)),
powf(XMVectorGetY(V1),XMVectorGetY(V2)),
powf(XMVectorGetZ(V1),XMVectorGetZ(V2)),
powf(XMVectorGetW(V1),XMVectorGetW(V2)));
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorPow
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_) || defined(_XM_SSE_INTRINSICS_)
return XMVectorPowEst(V1, V2);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorAbs
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR vResult = {
fabsf(V.x),
fabsf(V.y),
fabsf(V.z),
fabsf(V.w)
};
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = _mm_setzero_ps();
vResult = _mm_sub_ps(vResult,V);
vResult = _mm_max_ps(vResult,V);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorMod
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Reciprocal;
XMVECTOR Quotient;
XMVECTOR Result;
// V1 % V2 = V1 - V2 * truncate(V1 / V2)
Reciprocal = XMVectorReciprocal(V2);
Quotient = XMVectorMultiply(V1, Reciprocal);
Quotient = XMVectorTruncate(Quotient);
Result = XMVectorNegativeMultiplySubtract(V2, Quotient, V1);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = _mm_div_ps(V1, V2);
vResult = XMVectorTruncate(vResult);
vResult = _mm_mul_ps(vResult,V2);
vResult = _mm_sub_ps(V1,vResult);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorModAngles
(
FXMVECTOR Angles
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR V;
XMVECTOR Result;
// Modulo the range of the given angles such that -XM_PI <= Angles < XM_PI
V = XMVectorMultiply(Angles, g_XMReciprocalTwoPi.v);
V = XMVectorRound(V);
Result = XMVectorNegativeMultiplySubtract(g_XMTwoPi.v, V, Angles);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Modulo the range of the given angles such that -XM_PI <= Angles < XM_PI
XMVECTOR vResult = _mm_mul_ps(Angles,g_XMReciprocalTwoPi);
// Use the inline function due to complexity for rounding
vResult = XMVectorRound(vResult);
vResult = _mm_mul_ps(vResult,g_XMTwoPi);
vResult = _mm_sub_ps(Angles,vResult);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMVECTOR XMVectorSin
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR V1, V2, V3, V5, V7, V9, V11, V13, V15, V17, V19, V21, V23;
XMVECTOR S1, S2, S3, S4, S5, S6, S7, S8, S9, S10, S11;
XMVECTOR Result;
V1 = XMVectorModAngles(V);
// sin(V) ~= V - V^3 / 3! + V^5 / 5! - V^7 / 7! + V^9 / 9! - V^11 / 11! + V^13 / 13! -
// V^15 / 15! + V^17 / 17! - V^19 / 19! + V^21 / 21! - V^23 / 23! (for -PI <= V < PI)
V2 = XMVectorMultiply(V1, V1);
V3 = XMVectorMultiply(V2, V1);
V5 = XMVectorMultiply(V3, V2);
V7 = XMVectorMultiply(V5, V2);
V9 = XMVectorMultiply(V7, V2);
V11 = XMVectorMultiply(V9, V2);
V13 = XMVectorMultiply(V11, V2);
V15 = XMVectorMultiply(V13, V2);
V17 = XMVectorMultiply(V15, V2);
V19 = XMVectorMultiply(V17, V2);
V21 = XMVectorMultiply(V19, V2);
V23 = XMVectorMultiply(V21, V2);
S1 = XMVectorSplatY(g_XMSinCoefficients0.v);
S2 = XMVectorSplatZ(g_XMSinCoefficients0.v);
S3 = XMVectorSplatW(g_XMSinCoefficients0.v);
S4 = XMVectorSplatX(g_XMSinCoefficients1.v);
S5 = XMVectorSplatY(g_XMSinCoefficients1.v);
S6 = XMVectorSplatZ(g_XMSinCoefficients1.v);
S7 = XMVectorSplatW(g_XMSinCoefficients1.v);
S8 = XMVectorSplatX(g_XMSinCoefficients2.v);
S9 = XMVectorSplatY(g_XMSinCoefficients2.v);
S10 = XMVectorSplatZ(g_XMSinCoefficients2.v);
S11 = XMVectorSplatW(g_XMSinCoefficients2.v);
Result = XMVectorMultiplyAdd(S1, V3, V1);
Result = XMVectorMultiplyAdd(S2, V5, Result);
Result = XMVectorMultiplyAdd(S3, V7, Result);
Result = XMVectorMultiplyAdd(S4, V9, Result);
Result = XMVectorMultiplyAdd(S5, V11, Result);
Result = XMVectorMultiplyAdd(S6, V13, Result);
Result = XMVectorMultiplyAdd(S7, V15, Result);
Result = XMVectorMultiplyAdd(S8, V17, Result);
Result = XMVectorMultiplyAdd(S9, V19, Result);
Result = XMVectorMultiplyAdd(S10, V21, Result);
Result = XMVectorMultiplyAdd(S11, V23, Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Force the value within the bounds of pi
XMVECTOR vResult = XMVectorModAngles(V);
// Each on is V to the "num" power
// V2 = V1^2
XMVECTOR V2 = _mm_mul_ps(vResult,vResult);
// V1^3
XMVECTOR vPower = _mm_mul_ps(vResult,V2);
XMVECTOR vConstants = _mm_load_ps1(&g_XMSinCoefficients0.f[1]);
vConstants = _mm_mul_ps(vConstants,vPower);
vResult = _mm_add_ps(vResult,vConstants);
// V^5
vPower = _mm_mul_ps(vPower,V2);
vConstants = _mm_load_ps1(&g_XMSinCoefficients0.f[2]);
vConstants = _mm_mul_ps(vConstants,vPower);
vResult = _mm_add_ps(vResult,vConstants);
// V^7
vPower = _mm_mul_ps(vPower,V2);
vConstants = _mm_load_ps1(&g_XMSinCoefficients0.f[3]);
vConstants = _mm_mul_ps(vConstants,vPower);
vResult = _mm_add_ps(vResult,vConstants);
// V^9
vPower = _mm_mul_ps(vPower,V2);
vConstants = _mm_load_ps1(&g_XMSinCoefficients1.f[0]);
vConstants = _mm_mul_ps(vConstants,vPower);
vResult = _mm_add_ps(vResult,vConstants);
// V^11
vPower = _mm_mul_ps(vPower,V2);
vConstants = _mm_load_ps1(&g_XMSinCoefficients1.f[1]);
vConstants = _mm_mul_ps(vConstants,vPower);
vResult = _mm_add_ps(vResult,vConstants);
// V^13
vPower = _mm_mul_ps(vPower,V2);
vConstants = _mm_load_ps1(&g_XMSinCoefficients1.f[2]);
vConstants = _mm_mul_ps(vConstants,vPower);
vResult = _mm_add_ps(vResult,vConstants);
// V^15
vPower = _mm_mul_ps(vPower,V2);
vConstants = _mm_load_ps1(&g_XMSinCoefficients1.f[3]);
vConstants = _mm_mul_ps(vConstants,vPower);
vResult = _mm_add_ps(vResult,vConstants);
// V^17
vPower = _mm_mul_ps(vPower,V2);
vConstants = _mm_load_ps1(&g_XMSinCoefficients2.f[0]);
vConstants = _mm_mul_ps(vConstants,vPower);
vResult = _mm_add_ps(vResult,vConstants);
// V^19
vPower = _mm_mul_ps(vPower,V2);
vConstants = _mm_load_ps1(&g_XMSinCoefficients2.f[1]);
vConstants = _mm_mul_ps(vConstants,vPower);
vResult = _mm_add_ps(vResult,vConstants);
// V^21
vPower = _mm_mul_ps(vPower,V2);
vConstants = _mm_load_ps1(&g_XMSinCoefficients2.f[2]);
vConstants = _mm_mul_ps(vConstants,vPower);
vResult = _mm_add_ps(vResult,vConstants);
// V^23
vPower = _mm_mul_ps(vPower,V2);
vConstants = _mm_load_ps1(&g_XMSinCoefficients2.f[3]);
vConstants = _mm_mul_ps(vConstants,vPower);
vResult = _mm_add_ps(vResult,vConstants);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMVECTOR XMVectorCos
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR V1, V2, V4, V6, V8, V10, V12, V14, V16, V18, V20, V22;
XMVECTOR C1, C2, C3, C4, C5, C6, C7, C8, C9, C10, C11;
XMVECTOR Result;
V1 = XMVectorModAngles(V);
// cos(V) ~= 1 - V^2 / 2! + V^4 / 4! - V^6 / 6! + V^8 / 8! - V^10 / 10! + V^12 / 12! -
// V^14 / 14! + V^16 / 16! - V^18 / 18! + V^20 / 20! - V^22 / 22! (for -PI <= V < PI)
V2 = XMVectorMultiply(V1, V1);
V4 = XMVectorMultiply(V2, V2);
V6 = XMVectorMultiply(V4, V2);
V8 = XMVectorMultiply(V4, V4);
V10 = XMVectorMultiply(V6, V4);
V12 = XMVectorMultiply(V6, V6);
V14 = XMVectorMultiply(V8, V6);
V16 = XMVectorMultiply(V8, V8);
V18 = XMVectorMultiply(V10, V8);
V20 = XMVectorMultiply(V10, V10);
V22 = XMVectorMultiply(V12, V10);
C1 = XMVectorSplatY(g_XMCosCoefficients0.v);
C2 = XMVectorSplatZ(g_XMCosCoefficients0.v);
C3 = XMVectorSplatW(g_XMCosCoefficients0.v);
C4 = XMVectorSplatX(g_XMCosCoefficients1.v);
C5 = XMVectorSplatY(g_XMCosCoefficients1.v);
C6 = XMVectorSplatZ(g_XMCosCoefficients1.v);
C7 = XMVectorSplatW(g_XMCosCoefficients1.v);
C8 = XMVectorSplatX(g_XMCosCoefficients2.v);
C9 = XMVectorSplatY(g_XMCosCoefficients2.v);
C10 = XMVectorSplatZ(g_XMCosCoefficients2.v);
C11 = XMVectorSplatW(g_XMCosCoefficients2.v);
Result = XMVectorMultiplyAdd(C1, V2, g_XMOne.v);
Result = XMVectorMultiplyAdd(C2, V4, Result);
Result = XMVectorMultiplyAdd(C3, V6, Result);
Result = XMVectorMultiplyAdd(C4, V8, Result);
Result = XMVectorMultiplyAdd(C5, V10, Result);
Result = XMVectorMultiplyAdd(C6, V12, Result);
Result = XMVectorMultiplyAdd(C7, V14, Result);
Result = XMVectorMultiplyAdd(C8, V16, Result);
Result = XMVectorMultiplyAdd(C9, V18, Result);
Result = XMVectorMultiplyAdd(C10, V20, Result);
Result = XMVectorMultiplyAdd(C11, V22, Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Force the value within the bounds of pi
XMVECTOR V2 = XMVectorModAngles(V);
// Each on is V to the "num" power
// V2 = V1^2
V2 = _mm_mul_ps(V2,V2);
// V^2
XMVECTOR vConstants = _mm_load_ps1(&g_XMCosCoefficients0.f[1]);
vConstants = _mm_mul_ps(vConstants,V2);
XMVECTOR vResult = _mm_add_ps(vConstants,g_XMOne);
// V^4
XMVECTOR vPower = _mm_mul_ps(V2,V2);
vConstants = _mm_load_ps1(&g_XMCosCoefficients0.f[2]);
vConstants = _mm_mul_ps(vConstants,vPower);
vResult = _mm_add_ps(vResult,vConstants);
// V^6
vPower = _mm_mul_ps(vPower,V2);
vConstants = _mm_load_ps1(&g_XMCosCoefficients0.f[3]);
vConstants = _mm_mul_ps(vConstants,vPower);
vResult = _mm_add_ps(vResult,vConstants);
// V^8
vPower = _mm_mul_ps(vPower,V2);
vConstants = _mm_load_ps1(&g_XMCosCoefficients1.f[0]);
vConstants = _mm_mul_ps(vConstants,vPower);
vResult = _mm_add_ps(vResult,vConstants);
// V^10
vPower = _mm_mul_ps(vPower,V2);
vConstants = _mm_load_ps1(&g_XMCosCoefficients1.f[1]);
vConstants = _mm_mul_ps(vConstants,vPower);
vResult = _mm_add_ps(vResult,vConstants);
// V^12
vPower = _mm_mul_ps(vPower,V2);
vConstants = _mm_load_ps1(&g_XMCosCoefficients1.f[2]);
vConstants = _mm_mul_ps(vConstants,vPower);
vResult = _mm_add_ps(vResult,vConstants);
// V^14
vPower = _mm_mul_ps(vPower,V2);
vConstants = _mm_load_ps1(&g_XMCosCoefficients1.f[3]);
vConstants = _mm_mul_ps(vConstants,vPower);
vResult = _mm_add_ps(vResult,vConstants);
// V^16
vPower = _mm_mul_ps(vPower,V2);
vConstants = _mm_load_ps1(&g_XMCosCoefficients2.f[0]);
vConstants = _mm_mul_ps(vConstants,vPower);
vResult = _mm_add_ps(vResult,vConstants);
// V^18
vPower = _mm_mul_ps(vPower,V2);
vConstants = _mm_load_ps1(&g_XMCosCoefficients2.f[1]);
vConstants = _mm_mul_ps(vConstants,vPower);
vResult = _mm_add_ps(vResult,vConstants);
// V^20
vPower = _mm_mul_ps(vPower,V2);
vConstants = _mm_load_ps1(&g_XMCosCoefficients2.f[2]);
vConstants = _mm_mul_ps(vConstants,vPower);
vResult = _mm_add_ps(vResult,vConstants);
// V^22
vPower = _mm_mul_ps(vPower,V2);
vConstants = _mm_load_ps1(&g_XMCosCoefficients2.f[3]);
vConstants = _mm_mul_ps(vConstants,vPower);
vResult = _mm_add_ps(vResult,vConstants);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE VOID XMVectorSinCos
(
XMVECTOR* pSin,
XMVECTOR* pCos,
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR V1, V2, V3, V4, V5, V6, V7, V8, V9, V10, V11, V12, V13;
XMVECTOR V14, V15, V16, V17, V18, V19, V20, V21, V22, V23;
XMVECTOR S1, S2, S3, S4, S5, S6, S7, S8, S9, S10, S11;
XMVECTOR C1, C2, C3, C4, C5, C6, C7, C8, C9, C10, C11;
XMVECTOR Sin, Cos;
XMASSERT(pSin);
XMASSERT(pCos);
V1 = XMVectorModAngles(V);
// sin(V) ~= V - V^3 / 3! + V^5 / 5! - V^7 / 7! + V^9 / 9! - V^11 / 11! + V^13 / 13! -
// V^15 / 15! + V^17 / 17! - V^19 / 19! + V^21 / 21! - V^23 / 23! (for -PI <= V < PI)
// cos(V) ~= 1 - V^2 / 2! + V^4 / 4! - V^6 / 6! + V^8 / 8! - V^10 / 10! + V^12 / 12! -
// V^14 / 14! + V^16 / 16! - V^18 / 18! + V^20 / 20! - V^22 / 22! (for -PI <= V < PI)
V2 = XMVectorMultiply(V1, V1);
V3 = XMVectorMultiply(V2, V1);
V4 = XMVectorMultiply(V2, V2);
V5 = XMVectorMultiply(V3, V2);
V6 = XMVectorMultiply(V3, V3);
V7 = XMVectorMultiply(V4, V3);
V8 = XMVectorMultiply(V4, V4);
V9 = XMVectorMultiply(V5, V4);
V10 = XMVectorMultiply(V5, V5);
V11 = XMVectorMultiply(V6, V5);
V12 = XMVectorMultiply(V6, V6);
V13 = XMVectorMultiply(V7, V6);
V14 = XMVectorMultiply(V7, V7);
V15 = XMVectorMultiply(V8, V7);
V16 = XMVectorMultiply(V8, V8);
V17 = XMVectorMultiply(V9, V8);
V18 = XMVectorMultiply(V9, V9);
V19 = XMVectorMultiply(V10, V9);
V20 = XMVectorMultiply(V10, V10);
V21 = XMVectorMultiply(V11, V10);
V22 = XMVectorMultiply(V11, V11);
V23 = XMVectorMultiply(V12, V11);
S1 = XMVectorSplatY(g_XMSinCoefficients0.v);
S2 = XMVectorSplatZ(g_XMSinCoefficients0.v);
S3 = XMVectorSplatW(g_XMSinCoefficients0.v);
S4 = XMVectorSplatX(g_XMSinCoefficients1.v);
S5 = XMVectorSplatY(g_XMSinCoefficients1.v);
S6 = XMVectorSplatZ(g_XMSinCoefficients1.v);
S7 = XMVectorSplatW(g_XMSinCoefficients1.v);
S8 = XMVectorSplatX(g_XMSinCoefficients2.v);
S9 = XMVectorSplatY(g_XMSinCoefficients2.v);
S10 = XMVectorSplatZ(g_XMSinCoefficients2.v);
S11 = XMVectorSplatW(g_XMSinCoefficients2.v);
C1 = XMVectorSplatY(g_XMCosCoefficients0.v);
C2 = XMVectorSplatZ(g_XMCosCoefficients0.v);
C3 = XMVectorSplatW(g_XMCosCoefficients0.v);
C4 = XMVectorSplatX(g_XMCosCoefficients1.v);
C5 = XMVectorSplatY(g_XMCosCoefficients1.v);
C6 = XMVectorSplatZ(g_XMCosCoefficients1.v);
C7 = XMVectorSplatW(g_XMCosCoefficients1.v);
C8 = XMVectorSplatX(g_XMCosCoefficients2.v);
C9 = XMVectorSplatY(g_XMCosCoefficients2.v);
C10 = XMVectorSplatZ(g_XMCosCoefficients2.v);
C11 = XMVectorSplatW(g_XMCosCoefficients2.v);
Sin = XMVectorMultiplyAdd(S1, V3, V1);
Sin = XMVectorMultiplyAdd(S2, V5, Sin);
Sin = XMVectorMultiplyAdd(S3, V7, Sin);
Sin = XMVectorMultiplyAdd(S4, V9, Sin);
Sin = XMVectorMultiplyAdd(S5, V11, Sin);
Sin = XMVectorMultiplyAdd(S6, V13, Sin);
Sin = XMVectorMultiplyAdd(S7, V15, Sin);
Sin = XMVectorMultiplyAdd(S8, V17, Sin);
Sin = XMVectorMultiplyAdd(S9, V19, Sin);
Sin = XMVectorMultiplyAdd(S10, V21, Sin);
Sin = XMVectorMultiplyAdd(S11, V23, Sin);
Cos = XMVectorMultiplyAdd(C1, V2, g_XMOne.v);
Cos = XMVectorMultiplyAdd(C2, V4, Cos);
Cos = XMVectorMultiplyAdd(C3, V6, Cos);
Cos = XMVectorMultiplyAdd(C4, V8, Cos);
Cos = XMVectorMultiplyAdd(C5, V10, Cos);
Cos = XMVectorMultiplyAdd(C6, V12, Cos);
Cos = XMVectorMultiplyAdd(C7, V14, Cos);
Cos = XMVectorMultiplyAdd(C8, V16, Cos);
Cos = XMVectorMultiplyAdd(C9, V18, Cos);
Cos = XMVectorMultiplyAdd(C10, V20, Cos);
Cos = XMVectorMultiplyAdd(C11, V22, Cos);
*pSin = Sin;
*pCos = Cos;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT(pSin);
XMASSERT(pCos);
XMVECTOR V1, V2, V3, V4, V5, V6, V7, V8, V9, V10, V11, V12, V13;
XMVECTOR V14, V15, V16, V17, V18, V19, V20, V21, V22, V23;
XMVECTOR S1, S2, S3, S4, S5, S6, S7, S8, S9, S10, S11;
XMVECTOR C1, C2, C3, C4, C5, C6, C7, C8, C9, C10, C11;
XMVECTOR Sin, Cos;
V1 = XMVectorModAngles(V);
// sin(V) ~= V - V^3 / 3! + V^5 / 5! - V^7 / 7! + V^9 / 9! - V^11 / 11! + V^13 / 13! -
// V^15 / 15! + V^17 / 17! - V^19 / 19! + V^21 / 21! - V^23 / 23! (for -PI <= V < PI)
// cos(V) ~= 1 - V^2 / 2! + V^4 / 4! - V^6 / 6! + V^8 / 8! - V^10 / 10! + V^12 / 12! -
// V^14 / 14! + V^16 / 16! - V^18 / 18! + V^20 / 20! - V^22 / 22! (for -PI <= V < PI)
V2 = XMVectorMultiply(V1, V1);
V3 = XMVectorMultiply(V2, V1);
V4 = XMVectorMultiply(V2, V2);
V5 = XMVectorMultiply(V3, V2);
V6 = XMVectorMultiply(V3, V3);
V7 = XMVectorMultiply(V4, V3);
V8 = XMVectorMultiply(V4, V4);
V9 = XMVectorMultiply(V5, V4);
V10 = XMVectorMultiply(V5, V5);
V11 = XMVectorMultiply(V6, V5);
V12 = XMVectorMultiply(V6, V6);
V13 = XMVectorMultiply(V7, V6);
V14 = XMVectorMultiply(V7, V7);
V15 = XMVectorMultiply(V8, V7);
V16 = XMVectorMultiply(V8, V8);
V17 = XMVectorMultiply(V9, V8);
V18 = XMVectorMultiply(V9, V9);
V19 = XMVectorMultiply(V10, V9);
V20 = XMVectorMultiply(V10, V10);
V21 = XMVectorMultiply(V11, V10);
V22 = XMVectorMultiply(V11, V11);
V23 = XMVectorMultiply(V12, V11);
S1 = _mm_load_ps1(&g_XMSinCoefficients0.f[1]);
S2 = _mm_load_ps1(&g_XMSinCoefficients0.f[2]);
S3 = _mm_load_ps1(&g_XMSinCoefficients0.f[3]);
S4 = _mm_load_ps1(&g_XMSinCoefficients1.f[0]);
S5 = _mm_load_ps1(&g_XMSinCoefficients1.f[1]);
S6 = _mm_load_ps1(&g_XMSinCoefficients1.f[2]);
S7 = _mm_load_ps1(&g_XMSinCoefficients1.f[3]);
S8 = _mm_load_ps1(&g_XMSinCoefficients2.f[0]);
S9 = _mm_load_ps1(&g_XMSinCoefficients2.f[1]);
S10 = _mm_load_ps1(&g_XMSinCoefficients2.f[2]);
S11 = _mm_load_ps1(&g_XMSinCoefficients2.f[3]);
C1 = _mm_load_ps1(&g_XMCosCoefficients0.f[1]);
C2 = _mm_load_ps1(&g_XMCosCoefficients0.f[2]);
C3 = _mm_load_ps1(&g_XMCosCoefficients0.f[3]);
C4 = _mm_load_ps1(&g_XMCosCoefficients1.f[0]);
C5 = _mm_load_ps1(&g_XMCosCoefficients1.f[1]);
C6 = _mm_load_ps1(&g_XMCosCoefficients1.f[2]);
C7 = _mm_load_ps1(&g_XMCosCoefficients1.f[3]);
C8 = _mm_load_ps1(&g_XMCosCoefficients2.f[0]);
C9 = _mm_load_ps1(&g_XMCosCoefficients2.f[1]);
C10 = _mm_load_ps1(&g_XMCosCoefficients2.f[2]);
C11 = _mm_load_ps1(&g_XMCosCoefficients2.f[3]);
S1 = _mm_mul_ps(S1,V3);
Sin = _mm_add_ps(S1,V1);
Sin = XMVectorMultiplyAdd(S2, V5, Sin);
Sin = XMVectorMultiplyAdd(S3, V7, Sin);
Sin = XMVectorMultiplyAdd(S4, V9, Sin);
Sin = XMVectorMultiplyAdd(S5, V11, Sin);
Sin = XMVectorMultiplyAdd(S6, V13, Sin);
Sin = XMVectorMultiplyAdd(S7, V15, Sin);
Sin = XMVectorMultiplyAdd(S8, V17, Sin);
Sin = XMVectorMultiplyAdd(S9, V19, Sin);
Sin = XMVectorMultiplyAdd(S10, V21, Sin);
Sin = XMVectorMultiplyAdd(S11, V23, Sin);
Cos = _mm_mul_ps(C1,V2);
Cos = _mm_add_ps(Cos,g_XMOne);
Cos = XMVectorMultiplyAdd(C2, V4, Cos);
Cos = XMVectorMultiplyAdd(C3, V6, Cos);
Cos = XMVectorMultiplyAdd(C4, V8, Cos);
Cos = XMVectorMultiplyAdd(C5, V10, Cos);
Cos = XMVectorMultiplyAdd(C6, V12, Cos);
Cos = XMVectorMultiplyAdd(C7, V14, Cos);
Cos = XMVectorMultiplyAdd(C8, V16, Cos);
Cos = XMVectorMultiplyAdd(C9, V18, Cos);
Cos = XMVectorMultiplyAdd(C10, V20, Cos);
Cos = XMVectorMultiplyAdd(C11, V22, Cos);
*pSin = Sin;
*pCos = Cos;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMVECTOR XMVectorTan
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
// Cody and Waite algorithm to compute tangent.
XMVECTOR VA, VB, VC, VC2;
XMVECTOR T0, T1, T2, T3, T4, T5, T6, T7;
XMVECTOR C0, C1, TwoDivPi, Epsilon;
XMVECTOR N, D;
XMVECTOR R0, R1;
XMVECTOR VIsZero, VCNearZero, VBIsEven;
XMVECTOR Zero;
XMVECTOR Result;
UINT i;
static CONST XMVECTOR TanCoefficients0 = {1.0f, -4.667168334e-1f, 2.566383229e-2f, -3.118153191e-4f};
static CONST XMVECTOR TanCoefficients1 = {4.981943399e-7f, -1.333835001e-1f, 3.424887824e-3f, -1.786170734e-5f};
static CONST XMVECTOR TanConstants = {1.570796371f, 6.077100628e-11f, 0.000244140625f, 2.0f / XM_PI};
static CONST XMVECTORU32 Mask = {0x1, 0x1, 0x1, 0x1};
TwoDivPi = XMVectorSplatW(TanConstants);
Zero = XMVectorZero();
C0 = XMVectorSplatX(TanConstants);
C1 = XMVectorSplatY(TanConstants);
Epsilon = XMVectorSplatZ(TanConstants);
VA = XMVectorMultiply(V, TwoDivPi);
VA = XMVectorRound(VA);
VC = XMVectorNegativeMultiplySubtract(VA, C0, V);
VB = XMVectorAbs(VA);
VC = XMVectorNegativeMultiplySubtract(VA, C1, VC);
for (i = 0; i < 4; i++)
{
VB.u[i] = (UINT)VB.v[i];
}
VC2 = XMVectorMultiply(VC, VC);
T7 = XMVectorSplatW(TanCoefficients1);
T6 = XMVectorSplatZ(TanCoefficients1);
T4 = XMVectorSplatX(TanCoefficients1);
T3 = XMVectorSplatW(TanCoefficients0);
T5 = XMVectorSplatY(TanCoefficients1);
T2 = XMVectorSplatZ(TanCoefficients0);
T1 = XMVectorSplatY(TanCoefficients0);
T0 = XMVectorSplatX(TanCoefficients0);
VBIsEven = XMVectorAndInt(VB, Mask.v);
VBIsEven = XMVectorEqualInt(VBIsEven, Zero);
N = XMVectorMultiplyAdd(VC2, T7, T6);
D = XMVectorMultiplyAdd(VC2, T4, T3);
N = XMVectorMultiplyAdd(VC2, N, T5);
D = XMVectorMultiplyAdd(VC2, D, T2);
N = XMVectorMultiply(VC2, N);
D = XMVectorMultiplyAdd(VC2, D, T1);
N = XMVectorMultiplyAdd(VC, N, VC);
VCNearZero = XMVectorInBounds(VC, Epsilon);
D = XMVectorMultiplyAdd(VC2, D, T0);
N = XMVectorSelect(N, VC, VCNearZero);
D = XMVectorSelect(D, g_XMOne.v, VCNearZero);
R0 = XMVectorNegate(N);
R1 = XMVectorReciprocal(D);
R0 = XMVectorReciprocal(R0);
R1 = XMVectorMultiply(N, R1);
R0 = XMVectorMultiply(D, R0);
VIsZero = XMVectorEqual(V, Zero);
Result = XMVectorSelect(R0, R1, VBIsEven);
Result = XMVectorSelect(Result, Zero, VIsZero);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Cody and Waite algorithm to compute tangent.
XMVECTOR VA, VB, VC, VC2;
XMVECTOR T0, T1, T2, T3, T4, T5, T6, T7;
XMVECTOR C0, C1, TwoDivPi, Epsilon;
XMVECTOR N, D;
XMVECTOR R0, R1;
XMVECTOR VIsZero, VCNearZero, VBIsEven;
XMVECTOR Zero;
XMVECTOR Result;
static CONST XMVECTORF32 TanCoefficients0 = {1.0f, -4.667168334e-1f, 2.566383229e-2f, -3.118153191e-4f};
static CONST XMVECTORF32 TanCoefficients1 = {4.981943399e-7f, -1.333835001e-1f, 3.424887824e-3f, -1.786170734e-5f};
static CONST XMVECTORF32 TanConstants = {1.570796371f, 6.077100628e-11f, 0.000244140625f, 2.0f / XM_PI};
static CONST XMVECTORI32 Mask = {0x1, 0x1, 0x1, 0x1};
TwoDivPi = XMVectorSplatW(TanConstants);
Zero = XMVectorZero();
C0 = XMVectorSplatX(TanConstants);
C1 = XMVectorSplatY(TanConstants);
Epsilon = XMVectorSplatZ(TanConstants);
VA = XMVectorMultiply(V, TwoDivPi);
VA = XMVectorRound(VA);
VC = XMVectorNegativeMultiplySubtract(VA, C0, V);
VB = XMVectorAbs(VA);
VC = XMVectorNegativeMultiplySubtract(VA, C1, VC);
reinterpret_cast<__m128i *>(&VB)[0] = _mm_cvttps_epi32(VB);
VC2 = XMVectorMultiply(VC, VC);
T7 = XMVectorSplatW(TanCoefficients1);
T6 = XMVectorSplatZ(TanCoefficients1);
T4 = XMVectorSplatX(TanCoefficients1);
T3 = XMVectorSplatW(TanCoefficients0);
T5 = XMVectorSplatY(TanCoefficients1);
T2 = XMVectorSplatZ(TanCoefficients0);
T1 = XMVectorSplatY(TanCoefficients0);
T0 = XMVectorSplatX(TanCoefficients0);
VBIsEven = XMVectorAndInt(VB,Mask);
VBIsEven = XMVectorEqualInt(VBIsEven, Zero);
N = XMVectorMultiplyAdd(VC2, T7, T6);
D = XMVectorMultiplyAdd(VC2, T4, T3);
N = XMVectorMultiplyAdd(VC2, N, T5);
D = XMVectorMultiplyAdd(VC2, D, T2);
N = XMVectorMultiply(VC2, N);
D = XMVectorMultiplyAdd(VC2, D, T1);
N = XMVectorMultiplyAdd(VC, N, VC);
VCNearZero = XMVectorInBounds(VC, Epsilon);
D = XMVectorMultiplyAdd(VC2, D, T0);
N = XMVectorSelect(N, VC, VCNearZero);
D = XMVectorSelect(D, g_XMOne, VCNearZero);
R0 = XMVectorNegate(N);
R1 = _mm_div_ps(N,D);
R0 = _mm_div_ps(D,R0);
VIsZero = XMVectorEqual(V, Zero);
Result = XMVectorSelect(R0, R1, VBIsEven);
Result = XMVectorSelect(Result, Zero, VIsZero);
return Result;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMVECTOR XMVectorSinH
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR V1, V2;
XMVECTOR E1, E2;
XMVECTOR Result;
static CONST XMVECTORF32 Scale = {1.442695040888963f, 1.442695040888963f, 1.442695040888963f, 1.442695040888963f}; // 1.0f / ln(2.0f)
V1 = XMVectorMultiplyAdd(V, Scale.v, g_XMNegativeOne.v);
V2 = XMVectorNegativeMultiplySubtract(V, Scale.v, g_XMNegativeOne.v);
E1 = XMVectorExp(V1);
E2 = XMVectorExp(V2);
Result = XMVectorSubtract(E1, E2);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR V1, V2;
XMVECTOR E1, E2;
XMVECTOR Result;
static CONST XMVECTORF32 Scale = {1.442695040888963f, 1.442695040888963f, 1.442695040888963f, 1.442695040888963f}; // 1.0f / ln(2.0f)
V1 = _mm_mul_ps(V, Scale);
V1 = _mm_add_ps(V1,g_XMNegativeOne);
V2 = _mm_mul_ps(V, Scale);
V2 = _mm_sub_ps(g_XMNegativeOne,V2);
E1 = XMVectorExp(V1);
E2 = XMVectorExp(V2);
Result = _mm_sub_ps(E1, E2);
return Result;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMVECTOR XMVectorCosH
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR V1, V2;
XMVECTOR E1, E2;
XMVECTOR Result;
static CONST XMVECTOR Scale = {1.442695040888963f, 1.442695040888963f, 1.442695040888963f, 1.442695040888963f}; // 1.0f / ln(2.0f)
V1 = XMVectorMultiplyAdd(V, Scale, g_XMNegativeOne.v);
V2 = XMVectorNegativeMultiplySubtract(V, Scale, g_XMNegativeOne.v);
E1 = XMVectorExp(V1);
E2 = XMVectorExp(V2);
Result = XMVectorAdd(E1, E2);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR V1, V2;
XMVECTOR E1, E2;
XMVECTOR Result;
static CONST XMVECTORF32 Scale = {1.442695040888963f, 1.442695040888963f, 1.442695040888963f, 1.442695040888963f}; // 1.0f / ln(2.0f)
V1 = _mm_mul_ps(V,Scale);
V1 = _mm_add_ps(V1,g_XMNegativeOne);
V2 = _mm_mul_ps(V, Scale);
V2 = _mm_sub_ps(g_XMNegativeOne,V2);
E1 = XMVectorExp(V1);
E2 = XMVectorExp(V2);
Result = _mm_add_ps(E1, E2);
return Result;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMVECTOR XMVectorTanH
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR E;
XMVECTOR Result;
static CONST XMVECTORF32 Scale = {2.8853900817779268f, 2.8853900817779268f, 2.8853900817779268f, 2.8853900817779268f}; // 2.0f / ln(2.0f)
E = XMVectorMultiply(V, Scale.v);
E = XMVectorExp(E);
E = XMVectorMultiplyAdd(E, g_XMOneHalf.v, g_XMOneHalf.v);
E = XMVectorReciprocal(E);
Result = XMVectorSubtract(g_XMOne.v, E);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
static CONST XMVECTORF32 Scale = {2.8853900817779268f, 2.8853900817779268f, 2.8853900817779268f, 2.8853900817779268f}; // 2.0f / ln(2.0f)
XMVECTOR E = _mm_mul_ps(V, Scale);
E = XMVectorExp(E);
E = _mm_mul_ps(E,g_XMOneHalf);
E = _mm_add_ps(E,g_XMOneHalf);
E = XMVectorReciprocal(E);
E = _mm_sub_ps(g_XMOne, E);
return E;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMVECTOR XMVectorASin
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR V2, V3, AbsV;
XMVECTOR C0, C1, C2, C3, C4, C5, C6, C7, C8, C9, C10, C11;
XMVECTOR R0, R1, R2, R3, R4;
XMVECTOR OneMinusAbsV;
XMVECTOR Rsq;
XMVECTOR Result;
static CONST XMVECTOR OnePlusEpsilon = {1.00000011921f, 1.00000011921f, 1.00000011921f, 1.00000011921f};
// asin(V) = V * (C0 + C1 * V + C2 * V^2 + C3 * V^3 + C4 * V^4 + C5 * V^5) + (1 - V) * rsq(1 - V) *
// V * (C6 + C7 * V + C8 * V^2 + C9 * V^3 + C10 * V^4 + C11 * V^5)
AbsV = XMVectorAbs(V);
V2 = XMVectorMultiply(V, V);
V3 = XMVectorMultiply(V2, AbsV);
R4 = XMVectorNegativeMultiplySubtract(AbsV, V, V);
OneMinusAbsV = XMVectorSubtract(OnePlusEpsilon, AbsV);
Rsq = XMVectorReciprocalSqrt(OneMinusAbsV);
C0 = XMVectorSplatX(g_XMASinCoefficients0.v);
C1 = XMVectorSplatY(g_XMASinCoefficients0.v);
C2 = XMVectorSplatZ(g_XMASinCoefficients0.v);
C3 = XMVectorSplatW(g_XMASinCoefficients0.v);
C4 = XMVectorSplatX(g_XMASinCoefficients1.v);
C5 = XMVectorSplatY(g_XMASinCoefficients1.v);
C6 = XMVectorSplatZ(g_XMASinCoefficients1.v);
C7 = XMVectorSplatW(g_XMASinCoefficients1.v);
C8 = XMVectorSplatX(g_XMASinCoefficients2.v);
C9 = XMVectorSplatY(g_XMASinCoefficients2.v);
C10 = XMVectorSplatZ(g_XMASinCoefficients2.v);
C11 = XMVectorSplatW(g_XMASinCoefficients2.v);
R0 = XMVectorMultiplyAdd(C3, AbsV, C7);
R1 = XMVectorMultiplyAdd(C1, AbsV, C5);
R2 = XMVectorMultiplyAdd(C2, AbsV, C6);
R3 = XMVectorMultiplyAdd(C0, AbsV, C4);
R0 = XMVectorMultiplyAdd(R0, AbsV, C11);
R1 = XMVectorMultiplyAdd(R1, AbsV, C9);
R2 = XMVectorMultiplyAdd(R2, AbsV, C10);
R3 = XMVectorMultiplyAdd(R3, AbsV, C8);
R0 = XMVectorMultiplyAdd(R2, V3, R0);
R1 = XMVectorMultiplyAdd(R3, V3, R1);
R0 = XMVectorMultiply(V, R0);
R1 = XMVectorMultiply(R4, R1);
Result = XMVectorMultiplyAdd(R1, Rsq, R0);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
static CONST XMVECTORF32 OnePlusEpsilon = {1.00000011921f, 1.00000011921f, 1.00000011921f, 1.00000011921f};
// asin(V) = V * (C0 + C1 * V + C2 * V^2 + C3 * V^3 + C4 * V^4 + C5 * V^5) + (1 - V) * rsq(1 - V) *
// V * (C6 + C7 * V + C8 * V^2 + C9 * V^3 + C10 * V^4 + C11 * V^5)
// Get abs(V)
XMVECTOR vAbsV = _mm_setzero_ps();
vAbsV = _mm_sub_ps(vAbsV,V);
vAbsV = _mm_max_ps(vAbsV,V);
XMVECTOR R0 = vAbsV;
XMVECTOR vConstants = _mm_load_ps1(&g_XMASinCoefficients0.f[3]);
R0 = _mm_mul_ps(R0,vConstants);
vConstants = _mm_load_ps1(&g_XMASinCoefficients1.f[3]);
R0 = _mm_add_ps(R0,vConstants);
XMVECTOR R1 = vAbsV;
vConstants = _mm_load_ps1(&g_XMASinCoefficients0.f[1]);
R1 = _mm_mul_ps(R1,vConstants);
vConstants = _mm_load_ps1(&g_XMASinCoefficients1.f[1]);
R1 = _mm_add_ps(R1, vConstants);
XMVECTOR R2 = vAbsV;
vConstants = _mm_load_ps1(&g_XMASinCoefficients0.f[2]);
R2 = _mm_mul_ps(R2,vConstants);
vConstants = _mm_load_ps1(&g_XMASinCoefficients1.f[2]);
R2 = _mm_add_ps(R2, vConstants);
XMVECTOR R3 = vAbsV;
vConstants = _mm_load_ps1(&g_XMASinCoefficients0.f[0]);
R3 = _mm_mul_ps(R3,vConstants);
vConstants = _mm_load_ps1(&g_XMASinCoefficients1.f[0]);
R3 = _mm_add_ps(R3, vConstants);
vConstants = _mm_load_ps1(&g_XMASinCoefficients2.f[3]);
R0 = _mm_mul_ps(R0,vAbsV);
R0 = _mm_add_ps(R0,vConstants);
vConstants = _mm_load_ps1(&g_XMASinCoefficients2.f[1]);
R1 = _mm_mul_ps(R1,vAbsV);
R1 = _mm_add_ps(R1,vConstants);
vConstants = _mm_load_ps1(&g_XMASinCoefficients2.f[2]);
R2 = _mm_mul_ps(R2,vAbsV);
R2 = _mm_add_ps(R2,vConstants);
vConstants = _mm_load_ps1(&g_XMASinCoefficients2.f[0]);
R3 = _mm_mul_ps(R3,vAbsV);
R3 = _mm_add_ps(R3,vConstants);
// V3 = V^3
vConstants = _mm_mul_ps(V,V);
vConstants = _mm_mul_ps(vConstants, vAbsV);
// Mul by V^3
R2 = _mm_mul_ps(R2,vConstants);
R3 = _mm_mul_ps(R3,vConstants);
// Merge the results
R0 = _mm_add_ps(R0,R2);
R1 = _mm_add_ps(R1,R3);
R0 = _mm_mul_ps(R0,V);
// vConstants = V-(V^2 retaining sign)
vConstants = _mm_mul_ps(vAbsV, V);
vConstants = _mm_sub_ps(V,vConstants);
R1 = _mm_mul_ps(R1,vConstants);
vConstants = _mm_sub_ps(OnePlusEpsilon,vAbsV);
// Do NOT use rsqrt/mul. This needs the precision
vConstants = _mm_sqrt_ps(vConstants);
R1 = _mm_div_ps(R1,vConstants);
R0 = _mm_add_ps(R0,R1);
return R0;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMVECTOR XMVectorACos
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR V2, V3, AbsV;
XMVECTOR C0, C1, C2, C3, C4, C5, C6, C7, C8, C9, C10, C11;
XMVECTOR R0, R1, R2, R3, R4;
XMVECTOR OneMinusAbsV;
XMVECTOR Rsq;
XMVECTOR Result;
static CONST XMVECTOR OnePlusEpsilon = {1.00000011921f, 1.00000011921f, 1.00000011921f, 1.00000011921f};
// acos(V) = PI / 2 - asin(V)
AbsV = XMVectorAbs(V);
V2 = XMVectorMultiply(V, V);
V3 = XMVectorMultiply(V2, AbsV);
R4 = XMVectorNegativeMultiplySubtract(AbsV, V, V);
OneMinusAbsV = XMVectorSubtract(OnePlusEpsilon, AbsV);
Rsq = XMVectorReciprocalSqrt(OneMinusAbsV);
C0 = XMVectorSplatX(g_XMASinCoefficients0.v);
C1 = XMVectorSplatY(g_XMASinCoefficients0.v);
C2 = XMVectorSplatZ(g_XMASinCoefficients0.v);
C3 = XMVectorSplatW(g_XMASinCoefficients0.v);
C4 = XMVectorSplatX(g_XMASinCoefficients1.v);
C5 = XMVectorSplatY(g_XMASinCoefficients1.v);
C6 = XMVectorSplatZ(g_XMASinCoefficients1.v);
C7 = XMVectorSplatW(g_XMASinCoefficients1.v);
C8 = XMVectorSplatX(g_XMASinCoefficients2.v);
C9 = XMVectorSplatY(g_XMASinCoefficients2.v);
C10 = XMVectorSplatZ(g_XMASinCoefficients2.v);
C11 = XMVectorSplatW(g_XMASinCoefficients2.v);
R0 = XMVectorMultiplyAdd(C3, AbsV, C7);
R1 = XMVectorMultiplyAdd(C1, AbsV, C5);
R2 = XMVectorMultiplyAdd(C2, AbsV, C6);
R3 = XMVectorMultiplyAdd(C0, AbsV, C4);
R0 = XMVectorMultiplyAdd(R0, AbsV, C11);
R1 = XMVectorMultiplyAdd(R1, AbsV, C9);
R2 = XMVectorMultiplyAdd(R2, AbsV, C10);
R3 = XMVectorMultiplyAdd(R3, AbsV, C8);
R0 = XMVectorMultiplyAdd(R2, V3, R0);
R1 = XMVectorMultiplyAdd(R3, V3, R1);
R0 = XMVectorMultiply(V, R0);
R1 = XMVectorMultiply(R4, R1);
Result = XMVectorMultiplyAdd(R1, Rsq, R0);
Result = XMVectorSubtract(g_XMHalfPi.v, Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
static CONST XMVECTORF32 s_OnePlusEpsilon = {1.00000011921f, 1.00000011921f, 1.00000011921f, 1.00000011921f};
// Uses only 6 registers for good code on x86 targets
// acos(V) = PI / 2 - asin(V)
// Get abs(V)
XMVECTOR vAbsV = _mm_setzero_ps();
vAbsV = _mm_sub_ps(vAbsV,V);
vAbsV = _mm_max_ps(vAbsV,V);
// Perform the series in precision groups to
// retain precision across 20 bits. (3 bits of imprecision due to operations)
XMVECTOR R0 = vAbsV;
XMVECTOR vConstants = _mm_load_ps1(&g_XMASinCoefficients0.f[3]);
R0 = _mm_mul_ps(R0,vConstants);
vConstants = _mm_load_ps1(&g_XMASinCoefficients1.f[3]);
R0 = _mm_add_ps(R0,vConstants);
R0 = _mm_mul_ps(R0,vAbsV);
vConstants = _mm_load_ps1(&g_XMASinCoefficients2.f[3]);
R0 = _mm_add_ps(R0,vConstants);
XMVECTOR R1 = vAbsV;
vConstants = _mm_load_ps1(&g_XMASinCoefficients0.f[1]);
R1 = _mm_mul_ps(R1,vConstants);
vConstants = _mm_load_ps1(&g_XMASinCoefficients1.f[1]);
R1 = _mm_add_ps(R1,vConstants);
R1 = _mm_mul_ps(R1, vAbsV);
vConstants = _mm_load_ps1(&g_XMASinCoefficients2.f[1]);
R1 = _mm_add_ps(R1,vConstants);
XMVECTOR R2 = vAbsV;
vConstants = _mm_load_ps1(&g_XMASinCoefficients0.f[2]);
R2 = _mm_mul_ps(R2,vConstants);
vConstants = _mm_load_ps1(&g_XMASinCoefficients1.f[2]);
R2 = _mm_add_ps(R2,vConstants);
R2 = _mm_mul_ps(R2, vAbsV);
vConstants = _mm_load_ps1(&g_XMASinCoefficients2.f[2]);
R2 = _mm_add_ps(R2,vConstants);
XMVECTOR R3 = vAbsV;
vConstants = _mm_load_ps1(&g_XMASinCoefficients0.f[0]);
R3 = _mm_mul_ps(R3,vConstants);
vConstants = _mm_load_ps1(&g_XMASinCoefficients1.f[0]);
R3 = _mm_add_ps(R3,vConstants);
R3 = _mm_mul_ps(R3, vAbsV);
vConstants = _mm_load_ps1(&g_XMASinCoefficients2.f[0]);
R3 = _mm_add_ps(R3,vConstants);
// vConstants = V^3
vConstants = _mm_mul_ps(V,V);
vConstants = _mm_mul_ps(vConstants,vAbsV);
R2 = _mm_mul_ps(R2,vConstants);
R3 = _mm_mul_ps(R3,vConstants);
// Add the pair of values together here to retain
// as much precision as possible
R0 = _mm_add_ps(R0,R2);
R1 = _mm_add_ps(R1,R3);
R0 = _mm_mul_ps(R0,V);
// vConstants = V-(V*abs(V))
vConstants = _mm_mul_ps(V,vAbsV);
vConstants = _mm_sub_ps(V,vConstants);
R1 = _mm_mul_ps(R1,vConstants);
// Episilon exists to allow 1.0 as an answer
vConstants = _mm_sub_ps(s_OnePlusEpsilon, vAbsV);
// Use sqrt instead of rsqrt for precision
vConstants = _mm_sqrt_ps(vConstants);
R1 = _mm_div_ps(R1,vConstants);
R1 = _mm_add_ps(R1,R0);
vConstants = _mm_sub_ps(g_XMHalfPi,R1);
return vConstants;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMVECTOR XMVectorATan
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
// Cody and Waite algorithm to compute inverse tangent.
XMVECTOR N, D;
XMVECTOR VF, G, ReciprocalF, AbsF, FA, FB;
XMVECTOR Sqrt3, Sqrt3MinusOne, TwoMinusSqrt3;
XMVECTOR HalfPi, OneThirdPi, OneSixthPi, Epsilon, MinV, MaxV;
XMVECTOR Zero;
XMVECTOR NegativeHalfPi;
XMVECTOR Angle1, Angle2;
XMVECTOR F_GT_One, F_GT_TwoMinusSqrt3, AbsF_LT_Epsilon, V_LT_Zero, V_GT_MaxV, V_LT_MinV;
XMVECTOR NegativeResult, Result;
XMVECTOR P0, P1, P2, P3, Q0, Q1, Q2, Q3;
static CONST XMVECTOR ATanConstants0 = {-1.3688768894e+1f, -2.0505855195e+1f, -8.4946240351f, -8.3758299368e-1f};
static CONST XMVECTOR ATanConstants1 = {4.1066306682e+1f, 8.6157349597e+1f, 5.9578436142e+1f, 1.5024001160e+1f};
static CONST XMVECTOR ATanConstants2 = {1.732050808f, 7.320508076e-1f, 2.679491924e-1f, 0.000244140625f}; // <sqrt(3), sqrt(3) - 1, 2 - sqrt(3), Epsilon>
static CONST XMVECTOR ATanConstants3 = {XM_PIDIV2, XM_PI / 3.0f, XM_PI / 6.0f, 8.507059173e+37f}; // <Pi / 2, Pi / 3, Pi / 6, MaxV>
Zero = XMVectorZero();
P0 = XMVectorSplatX(ATanConstants0);
P1 = XMVectorSplatY(ATanConstants0);
P2 = XMVectorSplatZ(ATanConstants0);
P3 = XMVectorSplatW(ATanConstants0);
Q0 = XMVectorSplatX(ATanConstants1);
Q1 = XMVectorSplatY(ATanConstants1);
Q2 = XMVectorSplatZ(ATanConstants1);
Q3 = XMVectorSplatW(ATanConstants1);
Sqrt3 = XMVectorSplatX(ATanConstants2);
Sqrt3MinusOne = XMVectorSplatY(ATanConstants2);
TwoMinusSqrt3 = XMVectorSplatZ(ATanConstants2);
Epsilon = XMVectorSplatW(ATanConstants2);
HalfPi = XMVectorSplatX(ATanConstants3);
OneThirdPi = XMVectorSplatY(ATanConstants3);
OneSixthPi = XMVectorSplatZ(ATanConstants3);
MaxV = XMVectorSplatW(ATanConstants3);
VF = XMVectorAbs(V);
ReciprocalF = XMVectorReciprocal(VF);
F_GT_One = XMVectorGreater(VF, g_XMOne.v);
VF = XMVectorSelect(VF, ReciprocalF, F_GT_One);
Angle1 = XMVectorSelect(Zero, HalfPi, F_GT_One);
Angle2 = XMVectorSelect(OneSixthPi, OneThirdPi, F_GT_One);
F_GT_TwoMinusSqrt3 = XMVectorGreater(VF, TwoMinusSqrt3);
FA = XMVectorMultiplyAdd(Sqrt3MinusOne, VF, VF);
FA = XMVectorAdd(FA, g_XMNegativeOne.v);
FB = XMVectorAdd(VF, Sqrt3);
FB = XMVectorReciprocal(FB);
FA = XMVectorMultiply(FA, FB);
VF = XMVectorSelect(VF, FA, F_GT_TwoMinusSqrt3);
Angle1 = XMVectorSelect(Angle1, Angle2, F_GT_TwoMinusSqrt3);
AbsF = XMVectorAbs(VF);
AbsF_LT_Epsilon = XMVectorLess(AbsF, Epsilon);
G = XMVectorMultiply(VF, VF);
D = XMVectorAdd(G, Q3);
D = XMVectorMultiplyAdd(D, G, Q2);
D = XMVectorMultiplyAdd(D, G, Q1);
D = XMVectorMultiplyAdd(D, G, Q0);
D = XMVectorReciprocal(D);
N = XMVectorMultiplyAdd(P3, G, P2);
N = XMVectorMultiplyAdd(N, G, P1);
N = XMVectorMultiplyAdd(N, G, P0);
N = XMVectorMultiply(N, G);
Result = XMVectorMultiply(N, D);
Result = XMVectorMultiplyAdd(Result, VF, VF);
Result = XMVectorSelect(Result, VF, AbsF_LT_Epsilon);
NegativeResult = XMVectorNegate(Result);
Result = XMVectorSelect(Result, NegativeResult, F_GT_One);
Result = XMVectorAdd(Result, Angle1);
V_LT_Zero = XMVectorLess(V, Zero);
NegativeResult = XMVectorNegate(Result);
Result = XMVectorSelect(Result, NegativeResult, V_LT_Zero);
MinV = XMVectorNegate(MaxV);
NegativeHalfPi = XMVectorNegate(HalfPi);
V_GT_MaxV = XMVectorGreater(V, MaxV);
V_LT_MinV = XMVectorLess(V, MinV);
Result = XMVectorSelect(Result, g_XMHalfPi.v, V_GT_MaxV);
Result = XMVectorSelect(Result, NegativeHalfPi, V_LT_MinV);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
static CONST XMVECTORF32 ATanConstants0 = {-1.3688768894e+1f, -2.0505855195e+1f, -8.4946240351f, -8.3758299368e-1f};
static CONST XMVECTORF32 ATanConstants1 = {4.1066306682e+1f, 8.6157349597e+1f, 5.9578436142e+1f, 1.5024001160e+1f};
static CONST XMVECTORF32 ATanConstants2 = {1.732050808f, 7.320508076e-1f, 2.679491924e-1f, 0.000244140625f}; // <sqrt(3), sqrt(3) - 1, 2 - sqrt(3), Epsilon>
static CONST XMVECTORF32 ATanConstants3 = {XM_PIDIV2, XM_PI / 3.0f, XM_PI / 6.0f, 8.507059173e+37f}; // <Pi / 2, Pi / 3, Pi / 6, MaxV>
XMVECTOR VF = XMVectorAbs(V);
XMVECTOR F_GT_One = _mm_cmpgt_ps(VF,g_XMOne);
XMVECTOR ReciprocalF = XMVectorReciprocal(VF);
VF = XMVectorSelect(VF, ReciprocalF, F_GT_One);
XMVECTOR Zero = XMVectorZero();
XMVECTOR HalfPi = _mm_load_ps1(&ATanConstants3.f[0]);
XMVECTOR Angle1 = XMVectorSelect(Zero, HalfPi, F_GT_One);
// Pi/3
XMVECTOR vConstants = _mm_load_ps1(&ATanConstants3.f[1]);
// Pi/6
XMVECTOR Angle2 = _mm_load_ps1(&ATanConstants3.f[2]);
Angle2 = XMVectorSelect(Angle2, vConstants, F_GT_One);
// 1-sqrt(3)
XMVECTOR FA = _mm_load_ps1(&ATanConstants2.f[1]);
FA = _mm_mul_ps(FA,VF);
FA = _mm_add_ps(FA,VF);
FA = _mm_add_ps(FA,g_XMNegativeOne);
// sqrt(3)
vConstants = _mm_load_ps1(&ATanConstants2.f[0]);
vConstants = _mm_add_ps(vConstants,VF);
FA = _mm_div_ps(FA,vConstants);
// 2-sqrt(3)
vConstants = _mm_load_ps1(&ATanConstants2.f[2]);
// >2-sqrt(3)?
vConstants = _mm_cmpgt_ps(VF,vConstants);
VF = XMVectorSelect(VF, FA, vConstants);
Angle1 = XMVectorSelect(Angle1, Angle2, vConstants);
XMVECTOR AbsF = XMVectorAbs(VF);
XMVECTOR G = _mm_mul_ps(VF,VF);
XMVECTOR D = _mm_load_ps1(&ATanConstants1.f[3]);
D = _mm_add_ps(D,G);
D = _mm_mul_ps(D,G);
vConstants = _mm_load_ps1(&ATanConstants1.f[2]);
D = _mm_add_ps(D,vConstants);
D = _mm_mul_ps(D,G);
vConstants = _mm_load_ps1(&ATanConstants1.f[1]);
D = _mm_add_ps(D,vConstants);
D = _mm_mul_ps(D,G);
vConstants = _mm_load_ps1(&ATanConstants1.f[0]);
D = _mm_add_ps(D,vConstants);
XMVECTOR N = _mm_load_ps1(&ATanConstants0.f[3]);
N = _mm_mul_ps(N,G);
vConstants = _mm_load_ps1(&ATanConstants0.f[2]);
N = _mm_add_ps(N,vConstants);
N = _mm_mul_ps(N,G);
vConstants = _mm_load_ps1(&ATanConstants0.f[1]);
N = _mm_add_ps(N,vConstants);
N = _mm_mul_ps(N,G);
vConstants = _mm_load_ps1(&ATanConstants0.f[0]);
N = _mm_add_ps(N,vConstants);
N = _mm_mul_ps(N,G);
XMVECTOR Result = _mm_div_ps(N,D);
Result = _mm_mul_ps(Result,VF);
Result = _mm_add_ps(Result,VF);
// Epsilon
vConstants = _mm_load_ps1(&ATanConstants2.f[3]);
vConstants = _mm_cmpge_ps(vConstants,AbsF);
Result = XMVectorSelect(Result,VF,vConstants);
XMVECTOR NegativeResult = _mm_mul_ps(Result,g_XMNegativeOne);
Result = XMVectorSelect(Result,NegativeResult,F_GT_One);
Result = _mm_add_ps(Result,Angle1);
Zero = _mm_cmpge_ps(Zero,V);
NegativeResult = _mm_mul_ps(Result,g_XMNegativeOne);
Result = XMVectorSelect(Result,NegativeResult,Zero);
XMVECTOR MaxV = _mm_load_ps1(&ATanConstants3.f[3]);
XMVECTOR MinV = _mm_mul_ps(MaxV,g_XMNegativeOne);
// Negate HalfPi
HalfPi = _mm_mul_ps(HalfPi,g_XMNegativeOne);
MaxV = _mm_cmple_ps(MaxV,V);
MinV = _mm_cmpge_ps(MinV,V);
Result = XMVectorSelect(Result,g_XMHalfPi,MaxV);
// HalfPi = -HalfPi
Result = XMVectorSelect(Result,HalfPi,MinV);
return Result;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMVECTOR XMVectorATan2
(
FXMVECTOR Y,
FXMVECTOR X
)
{
#if defined(_XM_NO_INTRINSICS_)
// Return the inverse tangent of Y / X in the range of -Pi to Pi with the following exceptions:
// Y == 0 and X is Negative -> Pi with the sign of Y
// Y == 0 and X is Positive -> 0 with the sign of Y
// Y != 0 and X == 0 -> Pi / 2 with the sign of Y
// X == -Infinity and Finite Y > 0 -> Pi with the sign of Y
// X == +Infinity and Finite Y > 0 -> 0 with the sign of Y
// Y == Infinity and X is Finite -> Pi / 2 with the sign of Y
// Y == Infinity and X == -Infinity -> 3Pi / 4 with the sign of Y
// Y == Infinity and X == +Infinity -> Pi / 4 with the sign of Y
// TODO: Return Y / X if the result underflows
XMVECTOR Reciprocal;
XMVECTOR V;
XMVECTOR YSign;
XMVECTOR Pi, PiOverTwo, PiOverFour, ThreePiOverFour;
XMVECTOR YEqualsZero, XEqualsZero, XIsPositive, YEqualsInfinity, XEqualsInfinity, FiniteYGreaterZero;
XMVECTOR ATanResultValid;
XMVECTOR R0, R1, R2, R3, R4, R5, R6, R7;
XMVECTOR Zero;
XMVECTOR Result;
static CONST XMVECTOR ATan2Constants = {XM_PI, XM_PIDIV2, XM_PIDIV4, XM_PI * 3.0f / 4.0f};
Zero = XMVectorZero();
ATanResultValid = XMVectorTrueInt();
Pi = XMVectorSplatX(ATan2Constants);
PiOverTwo = XMVectorSplatY(ATan2Constants);
PiOverFour = XMVectorSplatZ(ATan2Constants);
ThreePiOverFour = XMVectorSplatW(ATan2Constants);
YEqualsZero = XMVectorEqual(Y, Zero);
XEqualsZero = XMVectorEqual(X, Zero);
XIsPositive = XMVectorAndInt(X, g_XMNegativeZero.v);
XIsPositive = XMVectorEqualInt(XIsPositive, Zero);
YEqualsInfinity = XMVectorIsInfinite(Y);
XEqualsInfinity = XMVectorIsInfinite(X);
FiniteYGreaterZero = XMVectorGreater(Y, Zero);
FiniteYGreaterZero = XMVectorSelect(FiniteYGreaterZero, Zero, YEqualsInfinity);
YSign = XMVectorAndInt(Y, g_XMNegativeZero.v);
Pi = XMVectorOrInt(Pi, YSign);
PiOverTwo = XMVectorOrInt(PiOverTwo, YSign);
PiOverFour = XMVectorOrInt(PiOverFour, YSign);
ThreePiOverFour = XMVectorOrInt(ThreePiOverFour, YSign);
R1 = XMVectorSelect(Pi, YSign, XIsPositive);
R2 = XMVectorSelect(ATanResultValid, PiOverTwo, XEqualsZero);
R3 = XMVectorSelect(R2, R1, YEqualsZero);
R4 = XMVectorSelect(ThreePiOverFour, PiOverFour, XIsPositive);
R5 = XMVectorSelect(PiOverTwo, R4, XEqualsInfinity);
R6 = XMVectorSelect(R3, R5, YEqualsInfinity);
R7 = XMVectorSelect(R6, R1, FiniteYGreaterZero);
Result = XMVectorSelect(R6, R7, XEqualsInfinity);
ATanResultValid = XMVectorEqualInt(Result, ATanResultValid);
Reciprocal = XMVectorReciprocal(X);
V = XMVectorMultiply(Y, Reciprocal);
R0 = XMVectorATan(V);
Result = XMVectorSelect(Result, R0, ATanResultValid);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
static CONST XMVECTORF32 ATan2Constants = {XM_PI, XM_PIDIV2, XM_PIDIV4, XM_PI * 3.0f / 4.0f};
// Mask if Y>0 && Y!=INF
XMVECTOR FiniteYGreaterZero = _mm_cmpgt_ps(Y,g_XMZero);
XMVECTOR YEqualsInfinity = XMVectorIsInfinite(Y);
FiniteYGreaterZero = _mm_andnot_ps(YEqualsInfinity,FiniteYGreaterZero);
// Get the sign of (Y&0x80000000)
XMVECTOR YSign = _mm_and_ps(Y, g_XMNegativeZero);
// Get the sign bits of X
XMVECTOR XIsPositive = _mm_and_ps(X,g_XMNegativeZero);
// Change them to masks
XIsPositive = XMVectorEqualInt(XIsPositive,g_XMZero);
// Get Pi
XMVECTOR R1 = _mm_load_ps1(&ATan2Constants.f[0]);
// Copy the sign of Y
R1 = _mm_or_ps(R1,YSign);
R1 = XMVectorSelect(R1,YSign,XIsPositive);
// Mask for X==0
XMVECTOR vConstants = _mm_cmpeq_ps(X,g_XMZero);
// Get Pi/2 with with sign of Y
XMVECTOR PiOverTwo = _mm_load_ps1(&ATan2Constants.f[1]);
PiOverTwo = _mm_or_ps(PiOverTwo,YSign);
XMVECTOR R2 = XMVectorSelect(g_XMNegOneMask,PiOverTwo,vConstants);
// Mask for Y==0
vConstants = _mm_cmpeq_ps(Y,g_XMZero);
R2 = XMVectorSelect(R2,R1,vConstants);
// Get Pi/4 with sign of Y
XMVECTOR PiOverFour = _mm_load_ps1(&ATan2Constants.f[2]);
PiOverFour = _mm_or_ps(PiOverFour,YSign);
// Get (Pi*3)/4 with sign of Y
XMVECTOR ThreePiOverFour = _mm_load_ps1(&ATan2Constants.f[3]);
ThreePiOverFour = _mm_or_ps(ThreePiOverFour,YSign);
vConstants = XMVectorSelect(ThreePiOverFour, PiOverFour, XIsPositive);
XMVECTOR XEqualsInfinity = XMVectorIsInfinite(X);
vConstants = XMVectorSelect(PiOverTwo,vConstants,XEqualsInfinity);
XMVECTOR vResult = XMVectorSelect(R2,vConstants,YEqualsInfinity);
vConstants = XMVectorSelect(vResult,R1,FiniteYGreaterZero);
// At this point, any entry that's zero will get the result
// from XMVectorATan(), otherwise, return the failsafe value
vResult = XMVectorSelect(vResult,vConstants,XEqualsInfinity);
// Any entries not 0xFFFFFFFF, are considered precalculated
XMVECTOR ATanResultValid = XMVectorEqualInt(vResult,g_XMNegOneMask);
// Let's do the ATan2 function
vConstants = _mm_div_ps(Y,X);
vConstants = XMVectorATan(vConstants);
// Discard entries that have been declared void
vResult = XMVectorSelect(vResult,vConstants,ATanResultValid);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorSinEst
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR V2, V3, V5, V7;
XMVECTOR S1, S2, S3;
XMVECTOR Result;
// sin(V) ~= V - V^3 / 3! + V^5 / 5! - V^7 / 7! (for -PI <= V < PI)
V2 = XMVectorMultiply(V, V);
V3 = XMVectorMultiply(V2, V);
V5 = XMVectorMultiply(V3, V2);
V7 = XMVectorMultiply(V5, V2);
S1 = XMVectorSplatY(g_XMSinEstCoefficients.v);
S2 = XMVectorSplatZ(g_XMSinEstCoefficients.v);
S3 = XMVectorSplatW(g_XMSinEstCoefficients.v);
Result = XMVectorMultiplyAdd(S1, V3, V);
Result = XMVectorMultiplyAdd(S2, V5, Result);
Result = XMVectorMultiplyAdd(S3, V7, Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// sin(V) ~= V - V^3 / 3! + V^5 / 5! - V^7 / 7! (for -PI <= V < PI)
XMVECTOR V2 = _mm_mul_ps(V,V);
XMVECTOR V3 = _mm_mul_ps(V2,V);
XMVECTOR vResult = _mm_load_ps1(&g_XMSinEstCoefficients.f[1]);
vResult = _mm_mul_ps(vResult,V3);
vResult = _mm_add_ps(vResult,V);
XMVECTOR vConstants = _mm_load_ps1(&g_XMSinEstCoefficients.f[2]);
// V^5
V3 = _mm_mul_ps(V3,V2);
vConstants = _mm_mul_ps(vConstants,V3);
vResult = _mm_add_ps(vResult,vConstants);
vConstants = _mm_load_ps1(&g_XMSinEstCoefficients.f[3]);
// V^7
V3 = _mm_mul_ps(V3,V2);
vConstants = _mm_mul_ps(vConstants,V3);
vResult = _mm_add_ps(vResult,vConstants);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorCosEst
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR V2, V4, V6;
XMVECTOR C0, C1, C2, C3;
XMVECTOR Result;
V2 = XMVectorMultiply(V, V);
V4 = XMVectorMultiply(V2, V2);
V6 = XMVectorMultiply(V4, V2);
C0 = XMVectorSplatX(g_XMCosEstCoefficients.v);
C1 = XMVectorSplatY(g_XMCosEstCoefficients.v);
C2 = XMVectorSplatZ(g_XMCosEstCoefficients.v);
C3 = XMVectorSplatW(g_XMCosEstCoefficients.v);
Result = XMVectorMultiplyAdd(C1, V2, C0);
Result = XMVectorMultiplyAdd(C2, V4, Result);
Result = XMVectorMultiplyAdd(C3, V6, Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Get V^2
XMVECTOR V2 = _mm_mul_ps(V,V);
XMVECTOR vResult = _mm_load_ps1(&g_XMCosEstCoefficients.f[1]);
vResult = _mm_mul_ps(vResult,V2);
XMVECTOR vConstants = _mm_load_ps1(&g_XMCosEstCoefficients.f[0]);
vResult = _mm_add_ps(vResult,vConstants);
vConstants = _mm_load_ps1(&g_XMCosEstCoefficients.f[2]);
// Get V^4
XMVECTOR V4 = _mm_mul_ps(V2, V2);
vConstants = _mm_mul_ps(vConstants,V4);
vResult = _mm_add_ps(vResult,vConstants);
vConstants = _mm_load_ps1(&g_XMCosEstCoefficients.f[3]);
// It's really V^6
V4 = _mm_mul_ps(V4,V2);
vConstants = _mm_mul_ps(vConstants,V4);
vResult = _mm_add_ps(vResult,vConstants);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE VOID XMVectorSinCosEst
(
XMVECTOR* pSin,
XMVECTOR* pCos,
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR V2, V3, V4, V5, V6, V7;
XMVECTOR S1, S2, S3;
XMVECTOR C0, C1, C2, C3;
XMVECTOR Sin, Cos;
XMASSERT(pSin);
XMASSERT(pCos);
// sin(V) ~= V - V^3 / 3! + V^5 / 5! - V^7 / 7! (for -PI <= V < PI)
// cos(V) ~= 1 - V^2 / 2! + V^4 / 4! - V^6 / 6! (for -PI <= V < PI)
V2 = XMVectorMultiply(V, V);
V3 = XMVectorMultiply(V2, V);
V4 = XMVectorMultiply(V2, V2);
V5 = XMVectorMultiply(V3, V2);
V6 = XMVectorMultiply(V3, V3);
V7 = XMVectorMultiply(V4, V3);
S1 = XMVectorSplatY(g_XMSinEstCoefficients.v);
S2 = XMVectorSplatZ(g_XMSinEstCoefficients.v);
S3 = XMVectorSplatW(g_XMSinEstCoefficients.v);
C0 = XMVectorSplatX(g_XMCosEstCoefficients.v);
C1 = XMVectorSplatY(g_XMCosEstCoefficients.v);
C2 = XMVectorSplatZ(g_XMCosEstCoefficients.v);
C3 = XMVectorSplatW(g_XMCosEstCoefficients.v);
Sin = XMVectorMultiplyAdd(S1, V3, V);
Sin = XMVectorMultiplyAdd(S2, V5, Sin);
Sin = XMVectorMultiplyAdd(S3, V7, Sin);
Cos = XMVectorMultiplyAdd(C1, V2, C0);
Cos = XMVectorMultiplyAdd(C2, V4, Cos);
Cos = XMVectorMultiplyAdd(C3, V6, Cos);
*pSin = Sin;
*pCos = Cos;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT(pSin);
XMASSERT(pCos);
XMVECTOR V2, V3, V4, V5, V6, V7;
XMVECTOR S1, S2, S3;
XMVECTOR C0, C1, C2, C3;
XMVECTOR Sin, Cos;
// sin(V) ~= V - V^3 / 3! + V^5 / 5! - V^7 / 7! (for -PI <= V < PI)
// cos(V) ~= 1 - V^2 / 2! + V^4 / 4! - V^6 / 6! (for -PI <= V < PI)
V2 = XMVectorMultiply(V, V);
V3 = XMVectorMultiply(V2, V);
V4 = XMVectorMultiply(V2, V2);
V5 = XMVectorMultiply(V3, V2);
V6 = XMVectorMultiply(V3, V3);
V7 = XMVectorMultiply(V4, V3);
S1 = _mm_load_ps1(&g_XMSinEstCoefficients.f[1]);
S2 = _mm_load_ps1(&g_XMSinEstCoefficients.f[2]);
S3 = _mm_load_ps1(&g_XMSinEstCoefficients.f[3]);
C0 = _mm_load_ps1(&g_XMCosEstCoefficients.f[0]);
C1 = _mm_load_ps1(&g_XMCosEstCoefficients.f[1]);
C2 = _mm_load_ps1(&g_XMCosEstCoefficients.f[2]);
C3 = _mm_load_ps1(&g_XMCosEstCoefficients.f[3]);
Sin = XMVectorMultiplyAdd(S1, V3, V);
Sin = XMVectorMultiplyAdd(S2, V5, Sin);
Sin = XMVectorMultiplyAdd(S3, V7, Sin);
Cos = XMVectorMultiplyAdd(C1, V2, C0);
Cos = XMVectorMultiplyAdd(C2, V4, Cos);
Cos = XMVectorMultiplyAdd(C3, V6, Cos);
*pSin = Sin;
*pCos = Cos;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorTanEst
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR V1, V2, V1T0, V1T1, V2T2;
XMVECTOR T0, T1, T2;
XMVECTOR N, D;
XMVECTOR OneOverPi;
XMVECTOR Result;
OneOverPi = XMVectorSplatW(g_XMTanEstCoefficients.v);
V1 = XMVectorMultiply(V, OneOverPi);
V1 = XMVectorRound(V1);
V1 = XMVectorNegativeMultiplySubtract(g_XMPi.v, V1, V);
T0 = XMVectorSplatX(g_XMTanEstCoefficients.v);
T1 = XMVectorSplatY(g_XMTanEstCoefficients.v);
T2 = XMVectorSplatZ(g_XMTanEstCoefficients.v);
V2T2 = XMVectorNegativeMultiplySubtract(V1, V1, T2);
V2 = XMVectorMultiply(V1, V1);
V1T0 = XMVectorMultiply(V1, T0);
V1T1 = XMVectorMultiply(V1, T1);
D = XMVectorReciprocalEst(V2T2);
N = XMVectorMultiplyAdd(V2, V1T1, V1T0);
Result = XMVectorMultiply(N, D);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR V1, V2, V1T0, V1T1, V2T2;
XMVECTOR T0, T1, T2;
XMVECTOR N, D;
XMVECTOR OneOverPi;
XMVECTOR Result;
OneOverPi = XMVectorSplatW(g_XMTanEstCoefficients);
V1 = XMVectorMultiply(V, OneOverPi);
V1 = XMVectorRound(V1);
V1 = XMVectorNegativeMultiplySubtract(g_XMPi, V1, V);
T0 = XMVectorSplatX(g_XMTanEstCoefficients);
T1 = XMVectorSplatY(g_XMTanEstCoefficients);
T2 = XMVectorSplatZ(g_XMTanEstCoefficients);
V2T2 = XMVectorNegativeMultiplySubtract(V1, V1, T2);
V2 = XMVectorMultiply(V1, V1);
V1T0 = XMVectorMultiply(V1, T0);
V1T1 = XMVectorMultiply(V1, T1);
D = XMVectorReciprocalEst(V2T2);
N = XMVectorMultiplyAdd(V2, V1T1, V1T0);
Result = XMVectorMultiply(N, D);
return Result;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorSinHEst
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR V1, V2;
XMVECTOR E1, E2;
XMVECTOR Result;
static CONST XMVECTORF32 Scale = {1.442695040888963f, 1.442695040888963f, 1.442695040888963f, 1.442695040888963f}; // 1.0f / ln(2.0f)
V1 = XMVectorMultiplyAdd(V, Scale.v, g_XMNegativeOne.v);
V2 = XMVectorNegativeMultiplySubtract(V, Scale.v, g_XMNegativeOne.v);
E1 = XMVectorExpEst(V1);
E2 = XMVectorExpEst(V2);
Result = XMVectorSubtract(E1, E2);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR V1, V2;
XMVECTOR E1, E2;
XMVECTOR Result;
static CONST XMVECTORF32 Scale = {1.442695040888963f, 1.442695040888963f, 1.442695040888963f, 1.442695040888963f}; // 1.0f / ln(2.0f)
V1 = _mm_mul_ps(V,Scale);
V1 = _mm_add_ps(V1,g_XMNegativeOne);
V2 = _mm_mul_ps(V,Scale);
V2 = _mm_sub_ps(g_XMNegativeOne,V2);
E1 = XMVectorExpEst(V1);
E2 = XMVectorExpEst(V2);
Result = _mm_sub_ps(E1, E2);
return Result;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorCosHEst
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR V1, V2;
XMVECTOR E1, E2;
XMVECTOR Result;
static CONST XMVECTOR Scale = {1.442695040888963f, 1.442695040888963f, 1.442695040888963f, 1.442695040888963f}; // 1.0f / ln(2.0f)
V1 = XMVectorMultiplyAdd(V, Scale, g_XMNegativeOne.v);
V2 = XMVectorNegativeMultiplySubtract(V, Scale, g_XMNegativeOne.v);
E1 = XMVectorExpEst(V1);
E2 = XMVectorExpEst(V2);
Result = XMVectorAdd(E1, E2);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR V1, V2;
XMVECTOR E1, E2;
XMVECTOR Result;
static CONST XMVECTORF32 Scale = {1.442695040888963f, 1.442695040888963f, 1.442695040888963f, 1.442695040888963f}; // 1.0f / ln(2.0f)
V1 = _mm_mul_ps(V,Scale);
V1 = _mm_add_ps(V1,g_XMNegativeOne);
V2 = _mm_mul_ps(V, Scale);
V2 = _mm_sub_ps(g_XMNegativeOne,V2);
E1 = XMVectorExpEst(V1);
E2 = XMVectorExpEst(V2);
Result = _mm_add_ps(E1, E2);
return Result;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorTanHEst
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR E;
XMVECTOR Result;
static CONST XMVECTOR Scale = {2.8853900817779268f, 2.8853900817779268f, 2.8853900817779268f, 2.8853900817779268f}; // 2.0f / ln(2.0f)
E = XMVectorMultiply(V, Scale);
E = XMVectorExpEst(E);
E = XMVectorMultiplyAdd(E, g_XMOneHalf.v, g_XMOneHalf.v);
E = XMVectorReciprocalEst(E);
Result = XMVectorSubtract(g_XMOne.v, E);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
static CONST XMVECTORF32 Scale = {2.8853900817779268f, 2.8853900817779268f, 2.8853900817779268f, 2.8853900817779268f}; // 2.0f / ln(2.0f)
XMVECTOR E = _mm_mul_ps(V, Scale);
E = XMVectorExpEst(E);
E = _mm_mul_ps(E,g_XMOneHalf);
E = _mm_add_ps(E,g_XMOneHalf);
E = XMVectorReciprocalEst(E);
E = _mm_sub_ps(g_XMOne, E);
return E;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorASinEst
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR AbsV, V2, VD, VC0, V2C3;
XMVECTOR C0, C1, C2, C3;
XMVECTOR D, Rsq, SqrtD;
XMVECTOR OnePlusEps;
XMVECTOR Result;
AbsV = XMVectorAbs(V);
OnePlusEps = XMVectorSplatX(g_XMASinEstConstants.v);
C0 = XMVectorSplatX(g_XMASinEstCoefficients.v);
C1 = XMVectorSplatY(g_XMASinEstCoefficients.v);
C2 = XMVectorSplatZ(g_XMASinEstCoefficients.v);
C3 = XMVectorSplatW(g_XMASinEstCoefficients.v);
D = XMVectorSubtract(OnePlusEps, AbsV);
Rsq = XMVectorReciprocalSqrtEst(D);
SqrtD = XMVectorMultiply(D, Rsq);
V2 = XMVectorMultiply(V, AbsV);
V2C3 = XMVectorMultiply(V2, C3);
VD = XMVectorMultiply(D, AbsV);
VC0 = XMVectorMultiply(V, C0);
Result = XMVectorMultiply(V, C1);
Result = XMVectorMultiplyAdd(V2, C2, Result);
Result = XMVectorMultiplyAdd(V2C3, VD, Result);
Result = XMVectorMultiplyAdd(VC0, SqrtD, Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Get abs(V)
XMVECTOR vAbsV = _mm_setzero_ps();
vAbsV = _mm_sub_ps(vAbsV,V);
vAbsV = _mm_max_ps(vAbsV,V);
XMVECTOR D = _mm_load_ps1(&g_XMASinEstConstants.f[0]);
D = _mm_sub_ps(D,vAbsV);
// Since this is an estimate, rqsrt is okay
XMVECTOR vConstants = _mm_rsqrt_ps(D);
XMVECTOR SqrtD = _mm_mul_ps(D,vConstants);
// V2 = V^2 retaining sign
XMVECTOR V2 = _mm_mul_ps(V,vAbsV);
D = _mm_mul_ps(D,vAbsV);
XMVECTOR vResult = _mm_load_ps1(&g_XMASinEstCoefficients.f[1]);
vResult = _mm_mul_ps(vResult,V);
vConstants = _mm_load_ps1(&g_XMASinEstCoefficients.f[2]);
vConstants = _mm_mul_ps(vConstants,V2);
vResult = _mm_add_ps(vResult,vConstants);
vConstants = _mm_load_ps1(&g_XMASinEstCoefficients.f[3]);
vConstants = _mm_mul_ps(vConstants,V2);
vConstants = _mm_mul_ps(vConstants,D);
vResult = _mm_add_ps(vResult,vConstants);
vConstants = _mm_load_ps1(&g_XMASinEstCoefficients.f[0]);
vConstants = _mm_mul_ps(vConstants,V);
vConstants = _mm_mul_ps(vConstants,SqrtD);
vResult = _mm_add_ps(vResult,vConstants);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorACosEst
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR AbsV, V2, VD, VC0, V2C3;
XMVECTOR C0, C1, C2, C3;
XMVECTOR D, Rsq, SqrtD;
XMVECTOR OnePlusEps, HalfPi;
XMVECTOR Result;
// acos(V) = PI / 2 - asin(V)
AbsV = XMVectorAbs(V);
OnePlusEps = XMVectorSplatX(g_XMASinEstConstants.v);
HalfPi = XMVectorSplatY(g_XMASinEstConstants.v);
C0 = XMVectorSplatX(g_XMASinEstCoefficients.v);
C1 = XMVectorSplatY(g_XMASinEstCoefficients.v);
C2 = XMVectorSplatZ(g_XMASinEstCoefficients.v);
C3 = XMVectorSplatW(g_XMASinEstCoefficients.v);
D = XMVectorSubtract(OnePlusEps, AbsV);
Rsq = XMVectorReciprocalSqrtEst(D);
SqrtD = XMVectorMultiply(D, Rsq);
V2 = XMVectorMultiply(V, AbsV);
V2C3 = XMVectorMultiply(V2, C3);
VD = XMVectorMultiply(D, AbsV);
VC0 = XMVectorMultiply(V, C0);
Result = XMVectorMultiply(V, C1);
Result = XMVectorMultiplyAdd(V2, C2, Result);
Result = XMVectorMultiplyAdd(V2C3, VD, Result);
Result = XMVectorMultiplyAdd(VC0, SqrtD, Result);
Result = XMVectorSubtract(HalfPi, Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// acos(V) = PI / 2 - asin(V)
// Get abs(V)
XMVECTOR vAbsV = _mm_setzero_ps();
vAbsV = _mm_sub_ps(vAbsV,V);
vAbsV = _mm_max_ps(vAbsV,V);
// Calc D
XMVECTOR D = _mm_load_ps1(&g_XMASinEstConstants.f[0]);
D = _mm_sub_ps(D,vAbsV);
// SqrtD = sqrt(D-abs(V)) estimated
XMVECTOR vConstants = _mm_rsqrt_ps(D);
XMVECTOR SqrtD = _mm_mul_ps(D,vConstants);
// V2 = V^2 while retaining sign
XMVECTOR V2 = _mm_mul_ps(V, vAbsV);
// Drop vAbsV here. D = (Const-abs(V))*abs(V)
D = _mm_mul_ps(D, vAbsV);
XMVECTOR vResult = _mm_load_ps1(&g_XMASinEstCoefficients.f[1]);
vResult = _mm_mul_ps(vResult,V);
vConstants = _mm_load_ps1(&g_XMASinEstCoefficients.f[2]);
vConstants = _mm_mul_ps(vConstants,V2);
vResult = _mm_add_ps(vResult,vConstants);
vConstants = _mm_load_ps1(&g_XMASinEstCoefficients.f[3]);
vConstants = _mm_mul_ps(vConstants,V2);
vConstants = _mm_mul_ps(vConstants,D);
vResult = _mm_add_ps(vResult,vConstants);
vConstants = _mm_load_ps1(&g_XMASinEstCoefficients.f[0]);
vConstants = _mm_mul_ps(vConstants,V);
vConstants = _mm_mul_ps(vConstants,SqrtD);
vResult = _mm_add_ps(vResult,vConstants);
vConstants = _mm_load_ps1(&g_XMASinEstConstants.f[1]);
vResult = _mm_sub_ps(vConstants,vResult);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorATanEst
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR AbsV, V2S2, N, D;
XMVECTOR S0, S1, S2;
XMVECTOR HalfPi;
XMVECTOR Result;
S0 = XMVectorSplatX(g_XMATanEstCoefficients.v);
S1 = XMVectorSplatY(g_XMATanEstCoefficients.v);
S2 = XMVectorSplatZ(g_XMATanEstCoefficients.v);
HalfPi = XMVectorSplatW(g_XMATanEstCoefficients.v);
AbsV = XMVectorAbs(V);
V2S2 = XMVectorMultiplyAdd(V, V, S2);
N = XMVectorMultiplyAdd(AbsV, HalfPi, S0);
D = XMVectorMultiplyAdd(AbsV, S1, V2S2);
N = XMVectorMultiply(N, V);
D = XMVectorReciprocalEst(D);
Result = XMVectorMultiply(N, D);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Get abs(V)
XMVECTOR vAbsV = _mm_setzero_ps();
vAbsV = _mm_sub_ps(vAbsV,V);
vAbsV = _mm_max_ps(vAbsV,V);
XMVECTOR vResult = _mm_load_ps1(&g_XMATanEstCoefficients.f[3]);
vResult = _mm_mul_ps(vResult,vAbsV);
XMVECTOR vConstants = _mm_load_ps1(&g_XMATanEstCoefficients.f[0]);
vResult = _mm_add_ps(vResult,vConstants);
vResult = _mm_mul_ps(vResult,V);
XMVECTOR D = _mm_mul_ps(V,V);
vConstants = _mm_load_ps1(&g_XMATanEstCoefficients.f[2]);
D = _mm_add_ps(D,vConstants);
vConstants = _mm_load_ps1(&g_XMATanEstCoefficients.f[1]);
vConstants = _mm_mul_ps(vConstants,vAbsV);
D = _mm_add_ps(D,vConstants);
vResult = _mm_div_ps(vResult,D);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorATan2Est
(
FXMVECTOR Y,
FXMVECTOR X
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Reciprocal;
XMVECTOR V;
XMVECTOR YSign;
XMVECTOR Pi, PiOverTwo, PiOverFour, ThreePiOverFour;
XMVECTOR YEqualsZero, XEqualsZero, XIsPositive, YEqualsInfinity, XEqualsInfinity, FiniteYGreaterZero;
XMVECTOR ATanResultValid;
XMVECTOR R0, R1, R2, R3, R4, R5, R6, R7;
XMVECTOR Zero;
XMVECTOR Result;
static CONST XMVECTOR ATan2Constants = {XM_PI, XM_PIDIV2, XM_PIDIV4, XM_PI * 3.0f / 4.0f};
Zero = XMVectorZero();
ATanResultValid = XMVectorTrueInt();
Pi = XMVectorSplatX(ATan2Constants);
PiOverTwo = XMVectorSplatY(ATan2Constants);
PiOverFour = XMVectorSplatZ(ATan2Constants);
ThreePiOverFour = XMVectorSplatW(ATan2Constants);
YEqualsZero = XMVectorEqual(Y, Zero);
XEqualsZero = XMVectorEqual(X, Zero);
XIsPositive = XMVectorAndInt(X, g_XMNegativeZero.v);
XIsPositive = XMVectorEqualInt(XIsPositive, Zero);
YEqualsInfinity = XMVectorIsInfinite(Y);
XEqualsInfinity = XMVectorIsInfinite(X);
FiniteYGreaterZero = XMVectorGreater(Y, Zero);
FiniteYGreaterZero = XMVectorSelect(FiniteYGreaterZero, Zero, YEqualsInfinity);
YSign = XMVectorAndInt(Y, g_XMNegativeZero.v);
Pi = XMVectorOrInt(Pi, YSign);
PiOverTwo = XMVectorOrInt(PiOverTwo, YSign);
PiOverFour = XMVectorOrInt(PiOverFour, YSign);
ThreePiOverFour = XMVectorOrInt(ThreePiOverFour, YSign);
R1 = XMVectorSelect(Pi, YSign, XIsPositive);
R2 = XMVectorSelect(ATanResultValid, PiOverTwo, XEqualsZero);
R3 = XMVectorSelect(R2, R1, YEqualsZero);
R4 = XMVectorSelect(ThreePiOverFour, PiOverFour, XIsPositive);
R5 = XMVectorSelect(PiOverTwo, R4, XEqualsInfinity);
R6 = XMVectorSelect(R3, R5, YEqualsInfinity);
R7 = XMVectorSelect(R6, R1, FiniteYGreaterZero);
Result = XMVectorSelect(R6, R7, XEqualsInfinity);
ATanResultValid = XMVectorEqualInt(Result, ATanResultValid);
Reciprocal = XMVectorReciprocalEst(X);
V = XMVectorMultiply(Y, Reciprocal);
R0 = XMVectorATanEst(V);
Result = XMVectorSelect(Result, R0, ATanResultValid);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
static CONST XMVECTORF32 ATan2Constants = {XM_PI, XM_PIDIV2, XM_PIDIV4, XM_PI * 3.0f / 4.0f};
// Mask if Y>0 && Y!=INF
XMVECTOR FiniteYGreaterZero = _mm_cmpgt_ps(Y,g_XMZero);
XMVECTOR YEqualsInfinity = XMVectorIsInfinite(Y);
FiniteYGreaterZero = _mm_andnot_ps(YEqualsInfinity,FiniteYGreaterZero);
// Get the sign of (Y&0x80000000)
XMVECTOR YSign = _mm_and_ps(Y, g_XMNegativeZero);
// Get the sign bits of X
XMVECTOR XIsPositive = _mm_and_ps(X,g_XMNegativeZero);
// Change them to masks
XIsPositive = XMVectorEqualInt(XIsPositive,g_XMZero);
// Get Pi
XMVECTOR R1 = _mm_load_ps1(&ATan2Constants.f[0]);
// Copy the sign of Y
R1 = _mm_or_ps(R1,YSign);
R1 = XMVectorSelect(R1,YSign,XIsPositive);
// Mask for X==0
XMVECTOR vConstants = _mm_cmpeq_ps(X,g_XMZero);
// Get Pi/2 with with sign of Y
XMVECTOR PiOverTwo = _mm_load_ps1(&ATan2Constants.f[1]);
PiOverTwo = _mm_or_ps(PiOverTwo,YSign);
XMVECTOR R2 = XMVectorSelect(g_XMNegOneMask,PiOverTwo,vConstants);
// Mask for Y==0
vConstants = _mm_cmpeq_ps(Y,g_XMZero);
R2 = XMVectorSelect(R2,R1,vConstants);
// Get Pi/4 with sign of Y
XMVECTOR PiOverFour = _mm_load_ps1(&ATan2Constants.f[2]);
PiOverFour = _mm_or_ps(PiOverFour,YSign);
// Get (Pi*3)/4 with sign of Y
XMVECTOR ThreePiOverFour = _mm_load_ps1(&ATan2Constants.f[3]);
ThreePiOverFour = _mm_or_ps(ThreePiOverFour,YSign);
vConstants = XMVectorSelect(ThreePiOverFour, PiOverFour, XIsPositive);
XMVECTOR XEqualsInfinity = XMVectorIsInfinite(X);
vConstants = XMVectorSelect(PiOverTwo,vConstants,XEqualsInfinity);
XMVECTOR vResult = XMVectorSelect(R2,vConstants,YEqualsInfinity);
vConstants = XMVectorSelect(vResult,R1,FiniteYGreaterZero);
// At this point, any entry that's zero will get the result
// from XMVectorATan(), otherwise, return the failsafe value
vResult = XMVectorSelect(vResult,vConstants,XEqualsInfinity);
// Any entries not 0xFFFFFFFF, are considered precalculated
XMVECTOR ATanResultValid = XMVectorEqualInt(vResult,g_XMNegOneMask);
// Let's do the ATan2 function
vConstants = _mm_div_ps(Y,X);
vConstants = XMVectorATanEst(vConstants);
// Discard entries that have been declared void
vResult = XMVectorSelect(vResult,vConstants,ATanResultValid);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorLerp
(
FXMVECTOR V0,
FXMVECTOR V1,
FLOAT t
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Scale;
XMVECTOR Length;
XMVECTOR Result;
// V0 + t * (V1 - V0)
Scale = XMVectorReplicate(t);
Length = XMVectorSubtract(V1, V0);
Result = XMVectorMultiplyAdd(Length, Scale, V0);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR L, S;
XMVECTOR Result;
L = _mm_sub_ps( V1, V0 );
S = _mm_set_ps1( t );
Result = _mm_mul_ps( L, S );
return _mm_add_ps( Result, V0 );
#elif defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorLerpV
(
FXMVECTOR V0,
FXMVECTOR V1,
FXMVECTOR T
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Length;
XMVECTOR Result;
// V0 + T * (V1 - V0)
Length = XMVectorSubtract(V1, V0);
Result = XMVectorMultiplyAdd(Length, T, V0);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR Length;
XMVECTOR Result;
Length = _mm_sub_ps( V1, V0 );
Result = _mm_mul_ps( Length, T );
return _mm_add_ps( Result, V0 );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorHermite
(
FXMVECTOR Position0,
FXMVECTOR Tangent0,
FXMVECTOR Position1,
CXMVECTOR Tangent1,
FLOAT t
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR P0;
XMVECTOR T0;
XMVECTOR P1;
XMVECTOR T1;
XMVECTOR Result;
FLOAT t2;
FLOAT t3;
// Result = (2 * t^3 - 3 * t^2 + 1) * Position0 +
// (t^3 - 2 * t^2 + t) * Tangent0 +
// (-2 * t^3 + 3 * t^2) * Position1 +
// (t^3 - t^2) * Tangent1
t2 = t * t;
t3 = t * t2;
P0 = XMVectorReplicate(2.0f * t3 - 3.0f * t2 + 1.0f);
T0 = XMVectorReplicate(t3 - 2.0f * t2 + t);
P1 = XMVectorReplicate(-2.0f * t3 + 3.0f * t2);
T1 = XMVectorReplicate(t3 - t2);
Result = XMVectorMultiply(P0, Position0);
Result = XMVectorMultiplyAdd(T0, Tangent0, Result);
Result = XMVectorMultiplyAdd(P1, Position1, Result);
Result = XMVectorMultiplyAdd(T1, Tangent1, Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
FLOAT t2 = t * t;
FLOAT t3 = t * t2;
XMVECTOR P0 = _mm_set_ps1(2.0f * t3 - 3.0f * t2 + 1.0f);
XMVECTOR T0 = _mm_set_ps1(t3 - 2.0f * t2 + t);
XMVECTOR P1 = _mm_set_ps1(-2.0f * t3 + 3.0f * t2);
XMVECTOR T1 = _mm_set_ps1(t3 - t2);
XMVECTOR vResult = _mm_mul_ps(P0, Position0);
XMVECTOR vTemp = _mm_mul_ps(T0, Tangent0);
vResult = _mm_add_ps(vResult,vTemp);
vTemp = _mm_mul_ps(P1, Position1);
vResult = _mm_add_ps(vResult,vTemp);
vTemp = _mm_mul_ps(T1, Tangent1);
vResult = _mm_add_ps(vResult,vTemp);
return vResult;
#elif defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorHermiteV
(
FXMVECTOR Position0,
FXMVECTOR Tangent0,
FXMVECTOR Position1,
CXMVECTOR Tangent1,
CXMVECTOR T
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR P0;
XMVECTOR T0;
XMVECTOR P1;
XMVECTOR T1;
XMVECTOR Result;
XMVECTOR T2;
XMVECTOR T3;
// Result = (2 * t^3 - 3 * t^2 + 1) * Position0 +
// (t^3 - 2 * t^2 + t) * Tangent0 +
// (-2 * t^3 + 3 * t^2) * Position1 +
// (t^3 - t^2) * Tangent1
T2 = XMVectorMultiply(T, T);
T3 = XMVectorMultiply(T , T2);
P0 = XMVectorReplicate(2.0f * T3.v[0] - 3.0f * T2.v[0] + 1.0f);
T0 = XMVectorReplicate(T3.v[1] - 2.0f * T2.v[1] + T.v[1]);
P1 = XMVectorReplicate(-2.0f * T3.v[2] + 3.0f * T2.v[2]);
T1 = XMVectorReplicate(T3.v[3] - T2.v[3]);
Result = XMVectorMultiply(P0, Position0);
Result = XMVectorMultiplyAdd(T0, Tangent0, Result);
Result = XMVectorMultiplyAdd(P1, Position1, Result);
Result = XMVectorMultiplyAdd(T1, Tangent1, Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
static const XMVECTORF32 g_XMCatMulT2 = {-3.0f,-2.0f,3.0f,-1.0f};
static const XMVECTORF32 g_XMCatMulT3 = {2.0f,1.0f,-2.0f,1.0f};
// Result = (2 * t^3 - 3 * t^2 + 1) * Position0 +
// (t^3 - 2 * t^2 + t) * Tangent0 +
// (-2 * t^3 + 3 * t^2) * Position1 +
// (t^3 - t^2) * Tangent1
XMVECTOR T2 = _mm_mul_ps(T,T);
XMVECTOR T3 = _mm_mul_ps(T,T2);
// Mul by the constants against t^2
T2 = _mm_mul_ps(T2,g_XMCatMulT2);
// Mul by the constants against t^3
T3 = _mm_mul_ps(T3,g_XMCatMulT3);
// T3 now has the pre-result.
T3 = _mm_add_ps(T3,T2);
// I need to add t.y only
T2 = _mm_and_ps(T,g_XMMaskY);
T3 = _mm_add_ps(T3,T2);
// Add 1.0f to x
T3 = _mm_add_ps(T3,g_XMIdentityR0);
// Now, I have the constants created
// Mul the x constant to Position0
XMVECTOR vResult = _mm_shuffle_ps(T3,T3,_MM_SHUFFLE(0,0,0,0));
vResult = _mm_mul_ps(vResult,Position0);
// Mul the y constant to Tangent0
T2 = _mm_shuffle_ps(T3,T3,_MM_SHUFFLE(1,1,1,1));
T2 = _mm_mul_ps(T2,Tangent0);
vResult = _mm_add_ps(vResult,T2);
// Mul the z constant to Position1
T2 = _mm_shuffle_ps(T3,T3,_MM_SHUFFLE(2,2,2,2));
T2 = _mm_mul_ps(T2,Position1);
vResult = _mm_add_ps(vResult,T2);
// Mul the w constant to Tangent1
T3 = _mm_shuffle_ps(T3,T3,_MM_SHUFFLE(3,3,3,3));
T3 = _mm_mul_ps(T3,Tangent1);
vResult = _mm_add_ps(vResult,T3);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorCatmullRom
(
FXMVECTOR Position0,
FXMVECTOR Position1,
FXMVECTOR Position2,
CXMVECTOR Position3,
FLOAT t
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR P0;
XMVECTOR P1;
XMVECTOR P2;
XMVECTOR P3;
XMVECTOR Result;
FLOAT t2;
FLOAT t3;
// Result = ((-t^3 + 2 * t^2 - t) * Position0 +
// (3 * t^3 - 5 * t^2 + 2) * Position1 +
// (-3 * t^3 + 4 * t^2 + t) * Position2 +
// (t^3 - t^2) * Position3) * 0.5
t2 = t * t;
t3 = t * t2;
P0 = XMVectorReplicate((-t3 + 2.0f * t2 - t) * 0.5f);
P1 = XMVectorReplicate((3.0f * t3 - 5.0f * t2 + 2.0f) * 0.5f);
P2 = XMVectorReplicate((-3.0f * t3 + 4.0f * t2 + t) * 0.5f);
P3 = XMVectorReplicate((t3 - t2) * 0.5f);
Result = XMVectorMultiply(P0, Position0);
Result = XMVectorMultiplyAdd(P1, Position1, Result);
Result = XMVectorMultiplyAdd(P2, Position2, Result);
Result = XMVectorMultiplyAdd(P3, Position3, Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
FLOAT t2 = t * t;
FLOAT t3 = t * t2;
XMVECTOR P0 = _mm_set_ps1((-t3 + 2.0f * t2 - t) * 0.5f);
XMVECTOR P1 = _mm_set_ps1((3.0f * t3 - 5.0f * t2 + 2.0f) * 0.5f);
XMVECTOR P2 = _mm_set_ps1((-3.0f * t3 + 4.0f * t2 + t) * 0.5f);
XMVECTOR P3 = _mm_set_ps1((t3 - t2) * 0.5f);
P0 = _mm_mul_ps(P0, Position0);
P1 = _mm_mul_ps(P1, Position1);
P2 = _mm_mul_ps(P2, Position2);
P3 = _mm_mul_ps(P3, Position3);
P0 = _mm_add_ps(P0,P1);
P2 = _mm_add_ps(P2,P3);
P0 = _mm_add_ps(P0,P2);
return P0;
#elif defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorCatmullRomV
(
FXMVECTOR Position0,
FXMVECTOR Position1,
FXMVECTOR Position2,
CXMVECTOR Position3,
CXMVECTOR T
)
{
#if defined(_XM_NO_INTRINSICS_)
float fx = T.x;
float fy = T.y;
float fz = T.z;
float fw = T.w;
XMVECTOR vResult = {
0.5f*((-fx*fx*fx+2*fx*fx-fx)*Position0.x+
(3*fx*fx*fx-5*fx*fx+2)*Position1.x+
(-3*fx*fx*fx+4*fx*fx+fx)*Position2.x+
(fx*fx*fx-fx*fx)*Position3.x),
0.5f*((-fy*fy*fy+2*fy*fy-fy)*Position0.y+
(3*fy*fy*fy-5*fy*fy+2)*Position1.y+
(-3*fy*fy*fy+4*fy*fy+fy)*Position2.y+
(fy*fy*fy-fy*fy)*Position3.y),
0.5f*((-fz*fz*fz+2*fz*fz-fz)*Position0.z+
(3*fz*fz*fz-5*fz*fz+2)*Position1.z+
(-3*fz*fz*fz+4*fz*fz+fz)*Position2.z+
(fz*fz*fz-fz*fz)*Position3.z),
0.5f*((-fw*fw*fw+2*fw*fw-fw)*Position0.w+
(3*fw*fw*fw-5*fw*fw+2)*Position1.w+
(-3*fw*fw*fw+4*fw*fw+fw)*Position2.w+
(fw*fw*fw-fw*fw)*Position3.w)
};
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
static const XMVECTORF32 g_Catmul2 = {2.0f,2.0f,2.0f,2.0f};
static const XMVECTORF32 g_Catmul3 = {3.0f,3.0f,3.0f,3.0f};
static const XMVECTORF32 g_Catmul4 = {4.0f,4.0f,4.0f,4.0f};
static const XMVECTORF32 g_Catmul5 = {5.0f,5.0f,5.0f,5.0f};
// Cache T^2 and T^3
XMVECTOR T2 = _mm_mul_ps(T,T);
XMVECTOR T3 = _mm_mul_ps(T,T2);
// Perform the Position0 term
XMVECTOR vResult = _mm_add_ps(T2,T2);
vResult = _mm_sub_ps(vResult,T);
vResult = _mm_sub_ps(vResult,T3);
vResult = _mm_mul_ps(vResult,Position0);
// Perform the Position1 term and add
XMVECTOR vTemp = _mm_mul_ps(T3,g_Catmul3);
XMVECTOR vTemp2 = _mm_mul_ps(T2,g_Catmul5);
vTemp = _mm_sub_ps(vTemp,vTemp2);
vTemp = _mm_add_ps(vTemp,g_Catmul2);
vTemp = _mm_mul_ps(vTemp,Position1);
vResult = _mm_add_ps(vResult,vTemp);
// Perform the Position2 term and add
vTemp = _mm_mul_ps(T2,g_Catmul4);
vTemp2 = _mm_mul_ps(T3,g_Catmul3);
vTemp = _mm_sub_ps(vTemp,vTemp2);
vTemp = _mm_add_ps(vTemp,T);
vTemp = _mm_mul_ps(vTemp,Position2);
vResult = _mm_add_ps(vResult,vTemp);
// Position3 is the last term
T3 = _mm_sub_ps(T3,T2);
T3 = _mm_mul_ps(T3,Position3);
vResult = _mm_add_ps(vResult,T3);
// Multiply by 0.5f and exit
vResult = _mm_mul_ps(vResult,g_XMOneHalf);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorBaryCentric
(
FXMVECTOR Position0,
FXMVECTOR Position1,
FXMVECTOR Position2,
FLOAT f,
FLOAT g
)
{
#if defined(_XM_NO_INTRINSICS_)
// Result = Position0 + f * (Position1 - Position0) + g * (Position2 - Position0)
XMVECTOR P10;
XMVECTOR P20;
XMVECTOR ScaleF;
XMVECTOR ScaleG;
XMVECTOR Result;
P10 = XMVectorSubtract(Position1, Position0);
ScaleF = XMVectorReplicate(f);
P20 = XMVectorSubtract(Position2, Position0);
ScaleG = XMVectorReplicate(g);
Result = XMVectorMultiplyAdd(P10, ScaleF, Position0);
Result = XMVectorMultiplyAdd(P20, ScaleG, Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR R1 = _mm_sub_ps(Position1,Position0);
XMVECTOR SF = _mm_set_ps1(f);
XMVECTOR R2 = _mm_sub_ps(Position2,Position0);
XMVECTOR SG = _mm_set_ps1(g);
R1 = _mm_mul_ps(R1,SF);
R2 = _mm_mul_ps(R2,SG);
R1 = _mm_add_ps(R1,Position0);
R1 = _mm_add_ps(R1,R2);
return R1;
#elif defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVectorBaryCentricV
(
FXMVECTOR Position0,
FXMVECTOR Position1,
FXMVECTOR Position2,
CXMVECTOR F,
CXMVECTOR G
)
{
#if defined(_XM_NO_INTRINSICS_)
// Result = Position0 + f * (Position1 - Position0) + g * (Position2 - Position0)
XMVECTOR P10;
XMVECTOR P20;
XMVECTOR Result;
P10 = XMVectorSubtract(Position1, Position0);
P20 = XMVectorSubtract(Position2, Position0);
Result = XMVectorMultiplyAdd(P10, F, Position0);
Result = XMVectorMultiplyAdd(P20, G, Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR R1 = _mm_sub_ps(Position1,Position0);
XMVECTOR R2 = _mm_sub_ps(Position2,Position0);
R1 = _mm_mul_ps(R1,F);
R2 = _mm_mul_ps(R2,G);
R1 = _mm_add_ps(R1,Position0);
R1 = _mm_add_ps(R1,R2);
return R1;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
/****************************************************************************
*
* 2D Vector
*
****************************************************************************/
//------------------------------------------------------------------------------
// Comparison operations
//------------------------------------------------------------------------------
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector2Equal
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.x == V2.x) && (V1.y == V2.y)) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmpeq_ps(V1,V2);
// z and w are don't care
return (((_mm_movemask_ps(vTemp)&3)==3) != 0);
#else // _XM_VMX128_INTRINSICS_
return XMComparisonAllTrue(XMVector2EqualR(V1, V2));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE UINT XMVector2EqualR
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
UINT CR = 0;
if ((V1.x == V2.x) &&
(V1.y == V2.y))
{
CR = XM_CRMASK_CR6TRUE;
}
else if ((V1.x != V2.x) &&
(V1.y != V2.y))
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmpeq_ps(V1,V2);
// z and w are don't care
int iTest = _mm_movemask_ps(vTemp)&3;
UINT CR = 0;
if (iTest==3)
{
CR = XM_CRMASK_CR6TRUE;
}
else if (!iTest)
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector2EqualInt
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.u[0] == V2.u[0]) && (V1.u[1] == V2.u[1])) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
__m128i vTemp = _mm_cmpeq_epi32(reinterpret_cast<const __m128i *>(&V1)[0],reinterpret_cast<const __m128i *>(&V2)[0]);
return (((_mm_movemask_ps(reinterpret_cast<const __m128 *>(&vTemp)[0])&3)==3) != 0);
#else // _XM_VMX128_INTRINSICS_
return XMComparisonAllTrue(XMVector2EqualIntR(V1, V2));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE UINT XMVector2EqualIntR
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
UINT CR = 0;
if ((V1.u[0] == V2.u[0]) &&
(V1.u[1] == V2.u[1]))
{
CR = XM_CRMASK_CR6TRUE;
}
else if ((V1.u[0] != V2.u[0]) &&
(V1.u[1] != V2.u[1]))
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#elif defined(_XM_SSE_INTRINSICS_)
__m128i vTemp = _mm_cmpeq_epi32(reinterpret_cast<const __m128i *>(&V1)[0],reinterpret_cast<const __m128i *>(&V2)[0]);
int iTest = _mm_movemask_ps(reinterpret_cast<const __m128 *>(&vTemp)[0])&3;
UINT CR = 0;
if (iTest==3)
{
CR = XM_CRMASK_CR6TRUE;
}
else if (!iTest)
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector2NearEqual
(
FXMVECTOR V1,
FXMVECTOR V2,
FXMVECTOR Epsilon
)
{
#if defined(_XM_NO_INTRINSICS_)
FLOAT dx, dy;
dx = fabsf(V1.x-V2.x);
dy = fabsf(V1.y-V2.y);
return ((dx <= Epsilon.x) &&
(dy <= Epsilon.y));
#elif defined(_XM_SSE_INTRINSICS_)
// Get the difference
XMVECTOR vDelta = _mm_sub_ps(V1,V2);
// Get the absolute value of the difference
XMVECTOR vTemp = _mm_setzero_ps();
vTemp = _mm_sub_ps(vTemp,vDelta);
vTemp = _mm_max_ps(vTemp,vDelta);
vTemp = _mm_cmple_ps(vTemp,Epsilon);
// z and w are don't care
return (((_mm_movemask_ps(vTemp)&3)==0x3) != 0);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector2NotEqual
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.x != V2.x) || (V1.y != V2.y)) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmpeq_ps(V1,V2);
// z and w are don't care
return (((_mm_movemask_ps(vTemp)&3)!=3) != 0);
#else // _XM_VMX128_INTRINSICS_
return XMComparisonAnyFalse(XMVector2EqualR(V1, V2));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector2NotEqualInt
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.u[0] != V2.u[0]) || (V1.u[1] != V2.u[1])) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
__m128i vTemp = _mm_cmpeq_epi32(reinterpret_cast<const __m128i *>(&V1)[0],reinterpret_cast<const __m128i *>(&V2)[0]);
return (((_mm_movemask_ps(reinterpret_cast<const __m128 *>(&vTemp)[0])&3)!=3) != 0);
#else // _XM_VMX128_INTRINSICS_
return XMComparisonAnyFalse(XMVector2EqualIntR(V1, V2));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector2Greater
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.x > V2.x) && (V1.y > V2.y)) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmpgt_ps(V1,V2);
// z and w are don't care
return (((_mm_movemask_ps(vTemp)&3)==3) != 0);
#else // _XM_VMX128_INTRINSICS_
return XMComparisonAllTrue(XMVector2GreaterR(V1, V2));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE UINT XMVector2GreaterR
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
UINT CR = 0;
if ((V1.x > V2.x) &&
(V1.y > V2.y))
{
CR = XM_CRMASK_CR6TRUE;
}
else if ((V1.x <= V2.x) &&
(V1.y <= V2.y))
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmpgt_ps(V1,V2);
int iTest = _mm_movemask_ps(vTemp)&3;
UINT CR = 0;
if (iTest==3)
{
CR = XM_CRMASK_CR6TRUE;
}
else if (!iTest)
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector2GreaterOrEqual
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.x >= V2.x) && (V1.y >= V2.y)) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmpge_ps(V1,V2);
return (((_mm_movemask_ps(vTemp)&3)==3) != 0);
#else // _XM_VMX128_INTRINSICS_
return XMComparisonAllTrue(XMVector2GreaterOrEqualR(V1, V2));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE UINT XMVector2GreaterOrEqualR
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
UINT CR = 0;
if ((V1.x >= V2.x) &&
(V1.y >= V2.y))
{
CR = XM_CRMASK_CR6TRUE;
}
else if ((V1.x < V2.x) &&
(V1.y < V2.y))
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmpge_ps(V1,V2);
int iTest = _mm_movemask_ps(vTemp)&3;
UINT CR = 0;
if (iTest == 3)
{
CR = XM_CRMASK_CR6TRUE;
}
else if (!iTest)
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector2Less
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.x < V2.x) && (V1.y < V2.y)) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmplt_ps(V1,V2);
return (((_mm_movemask_ps(vTemp)&3)==3) != 0);
#else // _XM_VMX128_INTRINSICS_
return XMComparisonAllTrue(XMVector2GreaterR(V2, V1));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector2LessOrEqual
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.x <= V2.x) && (V1.y <= V2.y)) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmple_ps(V1,V2);
return (((_mm_movemask_ps(vTemp)&3)==3) != 0);
#else // _XM_VMX128_INTRINSICS_
return XMComparisonAllTrue(XMVector2GreaterOrEqualR(V2, V1));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector2InBounds
(
FXMVECTOR V,
FXMVECTOR Bounds
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V.x <= Bounds.x && V.x >= -Bounds.x) &&
(V.y <= Bounds.y && V.y >= -Bounds.y)) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
// Test if less than or equal
XMVECTOR vTemp1 = _mm_cmple_ps(V,Bounds);
// Negate the bounds
XMVECTOR vTemp2 = _mm_mul_ps(Bounds,g_XMNegativeOne);
// Test if greater or equal (Reversed)
vTemp2 = _mm_cmple_ps(vTemp2,V);
// Blend answers
vTemp1 = _mm_and_ps(vTemp1,vTemp2);
// x and y in bounds? (z and w are don't care)
return (((_mm_movemask_ps(vTemp1)&0x3)==0x3) != 0);
#else // _XM_VMX128_INTRINSICS_
return XMComparisonAllInBounds(XMVector2InBoundsR(V, Bounds));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE UINT XMVector2InBoundsR
(
FXMVECTOR V,
FXMVECTOR Bounds
)
{
#if defined(_XM_NO_INTRINSICS_)
UINT CR = 0;
if ((V.x <= Bounds.x && V.x >= -Bounds.x) &&
(V.y <= Bounds.y && V.y >= -Bounds.y))
{
CR = XM_CRMASK_CR6BOUNDS;
}
return CR;
#elif defined(_XM_SSE_INTRINSICS_)
// Test if less than or equal
XMVECTOR vTemp1 = _mm_cmple_ps(V,Bounds);
// Negate the bounds
XMVECTOR vTemp2 = _mm_mul_ps(Bounds,g_XMNegativeOne);
// Test if greater or equal (Reversed)
vTemp2 = _mm_cmple_ps(vTemp2,V);
// Blend answers
vTemp1 = _mm_and_ps(vTemp1,vTemp2);
// x and y in bounds? (z and w are don't care)
return ((_mm_movemask_ps(vTemp1)&0x3)==0x3) ? XM_CRMASK_CR6BOUNDS : 0;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector2IsNaN
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
return (XMISNAN(V.x) ||
XMISNAN(V.y));
#elif defined(_XM_SSE_INTRINSICS_)
// Mask off the exponent
__m128i vTempInf = _mm_and_si128(reinterpret_cast<const __m128i *>(&V)[0],g_XMInfinity);
// Mask off the mantissa
__m128i vTempNan = _mm_and_si128(reinterpret_cast<const __m128i *>(&V)[0],g_XMQNaNTest);
// Are any of the exponents == 0x7F800000?
vTempInf = _mm_cmpeq_epi32(vTempInf,g_XMInfinity);
// Are any of the mantissa's zero? (SSE2 doesn't have a neq test)
vTempNan = _mm_cmpeq_epi32(vTempNan,g_XMZero);
// Perform a not on the NaN test to be true on NON-zero mantissas
vTempNan = _mm_andnot_si128(vTempNan,vTempInf);
// If x or y are NaN, the signs are true after the merge above
return ((_mm_movemask_ps(reinterpret_cast<const __m128 *>(&vTempNan)[0])&3) != 0);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector2IsInfinite
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
return (XMISINF(V.x) ||
XMISINF(V.y));
#elif defined(_XM_SSE_INTRINSICS_)
// Mask off the sign bit
__m128 vTemp = _mm_and_ps(V,g_XMAbsMask);
// Compare to infinity
vTemp = _mm_cmpeq_ps(vTemp,g_XMInfinity);
// If x or z are infinity, the signs are true.
return ((_mm_movemask_ps(vTemp)&3) != 0);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Computation operations
//------------------------------------------------------------------------------
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector2Dot
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result.v[0] =
Result.v[1] =
Result.v[2] =
Result.v[3] = V1.v[0] * V2.v[0] + V1.v[1] * V2.v[1];
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Perform the dot product on x and y
XMVECTOR vLengthSq = _mm_mul_ps(V1,V2);
// vTemp has y splatted
XMVECTOR vTemp = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(1,1,1,1));
// x+y
vLengthSq = _mm_add_ss(vLengthSq,vTemp);
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(0,0,0,0));
return vLengthSq;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector2Cross
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
FLOAT fCross = (V1.x * V2.y) - (V1.y * V2.x);
XMVECTOR vResult = {
fCross,
fCross,
fCross,
fCross
};
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
// Swap x and y
XMVECTOR vResult = _mm_shuffle_ps(V2,V2,_MM_SHUFFLE(0,1,0,1));
// Perform the muls
vResult = _mm_mul_ps(vResult,V1);
// Splat y
XMVECTOR vTemp = _mm_shuffle_ps(vResult,vResult,_MM_SHUFFLE(1,1,1,1));
// Sub the values
vResult = _mm_sub_ss(vResult,vTemp);
// Splat the cross product
vResult = _mm_shuffle_ps(vResult,vResult,_MM_SHUFFLE(0,0,0,0));
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector2LengthSq
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
return XMVector2Dot(V, V);
#elif defined(_XM_SSE_INTRINSICS_)
// Perform the dot product on x and y
XMVECTOR vLengthSq = _mm_mul_ps(V,V);
// vTemp has y splatted
XMVECTOR vTemp = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(1,1,1,1));
// x+y
vLengthSq = _mm_add_ss(vLengthSq,vTemp);
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(0,0,0,0));
return vLengthSq;
#else
return XMVector2Dot(V, V);
#endif
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector2ReciprocalLengthEst
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result = XMVector2LengthSq(V);
Result = XMVectorReciprocalSqrtEst(Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Perform the dot product on x and y
XMVECTOR vLengthSq = _mm_mul_ps(V,V);
// vTemp has y splatted
XMVECTOR vTemp = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(1,1,1,1));
// x+y
vLengthSq = _mm_add_ss(vLengthSq,vTemp);
vLengthSq = _mm_rsqrt_ss(vLengthSq);
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(0,0,0,0));
return vLengthSq;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector2ReciprocalLength
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result = XMVector2LengthSq(V);
Result = XMVectorReciprocalSqrt(Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Perform the dot product on x and y
XMVECTOR vLengthSq = _mm_mul_ps(V,V);
// vTemp has y splatted
XMVECTOR vTemp = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(1,1,1,1));
// x+y
vLengthSq = _mm_add_ss(vLengthSq,vTemp);
vLengthSq = _mm_sqrt_ss(vLengthSq);
vLengthSq = _mm_div_ss(g_XMOne,vLengthSq);
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(0,0,0,0));
return vLengthSq;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector2LengthEst
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result = XMVector2LengthSq(V);
Result = XMVectorSqrtEst(Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Perform the dot product on x and y
XMVECTOR vLengthSq = _mm_mul_ps(V,V);
// vTemp has y splatted
XMVECTOR vTemp = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(1,1,1,1));
// x+y
vLengthSq = _mm_add_ss(vLengthSq,vTemp);
vLengthSq = _mm_sqrt_ss(vLengthSq);
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(0,0,0,0));
return vLengthSq;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector2Length
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result = XMVector2LengthSq(V);
Result = XMVectorSqrt(Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Perform the dot product on x and y
XMVECTOR vLengthSq = _mm_mul_ps(V,V);
// vTemp has y splatted
XMVECTOR vTemp = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(1,1,1,1));
// x+y
vLengthSq = _mm_add_ss(vLengthSq,vTemp);
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(0,0,0,0));
vLengthSq = _mm_sqrt_ps(vLengthSq);
return vLengthSq;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// XMVector2NormalizeEst uses a reciprocal estimate and
// returns QNaN on zero and infinite vectors.
XMFINLINE XMVECTOR XMVector2NormalizeEst
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result = XMVector2ReciprocalLength(V);
Result = XMVectorMultiply(V, Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Perform the dot product on x and y
XMVECTOR vLengthSq = _mm_mul_ps(V,V);
// vTemp has y splatted
XMVECTOR vTemp = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(1,1,1,1));
// x+y
vLengthSq = _mm_add_ss(vLengthSq,vTemp);
vLengthSq = _mm_rsqrt_ss(vLengthSq);
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(0,0,0,0));
vLengthSq = _mm_mul_ps(vLengthSq,V);
return vLengthSq;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector2Normalize
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR LengthSq;
XMVECTOR Zero;
XMVECTOR InfiniteLength;
XMVECTOR ZeroLength;
XMVECTOR Select;
XMVECTOR Result;
LengthSq = XMVector2LengthSq(V);
Zero = XMVectorZero();
Result = XMVectorReciprocalSqrt(LengthSq);
InfiniteLength = XMVectorEqualInt(LengthSq, g_XMInfinity.v);
ZeroLength = XMVectorEqual(LengthSq, Zero);
Result = XMVectorMultiply(V, Result);
Select = XMVectorEqualInt(InfiniteLength, ZeroLength);
Result = XMVectorSelect(LengthSq, Result, Select);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Perform the dot product on x and y only
XMVECTOR vLengthSq = _mm_mul_ps(V,V);
XMVECTOR vTemp = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(1,1,1,1));
vLengthSq = _mm_add_ss(vLengthSq,vTemp);
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(0,0,0,0));
// Prepare for the division
XMVECTOR vResult = _mm_sqrt_ps(vLengthSq);
// Failsafe on zero (Or epsilon) length planes
// If the length is infinity, set the elements to zero
vLengthSq = _mm_cmpneq_ps(vLengthSq,g_XMInfinity);
// Reciprocal mul to perform the normalization
vResult = _mm_div_ps(V,vResult);
// Any that are infinity, set to zero
vResult = _mm_and_ps(vResult,vLengthSq);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector2ClampLength
(
FXMVECTOR V,
FLOAT LengthMin,
FLOAT LengthMax
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR ClampMax;
XMVECTOR ClampMin;
ClampMax = XMVectorReplicate(LengthMax);
ClampMin = XMVectorReplicate(LengthMin);
return XMVector2ClampLengthV(V, ClampMin, ClampMax);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR ClampMax = _mm_set_ps1(LengthMax);
XMVECTOR ClampMin = _mm_set_ps1(LengthMin);
return XMVector2ClampLengthV(V, ClampMin, ClampMax);
#elif defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector2ClampLengthV
(
FXMVECTOR V,
FXMVECTOR LengthMin,
FXMVECTOR LengthMax
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR ClampLength;
XMVECTOR LengthSq;
XMVECTOR RcpLength;
XMVECTOR Length;
XMVECTOR Normal;
XMVECTOR Zero;
XMVECTOR InfiniteLength;
XMVECTOR ZeroLength;
XMVECTOR Select;
XMVECTOR ControlMax;
XMVECTOR ControlMin;
XMVECTOR Control;
XMVECTOR Result;
XMASSERT((LengthMin.y == LengthMin.x));
XMASSERT((LengthMax.y == LengthMax.x));
XMASSERT(XMVector2GreaterOrEqual(LengthMin, XMVectorZero()));
XMASSERT(XMVector2GreaterOrEqual(LengthMax, XMVectorZero()));
XMASSERT(XMVector2GreaterOrEqual(LengthMax, LengthMin));
LengthSq = XMVector2LengthSq(V);
Zero = XMVectorZero();
RcpLength = XMVectorReciprocalSqrt(LengthSq);
InfiniteLength = XMVectorEqualInt(LengthSq, g_XMInfinity.v);
ZeroLength = XMVectorEqual(LengthSq, Zero);
Length = XMVectorMultiply(LengthSq, RcpLength);
Normal = XMVectorMultiply(V, RcpLength);
Select = XMVectorEqualInt(InfiniteLength, ZeroLength);
Length = XMVectorSelect(LengthSq, Length, Select);
Normal = XMVectorSelect(LengthSq, Normal, Select);
ControlMax = XMVectorGreater(Length, LengthMax);
ControlMin = XMVectorLess(Length, LengthMin);
ClampLength = XMVectorSelect(Length, LengthMax, ControlMax);
ClampLength = XMVectorSelect(ClampLength, LengthMin, ControlMin);
Result = XMVectorMultiply(Normal, ClampLength);
// Preserve the original vector (with no precision loss) if the length falls within the given range
Control = XMVectorEqualInt(ControlMax, ControlMin);
Result = XMVectorSelect(Result, V, Control);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR ClampLength;
XMVECTOR LengthSq;
XMVECTOR RcpLength;
XMVECTOR Length;
XMVECTOR Normal;
XMVECTOR InfiniteLength;
XMVECTOR ZeroLength;
XMVECTOR Select;
XMVECTOR ControlMax;
XMVECTOR ControlMin;
XMVECTOR Control;
XMVECTOR Result;
XMASSERT((XMVectorGetY(LengthMin) == XMVectorGetX(LengthMin)));
XMASSERT((XMVectorGetY(LengthMax) == XMVectorGetX(LengthMax)));
XMASSERT(XMVector2GreaterOrEqual(LengthMin, g_XMZero));
XMASSERT(XMVector2GreaterOrEqual(LengthMax, g_XMZero));
XMASSERT(XMVector2GreaterOrEqual(LengthMax, LengthMin));
LengthSq = XMVector2LengthSq(V);
RcpLength = XMVectorReciprocalSqrt(LengthSq);
InfiniteLength = XMVectorEqualInt(LengthSq, g_XMInfinity);
ZeroLength = XMVectorEqual(LengthSq, g_XMZero);
Length = _mm_mul_ps(LengthSq, RcpLength);
Normal = _mm_mul_ps(V, RcpLength);
Select = XMVectorEqualInt(InfiniteLength, ZeroLength);
Length = XMVectorSelect(LengthSq, Length, Select);
Normal = XMVectorSelect(LengthSq, Normal, Select);
ControlMax = XMVectorGreater(Length, LengthMax);
ControlMin = XMVectorLess(Length, LengthMin);
ClampLength = XMVectorSelect(Length, LengthMax, ControlMax);
ClampLength = XMVectorSelect(ClampLength, LengthMin, ControlMin);
Result = _mm_mul_ps(Normal, ClampLength);
// Preserve the original vector (with no precision loss) if the length falls within the given range
Control = XMVectorEqualInt(ControlMax, ControlMin);
Result = XMVectorSelect(Result, V, Control);
return Result;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector2Reflect
(
FXMVECTOR Incident,
FXMVECTOR Normal
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
// Result = Incident - (2 * dot(Incident, Normal)) * Normal
Result = XMVector2Dot(Incident, Normal);
Result = XMVectorAdd(Result, Result);
Result = XMVectorNegativeMultiplySubtract(Result, Normal, Incident);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Result = Incident - (2 * dot(Incident, Normal)) * Normal
XMVECTOR Result = XMVector2Dot(Incident,Normal);
Result = _mm_add_ps(Result, Result);
Result = _mm_mul_ps(Result, Normal);
Result = _mm_sub_ps(Incident,Result);
return Result;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector2Refract
(
FXMVECTOR Incident,
FXMVECTOR Normal,
FLOAT RefractionIndex
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Index;
Index = XMVectorReplicate(RefractionIndex);
return XMVector2RefractV(Incident, Normal, Index);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR Index = _mm_set_ps1(RefractionIndex);
return XMVector2RefractV(Incident,Normal,Index);
#elif defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Return the refraction of a 2D vector
XMFINLINE XMVECTOR XMVector2RefractV
(
FXMVECTOR Incident,
FXMVECTOR Normal,
FXMVECTOR RefractionIndex
)
{
#if defined(_XM_NO_INTRINSICS_)
float IDotN;
float RX,RY;
XMVECTOR vResult;
// Result = RefractionIndex * Incident - Normal * (RefractionIndex * dot(Incident, Normal) +
// sqrt(1 - RefractionIndex * RefractionIndex * (1 - dot(Incident, Normal) * dot(Incident, Normal))))
IDotN = (Incident.x*Normal.x)+(Incident.y*Normal.y);
// R = 1.0f - RefractionIndex * RefractionIndex * (1.0f - IDotN * IDotN)
RY = 1.0f-(IDotN*IDotN);
RX = 1.0f-(RY*RefractionIndex.x*RefractionIndex.x);
RY = 1.0f-(RY*RefractionIndex.y*RefractionIndex.y);
if (RX>=0.0f) {
RX = (RefractionIndex.x*Incident.x)-(Normal.x*((RefractionIndex.x*IDotN)+sqrtf(RX)));
} else {
RX = 0.0f;
}
if (RY>=0.0f) {
RY = (RefractionIndex.y*Incident.y)-(Normal.y*((RefractionIndex.y*IDotN)+sqrtf(RY)));
} else {
RY = 0.0f;
}
vResult.x = RX;
vResult.y = RY;
vResult.z = 0.0f;
vResult.w = 0.0f;
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
// Result = RefractionIndex * Incident - Normal * (RefractionIndex * dot(Incident, Normal) +
// sqrt(1 - RefractionIndex * RefractionIndex * (1 - dot(Incident, Normal) * dot(Incident, Normal))))
// Get the 2D Dot product of Incident-Normal
XMVECTOR IDotN = _mm_mul_ps(Incident,Normal);
XMVECTOR vTemp = _mm_shuffle_ps(IDotN,IDotN,_MM_SHUFFLE(1,1,1,1));
IDotN = _mm_add_ss(IDotN,vTemp);
IDotN = _mm_shuffle_ps(IDotN,IDotN,_MM_SHUFFLE(0,0,0,0));
// vTemp = 1.0f - RefractionIndex * RefractionIndex * (1.0f - IDotN * IDotN)
vTemp = _mm_mul_ps(IDotN,IDotN);
vTemp = _mm_sub_ps(g_XMOne,vTemp);
vTemp = _mm_mul_ps(vTemp,RefractionIndex);
vTemp = _mm_mul_ps(vTemp,RefractionIndex);
vTemp = _mm_sub_ps(g_XMOne,vTemp);
// If any terms are <=0, sqrt() will fail, punt to zero
XMVECTOR vMask = _mm_cmpgt_ps(vTemp,g_XMZero);
// R = RefractionIndex * IDotN + sqrt(R)
vTemp = _mm_sqrt_ps(vTemp);
XMVECTOR vResult = _mm_mul_ps(RefractionIndex,IDotN);
vTemp = _mm_add_ps(vTemp,vResult);
// Result = RefractionIndex * Incident - Normal * R
vResult = _mm_mul_ps(RefractionIndex,Incident);
vTemp = _mm_mul_ps(vTemp,Normal);
vResult = _mm_sub_ps(vResult,vTemp);
vResult = _mm_and_ps(vResult,vMask);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector2Orthogonal
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result.v[0] = -V.v[1];
Result.v[1] = V.v[0];
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(3,2,0,1));
vResult = _mm_mul_ps(vResult,g_XMNegateX);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector2AngleBetweenNormalsEst
(
FXMVECTOR N1,
FXMVECTOR N2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR NegativeOne;
XMVECTOR One;
XMVECTOR Result;
Result = XMVector2Dot(N1, N2);
NegativeOne = XMVectorSplatConstant(-1, 0);
One = XMVectorSplatOne();
Result = XMVectorClamp(Result, NegativeOne, One);
Result = XMVectorACosEst(Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = XMVector2Dot(N1,N2);
// Clamp to -1.0f to 1.0f
vResult = _mm_max_ps(vResult,g_XMNegativeOne);
vResult = _mm_min_ps(vResult,g_XMOne);;
vResult = XMVectorACosEst(vResult);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector2AngleBetweenNormals
(
FXMVECTOR N1,
FXMVECTOR N2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR NegativeOne;
XMVECTOR One;
XMVECTOR Result;
Result = XMVector2Dot(N1, N2);
NegativeOne = XMVectorSplatConstant(-1, 0);
One = XMVectorSplatOne();
Result = XMVectorClamp(Result, NegativeOne, One);
Result = XMVectorACos(Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = XMVector2Dot(N1,N2);
// Clamp to -1.0f to 1.0f
vResult = _mm_max_ps(vResult,g_XMNegativeOne);
vResult = _mm_min_ps(vResult,g_XMOne);;
vResult = XMVectorACos(vResult);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector2AngleBetweenVectors
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR L1;
XMVECTOR L2;
XMVECTOR Dot;
XMVECTOR CosAngle;
XMVECTOR NegativeOne;
XMVECTOR One;
XMVECTOR Result;
L1 = XMVector2ReciprocalLength(V1);
L2 = XMVector2ReciprocalLength(V2);
Dot = XMVector2Dot(V1, V2);
L1 = XMVectorMultiply(L1, L2);
CosAngle = XMVectorMultiply(Dot, L1);
NegativeOne = XMVectorSplatConstant(-1, 0);
One = XMVectorSplatOne();
CosAngle = XMVectorClamp(CosAngle, NegativeOne, One);
Result = XMVectorACos(CosAngle);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR L1;
XMVECTOR L2;
XMVECTOR Dot;
XMVECTOR CosAngle;
XMVECTOR Result;
L1 = XMVector2ReciprocalLength(V1);
L2 = XMVector2ReciprocalLength(V2);
Dot = XMVector2Dot(V1, V2);
L1 = _mm_mul_ps(L1, L2);
CosAngle = _mm_mul_ps(Dot, L1);
CosAngle = XMVectorClamp(CosAngle, g_XMNegativeOne,g_XMOne);
Result = XMVectorACos(CosAngle);
return Result;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector2LinePointDistance
(
FXMVECTOR LinePoint1,
FXMVECTOR LinePoint2,
FXMVECTOR Point
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR PointVector;
XMVECTOR LineVector;
XMVECTOR ReciprocalLengthSq;
XMVECTOR PointProjectionScale;
XMVECTOR DistanceVector;
XMVECTOR Result;
// Given a vector PointVector from LinePoint1 to Point and a vector
// LineVector from LinePoint1 to LinePoint2, the scaled distance
// PointProjectionScale from LinePoint1 to the perpendicular projection
// of PointVector onto the line is defined as:
//
// PointProjectionScale = dot(PointVector, LineVector) / LengthSq(LineVector)
PointVector = XMVectorSubtract(Point, LinePoint1);
LineVector = XMVectorSubtract(LinePoint2, LinePoint1);
ReciprocalLengthSq = XMVector2LengthSq(LineVector);
ReciprocalLengthSq = XMVectorReciprocal(ReciprocalLengthSq);
PointProjectionScale = XMVector2Dot(PointVector, LineVector);
PointProjectionScale = XMVectorMultiply(PointProjectionScale, ReciprocalLengthSq);
DistanceVector = XMVectorMultiply(LineVector, PointProjectionScale);
DistanceVector = XMVectorSubtract(PointVector, DistanceVector);
Result = XMVector2Length(DistanceVector);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR PointVector = _mm_sub_ps(Point,LinePoint1);
XMVECTOR LineVector = _mm_sub_ps(LinePoint2,LinePoint1);
XMVECTOR ReciprocalLengthSq = XMVector2LengthSq(LineVector);
XMVECTOR vResult = XMVector2Dot(PointVector,LineVector);
vResult = _mm_div_ps(vResult,ReciprocalLengthSq);
vResult = _mm_mul_ps(vResult,LineVector);
vResult = _mm_sub_ps(PointVector,vResult);
vResult = XMVector2Length(vResult);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector2IntersectLine
(
FXMVECTOR Line1Point1,
FXMVECTOR Line1Point2,
FXMVECTOR Line2Point1,
CXMVECTOR Line2Point2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR V1;
XMVECTOR V2;
XMVECTOR V3;
XMVECTOR C1;
XMVECTOR C2;
XMVECTOR Result;
CONST XMVECTOR Zero = XMVectorZero();
V1 = XMVectorSubtract(Line1Point2, Line1Point1);
V2 = XMVectorSubtract(Line2Point2, Line2Point1);
V3 = XMVectorSubtract(Line1Point1, Line2Point1);
C1 = XMVector2Cross(V1, V2);
C2 = XMVector2Cross(V2, V3);
if (XMVector2NearEqual(C1, Zero, g_XMEpsilon.v))
{
if (XMVector2NearEqual(C2, Zero, g_XMEpsilon.v))
{
// Coincident
Result = g_XMInfinity.v;
}
else
{
// Parallel
Result = g_XMQNaN.v;
}
}
else
{
// Intersection point = Line1Point1 + V1 * (C2 / C1)
XMVECTOR Scale;
Scale = XMVectorReciprocal(C1);
Scale = XMVectorMultiply(C2, Scale);
Result = XMVectorMultiplyAdd(V1, Scale, Line1Point1);
}
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR V1 = _mm_sub_ps(Line1Point2, Line1Point1);
XMVECTOR V2 = _mm_sub_ps(Line2Point2, Line2Point1);
XMVECTOR V3 = _mm_sub_ps(Line1Point1, Line2Point1);
// Generate the cross products
XMVECTOR C1 = XMVector2Cross(V1, V2);
XMVECTOR C2 = XMVector2Cross(V2, V3);
// If C1 is not close to epsilon, use the calculated value
XMVECTOR vResultMask = _mm_setzero_ps();
vResultMask = _mm_sub_ps(vResultMask,C1);
vResultMask = _mm_max_ps(vResultMask,C1);
// 0xFFFFFFFF if the calculated value is to be used
vResultMask = _mm_cmpgt_ps(vResultMask,g_XMEpsilon);
// If C1 is close to epsilon, which fail type is it? INFINITY or NAN?
XMVECTOR vFailMask = _mm_setzero_ps();
vFailMask = _mm_sub_ps(vFailMask,C2);
vFailMask = _mm_max_ps(vFailMask,C2);
vFailMask = _mm_cmple_ps(vFailMask,g_XMEpsilon);
XMVECTOR vFail = _mm_and_ps(vFailMask,g_XMInfinity);
vFailMask = _mm_andnot_ps(vFailMask,g_XMQNaN);
// vFail is NAN or INF
vFail = _mm_or_ps(vFail,vFailMask);
// Intersection point = Line1Point1 + V1 * (C2 / C1)
XMVECTOR vResult = _mm_div_ps(C2,C1);
vResult = _mm_mul_ps(vResult,V1);
vResult = _mm_add_ps(vResult,Line1Point1);
// Use result, or failure value
vResult = _mm_and_ps(vResult,vResultMask);
vResultMask = _mm_andnot_ps(vResultMask,vFail);
vResult = _mm_or_ps(vResult,vResultMask);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector2Transform
(
FXMVECTOR V,
CXMMATRIX M
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR X;
XMVECTOR Y;
XMVECTOR Result;
Y = XMVectorSplatY(V);
X = XMVectorSplatX(V);
Result = XMVectorMultiplyAdd(Y, M.r[1], M.r[3]);
Result = XMVectorMultiplyAdd(X, M.r[0], Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(0,0,0,0));
vResult = _mm_mul_ps(vResult,M.r[0]);
XMVECTOR vTemp = _mm_shuffle_ps(V,V,_MM_SHUFFLE(1,1,1,1));
vTemp = _mm_mul_ps(vTemp,M.r[1]);
vResult = _mm_add_ps(vResult,vTemp);
vResult = _mm_add_ps(vResult,M.r[3]);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMFLOAT4* XMVector2TransformStream
(
XMFLOAT4* pOutputStream,
UINT OutputStride,
CONST XMFLOAT2* pInputStream,
UINT InputStride,
UINT VectorCount,
CXMMATRIX M
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR V;
XMVECTOR X;
XMVECTOR Y;
XMVECTOR Result;
UINT i;
BYTE* pInputVector = (BYTE*)pInputStream;
BYTE* pOutputVector = (BYTE*)pOutputStream;
XMASSERT(pOutputStream);
XMASSERT(pInputStream);
for (i = 0; i < VectorCount; i++)
{
V = XMLoadFloat2((XMFLOAT2*)pInputVector);
Y = XMVectorSplatY(V);
X = XMVectorSplatX(V);
// Y = XMVectorReplicate(((XMFLOAT2*)pInputVector)->y);
// X = XMVectorReplicate(((XMFLOAT2*)pInputVector)->x);
Result = XMVectorMultiplyAdd(Y, M.r[1], M.r[3]);
Result = XMVectorMultiplyAdd(X, M.r[0], Result);
XMStoreFloat4((XMFLOAT4*)pOutputVector, Result);
pInputVector += InputStride;
pOutputVector += OutputStride;
}
return pOutputStream;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT(pOutputStream);
XMASSERT(pInputStream);
UINT i;
const BYTE* pInputVector = (const BYTE*)pInputStream;
BYTE* pOutputVector = (BYTE*)pOutputStream;
for (i = 0; i < VectorCount; i++)
{
XMVECTOR X = _mm_load_ps1(&reinterpret_cast<const XMFLOAT2*>(pInputVector)->x);
XMVECTOR vResult = _mm_load_ps1(&reinterpret_cast<const XMFLOAT2*>(pInputVector)->y);
vResult = _mm_mul_ps(vResult,M.r[1]);
vResult = _mm_add_ps(vResult,M.r[3]);
X = _mm_mul_ps(X,M.r[0]);
vResult = _mm_add_ps(vResult,X);
_mm_storeu_ps(reinterpret_cast<float*>(pOutputVector),vResult);
pInputVector += InputStride;
pOutputVector += OutputStride;
}
return pOutputStream;
#elif defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMFLOAT4* XMVector2TransformStreamNC
(
XMFLOAT4* pOutputStream,
UINT OutputStride,
CONST XMFLOAT2* pInputStream,
UINT InputStride,
UINT VectorCount,
CXMMATRIX M
)
{
#if defined(_XM_NO_INTRINSICS_) || defined(XM_NO_MISALIGNED_VECTOR_ACCESS) || defined(_XM_SSE_INTRINSICS_)
return XMVector2TransformStream( pOutputStream, OutputStride, pInputStream, InputStride, VectorCount, M );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector2TransformCoord
(
FXMVECTOR V,
CXMMATRIX M
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR X;
XMVECTOR Y;
XMVECTOR InverseW;
XMVECTOR Result;
Y = XMVectorSplatY(V);
X = XMVectorSplatX(V);
Result = XMVectorMultiplyAdd(Y, M.r[1], M.r[3]);
Result = XMVectorMultiplyAdd(X, M.r[0], Result);
InverseW = XMVectorSplatW(Result);
InverseW = XMVectorReciprocal(InverseW);
Result = XMVectorMultiply(Result, InverseW);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(0,0,0,0));
vResult = _mm_mul_ps(vResult,M.r[0]);
XMVECTOR vTemp = _mm_shuffle_ps(V,V,_MM_SHUFFLE(1,1,1,1));
vTemp = _mm_mul_ps(vTemp,M.r[1]);
vResult = _mm_add_ps(vResult,vTemp);
vResult = _mm_add_ps(vResult,M.r[3]);
vTemp = _mm_shuffle_ps(vResult,vResult,_MM_SHUFFLE(3,3,3,3));
vResult = _mm_div_ps(vResult,vTemp);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMFLOAT2* XMVector2TransformCoordStream
(
XMFLOAT2* pOutputStream,
UINT OutputStride,
CONST XMFLOAT2* pInputStream,
UINT InputStride,
UINT VectorCount,
CXMMATRIX M
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR V;
XMVECTOR X;
XMVECTOR Y;
XMVECTOR InverseW;
XMVECTOR Result;
UINT i;
BYTE* pInputVector = (BYTE*)pInputStream;
BYTE* pOutputVector = (BYTE*)pOutputStream;
XMASSERT(pOutputStream);
XMASSERT(pInputStream);
for (i = 0; i < VectorCount; i++)
{
V = XMLoadFloat2((XMFLOAT2*)pInputVector);
Y = XMVectorSplatY(V);
X = XMVectorSplatX(V);
// Y = XMVectorReplicate(((XMFLOAT2*)pInputVector)->y);
// X = XMVectorReplicate(((XMFLOAT2*)pInputVector)->x);
Result = XMVectorMultiplyAdd(Y, M.r[1], M.r[3]);
Result = XMVectorMultiplyAdd(X, M.r[0], Result);
InverseW = XMVectorSplatW(Result);
InverseW = XMVectorReciprocal(InverseW);
Result = XMVectorMultiply(Result, InverseW);
XMStoreFloat2((XMFLOAT2*)pOutputVector, Result);
pInputVector += InputStride;
pOutputVector += OutputStride;
}
return pOutputStream;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT(pOutputStream);
XMASSERT(pInputStream);
UINT i;
const BYTE *pInputVector = (BYTE*)pInputStream;
BYTE *pOutputVector = (BYTE*)pOutputStream;
for (i = 0; i < VectorCount; i++)
{
XMVECTOR X = _mm_load_ps1(&reinterpret_cast<const XMFLOAT2*>(pInputVector)->x);
XMVECTOR vResult = _mm_load_ps1(&reinterpret_cast<const XMFLOAT2*>(pInputVector)->y);
vResult = _mm_mul_ps(vResult,M.r[1]);
vResult = _mm_add_ps(vResult,M.r[3]);
X = _mm_mul_ps(X,M.r[0]);
vResult = _mm_add_ps(vResult,X);
X = _mm_shuffle_ps(vResult,vResult,_MM_SHUFFLE(3,3,3,3));
vResult = _mm_div_ps(vResult,X);
_mm_store_sd(reinterpret_cast<double *>(pOutputVector),reinterpret_cast<__m128d *>(&vResult)[0]);
pInputVector += InputStride;
pOutputVector += OutputStride;
}
return pOutputStream;
#elif defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector2TransformNormal
(
FXMVECTOR V,
CXMMATRIX M
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR X;
XMVECTOR Y;
XMVECTOR Result;
Y = XMVectorSplatY(V);
X = XMVectorSplatX(V);
Result = XMVectorMultiply(Y, M.r[1]);
Result = XMVectorMultiplyAdd(X, M.r[0], Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(0,0,0,0));
vResult = _mm_mul_ps(vResult,M.r[0]);
XMVECTOR vTemp = _mm_shuffle_ps(V,V,_MM_SHUFFLE(1,1,1,1));
vTemp = _mm_mul_ps(vTemp,M.r[1]);
vResult = _mm_add_ps(vResult,vTemp);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMFLOAT2* XMVector2TransformNormalStream
(
XMFLOAT2* pOutputStream,
UINT OutputStride,
CONST XMFLOAT2* pInputStream,
UINT InputStride,
UINT VectorCount,
CXMMATRIX M
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR V;
XMVECTOR X;
XMVECTOR Y;
XMVECTOR Result;
UINT i;
BYTE* pInputVector = (BYTE*)pInputStream;
BYTE* pOutputVector = (BYTE*)pOutputStream;
XMASSERT(pOutputStream);
XMASSERT(pInputStream);
for (i = 0; i < VectorCount; i++)
{
V = XMLoadFloat2((XMFLOAT2*)pInputVector);
Y = XMVectorSplatY(V);
X = XMVectorSplatX(V);
// Y = XMVectorReplicate(((XMFLOAT2*)pInputVector)->y);
// X = XMVectorReplicate(((XMFLOAT2*)pInputVector)->x);
Result = XMVectorMultiply(Y, M.r[1]);
Result = XMVectorMultiplyAdd(X, M.r[0], Result);
XMStoreFloat2((XMFLOAT2*)pOutputVector, Result);
pInputVector += InputStride;
pOutputVector += OutputStride;
}
return pOutputStream;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT(pOutputStream);
XMASSERT(pInputStream);
UINT i;
const BYTE*pInputVector = (const BYTE*)pInputStream;
BYTE *pOutputVector = (BYTE*)pOutputStream;
for (i = 0; i < VectorCount; i++)
{
XMVECTOR X = _mm_load_ps1(&reinterpret_cast<const XMFLOAT2 *>(pInputVector)->x);
XMVECTOR vResult = _mm_load_ps1(&reinterpret_cast<const XMFLOAT2 *>(pInputVector)->y);
vResult = _mm_mul_ps(vResult,M.r[1]);
X = _mm_mul_ps(X,M.r[0]);
vResult = _mm_add_ps(vResult,X);
_mm_store_sd(reinterpret_cast<double*>(pOutputVector),reinterpret_cast<const __m128d *>(&vResult)[0]);
pInputVector += InputStride;
pOutputVector += OutputStride;
}
return pOutputStream;
#elif defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
#endif // _XM_VMX128_INTRINSICS_
}
/****************************************************************************
*
* 3D Vector
*
****************************************************************************/
//------------------------------------------------------------------------------
// Comparison operations
//------------------------------------------------------------------------------
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector3Equal
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.x == V2.x) && (V1.y == V2.y) && (V1.z == V2.z)) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmpeq_ps(V1,V2);
return (((_mm_movemask_ps(vTemp)&7)==7) != 0);
#else // _XM_VMX128_INTRINSICS_
return XMComparisonAllTrue(XMVector3EqualR(V1, V2));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE UINT XMVector3EqualR
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
UINT CR = 0;
if ((V1.x == V2.x) &&
(V1.y == V2.y) &&
(V1.z == V2.z))
{
CR = XM_CRMASK_CR6TRUE;
}
else if ((V1.x != V2.x) &&
(V1.y != V2.y) &&
(V1.z != V2.z))
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmpeq_ps(V1,V2);
int iTest = _mm_movemask_ps(vTemp)&7;
UINT CR = 0;
if (iTest==7)
{
CR = XM_CRMASK_CR6TRUE;
}
else if (!iTest)
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector3EqualInt
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.u[0] == V2.u[0]) && (V1.u[1] == V2.u[1]) && (V1.u[2] == V2.u[2])) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
__m128i vTemp = _mm_cmpeq_epi32(reinterpret_cast<const __m128i *>(&V1)[0],reinterpret_cast<const __m128i *>(&V2)[0]);
return (((_mm_movemask_ps(reinterpret_cast<const __m128 *>(&vTemp)[0])&7)==7) != 0);
#else // _XM_VMX128_INTRINSICS_
return XMComparisonAllTrue(XMVector3EqualIntR(V1, V2));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE UINT XMVector3EqualIntR
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
UINT CR = 0;
if ((V1.u[0] == V2.u[0]) &&
(V1.u[1] == V2.u[1]) &&
(V1.u[2] == V2.u[2]))
{
CR = XM_CRMASK_CR6TRUE;
}
else if ((V1.u[0] != V2.u[0]) &&
(V1.u[1] != V2.u[1]) &&
(V1.u[2] != V2.u[2]))
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#elif defined(_XM_SSE_INTRINSICS_)
__m128i vTemp = _mm_cmpeq_epi32(reinterpret_cast<const __m128i *>(&V1)[0],reinterpret_cast<const __m128i *>(&V2)[0]);
int iTemp = _mm_movemask_ps(reinterpret_cast<const __m128 *>(&vTemp)[0])&7;
UINT CR = 0;
if (iTemp==7)
{
CR = XM_CRMASK_CR6TRUE;
}
else if (!iTemp)
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector3NearEqual
(
FXMVECTOR V1,
FXMVECTOR V2,
FXMVECTOR Epsilon
)
{
#if defined(_XM_NO_INTRINSICS_)
FLOAT dx, dy, dz;
dx = fabsf(V1.x-V2.x);
dy = fabsf(V1.y-V2.y);
dz = fabsf(V1.z-V2.z);
return (((dx <= Epsilon.x) &&
(dy <= Epsilon.y) &&
(dz <= Epsilon.z)) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
// Get the difference
XMVECTOR vDelta = _mm_sub_ps(V1,V2);
// Get the absolute value of the difference
XMVECTOR vTemp = _mm_setzero_ps();
vTemp = _mm_sub_ps(vTemp,vDelta);
vTemp = _mm_max_ps(vTemp,vDelta);
vTemp = _mm_cmple_ps(vTemp,Epsilon);
// w is don't care
return (((_mm_movemask_ps(vTemp)&7)==0x7) != 0);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector3NotEqual
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.x != V2.x) || (V1.y != V2.y) || (V1.z != V2.z)) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmpeq_ps(V1,V2);
return (((_mm_movemask_ps(vTemp)&7)!=7) != 0);
#else // _XM_VMX128_INTRINSICS_
return XMComparisonAnyFalse(XMVector3EqualR(V1, V2));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector3NotEqualInt
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.u[0] != V2.u[0]) || (V1.u[1] != V2.u[1]) || (V1.u[2] != V2.u[2])) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
__m128i vTemp = _mm_cmpeq_epi32(reinterpret_cast<const __m128i *>(&V1)[0],reinterpret_cast<const __m128i *>(&V2)[0]);
return (((_mm_movemask_ps(reinterpret_cast<const __m128 *>(&vTemp)[0])&7)!=7) != 0);
#else // _XM_VMX128_INTRINSICS_
return XMComparisonAnyFalse(XMVector3EqualIntR(V1, V2));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector3Greater
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.x > V2.x) && (V1.y > V2.y) && (V1.z > V2.z)) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmpgt_ps(V1,V2);
return (((_mm_movemask_ps(vTemp)&7)==7) != 0);
#else // _XM_VMX128_INTRINSICS_
return XMComparisonAllTrue(XMVector3GreaterR(V1, V2));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE UINT XMVector3GreaterR
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
UINT CR = 0;
if ((V1.x > V2.x) &&
(V1.y > V2.y) &&
(V1.z > V2.z))
{
CR = XM_CRMASK_CR6TRUE;
}
else if ((V1.x <= V2.x) &&
(V1.y <= V2.y) &&
(V1.z <= V2.z))
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmpgt_ps(V1,V2);
UINT CR = 0;
int iTest = _mm_movemask_ps(vTemp)&7;
if (iTest==7)
{
CR = XM_CRMASK_CR6TRUE;
}
else if (!iTest)
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector3GreaterOrEqual
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.x >= V2.x) && (V1.y >= V2.y) && (V1.z >= V2.z)) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmpge_ps(V1,V2);
return (((_mm_movemask_ps(vTemp)&7)==7) != 0);
#else // _XM_VMX128_INTRINSICS_
return XMComparisonAllTrue(XMVector3GreaterOrEqualR(V1, V2));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE UINT XMVector3GreaterOrEqualR
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
UINT CR = 0;
if ((V1.x >= V2.x) &&
(V1.y >= V2.y) &&
(V1.z >= V2.z))
{
CR = XM_CRMASK_CR6TRUE;
}
else if ((V1.x < V2.x) &&
(V1.y < V2.y) &&
(V1.z < V2.z))
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmpge_ps(V1,V2);
UINT CR = 0;
int iTest = _mm_movemask_ps(vTemp)&7;
if (iTest==7)
{
CR = XM_CRMASK_CR6TRUE;
}
else if (!iTest)
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector3Less
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.x < V2.x) && (V1.y < V2.y) && (V1.z < V2.z)) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmplt_ps(V1,V2);
return (((_mm_movemask_ps(vTemp)&7)==7) != 0);
#else // _XM_VMX128_INTRINSICS_
return XMComparisonAllTrue(XMVector3GreaterR(V2, V1));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector3LessOrEqual
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.x <= V2.x) && (V1.y <= V2.y) && (V1.z <= V2.z)) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmple_ps(V1,V2);
return (((_mm_movemask_ps(vTemp)&7)==7) != 0);
#else // _XM_VMX128_INTRINSICS_
return XMComparisonAllTrue(XMVector3GreaterOrEqualR(V2, V1));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector3InBounds
(
FXMVECTOR V,
FXMVECTOR Bounds
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V.x <= Bounds.x && V.x >= -Bounds.x) &&
(V.y <= Bounds.y && V.y >= -Bounds.y) &&
(V.z <= Bounds.z && V.z >= -Bounds.z)) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
// Test if less than or equal
XMVECTOR vTemp1 = _mm_cmple_ps(V,Bounds);
// Negate the bounds
XMVECTOR vTemp2 = _mm_mul_ps(Bounds,g_XMNegativeOne);
// Test if greater or equal (Reversed)
vTemp2 = _mm_cmple_ps(vTemp2,V);
// Blend answers
vTemp1 = _mm_and_ps(vTemp1,vTemp2);
// x,y and z in bounds? (w is don't care)
return (((_mm_movemask_ps(vTemp1)&0x7)==0x7) != 0);
#else
return XMComparisonAllInBounds(XMVector3InBoundsR(V, Bounds));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE UINT XMVector3InBoundsR
(
FXMVECTOR V,
FXMVECTOR Bounds
)
{
#if defined(_XM_NO_INTRINSICS_)
UINT CR = 0;
if ((V.x <= Bounds.x && V.x >= -Bounds.x) &&
(V.y <= Bounds.y && V.y >= -Bounds.y) &&
(V.z <= Bounds.z && V.z >= -Bounds.z))
{
CR = XM_CRMASK_CR6BOUNDS;
}
return CR;
#elif defined(_XM_SSE_INTRINSICS_)
// Test if less than or equal
XMVECTOR vTemp1 = _mm_cmple_ps(V,Bounds);
// Negate the bounds
XMVECTOR vTemp2 = _mm_mul_ps(Bounds,g_XMNegativeOne);
// Test if greater or equal (Reversed)
vTemp2 = _mm_cmple_ps(vTemp2,V);
// Blend answers
vTemp1 = _mm_and_ps(vTemp1,vTemp2);
// x,y and z in bounds? (w is don't care)
return ((_mm_movemask_ps(vTemp1)&0x7)==0x7) ? XM_CRMASK_CR6BOUNDS : 0;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector3IsNaN
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
return (XMISNAN(V.x) ||
XMISNAN(V.y) ||
XMISNAN(V.z));
#elif defined(_XM_SSE_INTRINSICS_)
// Mask off the exponent
__m128i vTempInf = _mm_and_si128(reinterpret_cast<const __m128i *>(&V)[0],g_XMInfinity);
// Mask off the mantissa
__m128i vTempNan = _mm_and_si128(reinterpret_cast<const __m128i *>(&V)[0],g_XMQNaNTest);
// Are any of the exponents == 0x7F800000?
vTempInf = _mm_cmpeq_epi32(vTempInf,g_XMInfinity);
// Are any of the mantissa's zero? (SSE2 doesn't have a neq test)
vTempNan = _mm_cmpeq_epi32(vTempNan,g_XMZero);
// Perform a not on the NaN test to be true on NON-zero mantissas
vTempNan = _mm_andnot_si128(vTempNan,vTempInf);
// If x, y or z are NaN, the signs are true after the merge above
return ((_mm_movemask_ps(reinterpret_cast<const __m128 *>(&vTempNan)[0])&7) != 0);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector3IsInfinite
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
return (XMISINF(V.x) ||
XMISINF(V.y) ||
XMISINF(V.z));
#elif defined(_XM_SSE_INTRINSICS_)
// Mask off the sign bit
__m128 vTemp = _mm_and_ps(V,g_XMAbsMask);
// Compare to infinity
vTemp = _mm_cmpeq_ps(vTemp,g_XMInfinity);
// If x,y or z are infinity, the signs are true.
return ((_mm_movemask_ps(vTemp)&7) != 0);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Computation operations
//------------------------------------------------------------------------------
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector3Dot
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
FLOAT fValue = V1.x * V2.x + V1.y * V2.y + V1.z * V2.z;
XMVECTOR vResult = {
fValue,
fValue,
fValue,
fValue
};
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
// Perform the dot product
XMVECTOR vDot = _mm_mul_ps(V1,V2);
// x=Dot.y, y=Dot.z
XMVECTOR vTemp = _mm_shuffle_ps(vDot,vDot,_MM_SHUFFLE(2,1,2,1));
// Result.x = x+y
vDot = _mm_add_ss(vDot,vTemp);
// x=Dot.z
vTemp = _mm_shuffle_ps(vTemp,vTemp,_MM_SHUFFLE(1,1,1,1));
// Result.x = (x+y)+z
vDot = _mm_add_ss(vDot,vTemp);
// Splat x
return _mm_shuffle_ps(vDot,vDot,_MM_SHUFFLE(0,0,0,0));
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector3Cross
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR vResult = {
(V1.y * V2.z) - (V1.z * V2.y),
(V1.z * V2.x) - (V1.x * V2.z),
(V1.x * V2.y) - (V1.y * V2.x),
0.0f
};
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
// y1,z1,x1,w1
XMVECTOR vTemp1 = _mm_shuffle_ps(V1,V1,_MM_SHUFFLE(3,0,2,1));
// z2,x2,y2,w2
XMVECTOR vTemp2 = _mm_shuffle_ps(V2,V2,_MM_SHUFFLE(3,1,0,2));
// Perform the left operation
XMVECTOR vResult = _mm_mul_ps(vTemp1,vTemp2);
// z1,x1,y1,w1
vTemp1 = _mm_shuffle_ps(vTemp1,vTemp1,_MM_SHUFFLE(3,0,2,1));
// y2,z2,x2,w2
vTemp2 = _mm_shuffle_ps(vTemp2,vTemp2,_MM_SHUFFLE(3,1,0,2));
// Perform the right operation
vTemp1 = _mm_mul_ps(vTemp1,vTemp2);
// Subract the right from left, and return answer
vResult = _mm_sub_ps(vResult,vTemp1);
// Set w to zero
return _mm_and_ps(vResult,g_XMMask3);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector3LengthSq
(
FXMVECTOR V
)
{
return XMVector3Dot(V, V);
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector3ReciprocalLengthEst
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result = XMVector3LengthSq(V);
Result = XMVectorReciprocalSqrtEst(Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Perform the dot product on x,y and z
XMVECTOR vLengthSq = _mm_mul_ps(V,V);
// vTemp has z and y
XMVECTOR vTemp = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(1,2,1,2));
// x+z, y
vLengthSq = _mm_add_ss(vLengthSq,vTemp);
// y,y,y,y
vTemp = _mm_shuffle_ps(vTemp,vTemp,_MM_SHUFFLE(1,1,1,1));
// x+z+y,??,??,??
vLengthSq = _mm_add_ss(vLengthSq,vTemp);
// Splat the length squared
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(0,0,0,0));
// Get the reciprocal
vLengthSq = _mm_rsqrt_ps(vLengthSq);
return vLengthSq;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector3ReciprocalLength
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result = XMVector3LengthSq(V);
Result = XMVectorReciprocalSqrt(Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Perform the dot product
XMVECTOR vDot = _mm_mul_ps(V,V);
// x=Dot.y, y=Dot.z
XMVECTOR vTemp = _mm_shuffle_ps(vDot,vDot,_MM_SHUFFLE(2,1,2,1));
// Result.x = x+y
vDot = _mm_add_ss(vDot,vTemp);
// x=Dot.z
vTemp = _mm_shuffle_ps(vTemp,vTemp,_MM_SHUFFLE(1,1,1,1));
// Result.x = (x+y)+z
vDot = _mm_add_ss(vDot,vTemp);
// Splat x
vDot = _mm_shuffle_ps(vDot,vDot,_MM_SHUFFLE(0,0,0,0));
// Get the reciprocal
vDot = _mm_sqrt_ps(vDot);
// Get the reciprocal
vDot = _mm_div_ps(g_XMOne,vDot);
return vDot;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector3LengthEst
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result = XMVector3LengthSq(V);
Result = XMVectorSqrtEst(Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Perform the dot product on x,y and z
XMVECTOR vLengthSq = _mm_mul_ps(V,V);
// vTemp has z and y
XMVECTOR vTemp = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(1,2,1,2));
// x+z, y
vLengthSq = _mm_add_ss(vLengthSq,vTemp);
// y,y,y,y
vTemp = _mm_shuffle_ps(vTemp,vTemp,_MM_SHUFFLE(1,1,1,1));
// x+z+y,??,??,??
vLengthSq = _mm_add_ss(vLengthSq,vTemp);
// Splat the length squared
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(0,0,0,0));
// Get the length
vLengthSq = _mm_sqrt_ps(vLengthSq);
return vLengthSq;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector3Length
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result = XMVector3LengthSq(V);
Result = XMVectorSqrt(Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Perform the dot product on x,y and z
XMVECTOR vLengthSq = _mm_mul_ps(V,V);
// vTemp has z and y
XMVECTOR vTemp = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(1,2,1,2));
// x+z, y
vLengthSq = _mm_add_ss(vLengthSq,vTemp);
// y,y,y,y
vTemp = _mm_shuffle_ps(vTemp,vTemp,_MM_SHUFFLE(1,1,1,1));
// x+z+y,??,??,??
vLengthSq = _mm_add_ss(vLengthSq,vTemp);
// Splat the length squared
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(0,0,0,0));
// Get the length
vLengthSq = _mm_sqrt_ps(vLengthSq);
return vLengthSq;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// XMVector3NormalizeEst uses a reciprocal estimate and
// returns QNaN on zero and infinite vectors.
XMFINLINE XMVECTOR XMVector3NormalizeEst
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result = XMVector3ReciprocalLength(V);
Result = XMVectorMultiply(V, Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Perform the dot product
XMVECTOR vDot = _mm_mul_ps(V,V);
// x=Dot.y, y=Dot.z
XMVECTOR vTemp = _mm_shuffle_ps(vDot,vDot,_MM_SHUFFLE(2,1,2,1));
// Result.x = x+y
vDot = _mm_add_ss(vDot,vTemp);
// x=Dot.z
vTemp = _mm_shuffle_ps(vTemp,vTemp,_MM_SHUFFLE(1,1,1,1));
// Result.x = (x+y)+z
vDot = _mm_add_ss(vDot,vTemp);
// Splat x
vDot = _mm_shuffle_ps(vDot,vDot,_MM_SHUFFLE(0,0,0,0));
// Get the reciprocal
vDot = _mm_rsqrt_ps(vDot);
// Perform the normalization
vDot = _mm_mul_ps(vDot,V);
return vDot;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector3Normalize
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
FLOAT fLengthSq;
XMVECTOR vResult;
fLengthSq = sqrtf((V.x*V.x)+(V.y*V.y)+(V.z*V.z));
// Prevent divide by zero
if (fLengthSq) {
fLengthSq = 1.0f/fLengthSq;
}
vResult.x = V.x*fLengthSq;
vResult.y = V.y*fLengthSq;
vResult.z = V.z*fLengthSq;
vResult.w = V.w*fLengthSq;
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
// Perform the dot product on x,y and z only
XMVECTOR vLengthSq = _mm_mul_ps(V,V);
XMVECTOR vTemp = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(2,1,2,1));
vLengthSq = _mm_add_ss(vLengthSq,vTemp);
vTemp = _mm_shuffle_ps(vTemp,vTemp,_MM_SHUFFLE(1,1,1,1));
vLengthSq = _mm_add_ss(vLengthSq,vTemp);
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(0,0,0,0));
// Prepare for the division
XMVECTOR vResult = _mm_sqrt_ps(vLengthSq);
// Failsafe on zero (Or epsilon) length planes
// If the length is infinity, set the elements to zero
vLengthSq = _mm_cmpneq_ps(vLengthSq,g_XMInfinity);
// Divide to perform the normalization
vResult = _mm_div_ps(V,vResult);
// Any that are infinity, set to zero
vResult = _mm_and_ps(vResult,vLengthSq);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector3ClampLength
(
FXMVECTOR V,
FLOAT LengthMin,
FLOAT LengthMax
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR ClampMax;
XMVECTOR ClampMin;
ClampMax = XMVectorReplicate(LengthMax);
ClampMin = XMVectorReplicate(LengthMin);
return XMVector3ClampLengthV(V, ClampMin, ClampMax);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR ClampMax = _mm_set_ps1(LengthMax);
XMVECTOR ClampMin = _mm_set_ps1(LengthMin);
return XMVector3ClampLengthV(V,ClampMin,ClampMax);
#elif defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector3ClampLengthV
(
FXMVECTOR V,
FXMVECTOR LengthMin,
FXMVECTOR LengthMax
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR ClampLength;
XMVECTOR LengthSq;
XMVECTOR RcpLength;
XMVECTOR Length;
XMVECTOR Normal;
XMVECTOR Zero;
XMVECTOR InfiniteLength;
XMVECTOR ZeroLength;
XMVECTOR Select;
XMVECTOR ControlMax;
XMVECTOR ControlMin;
XMVECTOR Control;
XMVECTOR Result;
XMASSERT((LengthMin.y == LengthMin.x) && (LengthMin.z == LengthMin.x));
XMASSERT((LengthMax.y == LengthMax.x) && (LengthMax.z == LengthMax.x));
XMASSERT(XMVector3GreaterOrEqual(LengthMin, XMVectorZero()));
XMASSERT(XMVector3GreaterOrEqual(LengthMax, XMVectorZero()));
XMASSERT(XMVector3GreaterOrEqual(LengthMax, LengthMin));
LengthSq = XMVector3LengthSq(V);
Zero = XMVectorZero();
RcpLength = XMVectorReciprocalSqrt(LengthSq);
InfiniteLength = XMVectorEqualInt(LengthSq, g_XMInfinity.v);
ZeroLength = XMVectorEqual(LengthSq, Zero);
Normal = XMVectorMultiply(V, RcpLength);
Length = XMVectorMultiply(LengthSq, RcpLength);
Select = XMVectorEqualInt(InfiniteLength, ZeroLength);
Length = XMVectorSelect(LengthSq, Length, Select);
Normal = XMVectorSelect(LengthSq, Normal, Select);
ControlMax = XMVectorGreater(Length, LengthMax);
ControlMin = XMVectorLess(Length, LengthMin);
ClampLength = XMVectorSelect(Length, LengthMax, ControlMax);
ClampLength = XMVectorSelect(ClampLength, LengthMin, ControlMin);
Result = XMVectorMultiply(Normal, ClampLength);
// Preserve the original vector (with no precision loss) if the length falls within the given range
Control = XMVectorEqualInt(ControlMax, ControlMin);
Result = XMVectorSelect(Result, V, Control);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR ClampLength;
XMVECTOR LengthSq;
XMVECTOR RcpLength;
XMVECTOR Length;
XMVECTOR Normal;
XMVECTOR InfiniteLength;
XMVECTOR ZeroLength;
XMVECTOR Select;
XMVECTOR ControlMax;
XMVECTOR ControlMin;
XMVECTOR Control;
XMVECTOR Result;
XMASSERT((XMVectorGetY(LengthMin) == XMVectorGetX(LengthMin)) && (XMVectorGetZ(LengthMin) == XMVectorGetX(LengthMin)));
XMASSERT((XMVectorGetY(LengthMax) == XMVectorGetX(LengthMax)) && (XMVectorGetZ(LengthMax) == XMVectorGetX(LengthMax)));
XMASSERT(XMVector3GreaterOrEqual(LengthMin, g_XMZero));
XMASSERT(XMVector3GreaterOrEqual(LengthMax, g_XMZero));
XMASSERT(XMVector3GreaterOrEqual(LengthMax, LengthMin));
LengthSq = XMVector3LengthSq(V);
RcpLength = XMVectorReciprocalSqrt(LengthSq);
InfiniteLength = XMVectorEqualInt(LengthSq, g_XMInfinity);
ZeroLength = XMVectorEqual(LengthSq,g_XMZero);
Normal = _mm_mul_ps(V, RcpLength);
Length = _mm_mul_ps(LengthSq, RcpLength);
Select = XMVectorEqualInt(InfiniteLength, ZeroLength);
Length = XMVectorSelect(LengthSq, Length, Select);
Normal = XMVectorSelect(LengthSq, Normal, Select);
ControlMax = XMVectorGreater(Length, LengthMax);
ControlMin = XMVectorLess(Length, LengthMin);
ClampLength = XMVectorSelect(Length, LengthMax, ControlMax);
ClampLength = XMVectorSelect(ClampLength, LengthMin, ControlMin);
Result = _mm_mul_ps(Normal, ClampLength);
// Preserve the original vector (with no precision loss) if the length falls within the given range
Control = XMVectorEqualInt(ControlMax, ControlMin);
Result = XMVectorSelect(Result, V, Control);
return Result;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector3Reflect
(
FXMVECTOR Incident,
FXMVECTOR Normal
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
// Result = Incident - (2 * dot(Incident, Normal)) * Normal
Result = XMVector3Dot(Incident, Normal);
Result = XMVectorAdd(Result, Result);
Result = XMVectorNegativeMultiplySubtract(Result, Normal, Incident);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Result = Incident - (2 * dot(Incident, Normal)) * Normal
XMVECTOR Result = XMVector3Dot(Incident, Normal);
Result = _mm_add_ps(Result, Result);
Result = _mm_mul_ps(Result, Normal);
Result = _mm_sub_ps(Incident,Result);
return Result;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector3Refract
(
FXMVECTOR Incident,
FXMVECTOR Normal,
FLOAT RefractionIndex
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Index;
Index = XMVectorReplicate(RefractionIndex);
return XMVector3RefractV(Incident, Normal, Index);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR Index = _mm_set_ps1(RefractionIndex);
return XMVector3RefractV(Incident,Normal,Index);
#elif defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector3RefractV
(
FXMVECTOR Incident,
FXMVECTOR Normal,
FXMVECTOR RefractionIndex
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR IDotN;
XMVECTOR R;
CONST XMVECTOR Zero = XMVectorZero();
// Result = RefractionIndex * Incident - Normal * (RefractionIndex * dot(Incident, Normal) +
// sqrt(1 - RefractionIndex * RefractionIndex * (1 - dot(Incident, Normal) * dot(Incident, Normal))))
IDotN = XMVector3Dot(Incident, Normal);
// R = 1.0f - RefractionIndex * RefractionIndex * (1.0f - IDotN * IDotN)
R = XMVectorNegativeMultiplySubtract(IDotN, IDotN, g_XMOne.v);
R = XMVectorMultiply(R, RefractionIndex);
R = XMVectorNegativeMultiplySubtract(R, RefractionIndex, g_XMOne.v);
if (XMVector4LessOrEqual(R, Zero))
{
// Total internal reflection
return Zero;
}
else
{
XMVECTOR Result;
// R = RefractionIndex * IDotN + sqrt(R)
R = XMVectorSqrt(R);
R = XMVectorMultiplyAdd(RefractionIndex, IDotN, R);
// Result = RefractionIndex * Incident - Normal * R
Result = XMVectorMultiply(RefractionIndex, Incident);
Result = XMVectorNegativeMultiplySubtract(Normal, R, Result);
return Result;
}
#elif defined(_XM_SSE_INTRINSICS_)
// Result = RefractionIndex * Incident - Normal * (RefractionIndex * dot(Incident, Normal) +
// sqrt(1 - RefractionIndex * RefractionIndex * (1 - dot(Incident, Normal) * dot(Incident, Normal))))
XMVECTOR IDotN = XMVector3Dot(Incident, Normal);
// R = 1.0f - RefractionIndex * RefractionIndex * (1.0f - IDotN * IDotN)
XMVECTOR R = _mm_mul_ps(IDotN, IDotN);
R = _mm_sub_ps(g_XMOne,R);
R = _mm_mul_ps(R, RefractionIndex);
R = _mm_mul_ps(R, RefractionIndex);
R = _mm_sub_ps(g_XMOne,R);
XMVECTOR vResult = _mm_cmple_ps(R,g_XMZero);
if (_mm_movemask_ps(vResult)==0x0f)
{
// Total internal reflection
vResult = g_XMZero;
}
else
{
// R = RefractionIndex * IDotN + sqrt(R)
R = _mm_sqrt_ps(R);
vResult = _mm_mul_ps(RefractionIndex,IDotN);
R = _mm_add_ps(R,vResult);
// Result = RefractionIndex * Incident - Normal * R
vResult = _mm_mul_ps(RefractionIndex, Incident);
R = _mm_mul_ps(R,Normal);
vResult = _mm_sub_ps(vResult,R);
}
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector3Orthogonal
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR NegativeV;
XMVECTOR Z, YZYY;
XMVECTOR ZIsNegative, YZYYIsNegative;
XMVECTOR S, D;
XMVECTOR R0, R1;
XMVECTOR Select;
XMVECTOR Zero;
XMVECTOR Result;
static CONST XMVECTORU32 Permute1X0X0X0X = {XM_PERMUTE_1X, XM_PERMUTE_0X, XM_PERMUTE_0X, XM_PERMUTE_0X};
static CONST XMVECTORU32 Permute0Y0Z0Y0Y= {XM_PERMUTE_0Y, XM_PERMUTE_0Z, XM_PERMUTE_0Y, XM_PERMUTE_0Y};
Zero = XMVectorZero();
Z = XMVectorSplatZ(V);
YZYY = XMVectorPermute(V, V, Permute0Y0Z0Y0Y.v);
NegativeV = XMVectorSubtract(Zero, V);
ZIsNegative = XMVectorLess(Z, Zero);
YZYYIsNegative = XMVectorLess(YZYY, Zero);
S = XMVectorAdd(YZYY, Z);
D = XMVectorSubtract(YZYY, Z);
Select = XMVectorEqualInt(ZIsNegative, YZYYIsNegative);
R0 = XMVectorPermute(NegativeV, S, Permute1X0X0X0X.v);
R1 = XMVectorPermute(V, D, Permute1X0X0X0X.v);
Result = XMVectorSelect(R1, R0, Select);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR NegativeV;
XMVECTOR Z, YZYY;
XMVECTOR ZIsNegative, YZYYIsNegative;
XMVECTOR S, D;
XMVECTOR R0, R1;
XMVECTOR Select;
XMVECTOR Zero;
XMVECTOR Result;
static CONST XMVECTORI32 Permute1X0X0X0X = {XM_PERMUTE_1X, XM_PERMUTE_0X, XM_PERMUTE_0X, XM_PERMUTE_0X};
static CONST XMVECTORI32 Permute0Y0Z0Y0Y= {XM_PERMUTE_0Y, XM_PERMUTE_0Z, XM_PERMUTE_0Y, XM_PERMUTE_0Y};
Zero = XMVectorZero();
Z = XMVectorSplatZ(V);
YZYY = XMVectorPermute(V, V, Permute0Y0Z0Y0Y);
NegativeV = _mm_sub_ps(Zero, V);
ZIsNegative = XMVectorLess(Z, Zero);
YZYYIsNegative = XMVectorLess(YZYY, Zero);
S = _mm_add_ps(YZYY, Z);
D = _mm_sub_ps(YZYY, Z);
Select = XMVectorEqualInt(ZIsNegative, YZYYIsNegative);
R0 = XMVectorPermute(NegativeV, S, Permute1X0X0X0X);
R1 = XMVectorPermute(V, D,Permute1X0X0X0X);
Result = XMVectorSelect(R1, R0, Select);
return Result;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector3AngleBetweenNormalsEst
(
FXMVECTOR N1,
FXMVECTOR N2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
XMVECTOR NegativeOne;
XMVECTOR One;
Result = XMVector3Dot(N1, N2);
NegativeOne = XMVectorSplatConstant(-1, 0);
One = XMVectorSplatOne();
Result = XMVectorClamp(Result, NegativeOne, One);
Result = XMVectorACosEst(Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = XMVector3Dot(N1,N2);
// Clamp to -1.0f to 1.0f
vResult = _mm_max_ps(vResult,g_XMNegativeOne);
vResult = _mm_min_ps(vResult,g_XMOne);
vResult = XMVectorACosEst(vResult);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector3AngleBetweenNormals
(
FXMVECTOR N1,
FXMVECTOR N2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
XMVECTOR NegativeOne;
XMVECTOR One;
Result = XMVector3Dot(N1, N2);
NegativeOne = XMVectorSplatConstant(-1, 0);
One = XMVectorSplatOne();
Result = XMVectorClamp(Result, NegativeOne, One);
Result = XMVectorACos(Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = XMVector3Dot(N1,N2);
// Clamp to -1.0f to 1.0f
vResult = _mm_max_ps(vResult,g_XMNegativeOne);
vResult = _mm_min_ps(vResult,g_XMOne);
vResult = XMVectorACos(vResult);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector3AngleBetweenVectors
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR L1;
XMVECTOR L2;
XMVECTOR Dot;
XMVECTOR CosAngle;
XMVECTOR NegativeOne;
XMVECTOR One;
XMVECTOR Result;
L1 = XMVector3ReciprocalLength(V1);
L2 = XMVector3ReciprocalLength(V2);
Dot = XMVector3Dot(V1, V2);
L1 = XMVectorMultiply(L1, L2);
NegativeOne = XMVectorSplatConstant(-1, 0);
One = XMVectorSplatOne();
CosAngle = XMVectorMultiply(Dot, L1);
CosAngle = XMVectorClamp(CosAngle, NegativeOne, One);
Result = XMVectorACos(CosAngle);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR L1;
XMVECTOR L2;
XMVECTOR Dot;
XMVECTOR CosAngle;
XMVECTOR Result;
L1 = XMVector3ReciprocalLength(V1);
L2 = XMVector3ReciprocalLength(V2);
Dot = XMVector3Dot(V1, V2);
L1 = _mm_mul_ps(L1, L2);
CosAngle = _mm_mul_ps(Dot, L1);
CosAngle = XMVectorClamp(CosAngle,g_XMNegativeOne,g_XMOne);
Result = XMVectorACos(CosAngle);
return Result;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector3LinePointDistance
(
FXMVECTOR LinePoint1,
FXMVECTOR LinePoint2,
FXMVECTOR Point
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR PointVector;
XMVECTOR LineVector;
XMVECTOR ReciprocalLengthSq;
XMVECTOR PointProjectionScale;
XMVECTOR DistanceVector;
XMVECTOR Result;
// Given a vector PointVector from LinePoint1 to Point and a vector
// LineVector from LinePoint1 to LinePoint2, the scaled distance
// PointProjectionScale from LinePoint1 to the perpendicular projection
// of PointVector onto the line is defined as:
//
// PointProjectionScale = dot(PointVector, LineVector) / LengthSq(LineVector)
PointVector = XMVectorSubtract(Point, LinePoint1);
LineVector = XMVectorSubtract(LinePoint2, LinePoint1);
ReciprocalLengthSq = XMVector3LengthSq(LineVector);
ReciprocalLengthSq = XMVectorReciprocal(ReciprocalLengthSq);
PointProjectionScale = XMVector3Dot(PointVector, LineVector);
PointProjectionScale = XMVectorMultiply(PointProjectionScale, ReciprocalLengthSq);
DistanceVector = XMVectorMultiply(LineVector, PointProjectionScale);
DistanceVector = XMVectorSubtract(PointVector, DistanceVector);
Result = XMVector3Length(DistanceVector);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR PointVector = _mm_sub_ps(Point,LinePoint1);
XMVECTOR LineVector = _mm_sub_ps(LinePoint2,LinePoint1);
XMVECTOR ReciprocalLengthSq = XMVector3LengthSq(LineVector);
XMVECTOR vResult = XMVector3Dot(PointVector,LineVector);
vResult = _mm_div_ps(vResult,ReciprocalLengthSq);
vResult = _mm_mul_ps(vResult,LineVector);
vResult = _mm_sub_ps(PointVector,vResult);
vResult = XMVector3Length(vResult);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE VOID XMVector3ComponentsFromNormal
(
XMVECTOR* pParallel,
XMVECTOR* pPerpendicular,
FXMVECTOR V,
FXMVECTOR Normal
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Parallel;
XMVECTOR Scale;
XMASSERT(pParallel);
XMASSERT(pPerpendicular);
Scale = XMVector3Dot(V, Normal);
Parallel = XMVectorMultiply(Normal, Scale);
*pParallel = Parallel;
*pPerpendicular = XMVectorSubtract(V, Parallel);
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT(pParallel);
XMASSERT(pPerpendicular);
XMVECTOR Scale = XMVector3Dot(V, Normal);
XMVECTOR Parallel = _mm_mul_ps(Normal,Scale);
*pParallel = Parallel;
*pPerpendicular = _mm_sub_ps(V,Parallel);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Transform a vector using a rotation expressed as a unit quaternion
XMFINLINE XMVECTOR XMVector3Rotate
(
FXMVECTOR V,
FXMVECTOR RotationQuaternion
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR A;
XMVECTOR Q;
XMVECTOR Result;
A = XMVectorSelect(g_XMSelect1110.v, V, g_XMSelect1110.v);
Q = XMQuaternionConjugate(RotationQuaternion);
Result = XMQuaternionMultiply(Q, A);
Result = XMQuaternionMultiply(Result, RotationQuaternion);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR A;
XMVECTOR Q;
XMVECTOR Result;
A = _mm_and_ps(V,g_XMMask3);
Q = XMQuaternionConjugate(RotationQuaternion);
Result = XMQuaternionMultiply(Q, A);
Result = XMQuaternionMultiply(Result, RotationQuaternion);
return Result;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Transform a vector using the inverse of a rotation expressed as a unit quaternion
XMFINLINE XMVECTOR XMVector3InverseRotate
(
FXMVECTOR V,
FXMVECTOR RotationQuaternion
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR A;
XMVECTOR Q;
XMVECTOR Result;
A = XMVectorSelect(g_XMSelect1110.v, V, g_XMSelect1110.v);
Result = XMQuaternionMultiply(RotationQuaternion, A);
Q = XMQuaternionConjugate(RotationQuaternion);
Result = XMQuaternionMultiply(Result, Q);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR A;
XMVECTOR Q;
XMVECTOR Result;
A = _mm_and_ps(V,g_XMMask3);
Result = XMQuaternionMultiply(RotationQuaternion, A);
Q = XMQuaternionConjugate(RotationQuaternion);
Result = XMQuaternionMultiply(Result, Q);
return Result;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector3Transform
(
FXMVECTOR V,
CXMMATRIX M
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR X;
XMVECTOR Y;
XMVECTOR Z;
XMVECTOR Result;
Z = XMVectorSplatZ(V);
Y = XMVectorSplatY(V);
X = XMVectorSplatX(V);
Result = XMVectorMultiplyAdd(Z, M.r[2], M.r[3]);
Result = XMVectorMultiplyAdd(Y, M.r[1], Result);
Result = XMVectorMultiplyAdd(X, M.r[0], Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(0,0,0,0));
vResult = _mm_mul_ps(vResult,M.r[0]);
XMVECTOR vTemp = _mm_shuffle_ps(V,V,_MM_SHUFFLE(1,1,1,1));
vTemp = _mm_mul_ps(vTemp,M.r[1]);
vResult = _mm_add_ps(vResult,vTemp);
vTemp = _mm_shuffle_ps(V,V,_MM_SHUFFLE(2,2,2,2));
vTemp = _mm_mul_ps(vTemp,M.r[2]);
vResult = _mm_add_ps(vResult,vTemp);
vResult = _mm_add_ps(vResult,M.r[3]);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMFLOAT4* XMVector3TransformStream
(
XMFLOAT4* pOutputStream,
UINT OutputStride,
CONST XMFLOAT3* pInputStream,
UINT InputStride,
UINT VectorCount,
CXMMATRIX M
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR V;
XMVECTOR X;
XMVECTOR Y;
XMVECTOR Z;
XMVECTOR Result;
UINT i;
BYTE* pInputVector = (BYTE*)pInputStream;
BYTE* pOutputVector = (BYTE*)pOutputStream;
XMASSERT(pOutputStream);
XMASSERT(pInputStream);
for (i = 0; i < VectorCount; i++)
{
V = XMLoadFloat3((XMFLOAT3*)pInputVector);
Z = XMVectorSplatZ(V);
Y = XMVectorSplatY(V);
X = XMVectorSplatX(V);
Result = XMVectorMultiplyAdd(Z, M.r[2], M.r[3]);
Result = XMVectorMultiplyAdd(Y, M.r[1], Result);
Result = XMVectorMultiplyAdd(X, M.r[0], Result);
XMStoreFloat4((XMFLOAT4*)pOutputVector, Result);
pInputVector += InputStride;
pOutputVector += OutputStride;
}
return pOutputStream;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT(pOutputStream);
XMASSERT(pInputStream);
UINT i;
const BYTE* pInputVector = (const BYTE*)pInputStream;
BYTE* pOutputVector = (BYTE*)pOutputStream;
for (i = 0; i < VectorCount; i++)
{
XMVECTOR X = _mm_load_ps1(&reinterpret_cast<const XMFLOAT3 *>(pInputVector)->x);
XMVECTOR Y = _mm_load_ps1(&reinterpret_cast<const XMFLOAT3 *>(pInputVector)->y);
XMVECTOR vResult = _mm_load_ps1(&reinterpret_cast<const XMFLOAT3 *>(pInputVector)->z);
vResult = _mm_mul_ps(vResult,M.r[2]);
vResult = _mm_add_ps(vResult,M.r[3]);
Y = _mm_mul_ps(Y,M.r[1]);
vResult = _mm_add_ps(vResult,Y);
X = _mm_mul_ps(X,M.r[0]);
vResult = _mm_add_ps(vResult,X);
_mm_storeu_ps(reinterpret_cast<float *>(pOutputVector),vResult);
pInputVector += InputStride;
pOutputVector += OutputStride;
}
return pOutputStream;
#elif defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMFLOAT4* XMVector3TransformStreamNC
(
XMFLOAT4* pOutputStream,
UINT OutputStride,
CONST XMFLOAT3* pInputStream,
UINT InputStride,
UINT VectorCount,
CXMMATRIX M
)
{
#if defined(_XM_NO_INTRINSICS_) || defined(XM_NO_MISALIGNED_VECTOR_ACCESS) || defined(_XM_SSE_INTRINSICS_)
return XMVector3TransformStream( pOutputStream, OutputStride, pInputStream, InputStride, VectorCount, M );
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector3TransformCoord
(
FXMVECTOR V,
CXMMATRIX M
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR X;
XMVECTOR Y;
XMVECTOR Z;
XMVECTOR InverseW;
XMVECTOR Result;
Z = XMVectorSplatZ(V);
Y = XMVectorSplatY(V);
X = XMVectorSplatX(V);
Result = XMVectorMultiplyAdd(Z, M.r[2], M.r[3]);
Result = XMVectorMultiplyAdd(Y, M.r[1], Result);
Result = XMVectorMultiplyAdd(X, M.r[0], Result);
InverseW = XMVectorSplatW(Result);
InverseW = XMVectorReciprocal(InverseW);
Result = XMVectorMultiply(Result, InverseW);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(0,0,0,0));
vResult = _mm_mul_ps(vResult,M.r[0]);
XMVECTOR vTemp = _mm_shuffle_ps(V,V,_MM_SHUFFLE(1,1,1,1));
vTemp = _mm_mul_ps(vTemp,M.r[1]);
vResult = _mm_add_ps(vResult,vTemp);
vTemp = _mm_shuffle_ps(V,V,_MM_SHUFFLE(2,2,2,2));
vTemp = _mm_mul_ps(vTemp,M.r[2]);
vResult = _mm_add_ps(vResult,vTemp);
vResult = _mm_add_ps(vResult,M.r[3]);
vTemp = _mm_shuffle_ps(vResult,vResult,_MM_SHUFFLE(3,3,3,3));
vResult = _mm_div_ps(vResult,vTemp);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMFLOAT3* XMVector3TransformCoordStream
(
XMFLOAT3* pOutputStream,
UINT OutputStride,
CONST XMFLOAT3* pInputStream,
UINT InputStride,
UINT VectorCount,
CXMMATRIX M
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR V;
XMVECTOR X;
XMVECTOR Y;
XMVECTOR Z;
XMVECTOR InverseW;
XMVECTOR Result;
UINT i;
BYTE* pInputVector = (BYTE*)pInputStream;
BYTE* pOutputVector = (BYTE*)pOutputStream;
XMASSERT(pOutputStream);
XMASSERT(pInputStream);
for (i = 0; i < VectorCount; i++)
{
V = XMLoadFloat3((XMFLOAT3*)pInputVector);
Z = XMVectorSplatZ(V);
Y = XMVectorSplatY(V);
X = XMVectorSplatX(V);
// Z = XMVectorReplicate(((XMFLOAT3*)pInputVector)->z);
// Y = XMVectorReplicate(((XMFLOAT3*)pInputVector)->y);
// X = XMVectorReplicate(((XMFLOAT3*)pInputVector)->x);
Result = XMVectorMultiplyAdd(Z, M.r[2], M.r[3]);
Result = XMVectorMultiplyAdd(Y, M.r[1], Result);
Result = XMVectorMultiplyAdd(X, M.r[0], Result);
InverseW = XMVectorSplatW(Result);
InverseW = XMVectorReciprocal(InverseW);
Result = XMVectorMultiply(Result, InverseW);
XMStoreFloat3((XMFLOAT3*)pOutputVector, Result);
pInputVector += InputStride;
pOutputVector += OutputStride;
}
return pOutputStream;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT(pOutputStream);
XMASSERT(pInputStream);
UINT i;
const BYTE *pInputVector = (BYTE*)pInputStream;
BYTE *pOutputVector = (BYTE*)pOutputStream;
for (i = 0; i < VectorCount; i++)
{
XMVECTOR X = _mm_load_ps1(&reinterpret_cast<const XMFLOAT3 *>(pInputVector)->x);
XMVECTOR Y = _mm_load_ps1(&reinterpret_cast<const XMFLOAT3 *>(pInputVector)->y);
XMVECTOR vResult = _mm_load_ps1(&reinterpret_cast<const XMFLOAT3 *>(pInputVector)->z);
vResult = _mm_mul_ps(vResult,M.r[2]);
vResult = _mm_add_ps(vResult,M.r[3]);
Y = _mm_mul_ps(Y,M.r[1]);
vResult = _mm_add_ps(vResult,Y);
X = _mm_mul_ps(X,M.r[0]);
vResult = _mm_add_ps(vResult,X);
X = _mm_shuffle_ps(vResult,vResult,_MM_SHUFFLE(3,3,3,3));
vResult = _mm_div_ps(vResult,X);
_mm_store_ss(&reinterpret_cast<XMFLOAT3 *>(pOutputVector)->x,vResult);
vResult = _mm_shuffle_ps(vResult,vResult,_MM_SHUFFLE(0,3,2,1));
_mm_store_ss(&reinterpret_cast<XMFLOAT3 *>(pOutputVector)->y,vResult);
vResult = _mm_shuffle_ps(vResult,vResult,_MM_SHUFFLE(0,3,2,1));
_mm_store_ss(&reinterpret_cast<XMFLOAT3 *>(pOutputVector)->z,vResult);
pInputVector += InputStride;
pOutputVector += OutputStride;
}
return pOutputStream;
#elif defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector3TransformNormal
(
FXMVECTOR V,
CXMMATRIX M
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR X;
XMVECTOR Y;
XMVECTOR Z;
XMVECTOR Result;
Z = XMVectorSplatZ(V);
Y = XMVectorSplatY(V);
X = XMVectorSplatX(V);
Result = XMVectorMultiply(Z, M.r[2]);
Result = XMVectorMultiplyAdd(Y, M.r[1], Result);
Result = XMVectorMultiplyAdd(X, M.r[0], Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(0,0,0,0));
vResult = _mm_mul_ps(vResult,M.r[0]);
XMVECTOR vTemp = _mm_shuffle_ps(V,V,_MM_SHUFFLE(1,1,1,1));
vTemp = _mm_mul_ps(vTemp,M.r[1]);
vResult = _mm_add_ps(vResult,vTemp);
vTemp = _mm_shuffle_ps(V,V,_MM_SHUFFLE(2,2,2,2));
vTemp = _mm_mul_ps(vTemp,M.r[2]);
vResult = _mm_add_ps(vResult,vTemp);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMFLOAT3* XMVector3TransformNormalStream
(
XMFLOAT3* pOutputStream,
UINT OutputStride,
CONST XMFLOAT3* pInputStream,
UINT InputStride,
UINT VectorCount,
CXMMATRIX M
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR V;
XMVECTOR X;
XMVECTOR Y;
XMVECTOR Z;
XMVECTOR Result;
UINT i;
BYTE* pInputVector = (BYTE*)pInputStream;
BYTE* pOutputVector = (BYTE*)pOutputStream;
XMASSERT(pOutputStream);
XMASSERT(pInputStream);
for (i = 0; i < VectorCount; i++)
{
V = XMLoadFloat3((XMFLOAT3*)pInputVector);
Z = XMVectorSplatZ(V);
Y = XMVectorSplatY(V);
X = XMVectorSplatX(V);
// Z = XMVectorReplicate(((XMFLOAT3*)pInputVector)->z);
// Y = XMVectorReplicate(((XMFLOAT3*)pInputVector)->y);
// X = XMVectorReplicate(((XMFLOAT3*)pInputVector)->x);
Result = XMVectorMultiply(Z, M.r[2]);
Result = XMVectorMultiplyAdd(Y, M.r[1], Result);
Result = XMVectorMultiplyAdd(X, M.r[0], Result);
XMStoreFloat3((XMFLOAT3*)pOutputVector, Result);
pInputVector += InputStride;
pOutputVector += OutputStride;
}
return pOutputStream;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT(pOutputStream);
XMASSERT(pInputStream);
UINT i;
const BYTE *pInputVector = (BYTE*)pInputStream;
BYTE *pOutputVector = (BYTE*)pOutputStream;
for (i = 0; i < VectorCount; i++)
{
XMVECTOR X = _mm_load_ps1(&reinterpret_cast<const XMFLOAT3 *>(pInputVector)->x);
XMVECTOR Y = _mm_load_ps1(&reinterpret_cast<const XMFLOAT3 *>(pInputVector)->y);
XMVECTOR vResult = _mm_load_ps1(&reinterpret_cast<const XMFLOAT3 *>(pInputVector)->z);
vResult = _mm_mul_ps(vResult,M.r[2]);
Y = _mm_mul_ps(Y,M.r[1]);
vResult = _mm_add_ps(vResult,Y);
X = _mm_mul_ps(X,M.r[0]);
vResult = _mm_add_ps(vResult,X);
_mm_store_ss(&reinterpret_cast<XMFLOAT3 *>(pOutputVector)->x,vResult);
vResult = _mm_shuffle_ps(vResult,vResult,_MM_SHUFFLE(0,3,2,1));
_mm_store_ss(&reinterpret_cast<XMFLOAT3 *>(pOutputVector)->y,vResult);
vResult = _mm_shuffle_ps(vResult,vResult,_MM_SHUFFLE(0,3,2,1));
_mm_store_ss(&reinterpret_cast<XMFLOAT3 *>(pOutputVector)->z,vResult);
pInputVector += InputStride;
pOutputVector += OutputStride;
}
return pOutputStream;
#elif defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMVECTOR XMVector3Project
(
FXMVECTOR V,
FLOAT ViewportX,
FLOAT ViewportY,
FLOAT ViewportWidth,
FLOAT ViewportHeight,
FLOAT ViewportMinZ,
FLOAT ViewportMaxZ,
CXMMATRIX Projection,
CXMMATRIX View,
CXMMATRIX World
)
{
#if defined(_XM_NO_INTRINSICS_)
XMMATRIX Transform;
XMVECTOR Scale;
XMVECTOR Offset;
XMVECTOR Result;
FLOAT HalfViewportWidth = ViewportWidth * 0.5f;
FLOAT HalfViewportHeight = ViewportHeight * 0.5f;
Scale = XMVectorSet(HalfViewportWidth,
-HalfViewportHeight,
ViewportMaxZ - ViewportMinZ,
0.0f);
Offset = XMVectorSet(ViewportX + HalfViewportWidth,
ViewportY + HalfViewportHeight,
ViewportMinZ,
0.0f);
Transform = XMMatrixMultiply(World, View);
Transform = XMMatrixMultiply(Transform, Projection);
Result = XMVector3TransformCoord(V, Transform);
Result = XMVectorMultiplyAdd(Result, Scale, Offset);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMMATRIX Transform;
XMVECTOR Scale;
XMVECTOR Offset;
XMVECTOR Result;
FLOAT HalfViewportWidth = ViewportWidth * 0.5f;
FLOAT HalfViewportHeight = ViewportHeight * 0.5f;
Scale = XMVectorSet(HalfViewportWidth,
-HalfViewportHeight,
ViewportMaxZ - ViewportMinZ,
0.0f);
Offset = XMVectorSet(ViewportX + HalfViewportWidth,
ViewportY + HalfViewportHeight,
ViewportMinZ,
0.0f);
Transform = XMMatrixMultiply(World, View);
Transform = XMMatrixMultiply(Transform, Projection);
Result = XMVector3TransformCoord(V, Transform);
Result = _mm_mul_ps(Result,Scale);
Result = _mm_add_ps(Result,Offset);
return Result;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMFLOAT3* XMVector3ProjectStream
(
XMFLOAT3* pOutputStream,
UINT OutputStride,
CONST XMFLOAT3* pInputStream,
UINT InputStride,
UINT VectorCount,
FLOAT ViewportX,
FLOAT ViewportY,
FLOAT ViewportWidth,
FLOAT ViewportHeight,
FLOAT ViewportMinZ,
FLOAT ViewportMaxZ,
CXMMATRIX Projection,
CXMMATRIX View,
CXMMATRIX World
)
{
#if defined(_XM_NO_INTRINSICS_)
XMMATRIX Transform;
XMVECTOR V;
XMVECTOR Scale;
XMVECTOR Offset;
XMVECTOR Result;
UINT i;
FLOAT HalfViewportWidth = ViewportWidth * 0.5f;
FLOAT HalfViewportHeight = ViewportHeight * 0.5f;
BYTE* pInputVector = (BYTE*)pInputStream;
BYTE* pOutputVector = (BYTE*)pOutputStream;
XMASSERT(pOutputStream);
XMASSERT(pInputStream);
Scale = XMVectorSet(HalfViewportWidth,
-HalfViewportHeight,
ViewportMaxZ - ViewportMinZ,
1.0f);
Offset = XMVectorSet(ViewportX + HalfViewportWidth,
ViewportY + HalfViewportHeight,
ViewportMinZ,
0.0f);
Transform = XMMatrixMultiply(World, View);
Transform = XMMatrixMultiply(Transform, Projection);
for (i = 0; i < VectorCount; i++)
{
V = XMLoadFloat3((XMFLOAT3*)pInputVector);
Result = XMVector3TransformCoord(V, Transform);
Result = XMVectorMultiplyAdd(Result, Scale, Offset);
XMStoreFloat3((XMFLOAT3*)pOutputVector, Result);
pInputVector += InputStride;
pOutputVector += OutputStride;
}
return pOutputStream;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT(pOutputStream);
XMASSERT(pInputStream);
XMMATRIX Transform;
XMVECTOR V;
XMVECTOR Scale;
XMVECTOR Offset;
XMVECTOR Result;
UINT i;
FLOAT HalfViewportWidth = ViewportWidth * 0.5f;
FLOAT HalfViewportHeight = ViewportHeight * 0.5f;
BYTE* pInputVector = (BYTE*)pInputStream;
BYTE* pOutputVector = (BYTE*)pOutputStream;
Scale = XMVectorSet(HalfViewportWidth,
-HalfViewportHeight,
ViewportMaxZ - ViewportMinZ,
1.0f);
Offset = XMVectorSet(ViewportX + HalfViewportWidth,
ViewportY + HalfViewportHeight,
ViewportMinZ,
0.0f);
Transform = XMMatrixMultiply(World, View);
Transform = XMMatrixMultiply(Transform, Projection);
for (i = 0; i < VectorCount; i++)
{
V = XMLoadFloat3((XMFLOAT3*)pInputVector);
Result = XMVector3TransformCoord(V, Transform);
Result = _mm_mul_ps(Result,Scale);
Result = _mm_add_ps(Result,Offset);
XMStoreFloat3((XMFLOAT3*)pOutputVector, Result);
pInputVector += InputStride;
pOutputVector += OutputStride;
}
return pOutputStream;
#elif defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector3Unproject
(
FXMVECTOR V,
FLOAT ViewportX,
FLOAT ViewportY,
FLOAT ViewportWidth,
FLOAT ViewportHeight,
FLOAT ViewportMinZ,
FLOAT ViewportMaxZ,
CXMMATRIX Projection,
CXMMATRIX View,
CXMMATRIX World
)
{
#if defined(_XM_NO_INTRINSICS_)
XMMATRIX Transform;
XMVECTOR Scale;
XMVECTOR Offset;
XMVECTOR Determinant;
XMVECTOR Result;
CONST XMVECTOR D = XMVectorSet(-1.0f, 1.0f, 0.0f, 0.0f);
Scale = XMVectorSet(ViewportWidth * 0.5f,
-ViewportHeight * 0.5f,
ViewportMaxZ - ViewportMinZ,
1.0f);
Scale = XMVectorReciprocal(Scale);
Offset = XMVectorSet(-ViewportX,
-ViewportY,
-ViewportMinZ,
0.0f);
Offset = XMVectorMultiplyAdd(Scale, Offset, D);
Transform = XMMatrixMultiply(World, View);
Transform = XMMatrixMultiply(Transform, Projection);
Transform = XMMatrixInverse(&Determinant, Transform);
Result = XMVectorMultiplyAdd(V, Scale, Offset);
Result = XMVector3TransformCoord(Result, Transform);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMMATRIX Transform;
XMVECTOR Scale;
XMVECTOR Offset;
XMVECTOR Determinant;
XMVECTOR Result;
CONST XMVECTORF32 D = {-1.0f, 1.0f, 0.0f, 0.0f};
Scale = XMVectorSet(ViewportWidth * 0.5f,
-ViewportHeight * 0.5f,
ViewportMaxZ - ViewportMinZ,
1.0f);
Scale = XMVectorReciprocal(Scale);
Offset = XMVectorSet(-ViewportX,
-ViewportY,
-ViewportMinZ,
0.0f);
Offset = _mm_mul_ps(Offset,Scale);
Offset = _mm_add_ps(Offset,D);
Transform = XMMatrixMultiply(World, View);
Transform = XMMatrixMultiply(Transform, Projection);
Transform = XMMatrixInverse(&Determinant, Transform);
Result = _mm_mul_ps(V,Scale);
Result = _mm_add_ps(Result,Offset);
Result = XMVector3TransformCoord(Result, Transform);
return Result;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMFLOAT3* XMVector3UnprojectStream
(
XMFLOAT3* pOutputStream,
UINT OutputStride,
CONST XMFLOAT3* pInputStream,
UINT InputStride,
UINT VectorCount,
FLOAT ViewportX,
FLOAT ViewportY,
FLOAT ViewportWidth,
FLOAT ViewportHeight,
FLOAT ViewportMinZ,
FLOAT ViewportMaxZ,
CXMMATRIX Projection,
CXMMATRIX View,
CXMMATRIX World)
{
#if defined(_XM_NO_INTRINSICS_)
XMMATRIX Transform;
XMVECTOR Scale;
XMVECTOR Offset;
XMVECTOR V;
XMVECTOR Determinant;
XMVECTOR Result;
UINT i;
BYTE* pInputVector = (BYTE*)pInputStream;
BYTE* pOutputVector = (BYTE*)pOutputStream;
CONST XMVECTOR D = XMVectorSet(-1.0f, 1.0f, 0.0f, 0.0f);
XMASSERT(pOutputStream);
XMASSERT(pInputStream);
Scale = XMVectorSet(ViewportWidth * 0.5f,
-ViewportHeight * 0.5f,
ViewportMaxZ - ViewportMinZ,
1.0f);
Scale = XMVectorReciprocal(Scale);
Offset = XMVectorSet(-ViewportX,
-ViewportY,
-ViewportMinZ,
0.0f);
Offset = XMVectorMultiplyAdd(Scale, Offset, D);
Transform = XMMatrixMultiply(World, View);
Transform = XMMatrixMultiply(Transform, Projection);
Transform = XMMatrixInverse(&Determinant, Transform);
for (i = 0; i < VectorCount; i++)
{
V = XMLoadFloat3((XMFLOAT3*)pInputVector);
Result = XMVectorMultiplyAdd(V, Scale, Offset);
Result = XMVector3TransformCoord(Result, Transform);
XMStoreFloat3((XMFLOAT3*)pOutputVector, Result);
pInputVector += InputStride;
pOutputVector += OutputStride;
}
return pOutputStream;
#elif defined(_XM_SSE_INTRINSICS_)
XMASSERT(pOutputStream);
XMASSERT(pInputStream);
XMMATRIX Transform;
XMVECTOR Scale;
XMVECTOR Offset;
XMVECTOR V;
XMVECTOR Determinant;
XMVECTOR Result;
UINT i;
BYTE* pInputVector = (BYTE*)pInputStream;
BYTE* pOutputVector = (BYTE*)pOutputStream;
CONST XMVECTORF32 D = {-1.0f, 1.0f, 0.0f, 0.0f};
Scale = XMVectorSet(ViewportWidth * 0.5f,
-ViewportHeight * 0.5f,
ViewportMaxZ - ViewportMinZ,
1.0f);
Scale = XMVectorReciprocal(Scale);
Offset = XMVectorSet(-ViewportX,
-ViewportY,
-ViewportMinZ,
0.0f);
Offset = _mm_mul_ps(Offset,Scale);
Offset = _mm_add_ps(Offset,D);
Transform = XMMatrixMultiply(World, View);
Transform = XMMatrixMultiply(Transform, Projection);
Transform = XMMatrixInverse(&Determinant, Transform);
for (i = 0; i < VectorCount; i++)
{
V = XMLoadFloat3((XMFLOAT3*)pInputVector);
Result = XMVectorMultiplyAdd(V, Scale, Offset);
Result = XMVector3TransformCoord(Result, Transform);
XMStoreFloat3((XMFLOAT3*)pOutputVector, Result);
pInputVector += InputStride;
pOutputVector += OutputStride;
}
return pOutputStream;
#elif defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
#endif // _XM_VMX128_INTRINSICS_
}
/****************************************************************************
*
* 4D Vector
*
****************************************************************************/
//------------------------------------------------------------------------------
// Comparison operations
//------------------------------------------------------------------------------
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector4Equal
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.x == V2.x) && (V1.y == V2.y) && (V1.z == V2.z) && (V1.w == V2.w)) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmpeq_ps(V1,V2);
return ((_mm_movemask_ps(vTemp)==0x0f) != 0);
#else
return XMComparisonAllTrue(XMVector4EqualR(V1, V2));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE UINT XMVector4EqualR
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
UINT CR = 0;
if ((V1.x == V2.x) &&
(V1.y == V2.y) &&
(V1.z == V2.z) &&
(V1.w == V2.w))
{
CR = XM_CRMASK_CR6TRUE;
}
else if ((V1.x != V2.x) &&
(V1.y != V2.y) &&
(V1.z != V2.z) &&
(V1.w != V2.w))
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmpeq_ps(V1,V2);
int iTest = _mm_movemask_ps(vTemp);
UINT CR = 0;
if (iTest==0xf) // All equal?
{
CR = XM_CRMASK_CR6TRUE;
}
else if (iTest==0) // All not equal?
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector4EqualInt
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.u[0] == V2.u[0]) && (V1.u[1] == V2.u[1]) && (V1.u[2] == V2.u[2]) && (V1.u[3] == V2.u[3])) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
__m128i vTemp = _mm_cmpeq_epi32(reinterpret_cast<const __m128i *>(&V1)[0],reinterpret_cast<const __m128i *>(&V2)[0]);
return ((_mm_movemask_ps(reinterpret_cast<const __m128 *>(&vTemp)[0])==0xf) != 0);
#else
return XMComparisonAllTrue(XMVector4EqualIntR(V1, V2));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE UINT XMVector4EqualIntR
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
UINT CR = 0;
if (V1.u[0] == V2.u[0] &&
V1.u[1] == V2.u[1] &&
V1.u[2] == V2.u[2] &&
V1.u[3] == V2.u[3])
{
CR = XM_CRMASK_CR6TRUE;
}
else if (V1.u[0] != V2.u[0] &&
V1.u[1] != V2.u[1] &&
V1.u[2] != V2.u[2] &&
V1.u[3] != V2.u[3])
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#elif defined(_XM_SSE_INTRINSICS_)
__m128i vTemp = _mm_cmpeq_epi32(reinterpret_cast<const __m128i *>(&V1)[0],reinterpret_cast<const __m128i *>(&V2)[0]);
int iTest = _mm_movemask_ps(reinterpret_cast<const __m128 *>(&vTemp)[0]);
UINT CR = 0;
if (iTest==0xf) // All equal?
{
CR = XM_CRMASK_CR6TRUE;
}
else if (iTest==0) // All not equal?
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
XMFINLINE BOOL XMVector4NearEqual
(
FXMVECTOR V1,
FXMVECTOR V2,
FXMVECTOR Epsilon
)
{
#if defined(_XM_NO_INTRINSICS_)
FLOAT dx, dy, dz, dw;
dx = fabsf(V1.x-V2.x);
dy = fabsf(V1.y-V2.y);
dz = fabsf(V1.z-V2.z);
dw = fabsf(V1.w-V2.w);
return (((dx <= Epsilon.x) &&
(dy <= Epsilon.y) &&
(dz <= Epsilon.z) &&
(dw <= Epsilon.w)) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
// Get the difference
XMVECTOR vDelta = _mm_sub_ps(V1,V2);
// Get the absolute value of the difference
XMVECTOR vTemp = _mm_setzero_ps();
vTemp = _mm_sub_ps(vTemp,vDelta);
vTemp = _mm_max_ps(vTemp,vDelta);
vTemp = _mm_cmple_ps(vTemp,Epsilon);
return ((_mm_movemask_ps(vTemp)==0xf) != 0);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector4NotEqual
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.x != V2.x) || (V1.y != V2.y) || (V1.z != V2.z) || (V1.w != V2.w)) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmpneq_ps(V1,V2);
return ((_mm_movemask_ps(vTemp)) != 0);
#else
return XMComparisonAnyFalse(XMVector4EqualR(V1, V2));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector4NotEqualInt
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.u[0] != V2.u[0]) || (V1.u[1] != V2.u[1]) || (V1.u[2] != V2.u[2]) || (V1.u[3] != V2.u[3])) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
__m128i vTemp = _mm_cmpeq_epi32(reinterpret_cast<const __m128i *>(&V1)[0],reinterpret_cast<const __m128i *>(&V2)[0]);
return ((_mm_movemask_ps(reinterpret_cast<const __m128 *>(&vTemp)[0])!=0xF) != 0);
#else
return XMComparisonAnyFalse(XMVector4EqualIntR(V1, V2));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector4Greater
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.x > V2.x) && (V1.y > V2.y) && (V1.z > V2.z) && (V1.w > V2.w)) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmpgt_ps(V1,V2);
return ((_mm_movemask_ps(vTemp)==0x0f) != 0);
#else
return XMComparisonAllTrue(XMVector4GreaterR(V1, V2));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE UINT XMVector4GreaterR
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
UINT CR = 0;
if (V1.x > V2.x &&
V1.y > V2.y &&
V1.z > V2.z &&
V1.w > V2.w)
{
CR = XM_CRMASK_CR6TRUE;
}
else if (V1.x <= V2.x &&
V1.y <= V2.y &&
V1.z <= V2.z &&
V1.w <= V2.w)
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#elif defined(_XM_SSE_INTRINSICS_)
UINT CR = 0;
XMVECTOR vTemp = _mm_cmpgt_ps(V1,V2);
int iTest = _mm_movemask_ps(vTemp);
if (iTest==0xf) {
CR = XM_CRMASK_CR6TRUE;
}
else if (!iTest)
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector4GreaterOrEqual
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.x >= V2.x) && (V1.y >= V2.y) && (V1.z >= V2.z) && (V1.w >= V2.w)) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmpge_ps(V1,V2);
return ((_mm_movemask_ps(vTemp)==0x0f) != 0);
#else
return XMComparisonAllTrue(XMVector4GreaterOrEqualR(V1, V2));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE UINT XMVector4GreaterOrEqualR
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
UINT CR = 0;
if ((V1.x >= V2.x) &&
(V1.y >= V2.y) &&
(V1.z >= V2.z) &&
(V1.w >= V2.w))
{
CR = XM_CRMASK_CR6TRUE;
}
else if ((V1.x < V2.x) &&
(V1.y < V2.y) &&
(V1.z < V2.z) &&
(V1.w < V2.w))
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#elif defined(_XM_SSE_INTRINSICS_)
UINT CR = 0;
XMVECTOR vTemp = _mm_cmpge_ps(V1,V2);
int iTest = _mm_movemask_ps(vTemp);
if (iTest==0x0f)
{
CR = XM_CRMASK_CR6TRUE;
}
else if (!iTest)
{
CR = XM_CRMASK_CR6FALSE;
}
return CR;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector4Less
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.x < V2.x) && (V1.y < V2.y) && (V1.z < V2.z) && (V1.w < V2.w)) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmplt_ps(V1,V2);
return ((_mm_movemask_ps(vTemp)==0x0f) != 0);
#else
return XMComparisonAllTrue(XMVector4GreaterR(V2, V1));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector4LessOrEqual
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V1.x <= V2.x) && (V1.y <= V2.y) && (V1.z <= V2.z) && (V1.w <= V2.w)) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp = _mm_cmple_ps(V1,V2);
return ((_mm_movemask_ps(vTemp)==0x0f) != 0);
#else
return XMComparisonAllTrue(XMVector4GreaterOrEqualR(V2, V1));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector4InBounds
(
FXMVECTOR V,
FXMVECTOR Bounds
)
{
#if defined(_XM_NO_INTRINSICS_)
return (((V.x <= Bounds.x && V.x >= -Bounds.x) &&
(V.y <= Bounds.y && V.y >= -Bounds.y) &&
(V.z <= Bounds.z && V.z >= -Bounds.z) &&
(V.w <= Bounds.w && V.w >= -Bounds.w)) != 0);
#elif defined(_XM_SSE_INTRINSICS_)
// Test if less than or equal
XMVECTOR vTemp1 = _mm_cmple_ps(V,Bounds);
// Negate the bounds
XMVECTOR vTemp2 = _mm_mul_ps(Bounds,g_XMNegativeOne);
// Test if greater or equal (Reversed)
vTemp2 = _mm_cmple_ps(vTemp2,V);
// Blend answers
vTemp1 = _mm_and_ps(vTemp1,vTemp2);
// All in bounds?
return ((_mm_movemask_ps(vTemp1)==0x0f) != 0);
#else
return XMComparisonAllInBounds(XMVector4InBoundsR(V, Bounds));
#endif
}
//------------------------------------------------------------------------------
XMFINLINE UINT XMVector4InBoundsR
(
FXMVECTOR V,
FXMVECTOR Bounds
)
{
#if defined(_XM_NO_INTRINSICS_)
UINT CR = 0;
if ((V.x <= Bounds.x && V.x >= -Bounds.x) &&
(V.y <= Bounds.y && V.y >= -Bounds.y) &&
(V.z <= Bounds.z && V.z >= -Bounds.z) &&
(V.w <= Bounds.w && V.w >= -Bounds.w))
{
CR = XM_CRMASK_CR6BOUNDS;
}
return CR;
#elif defined(_XM_SSE_INTRINSICS_)
// Test if less than or equal
XMVECTOR vTemp1 = _mm_cmple_ps(V,Bounds);
// Negate the bounds
XMVECTOR vTemp2 = _mm_mul_ps(Bounds,g_XMNegativeOne);
// Test if greater or equal (Reversed)
vTemp2 = _mm_cmple_ps(vTemp2,V);
// Blend answers
vTemp1 = _mm_and_ps(vTemp1,vTemp2);
// All in bounds?
return (_mm_movemask_ps(vTemp1)==0x0f) ? XM_CRMASK_CR6BOUNDS : 0;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector4IsNaN
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
return (XMISNAN(V.x) ||
XMISNAN(V.y) ||
XMISNAN(V.z) ||
XMISNAN(V.w));
#elif defined(_XM_SSE_INTRINSICS_)
// Test against itself. NaN is always not equal
XMVECTOR vTempNan = _mm_cmpneq_ps(V,V);
// If any are NaN, the mask is non-zero
return (_mm_movemask_ps(vTempNan)!=0);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE BOOL XMVector4IsInfinite
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
return (XMISINF(V.x) ||
XMISINF(V.y) ||
XMISINF(V.z) ||
XMISINF(V.w));
#elif defined(_XM_SSE_INTRINSICS_)
// Mask off the sign bit
XMVECTOR vTemp = _mm_and_ps(V,g_XMAbsMask);
// Compare to infinity
vTemp = _mm_cmpeq_ps(vTemp,g_XMInfinity);
// If any are infinity, the signs are true.
return (_mm_movemask_ps(vTemp) != 0);
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// Computation operations
//------------------------------------------------------------------------------
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector4Dot
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result.v[0] =
Result.v[1] =
Result.v[2] =
Result.v[3] = V1.v[0] * V2.v[0] + V1.v[1] * V2.v[1] + V1.v[2] * V2.v[2] + V1.v[3] * V2.v[3];
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vTemp2 = V2;
XMVECTOR vTemp = _mm_mul_ps(V1,vTemp2);
vTemp2 = _mm_shuffle_ps(vTemp2,vTemp,_MM_SHUFFLE(1,0,0,0)); // Copy X to the Z position and Y to the W position
vTemp2 = _mm_add_ps(vTemp2,vTemp); // Add Z = X+Z; W = Y+W;
vTemp = _mm_shuffle_ps(vTemp,vTemp2,_MM_SHUFFLE(0,3,0,0)); // Copy W to the Z position
vTemp = _mm_add_ps(vTemp,vTemp2); // Add Z and W together
return _mm_shuffle_ps(vTemp,vTemp,_MM_SHUFFLE(2,2,2,2)); // Splat Z and return
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector4Cross
(
FXMVECTOR V1,
FXMVECTOR V2,
FXMVECTOR V3
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result.x = (((V2.z*V3.w)-(V2.w*V3.z))*V1.y)-(((V2.y*V3.w)-(V2.w*V3.y))*V1.z)+(((V2.y*V3.z)-(V2.z*V3.y))*V1.w);
Result.y = (((V2.w*V3.z)-(V2.z*V3.w))*V1.x)-(((V2.w*V3.x)-(V2.x*V3.w))*V1.z)+(((V2.z*V3.x)-(V2.x*V3.z))*V1.w);
Result.z = (((V2.y*V3.w)-(V2.w*V3.y))*V1.x)-(((V2.x*V3.w)-(V2.w*V3.x))*V1.y)+(((V2.x*V3.y)-(V2.y*V3.x))*V1.w);
Result.w = (((V2.z*V3.y)-(V2.y*V3.z))*V1.x)-(((V2.z*V3.x)-(V2.x*V3.z))*V1.y)+(((V2.y*V3.x)-(V2.x*V3.y))*V1.z);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// V2zwyz * V3wzwy
XMVECTOR vResult = _mm_shuffle_ps(V2,V2,_MM_SHUFFLE(2,1,3,2));
XMVECTOR vTemp3 = _mm_shuffle_ps(V3,V3,_MM_SHUFFLE(1,3,2,3));
vResult = _mm_mul_ps(vResult,vTemp3);
// - V2wzwy * V3zwyz
XMVECTOR vTemp2 = _mm_shuffle_ps(V2,V2,_MM_SHUFFLE(1,3,2,3));
vTemp3 = _mm_shuffle_ps(vTemp3,vTemp3,_MM_SHUFFLE(1,3,0,1));
vTemp2 = _mm_mul_ps(vTemp2,vTemp3);
vResult = _mm_sub_ps(vResult,vTemp2);
// term1 * V1yxxx
XMVECTOR vTemp1 = _mm_shuffle_ps(V1,V1,_MM_SHUFFLE(0,0,0,1));
vResult = _mm_mul_ps(vResult,vTemp1);
// V2ywxz * V3wxwx
vTemp2 = _mm_shuffle_ps(V2,V2,_MM_SHUFFLE(2,0,3,1));
vTemp3 = _mm_shuffle_ps(V3,V3,_MM_SHUFFLE(0,3,0,3));
vTemp3 = _mm_mul_ps(vTemp3,vTemp2);
// - V2wxwx * V3ywxz
vTemp2 = _mm_shuffle_ps(vTemp2,vTemp2,_MM_SHUFFLE(2,1,2,1));
vTemp1 = _mm_shuffle_ps(V3,V3,_MM_SHUFFLE(2,0,3,1));
vTemp2 = _mm_mul_ps(vTemp2,vTemp1);
vTemp3 = _mm_sub_ps(vTemp3,vTemp2);
// vResult - temp * V1zzyy
vTemp1 = _mm_shuffle_ps(V1,V1,_MM_SHUFFLE(1,1,2,2));
vTemp1 = _mm_mul_ps(vTemp1,vTemp3);
vResult = _mm_sub_ps(vResult,vTemp1);
// V2yzxy * V3zxyx
vTemp2 = _mm_shuffle_ps(V2,V2,_MM_SHUFFLE(1,0,2,1));
vTemp3 = _mm_shuffle_ps(V3,V3,_MM_SHUFFLE(0,1,0,2));
vTemp3 = _mm_mul_ps(vTemp3,vTemp2);
// - V2zxyx * V3yzxy
vTemp2 = _mm_shuffle_ps(vTemp2,vTemp2,_MM_SHUFFLE(2,0,2,1));
vTemp1 = _mm_shuffle_ps(V3,V3,_MM_SHUFFLE(1,0,2,1));
vTemp1 = _mm_mul_ps(vTemp1,vTemp2);
vTemp3 = _mm_sub_ps(vTemp3,vTemp1);
// vResult + term * V1wwwz
vTemp1 = _mm_shuffle_ps(V1,V1,_MM_SHUFFLE(2,3,3,3));
vTemp3 = _mm_mul_ps(vTemp3,vTemp1);
vResult = _mm_add_ps(vResult,vTemp3);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector4LengthSq
(
FXMVECTOR V
)
{
return XMVector4Dot(V, V);
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector4ReciprocalLengthEst
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result = XMVector4LengthSq(V);
Result = XMVectorReciprocalSqrtEst(Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Perform the dot product on x,y,z and w
XMVECTOR vLengthSq = _mm_mul_ps(V,V);
// vTemp has z and w
XMVECTOR vTemp = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(3,2,3,2));
// x+z, y+w
vLengthSq = _mm_add_ps(vLengthSq,vTemp);
// x+z,x+z,x+z,y+w
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(1,0,0,0));
// ??,??,y+w,y+w
vTemp = _mm_shuffle_ps(vTemp,vLengthSq,_MM_SHUFFLE(3,3,0,0));
// ??,??,x+z+y+w,??
vLengthSq = _mm_add_ps(vLengthSq,vTemp);
// Splat the length
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(2,2,2,2));
// Get the reciprocal
vLengthSq = _mm_rsqrt_ps(vLengthSq);
return vLengthSq;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector4ReciprocalLength
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result = XMVector4LengthSq(V);
Result = XMVectorReciprocalSqrt(Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Perform the dot product on x,y,z and w
XMVECTOR vLengthSq = _mm_mul_ps(V,V);
// vTemp has z and w
XMVECTOR vTemp = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(3,2,3,2));
// x+z, y+w
vLengthSq = _mm_add_ps(vLengthSq,vTemp);
// x+z,x+z,x+z,y+w
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(1,0,0,0));
// ??,??,y+w,y+w
vTemp = _mm_shuffle_ps(vTemp,vLengthSq,_MM_SHUFFLE(3,3,0,0));
// ??,??,x+z+y+w,??
vLengthSq = _mm_add_ps(vLengthSq,vTemp);
// Splat the length
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(2,2,2,2));
// Get the reciprocal
vLengthSq = _mm_sqrt_ps(vLengthSq);
// Accurate!
vLengthSq = _mm_div_ps(g_XMOne,vLengthSq);
return vLengthSq;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector4LengthEst
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result = XMVector4LengthSq(V);
Result = XMVectorSqrtEst(Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Perform the dot product on x,y,z and w
XMVECTOR vLengthSq = _mm_mul_ps(V,V);
// vTemp has z and w
XMVECTOR vTemp = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(3,2,3,2));
// x+z, y+w
vLengthSq = _mm_add_ps(vLengthSq,vTemp);
// x+z,x+z,x+z,y+w
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(1,0,0,0));
// ??,??,y+w,y+w
vTemp = _mm_shuffle_ps(vTemp,vLengthSq,_MM_SHUFFLE(3,3,0,0));
// ??,??,x+z+y+w,??
vLengthSq = _mm_add_ps(vLengthSq,vTemp);
// Splat the length
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(2,2,2,2));
// Prepare for the division
vLengthSq = _mm_sqrt_ps(vLengthSq);
return vLengthSq;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector4Length
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result = XMVector4LengthSq(V);
Result = XMVectorSqrt(Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Perform the dot product on x,y,z and w
XMVECTOR vLengthSq = _mm_mul_ps(V,V);
// vTemp has z and w
XMVECTOR vTemp = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(3,2,3,2));
// x+z, y+w
vLengthSq = _mm_add_ps(vLengthSq,vTemp);
// x+z,x+z,x+z,y+w
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(1,0,0,0));
// ??,??,y+w,y+w
vTemp = _mm_shuffle_ps(vTemp,vLengthSq,_MM_SHUFFLE(3,3,0,0));
// ??,??,x+z+y+w,??
vLengthSq = _mm_add_ps(vLengthSq,vTemp);
// Splat the length
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(2,2,2,2));
// Prepare for the division
vLengthSq = _mm_sqrt_ps(vLengthSq);
return vLengthSq;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
// XMVector4NormalizeEst uses a reciprocal estimate and
// returns QNaN on zero and infinite vectors.
XMFINLINE XMVECTOR XMVector4NormalizeEst
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result = XMVector4ReciprocalLength(V);
Result = XMVectorMultiply(V, Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Perform the dot product on x,y,z and w
XMVECTOR vLengthSq = _mm_mul_ps(V,V);
// vTemp has z and w
XMVECTOR vTemp = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(3,2,3,2));
// x+z, y+w
vLengthSq = _mm_add_ps(vLengthSq,vTemp);
// x+z,x+z,x+z,y+w
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(1,0,0,0));
// ??,??,y+w,y+w
vTemp = _mm_shuffle_ps(vTemp,vLengthSq,_MM_SHUFFLE(3,3,0,0));
// ??,??,x+z+y+w,??
vLengthSq = _mm_add_ps(vLengthSq,vTemp);
// Splat the length
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(2,2,2,2));
// Prepare for the division
XMVECTOR vResult = _mm_rsqrt_ps(vLengthSq);
// Failsafe on zero (Or epsilon) length planes
// If the length is infinity, set the elements to zero
vLengthSq = _mm_cmpneq_ps(vLengthSq,g_XMInfinity);
// Reciprocal mul to perform the normalization
vResult = _mm_mul_ps(vResult,V);
// Any that are infinity, set to zero
vResult = _mm_and_ps(vResult,vLengthSq);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector4Normalize
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR LengthSq;
XMVECTOR Zero;
XMVECTOR InfiniteLength;
XMVECTOR ZeroLength;
XMVECTOR Select;
XMVECTOR Result;
LengthSq = XMVector4LengthSq(V);
Zero = XMVectorZero();
Result = XMVectorReciprocalSqrt(LengthSq);
InfiniteLength = XMVectorEqualInt(LengthSq, g_XMInfinity.v);
ZeroLength = XMVectorEqual(LengthSq, Zero);
Result = XMVectorMultiply(V, Result);
Select = XMVectorEqualInt(InfiniteLength, ZeroLength);
Result = XMVectorSelect(LengthSq, Result, Select);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Perform the dot product on x,y,z and w
XMVECTOR vLengthSq = _mm_mul_ps(V,V);
// vTemp has z and w
XMVECTOR vTemp = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(3,2,3,2));
// x+z, y+w
vLengthSq = _mm_add_ps(vLengthSq,vTemp);
// x+z,x+z,x+z,y+w
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(1,0,0,0));
// ??,??,y+w,y+w
vTemp = _mm_shuffle_ps(vTemp,vLengthSq,_MM_SHUFFLE(3,3,0,0));
// ??,??,x+z+y+w,??
vLengthSq = _mm_add_ps(vLengthSq,vTemp);
// Splat the length
vLengthSq = _mm_shuffle_ps(vLengthSq,vLengthSq,_MM_SHUFFLE(2,2,2,2));
// Prepare for the division
XMVECTOR vResult = _mm_sqrt_ps(vLengthSq);
// Failsafe on zero (Or epsilon) length planes
// If the length is infinity, set the elements to zero
vLengthSq = _mm_cmpneq_ps(vLengthSq,g_XMInfinity);
// Divide to perform the normalization
vResult = _mm_div_ps(V,vResult);
// Any that are infinity, set to zero
vResult = _mm_and_ps(vResult,vLengthSq);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector4ClampLength
(
FXMVECTOR V,
FLOAT LengthMin,
FLOAT LengthMax
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR ClampMax;
XMVECTOR ClampMin;
ClampMax = XMVectorReplicate(LengthMax);
ClampMin = XMVectorReplicate(LengthMin);
return XMVector4ClampLengthV(V, ClampMin, ClampMax);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR ClampMax = _mm_set_ps1(LengthMax);
XMVECTOR ClampMin = _mm_set_ps1(LengthMin);
return XMVector4ClampLengthV(V, ClampMin, ClampMax);
#elif defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector4ClampLengthV
(
FXMVECTOR V,
FXMVECTOR LengthMin,
FXMVECTOR LengthMax
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR ClampLength;
XMVECTOR LengthSq;
XMVECTOR RcpLength;
XMVECTOR Length;
XMVECTOR Normal;
XMVECTOR Zero;
XMVECTOR InfiniteLength;
XMVECTOR ZeroLength;
XMVECTOR Select;
XMVECTOR ControlMax;
XMVECTOR ControlMin;
XMVECTOR Control;
XMVECTOR Result;
XMASSERT((LengthMin.y == LengthMin.x) && (LengthMin.z == LengthMin.x) && (LengthMin.w == LengthMin.x));
XMASSERT((LengthMax.y == LengthMax.x) && (LengthMax.z == LengthMax.x) && (LengthMax.w == LengthMax.x));
XMASSERT(XMVector4GreaterOrEqual(LengthMin, XMVectorZero()));
XMASSERT(XMVector4GreaterOrEqual(LengthMax, XMVectorZero()));
XMASSERT(XMVector4GreaterOrEqual(LengthMax, LengthMin));
LengthSq = XMVector4LengthSq(V);
Zero = XMVectorZero();
RcpLength = XMVectorReciprocalSqrt(LengthSq);
InfiniteLength = XMVectorEqualInt(LengthSq, g_XMInfinity.v);
ZeroLength = XMVectorEqual(LengthSq, Zero);
Normal = XMVectorMultiply(V, RcpLength);
Length = XMVectorMultiply(LengthSq, RcpLength);
Select = XMVectorEqualInt(InfiniteLength, ZeroLength);
Length = XMVectorSelect(LengthSq, Length, Select);
Normal = XMVectorSelect(LengthSq, Normal, Select);
ControlMax = XMVectorGreater(Length, LengthMax);
ControlMin = XMVectorLess(Length, LengthMin);
ClampLength = XMVectorSelect(Length, LengthMax, ControlMax);
ClampLength = XMVectorSelect(ClampLength, LengthMin, ControlMin);
Result = XMVectorMultiply(Normal, ClampLength);
// Preserve the original vector (with no precision loss) if the length falls within the given range
Control = XMVectorEqualInt(ControlMax, ControlMin);
Result = XMVectorSelect(Result, V, Control);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR ClampLength;
XMVECTOR LengthSq;
XMVECTOR RcpLength;
XMVECTOR Length;
XMVECTOR Normal;
XMVECTOR Zero;
XMVECTOR InfiniteLength;
XMVECTOR ZeroLength;
XMVECTOR Select;
XMVECTOR ControlMax;
XMVECTOR ControlMin;
XMVECTOR Control;
XMVECTOR Result;
XMASSERT((XMVectorGetY(LengthMin) == XMVectorGetX(LengthMin)) && (XMVectorGetZ(LengthMin) == XMVectorGetX(LengthMin)) && (XMVectorGetW(LengthMin) == XMVectorGetX(LengthMin)));
XMASSERT((XMVectorGetY(LengthMax) == XMVectorGetX(LengthMax)) && (XMVectorGetZ(LengthMax) == XMVectorGetX(LengthMax)) && (XMVectorGetW(LengthMax) == XMVectorGetX(LengthMax)));
XMASSERT(XMVector4GreaterOrEqual(LengthMin, g_XMZero));
XMASSERT(XMVector4GreaterOrEqual(LengthMax, g_XMZero));
XMASSERT(XMVector4GreaterOrEqual(LengthMax, LengthMin));
LengthSq = XMVector4LengthSq(V);
Zero = XMVectorZero();
RcpLength = XMVectorReciprocalSqrt(LengthSq);
InfiniteLength = XMVectorEqualInt(LengthSq, g_XMInfinity);
ZeroLength = XMVectorEqual(LengthSq, Zero);
Normal = _mm_mul_ps(V, RcpLength);
Length = _mm_mul_ps(LengthSq, RcpLength);
Select = XMVectorEqualInt(InfiniteLength, ZeroLength);
Length = XMVectorSelect(LengthSq, Length, Select);
Normal = XMVectorSelect(LengthSq, Normal, Select);
ControlMax = XMVectorGreater(Length, LengthMax);
ControlMin = XMVectorLess(Length, LengthMin);
ClampLength = XMVectorSelect(Length, LengthMax, ControlMax);
ClampLength = XMVectorSelect(ClampLength, LengthMin, ControlMin);
Result = _mm_mul_ps(Normal, ClampLength);
// Preserve the original vector (with no precision loss) if the length falls within the given range
Control = XMVectorEqualInt(ControlMax,ControlMin);
Result = XMVectorSelect(Result,V,Control);
return Result;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector4Reflect
(
FXMVECTOR Incident,
FXMVECTOR Normal
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
// Result = Incident - (2 * dot(Incident, Normal)) * Normal
Result = XMVector4Dot(Incident, Normal);
Result = XMVectorAdd(Result, Result);
Result = XMVectorNegativeMultiplySubtract(Result, Normal, Incident);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
// Result = Incident - (2 * dot(Incident, Normal)) * Normal
XMVECTOR Result = XMVector4Dot(Incident,Normal);
Result = _mm_add_ps(Result,Result);
Result = _mm_mul_ps(Result,Normal);
Result = _mm_sub_ps(Incident,Result);
return Result;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector4Refract
(
FXMVECTOR Incident,
FXMVECTOR Normal,
FLOAT RefractionIndex
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Index;
Index = XMVectorReplicate(RefractionIndex);
return XMVector4RefractV(Incident, Normal, Index);
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR Index = _mm_set_ps1(RefractionIndex);
return XMVector4RefractV(Incident,Normal,Index);
#elif defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector4RefractV
(
FXMVECTOR Incident,
FXMVECTOR Normal,
FXMVECTOR RefractionIndex
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR IDotN;
XMVECTOR R;
CONST XMVECTOR Zero = XMVectorZero();
// Result = RefractionIndex * Incident - Normal * (RefractionIndex * dot(Incident, Normal) +
// sqrt(1 - RefractionIndex * RefractionIndex * (1 - dot(Incident, Normal) * dot(Incident, Normal))))
IDotN = XMVector4Dot(Incident, Normal);
// R = 1.0f - RefractionIndex * RefractionIndex * (1.0f - IDotN * IDotN)
R = XMVectorNegativeMultiplySubtract(IDotN, IDotN, g_XMOne.v);
R = XMVectorMultiply(R, RefractionIndex);
R = XMVectorNegativeMultiplySubtract(R, RefractionIndex, g_XMOne.v);
if (XMVector4LessOrEqual(R, Zero))
{
// Total internal reflection
return Zero;
}
else
{
XMVECTOR Result;
// R = RefractionIndex * IDotN + sqrt(R)
R = XMVectorSqrt(R);
R = XMVectorMultiplyAdd(RefractionIndex, IDotN, R);
// Result = RefractionIndex * Incident - Normal * R
Result = XMVectorMultiply(RefractionIndex, Incident);
Result = XMVectorNegativeMultiplySubtract(Normal, R, Result);
return Result;
}
#elif defined(_XM_SSE_INTRINSICS_)
// Result = RefractionIndex * Incident - Normal * (RefractionIndex * dot(Incident, Normal) +
// sqrt(1 - RefractionIndex * RefractionIndex * (1 - dot(Incident, Normal) * dot(Incident, Normal))))
XMVECTOR IDotN = XMVector4Dot(Incident,Normal);
// R = 1.0f - RefractionIndex * RefractionIndex * (1.0f - IDotN * IDotN)
XMVECTOR R = _mm_mul_ps(IDotN,IDotN);
R = _mm_sub_ps(g_XMOne,R);
R = _mm_mul_ps(R, RefractionIndex);
R = _mm_mul_ps(R, RefractionIndex);
R = _mm_sub_ps(g_XMOne,R);
XMVECTOR vResult = _mm_cmple_ps(R,g_XMZero);
if (_mm_movemask_ps(vResult)==0x0f)
{
// Total internal reflection
vResult = g_XMZero;
}
else
{
// R = RefractionIndex * IDotN + sqrt(R)
R = _mm_sqrt_ps(R);
vResult = _mm_mul_ps(RefractionIndex, IDotN);
R = _mm_add_ps(R,vResult);
// Result = RefractionIndex * Incident - Normal * R
vResult = _mm_mul_ps(RefractionIndex, Incident);
R = _mm_mul_ps(R,Normal);
vResult = _mm_sub_ps(vResult,R);
}
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector4Orthogonal
(
FXMVECTOR V
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR Result;
Result.v[0] = V.v[2];
Result.v[1] = V.v[3];
Result.v[2] = -V.v[0];
Result.v[3] = -V.v[1];
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
static const XMVECTORF32 g_XMFlipZW = {1.0f,1.0f,-1.0f,-1.0f};
XMVECTOR vResult = _mm_shuffle_ps(V,V,_MM_SHUFFLE(1,0,3,2));
vResult = _mm_mul_ps(vResult,g_XMFlipZW);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector4AngleBetweenNormalsEst
(
FXMVECTOR N1,
FXMVECTOR N2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR NegativeOne;
XMVECTOR One;
XMVECTOR Result;
Result = XMVector4Dot(N1, N2);
NegativeOne = XMVectorSplatConstant(-1, 0);
One = XMVectorSplatOne();
Result = XMVectorClamp(Result, NegativeOne, One);
Result = XMVectorACosEst(Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = XMVector4Dot(N1,N2);
// Clamp to -1.0f to 1.0f
vResult = _mm_max_ps(vResult,g_XMNegativeOne);
vResult = _mm_min_ps(vResult,g_XMOne);;
vResult = XMVectorACosEst(vResult);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector4AngleBetweenNormals
(
FXMVECTOR N1,
FXMVECTOR N2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR NegativeOne;
XMVECTOR One;
XMVECTOR Result;
Result = XMVector4Dot(N1, N2);
NegativeOne = XMVectorSplatConstant(-1, 0);
One = XMVectorSplatOne();
Result = XMVectorClamp(Result, NegativeOne, One);
Result = XMVectorACos(Result);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR vResult = XMVector4Dot(N1,N2);
// Clamp to -1.0f to 1.0f
vResult = _mm_max_ps(vResult,g_XMNegativeOne);
vResult = _mm_min_ps(vResult,g_XMOne);;
vResult = XMVectorACos(vResult);
return vResult;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector4AngleBetweenVectors
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR L1;
XMVECTOR L2;
XMVECTOR Dot;
XMVECTOR CosAngle;
XMVECTOR NegativeOne;
XMVECTOR One;
XMVECTOR Result;
L1 = XMVector4ReciprocalLength(V1);
L2 = XMVector4ReciprocalLength(V2);
Dot = XMVector4Dot(V1, V2);
L1 = XMVectorMultiply(L1, L2);
CosAngle = XMVectorMultiply(Dot, L1);
NegativeOne = XMVectorSplatConstant(-1, 0);
One = XMVectorSplatOne();
CosAngle = XMVectorClamp(CosAngle, NegativeOne, One);
Result = XMVectorACos(CosAngle);
return Result;
#elif defined(_XM_SSE_INTRINSICS_)
XMVECTOR L1;
XMVECTOR L2;
XMVECTOR Dot;
XMVECTOR CosAngle;
XMVECTOR Result;
L1 = XMVector4ReciprocalLength(V1);
L2 = XMVector4ReciprocalLength(V2);
Dot = XMVector4Dot(V1, V2);
L1 = _mm_mul_ps(L1,L2);
CosAngle = _mm_mul_ps(Dot,L1);
CosAngle = XMVectorClamp(CosAngle, g_XMNegativeOne, g_XMOne);
Result = XMVectorACos(CosAngle);
return Result;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR XMVector4Transform
(
FXMVECTOR V,
CXMMATRIX M
)
{
#if defined(_XM_NO_INTRINSICS_)
FLOAT fX = (M.m[0][0]*V.x)+(M.m[1][0]*V.y)+(M.m[2][0]*V.z)+(M.m[3][0]*V.w);
FLOAT fY = (M.m[0][1]*V.x)+(M.m[1][1]*V.y)+(M.m[2][1]*V.z)+(M.m[3][1]*V.w);
FLOAT fZ = (M.m[0][2]*V.x)+(M.m[1][2]*V.y)+(M.m[2][2]*V.z)+(M.m[3][2]*V.w);
FLOAT fW = (M.m[0][3]*V.x)+(M.m[1][3]*V.y)+(M.m[2][3]*V.z)+(M.m[3][3]*V.w);
XMVECTOR vResult = {
fX,
fY,
fZ,
fW
};
return vResult;
#elif defined(_XM_SSE_INTRINSICS_)
// Splat x,y,z and w
XMVECTOR vTempX = _mm_shuffle_ps(V,V,_MM_SHUFFLE(0,0,0,0));
XMVECTOR vTempY = _mm_shuffle_ps(V,V,_MM_SHUFFLE(1,1,1,1));
XMVECTOR vTempZ = _mm_shuffle_ps(V,V,_MM_SHUFFLE(2,2,2,2));
XMVECTOR vTempW = _mm_shuffle_ps(V,V,_MM_SHUFFLE(3,3,3,3));
// Mul by the matrix
vTempX = _mm_mul_ps(vTempX,M.r[0]);
vTempY = _mm_mul_ps(vTempY,M.r[1]);
vTempZ = _mm_mul_ps(vTempZ,M.r[2]);
vTempW = _mm_mul_ps(vTempW,M.r[3]);
// Add them all together
vTempX = _mm_add_ps(vTempX,vTempY);
vTempZ = _mm_add_ps(vTempZ,vTempW);
vTempX = _mm_add_ps(vTempX,vTempZ);
return vTempX;
#else // _XM_VMX128_INTRINSICS_
#endif // _XM_VMX128_INTRINSICS_
}
//------------------------------------------------------------------------------
XMINLINE XMFLOAT4* XMVector4TransformStream
(
XMFLOAT4* pOutputStream,
UINT OutputStride,
CONST XMFLOAT4* pInputStream,
UINT InputStride,
UINT VectorCount,
CXMMATRIX M
)
{
#if defined(_XM_NO_INTRINSICS_)
XMVECTOR V;
XMVECTOR X;
XMVECTOR Y;
XMVECTOR Z;
XMVECTOR W;
XMVECTOR Result;
UINT i;
BYTE* pInputVector = (BYTE*)pInputStream;
BYTE* pOutputVector = (BYTE*)pOutputStream;
XMASSERT(pOutputStream);
XMASSERT(pInputStream);
for (i = 0; i < VectorCount; i++)
{
V = XMLoadFloat4((XMFLOAT4*)pInputVector);
W = XMVectorSplatW(V);
Z = XMVectorSplatZ(V);
Y = XMVectorSplatY(V);
X = XMVectorSplatX(V);
// W = XMVectorReplicate(((XMFLOAT4*)pInputVector)->w);
// Z = XMVectorReplicate(((XMFLOAT4*)pInputVector)->z);
// Y = XMVectorReplicate(((XMFLOAT4*)pInputVector)->y);
// X = XMVectorReplicate(((XMFLOAT4*)pInputVector)->x);
Result = XMVectorMultiply(W, M.r[3]);
Result = XMVectorMultiplyAdd(Z, M.r[2], Result);
Result = XMVectorMultiplyAdd(Y, M.r[1], Result);
Result = XMVectorMultiplyAdd(X, M.r[0], Result);
XMStoreFloat4((XMFLOAT4*)pOutputVector, Result);
pInputVector += InputStride;
pOutputVector += OutputStride;
}
return pOutputStream;
#elif defined(_XM_SSE_INTRINSICS_)
UINT i;
XMASSERT(pOutputStream);
XMASSERT(pInputStream);
const BYTE*pInputVector = reinterpret_cast<const BYTE *>(pInputStream);
BYTE* pOutputVector = reinterpret_cast<BYTE *>(pOutputStream);
for (i = 0; i < VectorCount; i++)
{
// Fetch the row and splat it
XMVECTOR vTempx = _mm_loadu_ps(reinterpret_cast<const float *>(pInputVector));
XMVECTOR vTempy = _mm_shuffle_ps(vTempx,vTempx,_MM_SHUFFLE(1,1,1,1));
XMVECTOR vTempz = _mm_shuffle_ps(vTempx,vTempx,_MM_SHUFFLE(2,2,2,2));
XMVECTOR vTempw = _mm_shuffle_ps(vTempx,vTempx,_MM_SHUFFLE(3,3,3,3));
vTempx = _mm_shuffle_ps(vTempx,vTempx,_MM_SHUFFLE(0,0,0,0));
vTempx = _mm_mul_ps(vTempx,M.r[0]);
vTempy = _mm_mul_ps(vTempy,M.r[1]);
vTempz = _mm_mul_ps(vTempz,M.r[2]);
vTempw = _mm_mul_ps(vTempw,M.r[3]);
vTempx = _mm_add_ps(vTempx,vTempy);
vTempw = _mm_add_ps(vTempw,vTempz);
vTempw = _mm_add_ps(vTempw,vTempx);
// Store the transformed vector
_mm_storeu_ps(reinterpret_cast<float *>(pOutputVector),vTempw);
pInputVector += InputStride;
pOutputVector += OutputStride;
}
return pOutputStream;
#elif defined(XM_NO_MISALIGNED_VECTOR_ACCESS)
#endif // _XM_VMX128_INTRINSICS_
}
#ifdef __cplusplus
/****************************************************************************
*
* XMVECTOR operators
*
****************************************************************************/
#ifndef XM_NO_OPERATOR_OVERLOADS
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR operator+ (FXMVECTOR V)
{
return V;
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR operator- (FXMVECTOR V)
{
return XMVectorNegate(V);
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR& operator+=
(
XMVECTOR& V1,
FXMVECTOR V2
)
{
V1 = XMVectorAdd(V1, V2);
return V1;
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR& operator-=
(
XMVECTOR& V1,
FXMVECTOR V2
)
{
V1 = XMVectorSubtract(V1, V2);
return V1;
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR& operator*=
(
XMVECTOR& V1,
FXMVECTOR V2
)
{
V1 = XMVectorMultiply(V1, V2);
return V1;
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR& operator/=
(
XMVECTOR& V1,
FXMVECTOR V2
)
{
XMVECTOR InvV = XMVectorReciprocal(V2);
V1 = XMVectorMultiply(V1, InvV);
return V1;
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR& operator*=
(
XMVECTOR& V,
CONST FLOAT S
)
{
V = XMVectorScale(V, S);
return V;
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR& operator/=
(
XMVECTOR& V,
CONST FLOAT S
)
{
V = XMVectorScale(V, 1.0f / S);
return V;
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR operator+
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
return XMVectorAdd(V1, V2);
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR operator-
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
return XMVectorSubtract(V1, V2);
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR operator*
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
return XMVectorMultiply(V1, V2);
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR operator/
(
FXMVECTOR V1,
FXMVECTOR V2
)
{
XMVECTOR InvV = XMVectorReciprocal(V2);
return XMVectorMultiply(V1, InvV);
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR operator*
(
FXMVECTOR V,
CONST FLOAT S
)
{
return XMVectorScale(V, S);
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR operator/
(
FXMVECTOR V,
CONST FLOAT S
)
{
return XMVectorScale(V, 1.0f / S);
}
//------------------------------------------------------------------------------
XMFINLINE XMVECTOR operator*
(
FLOAT S,
FXMVECTOR V
)
{
return XMVectorScale(V, S);
}
#endif // !XM_NO_OPERATOR_OVERLOADS
/****************************************************************************
*
* XMFLOAT2 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMFLOAT2::_XMFLOAT2
(
FLOAT _x,
FLOAT _y
)
{
x = _x;
y = _y;
}
//------------------------------------------------------------------------------
XMFINLINE _XMFLOAT2::_XMFLOAT2
(
CONST FLOAT* pArray
)
{
x = pArray[0];
y = pArray[1];
}
//------------------------------------------------------------------------------
XMFINLINE _XMFLOAT2& _XMFLOAT2::operator=
(
CONST _XMFLOAT2& Float2
)
{
x = Float2.x;
y = Float2.y;
return *this;
}
/****************************************************************************
*
* XMHALF2 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMHALF2::_XMHALF2
(
HALF _x,
HALF _y
)
{
x = _x;
y = _y;
}
//------------------------------------------------------------------------------
XMFINLINE _XMHALF2::_XMHALF2
(
CONST HALF* pArray
)
{
x = pArray[0];
y = pArray[1];
}
//------------------------------------------------------------------------------
XMFINLINE _XMHALF2::_XMHALF2
(
FLOAT _x,
FLOAT _y
)
{
x = XMConvertFloatToHalf(_x);
y = XMConvertFloatToHalf(_y);
}
//------------------------------------------------------------------------------
XMFINLINE _XMHALF2::_XMHALF2
(
CONST FLOAT* pArray
)
{
x = XMConvertFloatToHalf(pArray[0]);
y = XMConvertFloatToHalf(pArray[1]);
}
//------------------------------------------------------------------------------
XMFINLINE _XMHALF2& _XMHALF2::operator=
(
CONST _XMHALF2& Half2
)
{
x = Half2.x;
y = Half2.y;
return *this;
}
/****************************************************************************
*
* XMSHORTN2 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMSHORTN2::_XMSHORTN2
(
SHORT _x,
SHORT _y
)
{
x = _x;
y = _y;
}
//------------------------------------------------------------------------------
XMFINLINE _XMSHORTN2::_XMSHORTN2
(
CONST SHORT* pArray
)
{
x = pArray[0];
y = pArray[1];
}
//------------------------------------------------------------------------------
XMFINLINE _XMSHORTN2::_XMSHORTN2
(
FLOAT _x,
FLOAT _y
)
{
XMStoreShortN2(this, XMVectorSet(_x, _y, 0.0f, 0.0f));
}
//------------------------------------------------------------------------------
XMFINLINE _XMSHORTN2::_XMSHORTN2
(
CONST FLOAT* pArray
)
{
XMStoreShortN2(this, XMLoadFloat2((XMFLOAT2*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMSHORTN2& _XMSHORTN2::operator=
(
CONST _XMSHORTN2& ShortN2
)
{
x = ShortN2.x;
y = ShortN2.y;
return *this;
}
/****************************************************************************
*
* XMSHORT2 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMSHORT2::_XMSHORT2
(
SHORT _x,
SHORT _y
)
{
x = _x;
y = _y;
}
//------------------------------------------------------------------------------
XMFINLINE _XMSHORT2::_XMSHORT2
(
CONST SHORT* pArray
)
{
x = pArray[0];
y = pArray[1];
}
//------------------------------------------------------------------------------
XMFINLINE _XMSHORT2::_XMSHORT2
(
FLOAT _x,
FLOAT _y
)
{
XMStoreShort2(this, XMVectorSet(_x, _y, 0.0f, 0.0f));
}
//------------------------------------------------------------------------------
XMFINLINE _XMSHORT2::_XMSHORT2
(
CONST FLOAT* pArray
)
{
XMStoreShort2(this, XMLoadFloat2((XMFLOAT2*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMSHORT2& _XMSHORT2::operator=
(
CONST _XMSHORT2& Short2
)
{
x = Short2.x;
y = Short2.y;
return *this;
}
/****************************************************************************
*
* XMUSHORTN2 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMUSHORTN2::_XMUSHORTN2
(
USHORT _x,
USHORT _y
)
{
x = _x;
y = _y;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUSHORTN2::_XMUSHORTN2
(
CONST USHORT* pArray
)
{
x = pArray[0];
y = pArray[1];
}
//------------------------------------------------------------------------------
XMFINLINE _XMUSHORTN2::_XMUSHORTN2
(
FLOAT _x,
FLOAT _y
)
{
XMStoreUShortN2(this, XMVectorSet(_x, _y, 0.0f, 0.0f));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUSHORTN2::_XMUSHORTN2
(
CONST FLOAT* pArray
)
{
XMStoreUShortN2(this, XMLoadFloat2((XMFLOAT2*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUSHORTN2& _XMUSHORTN2::operator=
(
CONST _XMUSHORTN2& UShortN2
)
{
x = UShortN2.x;
y = UShortN2.y;
return *this;
}
/****************************************************************************
*
* XMUSHORT2 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMUSHORT2::_XMUSHORT2
(
USHORT _x,
USHORT _y
)
{
x = _x;
y = _y;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUSHORT2::_XMUSHORT2
(
CONST USHORT* pArray
)
{
x = pArray[0];
y = pArray[1];
}
//------------------------------------------------------------------------------
XMFINLINE _XMUSHORT2::_XMUSHORT2
(
FLOAT _x,
FLOAT _y
)
{
XMStoreUShort2(this, XMVectorSet(_x, _y, 0.0f, 0.0f));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUSHORT2::_XMUSHORT2
(
CONST FLOAT* pArray
)
{
XMStoreUShort2(this, XMLoadFloat2((XMFLOAT2*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUSHORT2& _XMUSHORT2::operator=
(
CONST _XMUSHORT2& UShort2
)
{
x = UShort2.x;
y = UShort2.y;
return *this;
}
/****************************************************************************
*
* XMFLOAT3 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMFLOAT3::_XMFLOAT3
(
FLOAT _x,
FLOAT _y,
FLOAT _z
)
{
x = _x;
y = _y;
z = _z;
}
//------------------------------------------------------------------------------
XMFINLINE _XMFLOAT3::_XMFLOAT3
(
CONST FLOAT* pArray
)
{
x = pArray[0];
y = pArray[1];
z = pArray[2];
}
//------------------------------------------------------------------------------
XMFINLINE _XMFLOAT3& _XMFLOAT3::operator=
(
CONST _XMFLOAT3& Float3
)
{
x = Float3.x;
y = Float3.y;
z = Float3.z;
return *this;
}
/****************************************************************************
*
* XMHENDN3 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMHENDN3::_XMHENDN3
(
UINT Packed
)
{
v = Packed;
}
//------------------------------------------------------------------------------
XMFINLINE _XMHENDN3::_XMHENDN3
(
FLOAT _x,
FLOAT _y,
FLOAT _z
)
{
XMStoreHenDN3(this, XMVectorSet(_x, _y, _z, 0.0f));
}
//------------------------------------------------------------------------------
XMFINLINE _XMHENDN3::_XMHENDN3
(
CONST FLOAT* pArray
)
{
XMStoreHenDN3(this, XMLoadFloat3((XMFLOAT3*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMHENDN3::operator UINT ()
{
return v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMHENDN3& _XMHENDN3::operator=
(
CONST _XMHENDN3& HenDN3
)
{
v = HenDN3.v;
return *this;
}
//------------------------------------------------------------------------------
XMFINLINE _XMHENDN3& _XMHENDN3::operator=
(
CONST UINT Packed
)
{
v = Packed;
return *this;
}
/****************************************************************************
*
* XMHEND3 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMHEND3::_XMHEND3
(
UINT Packed
)
{
v = Packed;
}
//------------------------------------------------------------------------------
XMFINLINE _XMHEND3::_XMHEND3
(
FLOAT _x,
FLOAT _y,
FLOAT _z
)
{
XMStoreHenD3(this, XMVectorSet(_x, _y, _z, 0.0f));
}
//------------------------------------------------------------------------------
XMFINLINE _XMHEND3::_XMHEND3
(
CONST FLOAT* pArray
)
{
XMStoreHenD3(this, XMLoadFloat3((XMFLOAT3*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMHEND3::operator UINT ()
{
return v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMHEND3& _XMHEND3::operator=
(
CONST _XMHEND3& HenD3
)
{
v = HenD3.v;
return *this;
}
//------------------------------------------------------------------------------
XMFINLINE _XMHEND3& _XMHEND3::operator=
(
CONST UINT Packed
)
{
v = Packed;
return *this;
}
/****************************************************************************
*
* XMUHENDN3 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMUHENDN3::_XMUHENDN3
(
UINT Packed
)
{
v = Packed;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUHENDN3::_XMUHENDN3
(
FLOAT _x,
FLOAT _y,
FLOAT _z
)
{
XMStoreUHenDN3(this, XMVectorSet(_x, _y, _z, 0.0f));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUHENDN3::_XMUHENDN3
(
CONST FLOAT* pArray
)
{
XMStoreUHenDN3(this, XMLoadFloat3((XMFLOAT3*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUHENDN3::operator UINT ()
{
return v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUHENDN3& _XMUHENDN3::operator=
(
CONST _XMUHENDN3& UHenDN3
)
{
v = UHenDN3.v;
return *this;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUHENDN3& _XMUHENDN3::operator=
(
CONST UINT Packed
)
{
v = Packed;
return *this;
}
/****************************************************************************
*
* XMUHEND3 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMUHEND3::_XMUHEND3
(
UINT Packed
)
{
v = Packed;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUHEND3::_XMUHEND3
(
FLOAT _x,
FLOAT _y,
FLOAT _z
)
{
XMStoreUHenD3(this, XMVectorSet(_x, _y, _z, 0.0f));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUHEND3::_XMUHEND3
(
CONST FLOAT* pArray
)
{
XMStoreUHenD3(this, XMLoadFloat3((XMFLOAT3*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUHEND3::operator UINT ()
{
return v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUHEND3& _XMUHEND3::operator=
(
CONST _XMUHEND3& UHenD3
)
{
v = UHenD3.v;
return *this;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUHEND3& _XMUHEND3::operator=
(
CONST UINT Packed
)
{
v = Packed;
return *this;
}
/****************************************************************************
*
* XMDHENN3 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMDHENN3::_XMDHENN3
(
UINT Packed
)
{
v = Packed;
}
//------------------------------------------------------------------------------
XMFINLINE _XMDHENN3::_XMDHENN3
(
FLOAT _x,
FLOAT _y,
FLOAT _z
)
{
XMStoreDHenN3(this, XMVectorSet(_x, _y, _z, 0.0f));
}
//------------------------------------------------------------------------------
XMFINLINE _XMDHENN3::_XMDHENN3
(
CONST FLOAT* pArray
)
{
XMStoreDHenN3(this, XMLoadFloat3((XMFLOAT3*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMDHENN3::operator UINT ()
{
return v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMDHENN3& _XMDHENN3::operator=
(
CONST _XMDHENN3& DHenN3
)
{
v = DHenN3.v;
return *this;
}
//------------------------------------------------------------------------------
XMFINLINE _XMDHENN3& _XMDHENN3::operator=
(
CONST UINT Packed
)
{
v = Packed;
return *this;
}
/****************************************************************************
*
* XMDHEN3 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMDHEN3::_XMDHEN3
(
UINT Packed
)
{
v = Packed;
}
//------------------------------------------------------------------------------
XMFINLINE _XMDHEN3::_XMDHEN3
(
FLOAT _x,
FLOAT _y,
FLOAT _z
)
{
XMStoreDHen3(this, XMVectorSet(_x, _y, _z, 0.0f));
}
//------------------------------------------------------------------------------
XMFINLINE _XMDHEN3::_XMDHEN3
(
CONST FLOAT* pArray
)
{
XMStoreDHen3(this, XMLoadFloat3((XMFLOAT3*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMDHEN3::operator UINT ()
{
return v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMDHEN3& _XMDHEN3::operator=
(
CONST _XMDHEN3& DHen3
)
{
v = DHen3.v;
return *this;
}
//------------------------------------------------------------------------------
XMFINLINE _XMDHEN3& _XMDHEN3::operator=
(
CONST UINT Packed
)
{
v = Packed;
return *this;
}
/****************************************************************************
*
* XMUDHENN3 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMUDHENN3::_XMUDHENN3
(
UINT Packed
)
{
v = Packed;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUDHENN3::_XMUDHENN3
(
FLOAT _x,
FLOAT _y,
FLOAT _z
)
{
XMStoreUDHenN3(this, XMVectorSet(_x, _y, _z, 0.0f));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUDHENN3::_XMUDHENN3
(
CONST FLOAT* pArray
)
{
XMStoreUDHenN3(this, XMLoadFloat3((XMFLOAT3*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUDHENN3::operator UINT ()
{
return v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUDHENN3& _XMUDHENN3::operator=
(
CONST _XMUDHENN3& UDHenN3
)
{
v = UDHenN3.v;
return *this;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUDHENN3& _XMUDHENN3::operator=
(
CONST UINT Packed
)
{
v = Packed;
return *this;
}
/****************************************************************************
*
* XMUDHEN3 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMUDHEN3::_XMUDHEN3
(
UINT Packed
)
{
v = Packed;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUDHEN3::_XMUDHEN3
(
FLOAT _x,
FLOAT _y,
FLOAT _z
)
{
XMStoreUDHen3(this, XMVectorSet(_x, _y, _z, 0.0f));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUDHEN3::_XMUDHEN3
(
CONST FLOAT* pArray
)
{
XMStoreUDHen3(this, XMLoadFloat3((XMFLOAT3*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUDHEN3::operator UINT ()
{
return v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUDHEN3& _XMUDHEN3::operator=
(
CONST _XMUDHEN3& UDHen3
)
{
v = UDHen3.v;
return *this;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUDHEN3& _XMUDHEN3::operator=
(
CONST UINT Packed
)
{
v = Packed;
return *this;
}
/****************************************************************************
*
* XMFLOAT4 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMFLOAT4::_XMFLOAT4
(
FLOAT _x,
FLOAT _y,
FLOAT _z,
FLOAT _w
)
{
x = _x;
y = _y;
z = _z;
w = _w;
}
//------------------------------------------------------------------------------
XMFINLINE _XMFLOAT4::_XMFLOAT4
(
CONST FLOAT* pArray
)
{
x = pArray[0];
y = pArray[1];
z = pArray[2];
w = pArray[3];
}
//------------------------------------------------------------------------------
XMFINLINE _XMFLOAT4& _XMFLOAT4::operator=
(
CONST _XMFLOAT4& Float4
)
{
x = Float4.x;
y = Float4.y;
z = Float4.z;
w = Float4.w;
return *this;
}
/****************************************************************************
*
* XMHALF4 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMHALF4::_XMHALF4
(
HALF _x,
HALF _y,
HALF _z,
HALF _w
)
{
x = _x;
y = _y;
z = _z;
w = _w;
}
//------------------------------------------------------------------------------
XMFINLINE _XMHALF4::_XMHALF4
(
CONST HALF* pArray
)
{
x = pArray[0];
y = pArray[1];
z = pArray[2];
w = pArray[3];
}
//------------------------------------------------------------------------------
XMFINLINE _XMHALF4::_XMHALF4
(
FLOAT _x,
FLOAT _y,
FLOAT _z,
FLOAT _w
)
{
x = XMConvertFloatToHalf(_x);
y = XMConvertFloatToHalf(_y);
z = XMConvertFloatToHalf(_z);
w = XMConvertFloatToHalf(_w);
}
//------------------------------------------------------------------------------
XMFINLINE _XMHALF4::_XMHALF4
(
CONST FLOAT* pArray
)
{
XMConvertFloatToHalfStream(&x, sizeof(HALF), pArray, sizeof(FLOAT), 4);
}
//------------------------------------------------------------------------------
XMFINLINE _XMHALF4& _XMHALF4::operator=
(
CONST _XMHALF4& Half4
)
{
x = Half4.x;
y = Half4.y;
z = Half4.z;
w = Half4.w;
return *this;
}
/****************************************************************************
*
* XMSHORTN4 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMSHORTN4::_XMSHORTN4
(
SHORT _x,
SHORT _y,
SHORT _z,
SHORT _w
)
{
x = _x;
y = _y;
z = _z;
w = _w;
}
//------------------------------------------------------------------------------
XMFINLINE _XMSHORTN4::_XMSHORTN4
(
CONST SHORT* pArray
)
{
x = pArray[0];
y = pArray[1];
z = pArray[2];
w = pArray[3];
}
//------------------------------------------------------------------------------
XMFINLINE _XMSHORTN4::_XMSHORTN4
(
FLOAT _x,
FLOAT _y,
FLOAT _z,
FLOAT _w
)
{
XMStoreShortN4(this, XMVectorSet(_x, _y, _z, _w));
}
//------------------------------------------------------------------------------
XMFINLINE _XMSHORTN4::_XMSHORTN4
(
CONST FLOAT* pArray
)
{
XMStoreShortN4(this, XMLoadFloat4((XMFLOAT4*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMSHORTN4& _XMSHORTN4::operator=
(
CONST _XMSHORTN4& ShortN4
)
{
x = ShortN4.x;
y = ShortN4.y;
z = ShortN4.z;
w = ShortN4.w;
return *this;
}
/****************************************************************************
*
* XMSHORT4 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMSHORT4::_XMSHORT4
(
SHORT _x,
SHORT _y,
SHORT _z,
SHORT _w
)
{
x = _x;
y = _y;
z = _z;
w = _w;
}
//------------------------------------------------------------------------------
XMFINLINE _XMSHORT4::_XMSHORT4
(
CONST SHORT* pArray
)
{
x = pArray[0];
y = pArray[1];
z = pArray[2];
w = pArray[3];
}
//------------------------------------------------------------------------------
XMFINLINE _XMSHORT4::_XMSHORT4
(
FLOAT _x,
FLOAT _y,
FLOAT _z,
FLOAT _w
)
{
XMStoreShort4(this, XMVectorSet(_x, _y, _z, _w));
}
//------------------------------------------------------------------------------
XMFINLINE _XMSHORT4::_XMSHORT4
(
CONST FLOAT* pArray
)
{
XMStoreShort4(this, XMLoadFloat4((XMFLOAT4*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMSHORT4& _XMSHORT4::operator=
(
CONST _XMSHORT4& Short4
)
{
x = Short4.x;
y = Short4.y;
z = Short4.z;
w = Short4.w;
return *this;
}
/****************************************************************************
*
* XMUSHORTN4 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMUSHORTN4::_XMUSHORTN4
(
USHORT _x,
USHORT _y,
USHORT _z,
USHORT _w
)
{
x = _x;
y = _y;
z = _z;
w = _w;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUSHORTN4::_XMUSHORTN4
(
CONST USHORT* pArray
)
{
x = pArray[0];
y = pArray[1];
z = pArray[2];
w = pArray[3];
}
//------------------------------------------------------------------------------
XMFINLINE _XMUSHORTN4::_XMUSHORTN4
(
FLOAT _x,
FLOAT _y,
FLOAT _z,
FLOAT _w
)
{
XMStoreUShortN4(this, XMVectorSet(_x, _y, _z, _w));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUSHORTN4::_XMUSHORTN4
(
CONST FLOAT* pArray
)
{
XMStoreUShortN4(this, XMLoadFloat4((XMFLOAT4*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUSHORTN4& _XMUSHORTN4::operator=
(
CONST _XMUSHORTN4& UShortN4
)
{
x = UShortN4.x;
y = UShortN4.y;
z = UShortN4.z;
w = UShortN4.w;
return *this;
}
/****************************************************************************
*
* XMUSHORT4 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMUSHORT4::_XMUSHORT4
(
USHORT _x,
USHORT _y,
USHORT _z,
USHORT _w
)
{
x = _x;
y = _y;
z = _z;
w = _w;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUSHORT4::_XMUSHORT4
(
CONST USHORT* pArray
)
{
x = pArray[0];
y = pArray[1];
z = pArray[2];
w = pArray[3];
}
//------------------------------------------------------------------------------
XMFINLINE _XMUSHORT4::_XMUSHORT4
(
FLOAT _x,
FLOAT _y,
FLOAT _z,
FLOAT _w
)
{
XMStoreUShort4(this, XMVectorSet(_x, _y, _z, _w));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUSHORT4::_XMUSHORT4
(
CONST FLOAT* pArray
)
{
XMStoreUShort4(this, XMLoadFloat4((XMFLOAT4*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUSHORT4& _XMUSHORT4::operator=
(
CONST _XMUSHORT4& UShort4
)
{
x = UShort4.x;
y = UShort4.y;
z = UShort4.z;
w = UShort4.w;
return *this;
}
/****************************************************************************
*
* XMXDECN4 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMXDECN4::_XMXDECN4
(
UINT Packed
)
{
v = Packed;
}
//------------------------------------------------------------------------------
XMFINLINE _XMXDECN4::_XMXDECN4
(
FLOAT _x,
FLOAT _y,
FLOAT _z,
FLOAT _w
)
{
XMStoreXDecN4(this, XMVectorSet(_x, _y, _z, _w));
}
//------------------------------------------------------------------------------
XMFINLINE _XMXDECN4::_XMXDECN4
(
CONST FLOAT* pArray
)
{
XMStoreXDecN4(this, XMLoadFloat4((XMFLOAT4*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMXDECN4::operator UINT ()
{
return v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMXDECN4& _XMXDECN4::operator=
(
CONST _XMXDECN4& XDecN4
)
{
v = XDecN4.v;
return *this;
}
//------------------------------------------------------------------------------
XMFINLINE _XMXDECN4& _XMXDECN4::operator=
(
CONST UINT Packed
)
{
v = Packed;
return *this;
}
/****************************************************************************
*
* XMXDEC4 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMXDEC4::_XMXDEC4
(
UINT Packed
)
{
v = Packed;
}
//------------------------------------------------------------------------------
XMFINLINE _XMXDEC4::_XMXDEC4
(
FLOAT _x,
FLOAT _y,
FLOAT _z,
FLOAT _w
)
{
XMStoreXDec4(this, XMVectorSet(_x, _y, _z, _w));
}
//------------------------------------------------------------------------------
XMFINLINE _XMXDEC4::_XMXDEC4
(
CONST FLOAT* pArray
)
{
XMStoreXDec4(this, XMLoadFloat4((XMFLOAT4*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMXDEC4::operator UINT ()
{
return v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMXDEC4& _XMXDEC4::operator=
(
CONST _XMXDEC4& XDec4
)
{
v = XDec4.v;
return *this;
}
//------------------------------------------------------------------------------
XMFINLINE _XMXDEC4& _XMXDEC4::operator=
(
CONST UINT Packed
)
{
v = Packed;
return *this;
}
/****************************************************************************
*
* XMDECN4 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMDECN4::_XMDECN4
(
UINT Packed
)
{
v = Packed;
}
//------------------------------------------------------------------------------
XMFINLINE _XMDECN4::_XMDECN4
(
FLOAT _x,
FLOAT _y,
FLOAT _z,
FLOAT _w
)
{
XMStoreDecN4(this, XMVectorSet(_x, _y, _z, _w));
}
//------------------------------------------------------------------------------
XMFINLINE _XMDECN4::_XMDECN4
(
CONST FLOAT* pArray
)
{
XMStoreDecN4(this, XMLoadFloat4((XMFLOAT4*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMDECN4::operator UINT ()
{
return v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMDECN4& _XMDECN4::operator=
(
CONST _XMDECN4& DecN4
)
{
v = DecN4.v;
return *this;
}
//------------------------------------------------------------------------------
XMFINLINE _XMDECN4& _XMDECN4::operator=
(
CONST UINT Packed
)
{
v = Packed;
return *this;
}
/****************************************************************************
*
* XMDEC4 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMDEC4::_XMDEC4
(
UINT Packed
)
{
v = Packed;
}
//------------------------------------------------------------------------------
XMFINLINE _XMDEC4::_XMDEC4
(
FLOAT _x,
FLOAT _y,
FLOAT _z,
FLOAT _w
)
{
XMStoreDec4(this, XMVectorSet(_x, _y, _z, _w));
}
//------------------------------------------------------------------------------
XMFINLINE _XMDEC4::_XMDEC4
(
CONST FLOAT* pArray
)
{
XMStoreDec4(this, XMLoadFloat4((XMFLOAT4*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMDEC4::operator UINT ()
{
return v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMDEC4& _XMDEC4::operator=
(
CONST _XMDEC4& Dec4
)
{
v = Dec4.v;
return *this;
}
//------------------------------------------------------------------------------
XMFINLINE _XMDEC4& _XMDEC4::operator=
(
CONST UINT Packed
)
{
v = Packed;
return *this;
}
/****************************************************************************
*
* XMUDECN4 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMUDECN4::_XMUDECN4
(
UINT Packed
)
{
v = Packed;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUDECN4::_XMUDECN4
(
FLOAT _x,
FLOAT _y,
FLOAT _z,
FLOAT _w
)
{
XMStoreUDecN4(this, XMVectorSet(_x, _y, _z, _w));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUDECN4::_XMUDECN4
(
CONST FLOAT* pArray
)
{
XMStoreUDecN4(this, XMLoadFloat4((XMFLOAT4*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUDECN4::operator UINT ()
{
return v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUDECN4& _XMUDECN4::operator=
(
CONST _XMUDECN4& UDecN4
)
{
v = UDecN4.v;
return *this;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUDECN4& _XMUDECN4::operator=
(
CONST UINT Packed
)
{
v = Packed;
return *this;
}
/****************************************************************************
*
* XMUDEC4 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMUDEC4::_XMUDEC4
(
UINT Packed
)
{
v = Packed;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUDEC4::_XMUDEC4
(
FLOAT _x,
FLOAT _y,
FLOAT _z,
FLOAT _w
)
{
XMStoreUDec4(this, XMVectorSet(_x, _y, _z, _w));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUDEC4::_XMUDEC4
(
CONST FLOAT* pArray
)
{
XMStoreUDec4(this, XMLoadFloat4((XMFLOAT4*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUDEC4::operator UINT ()
{
return v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUDEC4& _XMUDEC4::operator=
(
CONST _XMUDEC4& UDec4
)
{
v = UDec4.v;
return *this;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUDEC4& _XMUDEC4::operator=
(
CONST UINT Packed
)
{
v = Packed;
return *this;
}
/****************************************************************************
*
* XMXICON4 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMXICON4::_XMXICON4
(
UINT64 Packed
)
{
v = Packed;
}
//------------------------------------------------------------------------------
XMFINLINE _XMXICON4::_XMXICON4
(
FLOAT _x,
FLOAT _y,
FLOAT _z,
FLOAT _w
)
{
XMStoreXIcoN4(this, XMVectorSet(_x, _y, _z, _w));
}
//------------------------------------------------------------------------------
XMFINLINE _XMXICON4::_XMXICON4
(
CONST FLOAT* pArray
)
{
XMStoreXIcoN4(this, XMLoadFloat4((XMFLOAT4*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMXICON4::operator UINT64 ()
{
return v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMXICON4& _XMXICON4::operator=
(
CONST _XMXICON4& XIcoN4
)
{
v = XIcoN4.v;
return *this;
}
//------------------------------------------------------------------------------
XMFINLINE _XMXICON4& _XMXICON4::operator=
(
CONST UINT64 Packed
)
{
v = Packed;
return *this;
}
/****************************************************************************
*
* XMXICO4 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMXICO4::_XMXICO4
(
UINT64 Packed
)
{
v = Packed;
}
//------------------------------------------------------------------------------
XMFINLINE _XMXICO4::_XMXICO4
(
FLOAT _x,
FLOAT _y,
FLOAT _z,
FLOAT _w
)
{
XMStoreXIco4(this, XMVectorSet(_x, _y, _z, _w));
}
//------------------------------------------------------------------------------
XMFINLINE _XMXICO4::_XMXICO4
(
CONST FLOAT* pArray
)
{
XMStoreXIco4(this, XMLoadFloat4((XMFLOAT4*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMXICO4::operator UINT64 ()
{
return v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMXICO4& _XMXICO4::operator=
(
CONST _XMXICO4& XIco4
)
{
v = XIco4.v;
return *this;
}
//------------------------------------------------------------------------------
XMFINLINE _XMXICO4& _XMXICO4::operator=
(
CONST UINT64 Packed
)
{
v = Packed;
return *this;
}
/****************************************************************************
*
* XMICON4 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMICON4::_XMICON4
(
UINT64 Packed
)
{
v = Packed;
}
//------------------------------------------------------------------------------
XMFINLINE _XMICON4::_XMICON4
(
FLOAT _x,
FLOAT _y,
FLOAT _z,
FLOAT _w
)
{
XMStoreIcoN4(this, XMVectorSet(_x, _y, _z, _w));
}
//------------------------------------------------------------------------------
XMFINLINE _XMICON4::_XMICON4
(
CONST FLOAT* pArray
)
{
XMStoreIcoN4(this, XMLoadFloat4((XMFLOAT4*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMICON4::operator UINT64 ()
{
return v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMICON4& _XMICON4::operator=
(
CONST _XMICON4& IcoN4
)
{
v = IcoN4.v;
return *this;
}
//------------------------------------------------------------------------------
XMFINLINE _XMICON4& _XMICON4::operator=
(
CONST UINT64 Packed
)
{
v = Packed;
return *this;
}
/****************************************************************************
*
* XMICO4 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMICO4::_XMICO4
(
UINT64 Packed
)
{
v = Packed;
}
//------------------------------------------------------------------------------
XMFINLINE _XMICO4::_XMICO4
(
FLOAT _x,
FLOAT _y,
FLOAT _z,
FLOAT _w
)
{
XMStoreIco4(this, XMVectorSet(_x, _y, _z, _w));
}
//------------------------------------------------------------------------------
XMFINLINE _XMICO4::_XMICO4
(
CONST FLOAT* pArray
)
{
XMStoreIco4(this, XMLoadFloat4((XMFLOAT4*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMICO4::operator UINT64 ()
{
return v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMICO4& _XMICO4::operator=
(
CONST _XMICO4& Ico4
)
{
v = Ico4.v;
return *this;
}
//------------------------------------------------------------------------------
XMFINLINE _XMICO4& _XMICO4::operator=
(
CONST UINT64 Packed
)
{
v = Packed;
return *this;
}
/****************************************************************************
*
* XMUICON4 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMUICON4::_XMUICON4
(
UINT64 Packed
)
{
v = Packed;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUICON4::_XMUICON4
(
FLOAT _x,
FLOAT _y,
FLOAT _z,
FLOAT _w
)
{
XMStoreUIcoN4(this, XMVectorSet(_x, _y, _z, _w));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUICON4::_XMUICON4
(
CONST FLOAT* pArray
)
{
XMStoreUIcoN4(this, XMLoadFloat4((XMFLOAT4*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUICON4::operator UINT64 ()
{
return v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUICON4& _XMUICON4::operator=
(
CONST _XMUICON4& UIcoN4
)
{
v = UIcoN4.v;
return *this;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUICON4& _XMUICON4::operator=
(
CONST UINT64 Packed
)
{
v = Packed;
return *this;
}
/****************************************************************************
*
* XMUICO4 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMUICO4::_XMUICO4
(
UINT64 Packed
)
{
v = Packed;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUICO4::_XMUICO4
(
FLOAT _x,
FLOAT _y,
FLOAT _z,
FLOAT _w
)
{
XMStoreUIco4(this, XMVectorSet(_x, _y, _z, _w));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUICO4::_XMUICO4
(
CONST FLOAT* pArray
)
{
XMStoreUIco4(this, XMLoadFloat4((XMFLOAT4*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUICO4::operator UINT64 ()
{
return v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUICO4& _XMUICO4::operator=
(
CONST _XMUICO4& UIco4
)
{
v = UIco4.v;
return *this;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUICO4& _XMUICO4::operator=
(
CONST UINT64 Packed
)
{
v = Packed;
return *this;
}
/****************************************************************************
*
* XMCOLOR4 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMCOLOR::_XMCOLOR
(
UINT Color
)
{
c = Color;
}
//------------------------------------------------------------------------------
XMFINLINE _XMCOLOR::_XMCOLOR
(
FLOAT _x,
FLOAT _y,
FLOAT _z,
FLOAT _w
)
{
XMStoreColor(this, XMVectorSet(_x, _y, _z, _w));
}
//------------------------------------------------------------------------------
XMFINLINE _XMCOLOR::_XMCOLOR
(
CONST FLOAT* pArray
)
{
XMStoreColor(this, XMLoadFloat4((XMFLOAT4*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMCOLOR::operator UINT ()
{
return c;
}
//------------------------------------------------------------------------------
XMFINLINE _XMCOLOR& _XMCOLOR::operator=
(
CONST _XMCOLOR& Color
)
{
c = Color.c;
return *this;
}
//------------------------------------------------------------------------------
XMFINLINE _XMCOLOR& _XMCOLOR::operator=
(
CONST UINT Color
)
{
c = Color;
return *this;
}
/****************************************************************************
*
* XMBYTEN4 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMBYTEN4::_XMBYTEN4
(
CHAR _x,
CHAR _y,
CHAR _z,
CHAR _w
)
{
x = _x;
y = _y;
z = _z;
w = _w;
}
//------------------------------------------------------------------------------
XMFINLINE _XMBYTEN4::_XMBYTEN4
(
UINT _v
)
{
v = _v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMBYTEN4::_XMBYTEN4
(
CONST CHAR* pArray
)
{
x = pArray[0];
y = pArray[1];
z = pArray[2];
w = pArray[3];
}
//------------------------------------------------------------------------------
XMFINLINE _XMBYTEN4::_XMBYTEN4
(
FLOAT _x,
FLOAT _y,
FLOAT _z,
FLOAT _w
)
{
XMStoreByteN4(this, XMVectorSet(_x, _y, _z, _w));
}
//------------------------------------------------------------------------------
XMFINLINE _XMBYTEN4::_XMBYTEN4
(
CONST FLOAT* pArray
)
{
XMStoreByteN4(this, XMLoadFloat4((XMFLOAT4*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMBYTEN4& _XMBYTEN4::operator=
(
CONST _XMBYTEN4& ByteN4
)
{
x = ByteN4.x;
y = ByteN4.y;
z = ByteN4.z;
w = ByteN4.w;
return *this;
}
/****************************************************************************
*
* XMBYTE4 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMBYTE4::_XMBYTE4
(
CHAR _x,
CHAR _y,
CHAR _z,
CHAR _w
)
{
x = _x;
y = _y;
z = _z;
w = _w;
}
//------------------------------------------------------------------------------
XMFINLINE _XMBYTE4::_XMBYTE4
(
UINT _v
)
{
v = _v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMBYTE4::_XMBYTE4
(
CONST CHAR* pArray
)
{
x = pArray[0];
y = pArray[1];
z = pArray[2];
w = pArray[3];
}
//------------------------------------------------------------------------------
XMFINLINE _XMBYTE4::_XMBYTE4
(
FLOAT _x,
FLOAT _y,
FLOAT _z,
FLOAT _w
)
{
XMStoreByte4(this, XMVectorSet(_x, _y, _z, _w));
}
//------------------------------------------------------------------------------
XMFINLINE _XMBYTE4::_XMBYTE4
(
CONST FLOAT* pArray
)
{
XMStoreByte4(this, XMLoadFloat4((XMFLOAT4*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMBYTE4& _XMBYTE4::operator=
(
CONST _XMBYTE4& Byte4
)
{
x = Byte4.x;
y = Byte4.y;
z = Byte4.z;
w = Byte4.w;
return *this;
}
/****************************************************************************
*
* XMUBYTEN4 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMUBYTEN4::_XMUBYTEN4
(
BYTE _x,
BYTE _y,
BYTE _z,
BYTE _w
)
{
x = _x;
y = _y;
z = _z;
w = _w;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUBYTEN4::_XMUBYTEN4
(
UINT _v
)
{
v = _v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUBYTEN4::_XMUBYTEN4
(
CONST BYTE* pArray
)
{
x = pArray[0];
y = pArray[1];
z = pArray[2];
w = pArray[3];
}
//------------------------------------------------------------------------------
XMFINLINE _XMUBYTEN4::_XMUBYTEN4
(
FLOAT _x,
FLOAT _y,
FLOAT _z,
FLOAT _w
)
{
XMStoreUByteN4(this, XMVectorSet(_x, _y, _z, _w));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUBYTEN4::_XMUBYTEN4
(
CONST FLOAT* pArray
)
{
XMStoreUByteN4(this, XMLoadFloat4((XMFLOAT4*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUBYTEN4& _XMUBYTEN4::operator=
(
CONST _XMUBYTEN4& UByteN4
)
{
x = UByteN4.x;
y = UByteN4.y;
z = UByteN4.z;
w = UByteN4.w;
return *this;
}
/****************************************************************************
*
* XMUBYTE4 operators
*
****************************************************************************/
//------------------------------------------------------------------------------
XMFINLINE _XMUBYTE4::_XMUBYTE4
(
BYTE _x,
BYTE _y,
BYTE _z,
BYTE _w
)
{
x = _x;
y = _y;
z = _z;
w = _w;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUBYTE4::_XMUBYTE4
(
UINT _v
)
{
v = _v;
}
//------------------------------------------------------------------------------
XMFINLINE _XMUBYTE4::_XMUBYTE4
(
CONST BYTE* pArray
)
{
x = pArray[0];
y = pArray[1];
z = pArray[2];
w = pArray[3];
}
//------------------------------------------------------------------------------
XMFINLINE _XMUBYTE4::_XMUBYTE4
(
FLOAT _x,
FLOAT _y,
FLOAT _z,
FLOAT _w
)
{
XMStoreUByte4(this, XMVectorSet(_x, _y, _z, _w));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUBYTE4::_XMUBYTE4
(
CONST FLOAT* pArray
)
{
XMStoreUByte4(this, XMLoadFloat4((XMFLOAT4*)pArray));
}
//------------------------------------------------------------------------------
XMFINLINE _XMUBYTE4& _XMUBYTE4::operator=
(
CONST _XMUBYTE4& UByte4
)
{
x = UByte4.x;
y = UByte4.y;
z = UByte4.z;
w = UByte4.w;
return *this;
}
#endif // __cplusplus
#if defined(_XM_NO_INTRINSICS_)
#undef XMISNAN
#undef XMISINF
#endif
#endif // __XNAMATHVECTOR_INL__
| [
"alexey.min@gmail.com"
] | alexey.min@gmail.com |
bfe8d59a818a9094d2a6bd129d354072de73016f | f0409cd1b74109f9ee11909ac7a6a20308b13db7 | /Linux64/vectors-riscv-none-gcc/riscv-none-embed/include/c++/8.1.0/cstdint | e27faffd7ab208e26f40a7d5e96520ef7834444a | [] | no_license | eroom1966/toolchains | 47b7256aac73d58cd07fe21b597ad861ef2fe04b | b7283d388be30e113bbf3a09c68ce7cf575cafb4 | refs/heads/master | 2020-05-24T09:36:46.481031 | 2019-11-14T12:34:39 | 2019-11-14T12:34:39 | 187,208,731 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,334 | // <cstdint> -*- C++ -*-
// Copyright (C) 2007-2018 Free Software Foundation, Inc.
//
// This file is part of the GNU ISO C++ Library. This library is free
// software; you can redistribute it and/or modify it under the
// terms of the GNU General Public License as published by the
// Free Software Foundation; either version 3, or (at your option)
// any later version.
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// Under Section 7 of GPL version 3, you are granted additional
// permissions described in the GCC Runtime Library Exception, version
// 3.1, as published by the Free Software Foundation.
// You should have received a copy of the GNU General Public License and
// a copy of the GCC Runtime Library Exception along with this program;
// see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
// <http://www.gnu.org/licenses/>.
/** @file include/cstdint
* This is a Standard C++ Library header.
*/
#ifndef _GLIBCXX_CSTDINT
#define _GLIBCXX_CSTDINT 1
#pragma GCC system_header
#if __cplusplus < 201103L
# include <bits/c++0x_warning.h>
#else
#include "../../../../../vectors-riscv-none-gcc/riscv-none-embed/include/c++/8.1.0/riscv-none-embed/bits/c++config.h"
#if _GLIBCXX_HAVE_STDINT_H
# include "../../../../../vectors-riscv-none-gcc/riscv-none-embed/include/c++/8.1.0/tr1/stdint.h"
#endif
#ifdef _GLIBCXX_USE_C99_STDINT_TR1
namespace std
{
using ::int8_t;
using ::int16_t;
using ::int32_t;
using ::int64_t;
using ::int_fast8_t;
using ::int_fast16_t;
using ::int_fast32_t;
using ::int_fast64_t;
using ::int_least8_t;
using ::int_least16_t;
using ::int_least32_t;
using ::int_least64_t;
using ::intmax_t;
using ::intptr_t;
using ::uint8_t;
using ::uint16_t;
using ::uint32_t;
using ::uint64_t;
using ::uint_fast8_t;
using ::uint_fast16_t;
using ::uint_fast32_t;
using ::uint_fast64_t;
using ::uint_least8_t;
using ::uint_least16_t;
using ::uint_least32_t;
using ::uint_least64_t;
using ::uintmax_t;
using ::uintptr_t;
} // namespace std
#endif // _GLIBCXX_USE_C99_STDINT_TR1
#endif // C++11
#endif // _GLIBCXX_CSTDINT
| [
"moore@imperas.com"
] | moore@imperas.com | |
9c8aba9bbedaeb2f8b31f80f9b3b0aef45172f4f | 26d4c3c02c21cb2d88b0838688f1e5e994303dd3 | /OCG.cpp | 1256379d58422e17d2b60dc5221ebe200d717f88 | [] | no_license | wherefree/Computer-Graphics-Homework | df4f94de60b30a073a8f3dcf3d16d52fe91d9163 | 04b3dd846acf57a2b379f491cb5390f2118d2aad | refs/heads/master | 2023-06-13T04:28:40.987799 | 2021-07-11T15:13:55 | 2021-07-11T15:13:55 | 376,738,628 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 136 | cpp | #include "OCG.h"
#include "CutLine.h"
#include "Line.h"
#include "Point.h"
#include "PointSet.h"
#include "Zdeep.h"
#include "TDpoint.h" | [
"1091021114@qq.com"
] | 1091021114@qq.com |
8006eb800735061993204e739c90851bc4f833a5 | b3241cb2d2761a084c219b6e854f8a65d0a6a59d | /estun/src/renderer/context/resources.h | df293e08a1419f6d8f980fb3dd07852c3577d573 | [
"MIT"
] | permissive | ibvfteh/watersim | b88bae9d3aa078d923db9d8e16ba8103c90917ea | 8a524f9290c49b84889785160ce875d524ed190b | refs/heads/master | 2020-12-04T05:35:04.492335 | 2020-05-12T16:48:12 | 2020-05-12T16:48:12 | 231,634,106 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 687 | h | #pragma once
#include "renderer/common.h"
#include "renderer/context/image_holder.h"
namespace estun
{
class SwapChain;
class DepthResources : public ImageHolder
{
public:
DepthResources(const VkExtent2D &extent, VkSampleCountFlagBits msaaSamples);
~DepthResources();
static VkFormat FindSupportedFormat(const std::vector<VkFormat> &candidates, VkImageTiling tiling, const VkFormatFeatureFlags &features);
static VkFormat FindDepthFormat();
static bool HasStencilComponent(const VkFormat &format);
};
class ColorResources : public ImageHolder
{
public:
ColorResources(const VkExtent2D &extent, VkSampleCountFlagBits msaaSamples);
~ColorResources();
};
} // namespace estun
| [
"ibvfteh@gmail.com"
] | ibvfteh@gmail.com |
5886bf482cafa3f1d652ecb2e74b58e4385b4f1c | e4292ab5dfb57c4d50cc514c369456b7d6715af4 | /cpp/BitManipulation/Fold.h | 6ba04d0adc26447ac5e6ba2f8908a7e7bfba7a52 | [
"MIT"
] | permissive | tsmanner/sandbox | e80d4f9213b436b2b0a7da12bc29fdc50e5fec6b | 53b07c49b8cb5d2fb86cec5c1464a02fd1f4c673 | refs/heads/master | 2021-07-25T05:23:53.944411 | 2020-08-05T18:44:27 | 2020-08-05T18:44:27 | 205,987,288 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,078 | h | #ifndef Fold_h
#define Fold_h
template <int MSB, int LSB, int STEP, typename Scramble>
class Fold {
public:
// Query function, templated only with the index to look up
// Enabled if QUERY falls between MSB and LSB
template <int QUERY>
static constexpr typename std::enable_if<(MSB <= QUERY and QUERY <= LSB), int>::type
query() {
// Query the Scramble by normalizing this value to the range [0:STEP)
// (QUERY - MSB) % STEP
// then put it back into the folding range
// ScrambleResult + RANGE_MSB
// StepCount = (QUERY - MSB) / STEP
// RANGE_MSB = MSB + StepCount * STEP
// Result = ScrambleResult + MSB + (((QUERY - MSB) / STEP) * STEP)
return Scramble::template query<(QUERY - MSB) % STEP>() + MSB + (((QUERY - MSB) / STEP) * STEP);
}
// Query function, templated only with the index to look up
// Enabled if QUERY does not fall between MSB and LSB
template <int QUERY>
static constexpr typename std::enable_if<(!(MSB <= QUERY and QUERY <= LSB)), int>::type
query() {
return QUERY;
}
};
#endif
| [
"tsmanner@us.ibm.com"
] | tsmanner@us.ibm.com |
de12c547a9f7c2a5add5edccb7aa0a596e2078c8 | 229ebc93bb4e2d237517a3e322bdb88ebe67c8f9 | /algadv-lab2/aula6/a.cpp | 8ca284be9dd95dae0d719fb22bdd29d050483e1d | [] | no_license | fredbr/usp | d145e6798c8e5617b18d3bcedcb8b7a36fa5f4ee | 3e54a0167048ab4d25727876a87f60e683a258a4 | refs/heads/master | 2023-05-18T23:54:43.425159 | 2021-05-27T20:56:36 | 2021-05-27T20:56:36 | 181,331,797 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,031 | cpp | #include <bits/stdc++.h>
#define ff first
#define ss second
#define pb push_back
#define eb emplace_back
#define all(x) begin(x), end(x)
#define rall(x) rbegin(x), rend(x)
#define clr(x, c) memset((x), (c), sizeof((x)))
using namespace std;
using ll = long long;
using ii = pair<int, int>;
int const inf = 0x3f3f3f3f;
ll const linf = 0x3f3f3f3f3f3f3f3f;
constexpr int maxn = 30001;
constexpr int coins[] = {
1, 5, 10, 25, 50
};
int main() {
ios_base::sync_with_stdio(false), cin.tie(nullptr);
vector<long long> dp(maxn);
dp[0] = 1;
for (int c : coins) {
for (int i = maxn-1; i > 0; i--) {
for (int amt = 1; amt * c <= i; amt++) {
dp[i] += dp[i - amt*c];
}
}
}
int x;
while (cin >> x) {
if (dp[x] == 1) {
cout << "There is only 1 way to produce " << x << " cents change.\n";
}
else {
cout << "There are " << dp[x] << " ways to produce " << x << " cents change.\n";
}
}
}
| [
"fredericobsr@gmail.com"
] | fredericobsr@gmail.com |
68ea2f562d3b3e854227ecc6674214129aa70163 | cd8e140510f694df5f66b7acc0454ddc40e8be52 | /renderer/surface_render.h | 48aefa2103efd94e396f8a1e81f69e612e365f32 | [] | no_license | HaoLi-China/Mobility-Reconstruction | 721dc0c22ab1b4da12046b9bf6238267c1d20b95 | 7c4c02bffe0ff0a14e9f7189fad4c7ebf1404e86 | refs/heads/master | 2020-04-15T23:56:07.235922 | 2015-08-29T02:37:13 | 2015-08-29T02:37:13 | 40,639,055 | 1 | 1 | null | null | null | null | UTF-8 | C++ | false | false | 1,539 | h |
#ifndef _RENDERER_SURFACE_RENDERER_H_
#define _RENDERER_SURFACE_RENDERER_H_
#include "renderer_common.h"
#include "render.h"
#include "rendering_styles.h"
#include "point_as_sphere.h"
#include "../geom/map_attributes.h"
class Map;
class RENDERER_API SurfaceRender : public Render, public PointAsSphere
{
public:
SurfaceRender(Map* obj) ;
Map* target() const;
virtual void draw() ;
virtual void blink() ;
//___________________________________________________________
bool smooth_shading() const ;
void set_smooth_shading(bool x) ;
const SurfaceStyle& surface_style() const ;
void set_surface_style(const SurfaceStyle& x) ;
const EdgeStyle& mesh_style() const ;
void set_mesh_style(const EdgeStyle& x) ;
const EdgeStyle& border_style() const ;
void set_border_style(const EdgeStyle& x) ;
const PointStyle& vertices_style() const ;
void set_vertices_style(const PointStyle& x) ;
const PointStyle& anchors_style() const ;
void set_anchors_style(const PointStyle& x) ;
const PointStyle& pins_style() const ;
void set_pins_style(const PointStyle& x) ;
protected:
virtual void draw_surface() = 0 ;
virtual void draw_mesh() = 0 ;
virtual void draw_vertices() = 0 ;
virtual void draw_anchors() = 0 ;
virtual void draw_border() = 0 ;
virtual void draw_pins() = 0 ;
protected:
bool smooth_shading_ ;
SurfaceStyle surface_style_ ;
EdgeStyle mesh_style_ ;
EdgeStyle border_style_ ;
PointStyle vertices_style_ ;
PointStyle anchors_style_ ;
PointStyle pins_style_ ;
} ;
#endif
| [
"gwwan.nudt@gmail.com"
] | gwwan.nudt@gmail.com |
ae76d66024663bc1d4ddf543318c29299d5364af | 16be59da3e5d37345b3f0a05489dfa1a85c99971 | /ControlData/CLoaderFile.h | 95477a578d63ea6454715a3903830027bdf3f59f | [] | no_license | chizon/hdr | d3bb9cb6a71e8fa5c4d0c29f945f0d89075e7686 | 4a92206a9722f98966aae007975debce333623db | refs/heads/master | 2021-01-12T21:04:29.627559 | 2015-05-26T20:14:21 | 2015-05-26T20:14:21 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 706 | h | #ifndef _CLOADERFILE_H_
#define _CLOADERFILE_H_
class CLoaderFile
{
public:
bool Read (bool& bVal);
bool Read (char& nVal);
bool Read (unsigned char& cVal);
bool Read (short& nVal);
bool Read (unsigned short& nVal);
bool Read (int& nVal);
bool Read (unsigned int& nVal);
bool Read (char* pChar,int nLen);
bool Read (CString &str,int nLen);
bool Read (unsigned int* pInt,int nInt);
bool Read (int* pInt,int nInt);
bool SeekIdentString (CString& strIdent);
bool ReadCompactString (CString& strCS);
bool IsOpen();
CLoaderFile();
CLoaderFile(const char* pszFile);
void Close();
virtual ~CLoaderFile();
private:
FILE* m_pFile;
};
#endif //_CLOADERFILE_H_
| [
"michael@sys-map.com"
] | michael@sys-map.com |
cc08b18d81a209a5bbcc23d46fd1a8595ad0887d | 7ecb6dca0861845ebe347d11632216241a681071 | /src/drivers/optical_flow/pmw3901/pmw3901_main.cpp | 3c59adc3b246e7e459889289d9d2b2a29dcb64c2 | [
"BSD-3-Clause"
] | permissive | tonirosendahl/Thunderbird | 5c25dfaf40c43980e5f55abd2b2dfff92c6ea20b | d67045c1acd4629335f439ecacd9d62e2e163b7b | refs/heads/Typhoon_H_480 | 2023-04-04T08:40:07.173694 | 2022-07-17T11:45:04 | 2022-07-17T11:45:04 | 221,052,042 | 9 | 3 | BSD-3-Clause | 2020-01-24T11:47:11 | 2019-11-11T19:14:58 | C++ | UTF-8 | C++ | false | false | 3,965 | cpp | /****************************************************************************
*
* Copyright (c) 2018 PX4 Development Team. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in
* the documentation and/or other materials provided with the
* distribution.
* 3. Neither the name PX4 nor the names of its contributors may be
* used to endorse or promote products derived from this software
* without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
* FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
* COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
* OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
* AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
* ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*
****************************************************************************/
#include "PMW3901.hpp"
/*
* Driver 'main' command.
*/
extern "C" __EXPORT int pmw3901_main(int argc, char *argv[]);
/**
* Local functions in support of the shell command.
*/
namespace pmw3901
{
PMW3901 *g_dev;
void start(int spi_bus);
void stop();
void test();
void reset();
void info();
void usage();
/**
* Start the driver.
*/
void
start(int spi_bus)
{
if (g_dev != nullptr) {
errx(1, "already started");
}
/* create the driver */
g_dev = new PMW3901(spi_bus, (enum Rotation)0);
if (g_dev == nullptr) {
goto fail;
}
if (OK != g_dev->init()) {
goto fail;
}
exit(0);
fail:
if (g_dev != nullptr) {
delete g_dev;
g_dev = nullptr;
}
errx(1, "driver start failed");
}
/**
* Stop the driver
*/
void stop()
{
if (g_dev != nullptr) {
delete g_dev;
g_dev = nullptr;
} else {
errx(1, "driver not running");
}
exit(0);
}
/**
* Print a little info about the driver.
*/
void
info()
{
if (g_dev == nullptr) {
errx(1, "driver not running");
}
printf("state @ %p\n", g_dev);
g_dev->print_info();
exit(0);
}
/**
* Print a little info about how to start/stop/use the driver
*/
void usage()
{
PX4_INFO("usage: pmw3901 {start|test|reset|info'}");
PX4_INFO(" [-b SPI_BUS]");
}
} // namespace pmw3901
int
pmw3901_main(int argc, char *argv[])
{
if (argc < 2) {
pmw3901::usage();
return PX4_ERROR;
}
// don't exit from getopt loop to leave getopt global variables in consistent state,
// set error flag instead
bool err_flag = false;
int ch;
int myoptind = 1;
const char *myoptarg = nullptr;
int spi_bus = PMW3901_BUS;
while ((ch = px4_getopt(argc, argv, "b:", &myoptind, &myoptarg)) != EOF) {
switch (ch) {
case 'b':
spi_bus = (uint8_t)atoi(myoptarg);
break;
default:
err_flag = true;
break;
}
}
if (err_flag) {
pmw3901::usage();
return PX4_ERROR;
}
/*
* Start/load the driver.
*/
if (!strcmp(argv[myoptind], "start")) {
pmw3901::start(spi_bus);
}
/*
* Stop the driver
*/
if (!strcmp(argv[myoptind], "stop")) {
pmw3901::stop();
}
/*
* Print driver information.
*/
if (!strcmp(argv[myoptind], "info") || !strcmp(argv[myoptind], "status")) {
pmw3901::info();
}
pmw3901::usage();
return PX4_ERROR;
}
| [
"daniel@agar.ca"
] | daniel@agar.ca |
910086bb9a666ae9c744dc1f7db47bed4d4b15ba | 700afb9978066df27666c3f2f79615b7180bd163 | /include/constants.hpp | ec4de00f8503e468296ff2f768287e53a40cb8e7 | [] | no_license | Iverian/mke2 | 9ba9972a30be962e9d9787231a484e73158ffbe8 | 22d336baa9e24f6c898e3c4352c005f8ebfdde97 | refs/heads/master | 2020-04-14T17:54:11.985800 | 2019-02-01T15:06:04 | 2019-02-01T15:06:04 | 163,998,487 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,175 | hpp | #ifndef MKE2_INCLUDE_CONSTANTS_HPP_
#define MKE2_INCLUDE_CONSTANTS_HPP_
#include <common_types.hpp>
// #define MKE2_DENSE_SOLVE
namespace cnst {
static constexpr Index scale = 10;
static constexpr Index max_iter = 100000;
static constexpr Value xdim = 200.;
static constexpr Value ydim = 40.;
static constexpr Value zdim = 40.;
static constexpr Value init = 0.;
static constexpr Value pi = 3.141592653589; // 1
static constexpr Value p = 1e5; // Па
static constexpr Value mu = 1e3; // Па/м
static constexpr Value E = 212e9; // Па
static constexpr Value omega = 2e4 * pi; // Гц
static constexpr Value nu = 0.29; // 1
static constexpr Value rho = 10210; // кг / м^3
static constexpr Value L[2]
= {E * nu / ((1 + nu) * (1 - 2 * nu)), E / (2 * (1 + nu))};
static constexpr Value C[36] = {
L[0] + 2 * L[1], L[0], L[0], 0, 0, 0, //
L[0], L[0] + 2 * L[1], L[0], 0, 0, 0, //
L[0], L[0], L[0] + 2 * L[1], 0, 0, 0, //
0, 0, 0, L[1], 0, 0, //
0, 0, 0, 0, L[1], 0, //
0, 0, 0, 0, 0, L[1] //
};
}
#endif // MKE2_INCLUDE_CONSTANTS_HPP_ | [
"41ways1ucky@gmail.com"
] | 41ways1ucky@gmail.com |
562e5dd90fe52401850acab4cc7d06fa05ee7fd2 | b8d672c6acfd438100dee757eb307ad8104bbaa8 | /1015.cpp | 44fe5ca79e719fab4d748def67cf8f91c83adffb | [] | no_license | zhang35/PAT-Basic-Level | 4925b74fa39f1e1dbe19e2012a62194c9a6da669 | 9f7612a1800c8955bc384ddbc33954152f23b26d | refs/heads/master | 2020-09-25T11:06:06.582651 | 2020-07-22T23:22:56 | 2020-07-22T23:22:56 | 225,992,475 | 9 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,626 | cpp | //#include <iostream>
#include <stdio.h>
#include <vector>
#include <algorithm>
using namespace std;
struct Student{
int id;
int moral;
int talent;
};
bool cmp(Student s1, Student s2){
int sum1 = s1.moral + s1.talent;
int sum2 = s2.moral + s2.talent;
if (sum1==sum2) {
if (s1.moral == s2.moral){
return s1.id < s2.id;
}
else {
return s1.moral > s2.moral;
}
}
else {
return sum1 > sum2;
}
}
int main()
{
int n;
int l;
int h;
//cin >> n >> l >> h;
scanf("%d%d%d", &n, &l, &h);
vector <vector<Student> > t(4); //分为4档
int m = 0;
for (int i=0; i<n; i++){
Student stu;
//cin >> stu.id >> stu.moral >> stu.talent;
scanf("%d%d%d", &stu.id, &stu.moral, &stu.talent);
if (stu.moral>=l && stu.talent>=l){
if (stu.moral>=h && stu.talent>=h){
t[0].push_back(stu);
}
else if (stu.moral>=h){
t[1].push_back(stu);
}
else if (stu.moral>=stu.talent){
t[2].push_back(stu);
}
else {
t[3].push_back(stu);
}
m++;
}
}
//cout << m << endl;
printf("%d\n", m);
for (int i=0; i<4; i++){
sort(t[i].begin(), t[i].end(), cmp);
for (int j=0; j<t[i].size(); j++){
//cout << t[i][j].id << " "<< t[i][j].moral << " "<< t[i][j].talent << endl;
printf("%d %d %d\n", t[i][j].id, t[i][j].moral, t[i][j].talent);
}
}
return 0;
}
| [
"zhangjqfriend@126.com"
] | zhangjqfriend@126.com |
205792f7e59d86adcede54ea7e52901df17e9ef2 | 832f8a731d307e7fca61adf11bd7bcdd9b402e65 | /submodules/externals/libvpx/test/test_libvpx.cc | c44c430d61a0e59d172b93a80d674053c88bc125 | [] | no_license | mohmo42/linphone-android_v2202_project | 84fcbd663d0ea16358a5b249c52d85254425fb6f | 64c98df64296a95244a5d87ba955bd3fea0f9720 | refs/heads/master | 2021-06-13T04:30:13.609322 | 2017-04-10T15:28:50 | 2017-04-10T15:28:50 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,389 | cc | /*
* Copyright (c) 2012 The WebM project authors. All Rights Reserved.
*
* Use of this source code is governed by a BSD-style license
* that can be found in the LICENSE file in the root of the source
* tree. An additional intellectual property rights grant can be found
* in the file PATENTS. All contributing project authors may
* be found in the AUTHORS file in the root of the source tree.
*/
#include <string>
#include "vpx_config.h"
#if ARCH_X86 || ARCH_X86_64
extern "C" {
#include "vpx_ports/x86.h"
}
#endif
#include "third_party/googletest/src/include/gtest/gtest.h"
static void append_gtest_filter(const char *str) {
std::string filter = ::testing::FLAGS_gtest_filter;
filter += str;
::testing::FLAGS_gtest_filter = filter;
}
int main(int argc, char **argv) {
::testing::InitGoogleTest(&argc, argv);
#if ARCH_X86 || ARCH_X86_64
const int simd_caps = x86_simd_caps();
if(!(simd_caps & HAS_MMX))
append_gtest_filter(":-MMX/*");
if(!(simd_caps & HAS_SSE))
append_gtest_filter(":-SSE/*");
if(!(simd_caps & HAS_SSE2))
append_gtest_filter(":-SSE2/*");
if(!(simd_caps & HAS_SSE3))
append_gtest_filter(":-SSE3/*");
if(!(simd_caps & HAS_SSSE3))
append_gtest_filter(":-SSSE3/*");
if(!(simd_caps & HAS_SSE4_1))
append_gtest_filter(":-SSE4_1/*");
#endif
return RUN_ALL_TESTS();
}
| [
"2270992199@qq.com"
] | 2270992199@qq.com |
e59c4f5a01817e25e159ba73e5426a7fe07ab99a | ac16a937f32602cf16114463f8e875a972f64c27 | /docs/dolfin/1.0.beta2/cpp/source/demo/undocumented/poisson1D/cpp/Poisson.h | f06f7e1fb4074b373d9613ff597034b7564dfe02 | [] | no_license | mparno/fenics-web | 2073248da6f9918ffedbe9be8a3433bc1cbb7ffb | 7202752da876b1f9ab02c1d5a5f28ff5da526528 | refs/heads/master | 2021-05-05T04:45:46.436236 | 2016-12-06T20:25:44 | 2016-12-06T20:25:44 | 118,628,385 | 2 | 0 | null | 2018-01-23T15:21:47 | 2018-01-23T15:21:46 | null | UTF-8 | C++ | false | false | 52,028 | h | // This code conforms with the UFC specification version 2.0.2
// and was automatically generated by FFC version 1.0-beta+.
//
// This code was generated with the option '-l dolfin' and
// contains DOLFIN-specific wrappers that depend on DOLFIN.
//
// This code was generated with the following parameters:
//
// cache_dir: ''
// convert_exceptions_to_warnings: False
// cpp_optimize: False
// cpp_optimize_flags: '-O2'
// epsilon: 1e-14
// error_control: False
// form_postfix: True
// format: 'dolfin'
// log_level: 10
// log_prefix: ''
// no_ferari: True
// optimize: True
// output_dir: '.'
// precision: 15
// quadrature_degree: 'auto'
// quadrature_rule: 'auto'
// representation: 'auto'
// split: False
// swig_binary: 'swig'
// swig_path: ''
#ifndef __POISSON_H
#define __POISSON_H
#include <cmath>
#include <stdexcept>
#include <fstream>
#include <ufc.h>
/// This class defines the interface for a finite element.
class poisson_finite_element_0: public ufc::finite_element
{
public:
/// Constructor
poisson_finite_element_0() : ufc::finite_element()
{
// Do nothing
}
/// Destructor
virtual ~poisson_finite_element_0()
{
// Do nothing
}
/// Return a string identifying the finite element
virtual const char* signature() const
{
return "FiniteElement('Lagrange', Cell('interval', Space(1)), 1, None)";
}
/// Return the cell shape
virtual ufc::shape cell_shape() const
{
return ufc::interval;
}
/// Return the topological dimension of the cell shape
virtual unsigned int topological_dimension() const
{
return 1;
}
/// Return the geometric dimension of the cell shape
virtual unsigned int geometric_dimension() const
{
return 1;
}
/// Return the dimension of the finite element function space
virtual unsigned int space_dimension() const
{
return 2;
}
/// Return the rank of the value space
virtual unsigned int value_rank() const
{
return 0;
}
/// Return the dimension of the value space for axis i
virtual unsigned int value_dimension(unsigned int i) const
{
return 1;
}
/// Evaluate basis function i at given point in cell
virtual void evaluate_basis(unsigned int i,
double* values,
const double* coordinates,
const ufc::cell& c) const
{
// Extract vertex coordinates
const double * const * x = c.coordinates;
// Compute Jacobian of affine map from reference cell
const double J_00 = x[1][0] - x[0][0];
// Compute determinant of Jacobian
// Compute inverse of Jacobian
// Get coordinates and map to the reference (FIAT) element
double X = (2.0*coordinates[0] - x[0][0] - x[1][0]) / J_00;
// Reset values.
*values = 0.0;
switch (i)
{
case 0:
{
// Array of basisvalues.
double basisvalues[2] = {0.0, 0.0};
// Declare helper variables.
// Compute basisvalues.
basisvalues[0] = 1.0;
basisvalues[1] = X;
for (unsigned int r = 0; r < 2; r++)
{
basisvalues[r] *= std::sqrt((0.5 + r));
}// end loop over 'r'
// Table(s) of coefficients.
static const double coefficients0[2] = \
{0.707106781186547, -0.408248290463863};
// Compute value(s).
for (unsigned int r = 0; r < 2; r++)
{
*values += coefficients0[r]*basisvalues[r];
}// end loop over 'r'
break;
}
case 1:
{
// Array of basisvalues.
double basisvalues[2] = {0.0, 0.0};
// Declare helper variables.
// Compute basisvalues.
basisvalues[0] = 1.0;
basisvalues[1] = X;
for (unsigned int r = 0; r < 2; r++)
{
basisvalues[r] *= std::sqrt((0.5 + r));
}// end loop over 'r'
// Table(s) of coefficients.
static const double coefficients0[2] = \
{0.707106781186547, 0.408248290463863};
// Compute value(s).
for (unsigned int r = 0; r < 2; r++)
{
*values += coefficients0[r]*basisvalues[r];
}// end loop over 'r'
break;
}
}
}
/// Evaluate all basis functions at given point in cell
virtual void evaluate_basis_all(double* values,
const double* coordinates,
const ufc::cell& c) const
{
// Helper variable to hold values of a single dof.
double dof_values = 0.0;
// Loop dofs and call evaluate_basis.
for (unsigned int r = 0; r < 2; r++)
{
evaluate_basis(r, &dof_values, coordinates, c);
values[r] = dof_values;
}// end loop over 'r'
}
/// Evaluate order n derivatives of basis function i at given point in cell
virtual void evaluate_basis_derivatives(unsigned int i,
unsigned int n,
double* values,
const double* coordinates,
const ufc::cell& c) const
{
// Extract vertex coordinates
const double * const * x = c.coordinates;
// Compute Jacobian of affine map from reference cell
const double J_00 = x[1][0] - x[0][0];
// Compute determinant of Jacobian
const double detJ = J_00;
// Compute inverse of Jacobian
const double K_00 = 1.0 / detJ;
// Get coordinates and map to the reference (FIAT) element
double X = (2.0*coordinates[0] - x[0][0] - x[1][0]) / J_00;
// Compute number of derivatives.
unsigned int num_derivatives = 1;
for (unsigned int r = 0; r < n; r++)
{
num_derivatives *= 1;
}// end loop over 'r'
// Declare pointer to two dimensional array that holds combinations of derivatives and initialise
unsigned int **combinations = new unsigned int *[num_derivatives];
for (unsigned int row = 0; row < num_derivatives; row++)
{
combinations[row] = new unsigned int [n];
for (unsigned int col = 0; col < n; col++)
combinations[row][col] = 0;
}
// Generate combinations of derivatives
for (unsigned int row = 1; row < num_derivatives; row++)
{
for (unsigned int num = 0; num < row; num++)
{
for (unsigned int col = n-1; col+1 > 0; col--)
{
if (combinations[row][col] + 1 > 0)
combinations[row][col] = 0;
else
{
combinations[row][col] += 1;
break;
}
}
}
}
// Compute inverse of Jacobian
const double Jinv[1][1] = {{K_00}};
// Declare transformation matrix
// Declare pointer to two dimensional array and initialise
double **transform = new double *[num_derivatives];
for (unsigned int j = 0; j < num_derivatives; j++)
{
transform[j] = new double [num_derivatives];
for (unsigned int k = 0; k < num_derivatives; k++)
transform[j][k] = 1;
}
// Construct transformation matrix
for (unsigned int row = 0; row < num_derivatives; row++)
{
for (unsigned int col = 0; col < num_derivatives; col++)
{
for (unsigned int k = 0; k < n; k++)
transform[row][col] *= Jinv[combinations[col][k]][combinations[row][k]];
}
}
// Reset values. Assuming that values is always an array.
for (unsigned int r = 0; r < num_derivatives; r++)
{
values[r] = 0.0;
}// end loop over 'r'
switch (i)
{
case 0:
{
// Array of basisvalues.
double basisvalues[2] = {0.0, 0.0};
// Declare helper variables.
// Compute basisvalues.
basisvalues[0] = 1.0;
basisvalues[1] = X;
for (unsigned int r = 0; r < 2; r++)
{
basisvalues[r] *= std::sqrt((0.5 + r));
}// end loop over 'r'
// Table(s) of coefficients.
static const double coefficients0[2] = \
{0.707106781186547, -0.408248290463863};
// Tables of derivatives of the polynomial base (transpose).
static const double dmats0[2][2] = \
{{0.0, 0.0},
{3.46410161513775, 0.0}};
// Compute reference derivatives.
// Declare pointer to array of derivatives on FIAT element.
double *derivatives = new double[num_derivatives];
for (unsigned int r = 0; r < num_derivatives; r++)
{
derivatives[r] = 0.0;
}// end loop over 'r'
// Declare derivative matrix (of polynomial basis).
double dmats[2][2] = \
{{1.0, 0.0},
{0.0, 1.0}};
// Declare (auxiliary) derivative matrix (of polynomial basis).
double dmats_old[2][2] = \
{{1.0, 0.0},
{0.0, 1.0}};
// Loop possible derivatives.
for (unsigned int r = 0; r < num_derivatives; r++)
{
// Resetting dmats values to compute next derivative.
for (unsigned int t = 0; t < 2; t++)
{
for (unsigned int u = 0; u < 2; u++)
{
dmats[t][u] = 0.0;
if (t == u)
{
dmats[t][u] = 1.0;
}
}// end loop over 'u'
}// end loop over 't'
// Looping derivative order to generate dmats.
for (unsigned int s = 0; s < n; s++)
{
// Updating dmats_old with new values and resetting dmats.
for (unsigned int t = 0; t < 2; t++)
{
for (unsigned int u = 0; u < 2; u++)
{
dmats_old[t][u] = dmats[t][u];
dmats[t][u] = 0.0;
}// end loop over 'u'
}// end loop over 't'
// Update dmats using an inner product.
if (combinations[r][s] == 0)
{
for (unsigned int t = 0; t < 2; t++)
{
for (unsigned int u = 0; u < 2; u++)
{
for (unsigned int tu = 0; tu < 2; tu++)
{
dmats[t][u] += dmats0[t][tu]*dmats_old[tu][u];
}// end loop over 'tu'
}// end loop over 'u'
}// end loop over 't'
}
}// end loop over 's'
for (unsigned int s = 0; s < 2; s++)
{
for (unsigned int t = 0; t < 2; t++)
{
derivatives[r] += coefficients0[s]*dmats[s][t]*basisvalues[t];
}// end loop over 't'
}// end loop over 's'
}// end loop over 'r'
// Transform derivatives back to physical element
for (unsigned int r = 0; r < num_derivatives; r++)
{
for (unsigned int s = 0; s < num_derivatives; s++)
{
values[r] += transform[r][s]*derivatives[s];
}// end loop over 's'
}// end loop over 'r'
// Delete pointer to array of derivatives on FIAT element
delete [] derivatives;
// Delete pointer to array of combinations of derivatives and transform
for (unsigned int r = 0; r < num_derivatives; r++)
{
delete [] combinations[r];
}// end loop over 'r'
delete [] combinations;
for (unsigned int r = 0; r < num_derivatives; r++)
{
delete [] transform[r];
}// end loop over 'r'
delete [] transform;
break;
}
case 1:
{
// Array of basisvalues.
double basisvalues[2] = {0.0, 0.0};
// Declare helper variables.
// Compute basisvalues.
basisvalues[0] = 1.0;
basisvalues[1] = X;
for (unsigned int r = 0; r < 2; r++)
{
basisvalues[r] *= std::sqrt((0.5 + r));
}// end loop over 'r'
// Table(s) of coefficients.
static const double coefficients0[2] = \
{0.707106781186547, 0.408248290463863};
// Tables of derivatives of the polynomial base (transpose).
static const double dmats0[2][2] = \
{{0.0, 0.0},
{3.46410161513775, 0.0}};
// Compute reference derivatives.
// Declare pointer to array of derivatives on FIAT element.
double *derivatives = new double[num_derivatives];
for (unsigned int r = 0; r < num_derivatives; r++)
{
derivatives[r] = 0.0;
}// end loop over 'r'
// Declare derivative matrix (of polynomial basis).
double dmats[2][2] = \
{{1.0, 0.0},
{0.0, 1.0}};
// Declare (auxiliary) derivative matrix (of polynomial basis).
double dmats_old[2][2] = \
{{1.0, 0.0},
{0.0, 1.0}};
// Loop possible derivatives.
for (unsigned int r = 0; r < num_derivatives; r++)
{
// Resetting dmats values to compute next derivative.
for (unsigned int t = 0; t < 2; t++)
{
for (unsigned int u = 0; u < 2; u++)
{
dmats[t][u] = 0.0;
if (t == u)
{
dmats[t][u] = 1.0;
}
}// end loop over 'u'
}// end loop over 't'
// Looping derivative order to generate dmats.
for (unsigned int s = 0; s < n; s++)
{
// Updating dmats_old with new values and resetting dmats.
for (unsigned int t = 0; t < 2; t++)
{
for (unsigned int u = 0; u < 2; u++)
{
dmats_old[t][u] = dmats[t][u];
dmats[t][u] = 0.0;
}// end loop over 'u'
}// end loop over 't'
// Update dmats using an inner product.
if (combinations[r][s] == 0)
{
for (unsigned int t = 0; t < 2; t++)
{
for (unsigned int u = 0; u < 2; u++)
{
for (unsigned int tu = 0; tu < 2; tu++)
{
dmats[t][u] += dmats0[t][tu]*dmats_old[tu][u];
}// end loop over 'tu'
}// end loop over 'u'
}// end loop over 't'
}
}// end loop over 's'
for (unsigned int s = 0; s < 2; s++)
{
for (unsigned int t = 0; t < 2; t++)
{
derivatives[r] += coefficients0[s]*dmats[s][t]*basisvalues[t];
}// end loop over 't'
}// end loop over 's'
}// end loop over 'r'
// Transform derivatives back to physical element
for (unsigned int r = 0; r < num_derivatives; r++)
{
for (unsigned int s = 0; s < num_derivatives; s++)
{
values[r] += transform[r][s]*derivatives[s];
}// end loop over 's'
}// end loop over 'r'
// Delete pointer to array of derivatives on FIAT element
delete [] derivatives;
// Delete pointer to array of combinations of derivatives and transform
for (unsigned int r = 0; r < num_derivatives; r++)
{
delete [] combinations[r];
}// end loop over 'r'
delete [] combinations;
for (unsigned int r = 0; r < num_derivatives; r++)
{
delete [] transform[r];
}// end loop over 'r'
delete [] transform;
break;
}
}
}
/// Evaluate order n derivatives of all basis functions at given point in cell
virtual void evaluate_basis_derivatives_all(unsigned int n,
double* values,
const double* coordinates,
const ufc::cell& c) const
{
// Compute number of derivatives.
unsigned int num_derivatives = 1;
for (unsigned int r = 0; r < n; r++)
{
num_derivatives *= 1;
}// end loop over 'r'
// Helper variable to hold values of a single dof.
double *dof_values = new double[num_derivatives];
for (unsigned int r = 0; r < num_derivatives; r++)
{
dof_values[r] = 0.0;
}// end loop over 'r'
// Loop dofs and call evaluate_basis_derivatives.
for (unsigned int r = 0; r < 2; r++)
{
evaluate_basis_derivatives(r, n, dof_values, coordinates, c);
for (unsigned int s = 0; s < num_derivatives; s++)
{
values[r*num_derivatives + s] = dof_values[s];
}// end loop over 's'
}// end loop over 'r'
// Delete pointer.
delete [] dof_values;
}
/// Evaluate linear functional for dof i on the function f
virtual double evaluate_dof(unsigned int i,
const ufc::function& f,
const ufc::cell& c) const
{
// Declare variables for result of evaluation.
double vals[1];
// Declare variable for physical coordinates.
double y[1];
const double * const * x = c.coordinates;
switch (i)
{
case 0:
{
y[0] = x[0][0];
f.evaluate(vals, y, c);
return vals[0];
break;
}
case 1:
{
y[0] = x[1][0];
f.evaluate(vals, y, c);
return vals[0];
break;
}
}
return 0.0;
}
/// Evaluate linear functionals for all dofs on the function f
virtual void evaluate_dofs(double* values,
const ufc::function& f,
const ufc::cell& c) const
{
// Declare variables for result of evaluation.
double vals[1];
// Declare variable for physical coordinates.
double y[1];
const double * const * x = c.coordinates;
y[0] = x[0][0];
f.evaluate(vals, y, c);
values[0] = vals[0];
y[0] = x[1][0];
f.evaluate(vals, y, c);
values[1] = vals[0];
}
/// Interpolate vertex values from dof values
virtual void interpolate_vertex_values(double* vertex_values,
const double* dof_values,
const ufc::cell& c) const
{
// Evaluate function and change variables
vertex_values[0] = dof_values[0];
vertex_values[1] = dof_values[1];
}
/// Map coordinate xhat from reference cell to coordinate x in cell
virtual void map_from_reference_cell(double* x,
const double* xhat,
const ufc::cell& c) const
{
throw std::runtime_error("map_from_reference_cell not yet implemented (introduced in UFC 2.0).");
}
/// Map from coordinate x in cell to coordinate xhat in reference cell
virtual void map_to_reference_cell(double* xhat,
const double* x,
const ufc::cell& c) const
{
throw std::runtime_error("map_to_reference_cell not yet implemented (introduced in UFC 2.0).");
}
/// Return the number of sub elements (for a mixed element)
virtual unsigned int num_sub_elements() const
{
return 0;
}
/// Create a new finite element for sub element i (for a mixed element)
virtual ufc::finite_element* create_sub_element(unsigned int i) const
{
return 0;
}
/// Create a new class instance
virtual ufc::finite_element* create() const
{
return new poisson_finite_element_0();
}
};
/// This class defines the interface for a local-to-global mapping of
/// degrees of freedom (dofs).
class poisson_dofmap_0: public ufc::dofmap
{
private:
unsigned int _global_dimension;
public:
/// Constructor
poisson_dofmap_0() : ufc::dofmap()
{
_global_dimension = 0;
}
/// Destructor
virtual ~poisson_dofmap_0()
{
// Do nothing
}
/// Return a string identifying the dofmap
virtual const char* signature() const
{
return "FFC dofmap for FiniteElement('Lagrange', Cell('interval', Space(1)), 1, None)";
}
/// Return true iff mesh entities of topological dimension d are needed
virtual bool needs_mesh_entities(unsigned int d) const
{
switch (d)
{
case 0:
{
return true;
break;
}
case 1:
{
return false;
break;
}
}
return false;
}
/// Initialize dofmap for mesh (return true iff init_cell() is needed)
virtual bool init_mesh(const ufc::mesh& m)
{
_global_dimension = m.num_entities[0];
return false;
}
/// Initialize dofmap for given cell
virtual void init_cell(const ufc::mesh& m,
const ufc::cell& c)
{
// Do nothing
}
/// Finish initialization of dofmap for cells
virtual void init_cell_finalize()
{
// Do nothing
}
/// Return the topological dimension of the associated cell shape
virtual unsigned int topological_dimension() const
{
return 1;
}
/// Return the geometric dimension of the associated cell shape
virtual unsigned int geometric_dimension() const
{
return 1;
}
/// Return the dimension of the global finite element function space
virtual unsigned int global_dimension() const
{
return _global_dimension;
}
/// Return the dimension of the local finite element function space for a cell
virtual unsigned int local_dimension(const ufc::cell& c) const
{
return 2;
}
/// Return the maximum dimension of the local finite element function space
virtual unsigned int max_local_dimension() const
{
return 2;
}
/// Return the number of dofs on each cell facet
virtual unsigned int num_facet_dofs() const
{
return 1;
}
/// Return the number of dofs associated with each cell entity of dimension d
virtual unsigned int num_entity_dofs(unsigned int d) const
{
switch (d)
{
case 0:
{
return 1;
break;
}
case 1:
{
return 0;
break;
}
}
return 0;
}
/// Tabulate the local-to-global mapping of dofs on a cell
virtual void tabulate_dofs(unsigned int* dofs,
const ufc::mesh& m,
const ufc::cell& c) const
{
dofs[0] = c.entity_indices[0][0];
dofs[1] = c.entity_indices[0][1];
}
/// Tabulate the local-to-local mapping from facet dofs to cell dofs
virtual void tabulate_facet_dofs(unsigned int* dofs,
unsigned int facet) const
{
switch (facet)
{
case 0:
{
dofs[0] = 0;
break;
}
case 1:
{
dofs[0] = 1;
break;
}
}
}
/// Tabulate the local-to-local mapping of dofs on entity (d, i)
virtual void tabulate_entity_dofs(unsigned int* dofs,
unsigned int d, unsigned int i) const
{
if (d > 1)
{
throw std::runtime_error("d is larger than dimension (1)");
}
switch (d)
{
case 0:
{
if (i > 1)
{
throw std::runtime_error("i is larger than number of entities (1)");
}
switch (i)
{
case 0:
{
dofs[0] = 0;
break;
}
case 1:
{
dofs[0] = 1;
break;
}
}
break;
}
case 1:
{
break;
}
}
}
/// Tabulate the coordinates of all dofs on a cell
virtual void tabulate_coordinates(double** coordinates,
const ufc::cell& c) const
{
const double * const * x = c.coordinates;
coordinates[0][0] = x[0][0];
coordinates[1][0] = x[1][0];
}
/// Return the number of sub dofmaps (for a mixed element)
virtual unsigned int num_sub_dofmaps() const
{
return 0;
}
/// Create a new dofmap for sub dofmap i (for a mixed element)
virtual ufc::dofmap* create_sub_dofmap(unsigned int i) const
{
return 0;
}
/// Create a new class instance
virtual ufc::dofmap* create() const
{
return new poisson_dofmap_0();
}
};
/// This class defines the interface for the tabulation of the cell
/// tensor corresponding to the local contribution to a form from
/// the integral over a cell.
class poisson_cell_integral_0_0: public ufc::cell_integral
{
public:
/// Constructor
poisson_cell_integral_0_0() : ufc::cell_integral()
{
// Do nothing
}
/// Destructor
virtual ~poisson_cell_integral_0_0()
{
// Do nothing
}
/// Tabulate the tensor for the contribution from a local cell
virtual void tabulate_tensor(double* A,
const double * const * w,
const ufc::cell& c) const
{
// Number of operations (multiply-add pairs) for Jacobian data: 7
// Number of operations (multiply-add pairs) for geometry tensor: 1
// Number of operations (multiply-add pairs) for tensor contraction: 0
// Total number of operations (multiply-add pairs): 8
// Extract vertex coordinates
const double * const * x = c.coordinates;
// Compute Jacobian of affine map from reference cell
const double J_00 = x[1][0] - x[0][0];
// Compute determinant of Jacobian
const double detJ = J_00;
// Compute inverse of Jacobian
const double K_00 = 1.0 / detJ;
// Set scale factor
const double det = std::abs(detJ);
// Compute geometry tensor
const double G0_0_0 = det*K_00*K_00*(1.0);
// Compute element tensor
A[0] = G0_0_0;
A[1] = -G0_0_0;
A[2] = -G0_0_0;
A[3] = G0_0_0;
}
/// Tabulate the tensor for the contribution from a local cell
/// using the specified reference cell quadrature points/weights
virtual void tabulate_tensor(double* A,
const double * const * w,
const ufc::cell& c,
unsigned int num_quadrature_points,
const double * const * quadrature_points,
const double* quadrature_weights) const
{
throw std::runtime_error("Quadrature version of tabulate_tensor not available when using the FFC tensor representation.");
}
};
/// This class defines the interface for the tabulation of the cell
/// tensor corresponding to the local contribution to a form from
/// the integral over a cell.
class poisson_cell_integral_1_0: public ufc::cell_integral
{
public:
/// Constructor
poisson_cell_integral_1_0() : ufc::cell_integral()
{
// Do nothing
}
/// Destructor
virtual ~poisson_cell_integral_1_0()
{
// Do nothing
}
/// Tabulate the tensor for the contribution from a local cell
virtual void tabulate_tensor(double* A,
const double * const * w,
const ufc::cell& c) const
{
// Number of operations (multiply-add pairs) for Jacobian data: 6
// Number of operations (multiply-add pairs) for geometry tensor: 2
// Number of operations (multiply-add pairs) for tensor contraction: 3
// Total number of operations (multiply-add pairs): 11
// Extract vertex coordinates
const double * const * x = c.coordinates;
// Compute Jacobian of affine map from reference cell
const double J_00 = x[1][0] - x[0][0];
// Compute determinant of Jacobian
const double detJ = J_00;
// Compute inverse of Jacobian
// Set scale factor
const double det = std::abs(detJ);
// Compute geometry tensor
const double G0_0 = det*w[0][0]*(1.0);
const double G0_1 = det*w[0][1]*(1.0);
// Compute element tensor
A[0] = 0.333333333333333*G0_0 + 0.166666666666666*G0_1;
A[1] = 0.166666666666666*G0_0 + 0.333333333333333*G0_1;
}
/// Tabulate the tensor for the contribution from a local cell
/// using the specified reference cell quadrature points/weights
virtual void tabulate_tensor(double* A,
const double * const * w,
const ufc::cell& c,
unsigned int num_quadrature_points,
const double * const * quadrature_points,
const double* quadrature_weights) const
{
throw std::runtime_error("Quadrature version of tabulate_tensor not available when using the FFC tensor representation.");
}
};
/// This class defines the interface for the tabulation of the
/// exterior facet tensor corresponding to the local contribution to
/// a form from the integral over an exterior facet.
class poisson_exterior_facet_integral_1_0: public ufc::exterior_facet_integral
{
public:
/// Constructor
poisson_exterior_facet_integral_1_0() : ufc::exterior_facet_integral()
{
// Do nothing
}
/// Destructor
virtual ~poisson_exterior_facet_integral_1_0()
{
// Do nothing
}
/// Tabulate the tensor for the contribution from a local exterior facet
virtual void tabulate_tensor(double* A,
const double * const * w,
const ufc::cell& c,
unsigned int facet) const
{
// Number of operations (multiply-add pairs) for Jacobian data: 5
// Number of operations (multiply-add pairs) for geometry tensor: 2
// Number of operations (multiply-add pairs) for tensor contraction: 0
// Total number of operations (multiply-add pairs): 7
// Extract vertex coordinates
// Compute Jacobian of affine map from reference cell
// Compute determinant of Jacobian
// Compute inverse of Jacobian
// Facet determinant 1D (vertex)
const double det = 1.0;
// Compute geometry tensor
const double G0_0 = det*w[1][0]*(1.0);
const double G0_1 = det*w[1][1]*(1.0);
// Compute element tensor
switch (facet)
{
case 0:
{
A[0] = G0_0;
A[1] = 0.0;
break;
}
case 1:
{
A[0] = 0.0;
A[1] = G0_1;
break;
}
}
}
/// Tabulate the tensor for the contribution from a local exterior facet
/// using the specified reference cell quadrature points/weights
virtual void tabulate_tensor(double* A,
const double * const * w,
const ufc::cell& c,
unsigned int num_quadrature_points,
const double * const * quadrature_points,
const double* quadrature_weights) const
{
throw std::runtime_error("Quadrature version of tabulate_tensor not available when using the FFC tensor representation.");
}
};
/// This class defines the interface for the assembly of the global
/// tensor corresponding to a form with r + n arguments, that is, a
/// mapping
///
/// a : V1 x V2 x ... Vr x W1 x W2 x ... x Wn -> R
///
/// with arguments v1, v2, ..., vr, w1, w2, ..., wn. The rank r
/// global tensor A is defined by
///
/// A = a(V1, V2, ..., Vr, w1, w2, ..., wn),
///
/// where each argument Vj represents the application to the
/// sequence of basis functions of Vj and w1, w2, ..., wn are given
/// fixed functions (coefficients).
class poisson_form_0: public ufc::form
{
public:
/// Constructor
poisson_form_0() : ufc::form()
{
// Do nothing
}
/// Destructor
virtual ~poisson_form_0()
{
// Do nothing
}
/// Return a string identifying the form
virtual const char* signature() const
{
return "Form([Integral(Product(SpatialDerivative(Argument(FiniteElement('Lagrange', Cell('interval', Space(1)), 1, None), 0), MultiIndex((FixedIndex(0),), {})), SpatialDerivative(Argument(FiniteElement('Lagrange', Cell('interval', Space(1)), 1, None), 1), MultiIndex((FixedIndex(0),), {}))), Measure('cell', 0, None))])";
}
/// Return the rank of the global tensor (r)
virtual unsigned int rank() const
{
return 2;
}
/// Return the number of coefficients (n)
virtual unsigned int num_coefficients() const
{
return 0;
}
/// Return the number of cell domains
virtual unsigned int num_cell_domains() const
{
return 1;
}
/// Return the number of exterior facet domains
virtual unsigned int num_exterior_facet_domains() const
{
return 0;
}
/// Return the number of interior facet domains
virtual unsigned int num_interior_facet_domains() const
{
return 0;
}
/// Create a new finite element for argument function i
virtual ufc::finite_element* create_finite_element(unsigned int i) const
{
switch (i)
{
case 0:
{
return new poisson_finite_element_0();
break;
}
case 1:
{
return new poisson_finite_element_0();
break;
}
}
return 0;
}
/// Create a new dofmap for argument function i
virtual ufc::dofmap* create_dofmap(unsigned int i) const
{
switch (i)
{
case 0:
{
return new poisson_dofmap_0();
break;
}
case 1:
{
return new poisson_dofmap_0();
break;
}
}
return 0;
}
/// Create a new cell integral on sub domain i
virtual ufc::cell_integral* create_cell_integral(unsigned int i) const
{
switch (i)
{
case 0:
{
return new poisson_cell_integral_0_0();
break;
}
}
return 0;
}
/// Create a new exterior facet integral on sub domain i
virtual ufc::exterior_facet_integral* create_exterior_facet_integral(unsigned int i) const
{
return 0;
}
/// Create a new interior facet integral on sub domain i
virtual ufc::interior_facet_integral* create_interior_facet_integral(unsigned int i) const
{
return 0;
}
};
/// This class defines the interface for the assembly of the global
/// tensor corresponding to a form with r + n arguments, that is, a
/// mapping
///
/// a : V1 x V2 x ... Vr x W1 x W2 x ... x Wn -> R
///
/// with arguments v1, v2, ..., vr, w1, w2, ..., wn. The rank r
/// global tensor A is defined by
///
/// A = a(V1, V2, ..., Vr, w1, w2, ..., wn),
///
/// where each argument Vj represents the application to the
/// sequence of basis functions of Vj and w1, w2, ..., wn are given
/// fixed functions (coefficients).
class poisson_form_1: public ufc::form
{
public:
/// Constructor
poisson_form_1() : ufc::form()
{
// Do nothing
}
/// Destructor
virtual ~poisson_form_1()
{
// Do nothing
}
/// Return a string identifying the form
virtual const char* signature() const
{
return "Form([Integral(Product(Argument(FiniteElement('Lagrange', Cell('interval', Space(1)), 1, None), 0), Coefficient(FiniteElement('Lagrange', Cell('interval', Space(1)), 1, None), 0)), Measure('cell', 0, None)), Integral(Product(Argument(FiniteElement('Lagrange', Cell('interval', Space(1)), 1, None), 0), Coefficient(FiniteElement('Lagrange', Cell('interval', Space(1)), 1, None), 1)), Measure('exterior_facet', 0, None))])";
}
/// Return the rank of the global tensor (r)
virtual unsigned int rank() const
{
return 1;
}
/// Return the number of coefficients (n)
virtual unsigned int num_coefficients() const
{
return 2;
}
/// Return the number of cell domains
virtual unsigned int num_cell_domains() const
{
return 1;
}
/// Return the number of exterior facet domains
virtual unsigned int num_exterior_facet_domains() const
{
return 1;
}
/// Return the number of interior facet domains
virtual unsigned int num_interior_facet_domains() const
{
return 0;
}
/// Create a new finite element for argument function i
virtual ufc::finite_element* create_finite_element(unsigned int i) const
{
switch (i)
{
case 0:
{
return new poisson_finite_element_0();
break;
}
case 1:
{
return new poisson_finite_element_0();
break;
}
case 2:
{
return new poisson_finite_element_0();
break;
}
}
return 0;
}
/// Create a new dofmap for argument function i
virtual ufc::dofmap* create_dofmap(unsigned int i) const
{
switch (i)
{
case 0:
{
return new poisson_dofmap_0();
break;
}
case 1:
{
return new poisson_dofmap_0();
break;
}
case 2:
{
return new poisson_dofmap_0();
break;
}
}
return 0;
}
/// Create a new cell integral on sub domain i
virtual ufc::cell_integral* create_cell_integral(unsigned int i) const
{
switch (i)
{
case 0:
{
return new poisson_cell_integral_1_0();
break;
}
}
return 0;
}
/// Create a new exterior facet integral on sub domain i
virtual ufc::exterior_facet_integral* create_exterior_facet_integral(unsigned int i) const
{
switch (i)
{
case 0:
{
return new poisson_exterior_facet_integral_1_0();
break;
}
}
return 0;
}
/// Create a new interior facet integral on sub domain i
virtual ufc::interior_facet_integral* create_interior_facet_integral(unsigned int i) const
{
return 0;
}
};
// DOLFIN wrappers
// Standard library includes
#include <string>
// DOLFIN includes
#include <dolfin/common/NoDeleter.h>
#include <dolfin/fem/FiniteElement.h>
#include <dolfin/fem/DofMap.h>
#include <dolfin/fem/Form.h>
#include <dolfin/function/FunctionSpace.h>
#include <dolfin/function/GenericFunction.h>
#include <dolfin/function/CoefficientAssigner.h>
#include <dolfin/adaptivity/ErrorControl.h>
#include <dolfin/adaptivity/GoalFunctional.h>
namespace Poisson
{
class CoefficientSpace_f: public dolfin::FunctionSpace
{
public:
CoefficientSpace_f(const dolfin::Mesh& mesh):
dolfin::FunctionSpace(dolfin::reference_to_no_delete_pointer(mesh),
boost::shared_ptr<const dolfin::FiniteElement>(new dolfin::FiniteElement(boost::shared_ptr<ufc::finite_element>(new poisson_finite_element_0()))),
boost::shared_ptr<const dolfin::DofMap>(new dolfin::DofMap(boost::shared_ptr<ufc::dofmap>(new poisson_dofmap_0()), mesh)))
{
// Do nothing
}
CoefficientSpace_f(dolfin::Mesh& mesh):
dolfin::FunctionSpace(dolfin::reference_to_no_delete_pointer(mesh),
boost::shared_ptr<const dolfin::FiniteElement>(new dolfin::FiniteElement(boost::shared_ptr<ufc::finite_element>(new poisson_finite_element_0()))),
boost::shared_ptr<const dolfin::DofMap>(new dolfin::DofMap(boost::shared_ptr<ufc::dofmap>(new poisson_dofmap_0()), mesh)))
{
// Do nothing
}
CoefficientSpace_f(boost::shared_ptr<dolfin::Mesh> mesh):
dolfin::FunctionSpace(mesh,
boost::shared_ptr<const dolfin::FiniteElement>(new dolfin::FiniteElement(boost::shared_ptr<ufc::finite_element>(new poisson_finite_element_0()))),
boost::shared_ptr<const dolfin::DofMap>(new dolfin::DofMap(boost::shared_ptr<ufc::dofmap>(new poisson_dofmap_0()), *mesh)))
{
// Do nothing
}
CoefficientSpace_f(boost::shared_ptr<const dolfin::Mesh> mesh):
dolfin::FunctionSpace(mesh,
boost::shared_ptr<const dolfin::FiniteElement>(new dolfin::FiniteElement(boost::shared_ptr<ufc::finite_element>(new poisson_finite_element_0()))),
boost::shared_ptr<const dolfin::DofMap>(new dolfin::DofMap(boost::shared_ptr<ufc::dofmap>(new poisson_dofmap_0()), *mesh)))
{
// Do nothing
}
~CoefficientSpace_f()
{
}
};
class CoefficientSpace_g: public dolfin::FunctionSpace
{
public:
CoefficientSpace_g(const dolfin::Mesh& mesh):
dolfin::FunctionSpace(dolfin::reference_to_no_delete_pointer(mesh),
boost::shared_ptr<const dolfin::FiniteElement>(new dolfin::FiniteElement(boost::shared_ptr<ufc::finite_element>(new poisson_finite_element_0()))),
boost::shared_ptr<const dolfin::DofMap>(new dolfin::DofMap(boost::shared_ptr<ufc::dofmap>(new poisson_dofmap_0()), mesh)))
{
// Do nothing
}
CoefficientSpace_g(dolfin::Mesh& mesh):
dolfin::FunctionSpace(dolfin::reference_to_no_delete_pointer(mesh),
boost::shared_ptr<const dolfin::FiniteElement>(new dolfin::FiniteElement(boost::shared_ptr<ufc::finite_element>(new poisson_finite_element_0()))),
boost::shared_ptr<const dolfin::DofMap>(new dolfin::DofMap(boost::shared_ptr<ufc::dofmap>(new poisson_dofmap_0()), mesh)))
{
// Do nothing
}
CoefficientSpace_g(boost::shared_ptr<dolfin::Mesh> mesh):
dolfin::FunctionSpace(mesh,
boost::shared_ptr<const dolfin::FiniteElement>(new dolfin::FiniteElement(boost::shared_ptr<ufc::finite_element>(new poisson_finite_element_0()))),
boost::shared_ptr<const dolfin::DofMap>(new dolfin::DofMap(boost::shared_ptr<ufc::dofmap>(new poisson_dofmap_0()), *mesh)))
{
// Do nothing
}
CoefficientSpace_g(boost::shared_ptr<const dolfin::Mesh> mesh):
dolfin::FunctionSpace(mesh,
boost::shared_ptr<const dolfin::FiniteElement>(new dolfin::FiniteElement(boost::shared_ptr<ufc::finite_element>(new poisson_finite_element_0()))),
boost::shared_ptr<const dolfin::DofMap>(new dolfin::DofMap(boost::shared_ptr<ufc::dofmap>(new poisson_dofmap_0()), *mesh)))
{
// Do nothing
}
~CoefficientSpace_g()
{
}
};
class Form_0_FunctionSpace_0: public dolfin::FunctionSpace
{
public:
Form_0_FunctionSpace_0(const dolfin::Mesh& mesh):
dolfin::FunctionSpace(dolfin::reference_to_no_delete_pointer(mesh),
boost::shared_ptr<const dolfin::FiniteElement>(new dolfin::FiniteElement(boost::shared_ptr<ufc::finite_element>(new poisson_finite_element_0()))),
boost::shared_ptr<const dolfin::DofMap>(new dolfin::DofMap(boost::shared_ptr<ufc::dofmap>(new poisson_dofmap_0()), mesh)))
{
// Do nothing
}
Form_0_FunctionSpace_0(dolfin::Mesh& mesh):
dolfin::FunctionSpace(dolfin::reference_to_no_delete_pointer(mesh),
boost::shared_ptr<const dolfin::FiniteElement>(new dolfin::FiniteElement(boost::shared_ptr<ufc::finite_element>(new poisson_finite_element_0()))),
boost::shared_ptr<const dolfin::DofMap>(new dolfin::DofMap(boost::shared_ptr<ufc::dofmap>(new poisson_dofmap_0()), mesh)))
{
// Do nothing
}
Form_0_FunctionSpace_0(boost::shared_ptr<dolfin::Mesh> mesh):
dolfin::FunctionSpace(mesh,
boost::shared_ptr<const dolfin::FiniteElement>(new dolfin::FiniteElement(boost::shared_ptr<ufc::finite_element>(new poisson_finite_element_0()))),
boost::shared_ptr<const dolfin::DofMap>(new dolfin::DofMap(boost::shared_ptr<ufc::dofmap>(new poisson_dofmap_0()), *mesh)))
{
// Do nothing
}
Form_0_FunctionSpace_0(boost::shared_ptr<const dolfin::Mesh> mesh):
dolfin::FunctionSpace(mesh,
boost::shared_ptr<const dolfin::FiniteElement>(new dolfin::FiniteElement(boost::shared_ptr<ufc::finite_element>(new poisson_finite_element_0()))),
boost::shared_ptr<const dolfin::DofMap>(new dolfin::DofMap(boost::shared_ptr<ufc::dofmap>(new poisson_dofmap_0()), *mesh)))
{
// Do nothing
}
~Form_0_FunctionSpace_0()
{
}
};
class Form_0_FunctionSpace_1: public dolfin::FunctionSpace
{
public:
Form_0_FunctionSpace_1(const dolfin::Mesh& mesh):
dolfin::FunctionSpace(dolfin::reference_to_no_delete_pointer(mesh),
boost::shared_ptr<const dolfin::FiniteElement>(new dolfin::FiniteElement(boost::shared_ptr<ufc::finite_element>(new poisson_finite_element_0()))),
boost::shared_ptr<const dolfin::DofMap>(new dolfin::DofMap(boost::shared_ptr<ufc::dofmap>(new poisson_dofmap_0()), mesh)))
{
// Do nothing
}
Form_0_FunctionSpace_1(dolfin::Mesh& mesh):
dolfin::FunctionSpace(dolfin::reference_to_no_delete_pointer(mesh),
boost::shared_ptr<const dolfin::FiniteElement>(new dolfin::FiniteElement(boost::shared_ptr<ufc::finite_element>(new poisson_finite_element_0()))),
boost::shared_ptr<const dolfin::DofMap>(new dolfin::DofMap(boost::shared_ptr<ufc::dofmap>(new poisson_dofmap_0()), mesh)))
{
// Do nothing
}
Form_0_FunctionSpace_1(boost::shared_ptr<dolfin::Mesh> mesh):
dolfin::FunctionSpace(mesh,
boost::shared_ptr<const dolfin::FiniteElement>(new dolfin::FiniteElement(boost::shared_ptr<ufc::finite_element>(new poisson_finite_element_0()))),
boost::shared_ptr<const dolfin::DofMap>(new dolfin::DofMap(boost::shared_ptr<ufc::dofmap>(new poisson_dofmap_0()), *mesh)))
{
// Do nothing
}
Form_0_FunctionSpace_1(boost::shared_ptr<const dolfin::Mesh> mesh):
dolfin::FunctionSpace(mesh,
boost::shared_ptr<const dolfin::FiniteElement>(new dolfin::FiniteElement(boost::shared_ptr<ufc::finite_element>(new poisson_finite_element_0()))),
boost::shared_ptr<const dolfin::DofMap>(new dolfin::DofMap(boost::shared_ptr<ufc::dofmap>(new poisson_dofmap_0()), *mesh)))
{
// Do nothing
}
~Form_0_FunctionSpace_1()
{
}
};
class Form_0: public dolfin::Form
{
public:
// Constructor
Form_0(const dolfin::FunctionSpace& V1, const dolfin::FunctionSpace& V0):
dolfin::Form(2, 0)
{
_function_spaces[0] = reference_to_no_delete_pointer(V0);
_function_spaces[1] = reference_to_no_delete_pointer(V1);
_ufc_form = boost::shared_ptr<const ufc::form>(new poisson_form_0());
}
// Constructor
Form_0(boost::shared_ptr<const dolfin::FunctionSpace> V1, boost::shared_ptr<const dolfin::FunctionSpace> V0):
dolfin::Form(2, 0)
{
_function_spaces[0] = V0;
_function_spaces[1] = V1;
_ufc_form = boost::shared_ptr<const ufc::form>(new poisson_form_0());
}
// Destructor
~Form_0()
{}
/// Return the number of the coefficient with this name
virtual dolfin::uint coefficient_number(const std::string& name) const
{
dolfin::error("No coefficients.");
return 0;
}
/// Return the name of the coefficient with this number
virtual std::string coefficient_name(dolfin::uint i) const
{
dolfin::error("No coefficients.");
return "unnamed";
}
// Typedefs
typedef Form_0_FunctionSpace_0 TestSpace;
typedef Form_0_FunctionSpace_1 TrialSpace;
// Coefficients
};
class Form_1_FunctionSpace_0: public dolfin::FunctionSpace
{
public:
Form_1_FunctionSpace_0(const dolfin::Mesh& mesh):
dolfin::FunctionSpace(dolfin::reference_to_no_delete_pointer(mesh),
boost::shared_ptr<const dolfin::FiniteElement>(new dolfin::FiniteElement(boost::shared_ptr<ufc::finite_element>(new poisson_finite_element_0()))),
boost::shared_ptr<const dolfin::DofMap>(new dolfin::DofMap(boost::shared_ptr<ufc::dofmap>(new poisson_dofmap_0()), mesh)))
{
// Do nothing
}
Form_1_FunctionSpace_0(dolfin::Mesh& mesh):
dolfin::FunctionSpace(dolfin::reference_to_no_delete_pointer(mesh),
boost::shared_ptr<const dolfin::FiniteElement>(new dolfin::FiniteElement(boost::shared_ptr<ufc::finite_element>(new poisson_finite_element_0()))),
boost::shared_ptr<const dolfin::DofMap>(new dolfin::DofMap(boost::shared_ptr<ufc::dofmap>(new poisson_dofmap_0()), mesh)))
{
// Do nothing
}
Form_1_FunctionSpace_0(boost::shared_ptr<dolfin::Mesh> mesh):
dolfin::FunctionSpace(mesh,
boost::shared_ptr<const dolfin::FiniteElement>(new dolfin::FiniteElement(boost::shared_ptr<ufc::finite_element>(new poisson_finite_element_0()))),
boost::shared_ptr<const dolfin::DofMap>(new dolfin::DofMap(boost::shared_ptr<ufc::dofmap>(new poisson_dofmap_0()), *mesh)))
{
// Do nothing
}
Form_1_FunctionSpace_0(boost::shared_ptr<const dolfin::Mesh> mesh):
dolfin::FunctionSpace(mesh,
boost::shared_ptr<const dolfin::FiniteElement>(new dolfin::FiniteElement(boost::shared_ptr<ufc::finite_element>(new poisson_finite_element_0()))),
boost::shared_ptr<const dolfin::DofMap>(new dolfin::DofMap(boost::shared_ptr<ufc::dofmap>(new poisson_dofmap_0()), *mesh)))
{
// Do nothing
}
~Form_1_FunctionSpace_0()
{
}
};
typedef CoefficientSpace_f Form_1_FunctionSpace_1;
typedef CoefficientSpace_g Form_1_FunctionSpace_2;
class Form_1: public dolfin::Form
{
public:
// Constructor
Form_1(const dolfin::FunctionSpace& V0):
dolfin::Form(1, 2), f(*this, 0), g(*this, 1)
{
_function_spaces[0] = reference_to_no_delete_pointer(V0);
_ufc_form = boost::shared_ptr<const ufc::form>(new poisson_form_1());
}
// Constructor
Form_1(const dolfin::FunctionSpace& V0, const dolfin::GenericFunction& f, const dolfin::GenericFunction& g):
dolfin::Form(1, 2), f(*this, 0), g(*this, 1)
{
_function_spaces[0] = reference_to_no_delete_pointer(V0);
this->f = f;
this->g = g;
_ufc_form = boost::shared_ptr<const ufc::form>(new poisson_form_1());
}
// Constructor
Form_1(const dolfin::FunctionSpace& V0, boost::shared_ptr<const dolfin::GenericFunction> f, boost::shared_ptr<const dolfin::GenericFunction> g):
dolfin::Form(1, 2), f(*this, 0), g(*this, 1)
{
_function_spaces[0] = reference_to_no_delete_pointer(V0);
this->f = *f;
this->g = *g;
_ufc_form = boost::shared_ptr<const ufc::form>(new poisson_form_1());
}
// Constructor
Form_1(boost::shared_ptr<const dolfin::FunctionSpace> V0):
dolfin::Form(1, 2), f(*this, 0), g(*this, 1)
{
_function_spaces[0] = V0;
_ufc_form = boost::shared_ptr<const ufc::form>(new poisson_form_1());
}
// Constructor
Form_1(boost::shared_ptr<const dolfin::FunctionSpace> V0, const dolfin::GenericFunction& f, const dolfin::GenericFunction& g):
dolfin::Form(1, 2), f(*this, 0), g(*this, 1)
{
_function_spaces[0] = V0;
this->f = f;
this->g = g;
_ufc_form = boost::shared_ptr<const ufc::form>(new poisson_form_1());
}
// Constructor
Form_1(boost::shared_ptr<const dolfin::FunctionSpace> V0, boost::shared_ptr<const dolfin::GenericFunction> f, boost::shared_ptr<const dolfin::GenericFunction> g):
dolfin::Form(1, 2), f(*this, 0), g(*this, 1)
{
_function_spaces[0] = V0;
this->f = *f;
this->g = *g;
_ufc_form = boost::shared_ptr<const ufc::form>(new poisson_form_1());
}
// Destructor
~Form_1()
{}
/// Return the number of the coefficient with this name
virtual dolfin::uint coefficient_number(const std::string& name) const
{
if (name == "f")
return 0;
else if (name == "g")
return 1;
dolfin::error("Invalid coefficient.");
return 0;
}
/// Return the name of the coefficient with this number
virtual std::string coefficient_name(dolfin::uint i) const
{
switch (i)
{
case 0:
return "f";
case 1:
return "g";
}
dolfin::error("Invalid coefficient.");
return "unnamed";
}
// Typedefs
typedef Form_1_FunctionSpace_0 TestSpace;
typedef Form_1_FunctionSpace_1 CoefficientSpace_f;
typedef Form_1_FunctionSpace_2 CoefficientSpace_g;
// Coefficients
dolfin::CoefficientAssigner f;
dolfin::CoefficientAssigner g;
};
// Class typedefs
typedef Form_0 BilinearForm;
typedef Form_0 JacobianForm;
typedef Form_1 LinearForm;
typedef Form_1 ResidualForm;
typedef Form_0::TestSpace FunctionSpace;
}
#endif
| [
"johannr@simula.no"
] | johannr@simula.no |
61819d6397eeef8f33bf6c0865c1049f02094d26 | d35447d3bdbbaa1bdaa2e31a750d87fd96b1e929 | /mysql_connect/sql_api.h | 86ffb3bfb3efcdd5d830625cf88bcfa08ea3a28c | [] | no_license | HonestFox/HTTP_Server | 74cbb97aa9e0d884a01cc1d5116b3d93d32944d5 | 9320b6ec77703de21f699946aece3f3735ba9cf0 | refs/heads/master | 2020-04-06T06:59:20.356226 | 2016-08-30T12:22:04 | 2016-08-30T12:22:04 | 65,139,324 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,019 | h | /*************************************************************************
> File Name: sql_api.h
> Author: HonestFox
> Mail: zhweizhi@foxmail.com
> Created Time: Sat 13 Aug 2016 09:55:00 AM CST
************************************************************************/
#pragma once
#include <iostream>
#include <string>
#include <stdlib.h>
#include "mysql.h"
class sql_api
{
public:
// sql_api( const std::string &host , const std::string &user , const std::string &passwd , const std::string &db );
sql_api();
~sql_api();
public:
int my_connect_mysql();
int my_insert( const std::string &cols, const std::string &data );
int my_select();
int my_delete( const std::string &name );
int my_update( const std::string &name, const std::string &tag, const std::string &val );
int my_update( const std::string &name, const std::string &tag, const int &val );
void test();
private:
MYSQL *_conn;
MYSQL_RES *_res;
std::string _host;
std::string _user;
std::string _passwd;
std::string _db;
int _port;
};
| [
"noreply@github.com"
] | noreply@github.com |
e1ffea2f9856e152559475066a0ee7ea1f98be0f | 7fb8c421a2efa33969b0cf298a3f1fe4688dbbda | /GaleEngine/Recycle Bin/PhysicsStuff/physObj.cpp | 76c5076b0102dec77a3276f3a180bf169cf0e315 | [] | no_license | hakgagik/GaleEngine | 9c2e7d007ddb15a7a497b0aeac4a2df4e2107e06 | 3a3cb5a4330c67348d99bef56223f3ea4c14f09b | refs/heads/master | 2022-09-04T18:56:12.330889 | 2020-03-30T15:38:37 | 2020-03-30T15:38:37 | 47,303,019 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,424 | cpp | #include "physObj.h"
#include "mesh.h"
#include "trianglePhys.h"
#include "edge.h"
#include "vertex.h"
#include <glm\glm.hpp>
#include <string>
#include <unordered_map>
using namespace std;
PhysObj::PhysObj()
{
}
string edgeHash(int i0, int i1) {
if (i1 > i0) return to_string(i0) + " " + to_string(i1);
else return to_string(i1) + " " + to_string(i0);
}
PhysObj::PhysObj(Mesh * mesh)
{
for (vector<glm::vec3>::iterator it = mesh->verts.begin(); it != mesh->verts.end(); ++it) {
Vertex vert(mesh, *it);
verts.push_back(&vert);
}
int triVerts = mesh->vertexIndices.size();
unordered_map<string, Edge*> edgemap;
int vi0, vi1, vi2;
string key0, key1, key2;
Edge *e0, *e1, *e2;
for (int i = 0; i < triVerts; i += 3) {
vi0 = mesh->vertexIndices[i];
vi1 = mesh->vertexIndices[i + 1];
vi2 = mesh->vertexIndices[i + 2];
key0 = edgeHash(vi0, vi1);
key1 = edgeHash(vi1, vi2);
key2 = edgeHash(vi2, vi0);
if (edgemap.count(key0) == 0) {
e0 = Edge::buildEdge(mesh, verts[vi0], verts[vi1]);
edgemap.emplace(key0, e0);
}
else {
e0 = edgemap.at(key0);
}
if (edgemap.count(key1) == 0) {
e1 = Edge::buildEdge(mesh, verts[vi1], verts[vi2]);
edgemap.emplace(key1, e1);
}
else {
e1 = edgemap.at(key1);
}
if (edgemap.count(key2) == 0) {
e2 = Edge::buildEdge(mesh, verts[vi2], verts[vi0]);
edgemap.emplace(key2, e2);
}
else {
e2 = edgemap.at(key2);
}
}
}
| [
"xddarkgalegh@aim.com"
] | xddarkgalegh@aim.com |
43224e0799bfef68e46791c1595490e4e8d7e3be | 94bd295572de3f4934a3896ce1bb882fb4d35edc | /content/common/content_security_policy/csp_context.h | 45895e638f26f95e5b80aae89a89b864cc4d5049 | [
"BSD-3-Clause"
] | permissive | WebGameLinux/chromium | 06109b62d6019b051474cd479f3d577e0eec4463 | a35a1e2ce2ab74eccc467aa390eda1a8e29e3e09 | refs/heads/master | 2023-03-07T14:07:56.342758 | 2017-04-08T02:33:08 | 2017-04-08T03:38:27 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 4,037 | h | // Copyright 2017 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef CONTENT_COMMON_CONTENT_SECURITY_POLICY_CSP_CONTEXT_H_
#define CONTENT_COMMON_CONTENT_SECURITY_POLICY_CSP_CONTEXT_H_
#include <vector>
#include "content/common/content_export.h"
#include "content/common/content_security_policy/content_security_policy.h"
#include "content/common/content_security_policy_header.h"
#include "content/common/navigation_params.h"
#include "url/gurl.h"
#include "url/origin.h"
namespace content {
struct CSPViolationParams;
// A CSPContext represents the system on which the Content-Security-Policy are
// enforced. One must define via its virtual methods how to report violations
// and what is the set of scheme that bypass the CSP. Its main implementation
// is in content/browser/frame_host/render_frame_host_impl.h
class CONTENT_EXPORT CSPContext {
public:
CSPContext();
virtual ~CSPContext();
// Check if an |url| is allowed by the set of Content-Security-Policy. It will
// report any violation by:
// * displaying a console message.
// * triggering the "SecurityPolicyViolation" javascript event.
// * sending a JSON report to any uri defined with the "report-uri" directive.
// Returns true when the request can proceed, false otherwise.
bool IsAllowedByCsp(CSPDirective::Name directive_name,
const GURL& url,
bool is_redirect,
const SourceLocation& source_location);
void SetSelf(const url::Origin origin);
bool AllowSelf(const GURL& url);
bool ProtocolMatchesSelf(const GURL& url);
virtual void ReportContentSecurityPolicyViolation(
const CSPViolationParams& violation_params);
bool SelfSchemeShouldBypassCsp();
void ResetContentSecurityPolicies() { policies_.clear(); }
void AddContentSecurityPolicy(const ContentSecurityPolicy& policy) {
policies_.push_back(policy);
}
virtual bool SchemeShouldBypassCSP(const base::StringPiece& scheme);
private:
bool has_self_ = false;
std::string self_scheme_;
CSPSource self_source_;
std::vector<ContentSecurityPolicy> policies_;
DISALLOW_COPY_AND_ASSIGN(CSPContext);
};
// Used in CSPContext::ReportViolation()
struct CONTENT_EXPORT CSPViolationParams {
CSPViolationParams();
CSPViolationParams(const std::string& directive,
const std::string& effective_directive,
const std::string& console_message,
const GURL& blocked_url,
const std::vector<std::string>& report_endpoints,
const std::string& header,
const blink::WebContentSecurityPolicyType& disposition,
bool after_redirect,
const SourceLocation& source_location);
CSPViolationParams(const CSPViolationParams& other);
~CSPViolationParams();
// The name of the directive that violates the policy. |directive| might be a
// directive that serves as a fallback to the |effective_directive|.
std::string directive;
// The name the effective directive that was checked against.
std::string effective_directive;
// The console message to be displayed to the user.
std::string console_message;
// The URL that was blocked by the policy.
GURL blocked_url;
// The set of URI where a JSON-formatted report of the violation should be
// sent.
std::vector<std::string> report_endpoints;
// The raw content security policy header that was violated.
std::string header;
// Each policy has an associated disposition, which is either "enforce" or
// "report".
blink::WebContentSecurityPolicyType disposition;
// Whether or not the violation happens after a redirect.
bool after_redirect;
// The source code location that triggered the blocked navigation.
SourceLocation source_location;
};
} // namespace content
#endif // CONTENT_COMMON_CONTENT_SECURITY_POLICY_CSP_CONTEXT_H_
| [
"commit-bot@chromium.org"
] | commit-bot@chromium.org |
2bf507da316dce75899c6db583a08e781290fb98 | 57ac85ca91d0f218be2a97e41ad7f8967728e7b9 | /blazetest/src/mathtest/dynamicvector/ClassTest.cpp | 9367924e03a8967309ac56dc65dfe8d119980302 | [
"BSD-3-Clause"
] | permissive | AuroraDysis/blaze | b297baa6c96b77c3d32de789e0e3af27782ced77 | d5cacf64e8059ca924eef4b4e2a74fc9446d71cb | refs/heads/master | 2021-01-01T16:49:28.921446 | 2017-07-22T23:24:26 | 2017-07-22T23:24:26 | 97,930,727 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 96,590 | cpp | //=================================================================================================
/*!
// \file src/mathtest/dynamicvector/ClassTest.cpp
// \brief Source file for the DynamicVector class test
//
// Copyright (C) 2013 Klaus Iglberger - All Rights Reserved
//
// This file is part of the Blaze library. You can redistribute it and/or modify it under
// the terms of the New (Revised) BSD License. Redistribution and use in source and binary
// forms, with or without modification, are permitted provided that the following conditions
// are met:
//
// 1. Redistributions of source code must retain the above copyright notice, this list of
// conditions and the following disclaimer.
// 2. Redistributions in binary form must reproduce the above copyright notice, this list
// of conditions and the following disclaimer in the documentation and/or other materials
// provided with the distribution.
// 3. Neither the names of the Blaze development group nor the names of its contributors
// may be used to endorse or promote products derived from this software without specific
// prior written permission.
//
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
// OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT
// SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
// INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
// TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
// BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
// CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
// ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
// DAMAGE.
*/
//=================================================================================================
//*************************************************************************************************
// Includes
//*************************************************************************************************
#include <cstdlib>
#include <iostream>
#include <memory>
#include <blaze/math/CompressedVector.h>
#include <blaze/math/CustomVector.h>
#include <blaze/math/shims/Equal.h>
#include <blaze/util/Complex.h>
#include <blaze/util/policies/Deallocate.h>
#include <blaze/util/Random.h>
#include <blazetest/mathtest/dynamicvector/ClassTest.h>
#include <blazetest/mathtest/RandomMaximum.h>
#include <blazetest/mathtest/RandomMinimum.h>
namespace blazetest {
namespace mathtest {
namespace dynamicvector {
//=================================================================================================
//
// CONSTRUCTORS
//
//=================================================================================================
//*************************************************************************************************
/*!\brief Constructor for the DynamicVector class test.
//
// \exception std::runtime_error Operation error detected.
*/
ClassTest::ClassTest()
{
testAlignment< char >( "char" );
testAlignment< signed char >( "signed char" );
testAlignment< unsigned char >( "unsigned char" );
testAlignment< wchar_t >( "wchar_t" );
testAlignment< short >( "short" );
testAlignment< unsigned short >( "unsigned short" );
testAlignment< int >( "int" );
testAlignment< unsigned int >( "unsigned int" );
testAlignment< long >( "long" );
testAlignment< unsigned long >( "unsigned long" );
testAlignment< float >( "float" );
testAlignment< double >( "double" );
testAlignment< complex<char> >( "complex<char>" );
testAlignment< complex<signed char> >( "complex<signed char>" );
testAlignment< complex<unsigned char> >( "complex<unsigned char>" );
testAlignment< complex<wchar_t> >( "complex<wchar_t>" );
testAlignment< complex<short> >( "complex<short>" );
testAlignment< complex<unsigned short> >( "complex<unsigned short>" );
testAlignment< complex<int> >( "complex<int>" );
testAlignment< complex<unsigned int> >( "complex<unsigned int>" );
testAlignment< complex<float> >( "complex<float>" );
testAlignment< complex<double> >( "complex<double>" );
testConstructors();
testAssignment();
testAddAssign();
testSubAssign();
testMultAssign();
testDivAssign();
testCrossAssign();
testScaling();
testSubscript();
testAt();
testIterator();
testNonZeros();
testReset();
testClear();
testResize();
testExtend();
testReserve();
testShrinkToFit();
testSwap();
testIsDefault();
}
//*************************************************************************************************
//=================================================================================================
//
// TEST FUNCTIONS
//
//=================================================================================================
//*************************************************************************************************
/*!\brief Test of the DynamicVector constructors.
//
// \return void
// \exception std::runtime_error Error detected.
//
// This function performs a test of all constructors of the DynamicVector class template.
// In case an error is detected, a \a std::runtime_error exception is thrown.
*/
void ClassTest::testConstructors()
{
//=====================================================================================
// Default constructor
//=====================================================================================
{
test_ = "DynamicVector default constructor";
blaze::DynamicVector<int,blaze::rowVector> vec;
checkSize ( vec, 0UL );
checkNonZeros( vec, 0UL );
}
//=====================================================================================
// Size constructor
//=====================================================================================
{
test_ = "DynamicVector size constructor (size 0)";
blaze::DynamicVector<int,blaze::rowVector> vec( 0UL );
checkSize ( vec, 0UL );
checkNonZeros( vec, 0UL );
}
{
test_ = "DynamicVector size constructor (size 10)";
blaze::DynamicVector<int,blaze::rowVector> vec( 10UL );
checkSize ( vec, 10UL );
checkCapacity( vec, 10UL );
}
//=====================================================================================
// Homogeneous initialization
//=====================================================================================
{
test_ = "DynamicVector homogeneous initialization constructor (size 0)";
blaze::DynamicVector<int,blaze::rowVector> vec( 0UL, 2 );
checkSize ( vec, 0UL );
checkNonZeros( vec, 0UL );
}
{
test_ = "DynamicVector homogeneous initialization constructor (size 3)";
blaze::DynamicVector<int,blaze::rowVector> vec( 3UL, 2 );
checkSize ( vec, 3UL );
checkCapacity( vec, 3UL );
checkNonZeros( vec, 3UL );
if( vec[0] != 2 || vec[1] != 2 || vec[2] != 2 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Construction failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 2 2 2 )\n";
throw std::runtime_error( oss.str() );
}
}
//=====================================================================================
// List initialization
//=====================================================================================
{
test_ = "DynamicVector initializer list constructor (size 4)";
blaze::DynamicVector<int,blaze::rowVector> vec{ 1, 2, 3, 4 };
checkSize ( vec, 4UL );
checkCapacity( vec, 4UL );
checkNonZeros( vec, 4UL );
if( vec[0] != 1 || vec[1] != 2 || vec[2] != 3 || vec[3] != 4 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Construction failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 1 2 3 4 )\n";
throw std::runtime_error( oss.str() );
}
}
//=====================================================================================
// Array initialization
//=====================================================================================
{
test_ = "DynamicVector dynamic array initialization constructor (size 4)";
std::unique_ptr<int[]> array( new int[4] );
array[0] = 1;
array[1] = 2;
array[2] = 3;
array[3] = 4;
blaze::DynamicVector<int,blaze::rowVector> vec( 4UL, array.get() );
checkSize ( vec, 4UL );
checkCapacity( vec, 4UL );
checkNonZeros( vec, 4UL );
if( vec[0] != 1 || vec[1] != 2 || vec[2] != 3 || vec[3] != 4 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Construction failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 1 2 3 4 )\n";
throw std::runtime_error( oss.str() );
}
}
{
test_ = "DynamicVector static array initialization constructor (size 4)";
const int array[4] = { 1, 2, 3, 4 };
blaze::DynamicVector<int,blaze::rowVector> vec( array );
checkSize ( vec, 4UL );
checkCapacity( vec, 4UL );
checkNonZeros( vec, 4UL );
if( vec[0] != 1 || vec[1] != 2 || vec[2] != 3 || vec[3] != 4 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Construction failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 1 2 3 4 )\n";
throw std::runtime_error( oss.str() );
}
}
//=====================================================================================
// Copy constructor
//=====================================================================================
{
test_ = "DynamicVector copy constructor (size 0)";
blaze::DynamicVector<int,blaze::rowVector> vec1( 0UL );
blaze::DynamicVector<int,blaze::rowVector> vec2( vec1 );
checkSize ( vec2, 0UL );
checkNonZeros( vec2, 0UL );
}
{
test_ = "DynamicVector copy constructor (size 5)";
blaze::DynamicVector<int,blaze::rowVector> vec1{ 1, 2, 3, 4, 5 };
blaze::DynamicVector<int,blaze::rowVector> vec2( vec1 );
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 5UL );
if( vec2[0] != 1 || vec2[1] != 2 || vec2[2] != 3 || vec2[3] != 4 || vec2[4] != 5 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Construction failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 1 2 3 4 5 )\n";
throw std::runtime_error( oss.str() );
}
}
//=====================================================================================
// Move constructor
//=====================================================================================
{
test_ = "DynamicVector move constructor (size 0)";
blaze::DynamicVector<int,blaze::rowVector> vec1( 0UL );
blaze::DynamicVector<int,blaze::rowVector> vec2( std::move( vec1 ) );
checkSize ( vec2, 0UL );
checkNonZeros( vec2, 0UL );
}
{
test_ = "DynamicVector move constructor (size 5)";
blaze::DynamicVector<int,blaze::rowVector> vec1{ 1, 2, 3, 4, 5 };
blaze::DynamicVector<int,blaze::rowVector> vec2( std::move( vec1 ) );
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 5UL );
if( vec2[0] != 1 || vec2[1] != 2 || vec2[2] != 3 || vec2[3] != 4 || vec2[4] != 5 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Construction failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 1 2 3 4 5 )\n";
throw std::runtime_error( oss.str() );
}
}
//=====================================================================================
// Dense vector constructor
//=====================================================================================
{
test_ = "DynamicVector dense vector constructor (aligned/padded)";
using blaze::aligned;
using blaze::padded;
using blaze::rowVector;
typedef blaze::CustomVector<int,aligned,padded,rowVector> AlignedPadded;
std::unique_ptr<int[],blaze::Deallocate> memory( blaze::allocate<int>( 16UL ) );
AlignedPadded vec1( memory.get(), 5UL, 16UL );
vec1[0] = 1;
vec1[1] = 2;
vec1[2] = 3;
vec1[3] = 4;
vec1[4] = 5;
blaze::DynamicVector<int,blaze::rowVector> vec2( vec1 );
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 5UL );
if( vec2[0] != 1 || vec2[1] != 2 || vec2[2] != 3 || vec2[3] != 4 || vec2[4] != 5 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Construction failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 1 2 3 4 5 )\n";
throw std::runtime_error( oss.str() );
}
}
{
test_ = "DynamicVector dense vector constructor (unaligned/unpadded)";
using blaze::unaligned;
using blaze::unpadded;
using blaze::rowVector;
typedef blaze::CustomVector<int,unaligned,unpadded,rowVector> UnalignedUnpadded;
std::unique_ptr<int[]> memory( new int[6] );
UnalignedUnpadded vec1( memory.get()+1UL, 5UL );
vec1[0] = 1;
vec1[1] = 2;
vec1[2] = 3;
vec1[3] = 4;
vec1[4] = 5;
blaze::DynamicVector<int,blaze::rowVector> vec2( vec1 );
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 5UL );
if( vec2[0] != 1 || vec2[1] != 2 || vec2[2] != 3 || vec2[3] != 4 || vec2[4] != 5 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Construction failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 1 2 3 4 5 )\n";
throw std::runtime_error( oss.str() );
}
}
//=====================================================================================
// Sparse vector constructor
//=====================================================================================
{
test_ = "DynamicVector sparse vector constructor";
blaze::CompressedVector<int,blaze::rowVector> vec1( 5UL, 3UL );
vec1[0] = 1;
vec1[2] = 3;
vec1[4] = 5;
blaze::DynamicVector<int,blaze::rowVector> vec2( vec1 );
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 3UL );
if( vec2[0] != 1 || vec2[1] != 0 || vec2[2] != 3 || vec2[3] != 0 || vec2[4] != 5 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Construction failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 1 0 3 0 5 )\n";
throw std::runtime_error( oss.str() );
}
}
}
//*************************************************************************************************
//*************************************************************************************************
/*!\brief Test of the DynamicVector assignment operators.
//
// \return void
// \exception std::runtime_error Error detected.
//
// This function performs a test of all assignment operators of the DynamicVector class template.
// In case an error is detected, a \a std::runtime_error exception is thrown.
*/
void ClassTest::testAssignment()
{
//=====================================================================================
// Homogeneous assignment
//=====================================================================================
{
test_ = "DynamicVector homogeneous assignment";
blaze::DynamicVector<int,blaze::rowVector> vec( 3UL );
vec = 2;
checkSize ( vec, 3UL );
checkCapacity( vec, 3UL );
checkNonZeros( vec, 3UL );
if( vec[0] != 2 || vec[1] != 2 || vec[2] != 2 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 2 2 2 )\n";
throw std::runtime_error( oss.str() );
}
}
//=====================================================================================
// List assignment
//=====================================================================================
{
test_ = "DynamicVector initializer list assignment";
blaze::DynamicVector<int,blaze::rowVector> vec;
vec = { 1, 2, 3, 4 };
checkSize ( vec, 4UL );
checkCapacity( vec, 4UL );
checkNonZeros( vec, 4UL );
if( vec[0] != 1 || vec[1] != 2 || vec[2] != 3 || vec[3] != 4 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 1 2 3 4 )\n";
throw std::runtime_error( oss.str() );
}
}
//=====================================================================================
// Array assignment
//=====================================================================================
{
test_ = "DynamicVector array assignment";
const int array[4] = { 1, 2, 3, 4 };
blaze::DynamicVector<int,blaze::rowVector> vec;
vec = array;
checkSize ( vec, 4UL );
checkCapacity( vec, 4UL );
checkNonZeros( vec, 4UL );
if( vec[0] != 1 || vec[1] != 2 || vec[2] != 3 || vec[3] != 4 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 1 2 3 4 )\n";
throw std::runtime_error( oss.str() );
}
}
//=====================================================================================
// Copy assignment
//=====================================================================================
{
test_ = "DynamicVector copy assignment";
blaze::DynamicVector<int,blaze::rowVector> vec1{ 1, 2, 3, 4, 5 };
blaze::DynamicVector<int,blaze::rowVector> vec2;
vec2 = vec1;
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 5UL );
if( vec2[0] != 1 || vec2[1] != 2 || vec2[2] != 3 || vec2[3] != 4 || vec2[4] != 5 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 1 2 3 4 5 )\n";
throw std::runtime_error( oss.str() );
}
}
{
test_ = "DynamicVector copy assignment stress test";
typedef blaze::DynamicVector<int,blaze::rowVector> RandomVectorType;
blaze::DynamicVector<int,blaze::rowVector> vec1;
const int min( randmin );
const int max( randmax );
for( size_t i=0UL; i<100UL; ++i )
{
const size_t size( blaze::rand<size_t>( 0UL, 20UL ) );
const RandomVectorType vec2( blaze::rand<RandomVectorType>( size, min, max ) );
vec1 = vec2;
if( vec1 != vec2 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec1 << "\n"
<< " Expected result:\n" << vec2 << "\n";
throw std::runtime_error( oss.str() );
}
}
}
//=====================================================================================
// Move assignment
//=====================================================================================
{
test_ = "DynamicVector move assignment";
blaze::DynamicVector<int,blaze::rowVector> vec1{ 1, 2, 3, 4, 5 };
blaze::DynamicVector<int,blaze::rowVector> vec2{ 11, 12, 13 };
vec2 = std::move( vec1 );
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 5UL );
if( vec2[0] != 1 || vec2[1] != 2 || vec2[2] != 3 || vec2[3] != 4 || vec2[4] != 5 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 1 2 3 4 5 )\n";
throw std::runtime_error( oss.str() );
}
}
//=====================================================================================
// Dense vector assignment
//=====================================================================================
{
test_ = "DynamicVector dense vector assignment (mixed type)";
blaze::DynamicVector<short,blaze::rowVector> vec1{ 1, 2, 3, 4, 5 };
blaze::DynamicVector<int,blaze::rowVector> vec2;
vec2 = vec1;
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 5UL );
if( vec2[0] != 1 || vec2[1] != 2 || vec2[2] != 3 || vec2[3] != 4 || vec2[4] != 5 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 1 2 3 4 5 )\n";
throw std::runtime_error( oss.str() );
}
}
{
test_ = "DynamicVector dense vector assignment (aligned/padded)";
using blaze::aligned;
using blaze::padded;
using blaze::rowVector;
typedef blaze::CustomVector<int,aligned,padded,rowVector> AlignedPadded;
std::unique_ptr<int[],blaze::Deallocate> memory( blaze::allocate<int>( 16UL ) );
AlignedPadded vec1( memory.get(), 5UL, 16UL );
vec1[0] = 1;
vec1[1] = 2;
vec1[2] = 3;
vec1[3] = 4;
vec1[4] = 5;
blaze::DynamicVector<int,blaze::rowVector> vec2;
vec2 = vec1;
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 5UL );
if( vec2[0] != 1 || vec2[1] != 2 || vec2[2] != 3 || vec2[3] != 4 || vec2[4] != 5 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 1 2 3 4 5 )\n";
throw std::runtime_error( oss.str() );
}
}
{
test_ = "DynamicVector dense vector assignment (unaligned/unpadded)";
using blaze::unaligned;
using blaze::unpadded;
using blaze::rowVector;
typedef blaze::CustomVector<int,unaligned,unpadded,rowVector> UnalignedUnpadded;
std::unique_ptr<int[]> memory( new int[6] );
UnalignedUnpadded vec1( memory.get()+1UL, 5UL );
vec1[0] = 1;
vec1[1] = 2;
vec1[2] = 3;
vec1[3] = 4;
vec1[4] = 5;
blaze::DynamicVector<int,blaze::rowVector> vec2;
vec2 = vec1;
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 5UL );
if( vec2[0] != 1 || vec2[1] != 2 || vec2[2] != 3 || vec2[3] != 4 || vec2[4] != 5 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 1 2 3 4 5 )\n";
throw std::runtime_error( oss.str() );
}
}
{
test_ = "DynamicVector dense vector assignment stress test";
typedef blaze::DynamicVector<short,blaze::rowVector> RandomVectorType;
blaze::DynamicVector<int,blaze::rowVector> vec1;
const short min( randmin );
const short max( randmax );
for( size_t i=0UL; i<100UL; ++i )
{
const size_t size( blaze::rand<size_t>( 0UL, 20UL ) );
const RandomVectorType vec2( blaze::rand<RandomVectorType>( size, min, max ) );
vec1 = vec2;
if( vec1 != vec2 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec1 << "\n"
<< " Expected result:\n" << vec2 << "\n";
throw std::runtime_error( oss.str() );
}
}
}
//=====================================================================================
// Sparse vector assignment
//=====================================================================================
{
test_ = "DynamicVector sparse vector assignment";
blaze::CompressedVector<int,blaze::rowVector> vec1( 5UL );
vec1[0] = 1;
vec1[2] = 2;
vec1[3] = 3;
blaze::DynamicVector<int,blaze::rowVector> vec2;
vec2 = vec1;
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 3UL );
if( vec2[0] != 1 || vec2[1] != 0 || vec2[2] != 2 || vec2[3] != 3 || vec2[4] != 0 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 1 0 2 3 0 )\n";
throw std::runtime_error( oss.str() );
}
}
{
test_ = "DynamicVector sparse vector assignment stress test";
typedef blaze::CompressedVector<int,blaze::rowVector> RandomVectorType;
blaze::DynamicVector<int,blaze::rowVector> vec1;
const int min( randmin );
const int max( randmax );
for( size_t i=0UL; i<100UL; ++i )
{
const size_t size( blaze::rand<size_t>( 0UL, 20UL ) );
const RandomVectorType vec2( blaze::rand<RandomVectorType>( size, min, max ) );
vec1 = vec2;
if( vec1 != vec2 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec1 << "\n"
<< " Expected result:\n" << vec2 << "\n";
throw std::runtime_error( oss.str() );
}
}
}
}
//*************************************************************************************************
//*************************************************************************************************
/*!\brief Test of the DynamicVector addition assignment operators.
//
// \return void
// \exception std::runtime_error Error detected.
//
// This function performs a test of the addition assignment operators of the DynamicVector class
// template. In case an error is detected, a \a std::runtime_error exception is thrown.
*/
void ClassTest::testAddAssign()
{
//=====================================================================================
// Dense vector addition assignment
//=====================================================================================
{
test_ = "DynamicVector dense vector addition assignment (mixed type)";
blaze::DynamicVector<short,blaze::rowVector> vec1{ 1, 0, -2, 3, 0 };
blaze::DynamicVector<int,blaze::rowVector> vec2{ 0, 4, 2, -6, 7 };
vec2 += vec1;
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 4UL );
if( vec2[0] != 1 || vec2[1] != 4 || vec2[2] != 0 || vec2[3] != -3 || vec2[4] != 7 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Addition assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 1 4 0 -3 7 )\n";
throw std::runtime_error( oss.str() );
}
}
{
test_ = "DynamicVector dense vector addition assignment (aligned/padded)";
using blaze::aligned;
using blaze::padded;
using blaze::rowVector;
typedef blaze::CustomVector<int,aligned,padded,rowVector> AlignedPadded;
std::unique_ptr<int[],blaze::Deallocate> memory( blaze::allocate<int>( 16UL ) );
AlignedPadded vec1( memory.get(), 5UL, 16UL );
vec1[0] = 1;
vec1[1] = 0;
vec1[2] = -2;
vec1[3] = 3;
vec1[4] = 0;
blaze::DynamicVector<int,blaze::rowVector> vec2{ 0, 4, 2, -6, 7 };
vec2 += vec1;
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 4UL );
if( vec2[0] != 1 || vec2[1] != 4 || vec2[2] != 0 || vec2[3] != -3 || vec2[4] != 7 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Addition assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 1 4 0 -3 7 )\n";
throw std::runtime_error( oss.str() );
}
}
{
test_ = "DynamicVector dense vector addition assignment (unaligned/unpadded)";
using blaze::unaligned;
using blaze::unpadded;
using blaze::rowVector;
typedef blaze::CustomVector<int,unaligned,unpadded,rowVector> UnalignedUnpadded;
std::unique_ptr<int[]> memory( new int[6] );
UnalignedUnpadded vec1( memory.get()+1UL, 5UL );
vec1[0] = 1;
vec1[1] = 0;
vec1[2] = -2;
vec1[3] = 3;
vec1[4] = 0;
blaze::DynamicVector<int,blaze::rowVector> vec2{ 0, 4, 2, -6, 7 };
vec2 += vec1;
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 4UL );
if( vec2[0] != 1 || vec2[1] != 4 || vec2[2] != 0 || vec2[3] != -3 || vec2[4] != 7 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Addition assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 1 4 0 -3 7 )\n";
throw std::runtime_error( oss.str() );
}
}
//=====================================================================================
// Sparse vector addition assignment
//=====================================================================================
{
test_ = "DynamicVector sparse vector addition assignment";
blaze::CompressedVector<int,blaze::rowVector> vec1( 5UL, 3UL );
vec1[0] = 1;
vec1[2] = -2;
vec1[3] = 3;
blaze::DynamicVector<int,blaze::rowVector> vec2{ 0, 4, 2, -6, 7 };
vec2 += vec1;
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 4UL );
if( vec2[0] != 1 || vec2[1] != 4 || vec2[2] != 0 || vec2[3] != -3 || vec2[4] != 7 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Addition assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 1 4 0 -3 7 )\n";
throw std::runtime_error( oss.str() );
}
}
}
//*************************************************************************************************
//*************************************************************************************************
/*!\brief Test of the DynamicVector subtraction assignment operators.
//
// \return void
// \exception std::runtime_error Error detected.
//
// This function performs a test of the subtraction assignment operators of the DynamicVector class
// template. In case an error is detected, a \a std::runtime_error exception is thrown.
*/
void ClassTest::testSubAssign()
{
//=====================================================================================
// Dense vector subtraction assignment
//=====================================================================================
{
test_ = "DynamicVector dense vector subtraction assignment (mixed type)";
blaze::DynamicVector<short,blaze::rowVector> vec1{ -1, 0, 2, -3, 0 };
blaze::DynamicVector<int,blaze::rowVector> vec2{ 0, 4, 2, -6, 7 };
vec2 -= vec1;
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 4UL );
if( vec2[0] != 1 || vec2[1] != 4 || vec2[2] != 0 || vec2[3] != -3 || vec2[4] != 7 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Subtraction assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 1 4 0 -3 7 )\n";
throw std::runtime_error( oss.str() );
}
}
{
test_ = "DynamicVector dense vector subtraction assignment (aligned/padded)";
using blaze::aligned;
using blaze::padded;
using blaze::rowVector;
typedef blaze::CustomVector<int,aligned,padded,rowVector> AlignedPadded;
std::unique_ptr<int[],blaze::Deallocate> memory( blaze::allocate<int>( 16UL ) );
AlignedPadded vec1( memory.get(), 5UL, 16UL );
vec1[0] = -1;
vec1[1] = 0;
vec1[2] = 2;
vec1[3] = -3;
vec1[4] = 0;
blaze::DynamicVector<int,blaze::rowVector> vec2{ 0, 4, 2, -6, 7 };
vec2 -= vec1;
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 4UL );
if( vec2[0] != 1 || vec2[1] != 4 || vec2[2] != 0 || vec2[3] != -3 || vec2[4] != 7 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Subtraction assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 1 4 0 -3 7 )\n";
throw std::runtime_error( oss.str() );
}
}
{
test_ = "DynamicVector dense vector subtraction assignment (unaligned/unpadded)";
using blaze::unaligned;
using blaze::unpadded;
using blaze::rowVector;
typedef blaze::CustomVector<int,unaligned,unpadded,rowVector> UnalignedUnpadded;
std::unique_ptr<int[]> memory( new int[6] );
UnalignedUnpadded vec1( memory.get()+1UL, 5UL );
vec1[0] = -1;
vec1[1] = 0;
vec1[2] = 2;
vec1[3] = -3;
vec1[4] = 0;
blaze::DynamicVector<int,blaze::rowVector> vec2{ 0, 4, 2, -6, 7 };
vec2 -= vec1;
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 4UL );
if( vec2[0] != 1 || vec2[1] != 4 || vec2[2] != 0 || vec2[3] != -3 || vec2[4] != 7 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Subtraction assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 1 4 0 -3 7 )\n";
throw std::runtime_error( oss.str() );
}
}
//=====================================================================================
// Sparse vector subtraction assignment
//=====================================================================================
{
test_ = "DynamicVector sparse vector subtraction assignment";
blaze::CompressedVector<int,blaze::rowVector> vec1( 5UL, 3UL );
vec1[0] = -1;
vec1[2] = 2;
vec1[3] = -3;
blaze::DynamicVector<int,blaze::rowVector> vec2{ 0, 4, 2, -6, 7 };
vec2 -= vec1;
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 4UL );
if( vec2[0] != 1 || vec2[1] != 4 || vec2[2] != 0 || vec2[3] != -3 || vec2[4] != 7 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Subtraction assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 1 4 0 -3 7 )\n";
throw std::runtime_error( oss.str() );
}
}
}
//*************************************************************************************************
//*************************************************************************************************
/*!\brief Test of the DynamicVector multiplication assignment operators.
//
// \return void
// \exception std::runtime_error Error detected.
//
// This function performs a test of the multiplication assignment operators of the DynamicVector
// class template. In case an error is detected, a \a std::runtime_error exception is thrown.
*/
void ClassTest::testMultAssign()
{
//=====================================================================================
// Dense vector multiplication assignment
//=====================================================================================
{
test_ = "DynamicVector dense vector multiplication assignment (mixed type)";
blaze::DynamicVector<short,blaze::rowVector> vec1{ 1, 0, -2, 3, 0 };
blaze::DynamicVector<int,blaze::rowVector> vec2{ 0, 4, 2, -6, 7 };
vec2 *= vec1;
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 2UL );
if( vec2[0] != 0 || vec2[1] != 0 || vec2[2] != -4 || vec2[3] != -18 || vec2[4] != 0 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Multiplication assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 0 0 -4 -18 0 )\n";
throw std::runtime_error( oss.str() );
}
}
{
test_ = "DynamicVector dense vector multiplication assignment (aligned/padded)";
using blaze::aligned;
using blaze::padded;
using blaze::rowVector;
typedef blaze::CustomVector<int,aligned,padded,rowVector> AlignedPadded;
std::unique_ptr<int[],blaze::Deallocate> memory( blaze::allocate<int>( 16UL ) );
AlignedPadded vec1( memory.get(), 5UL, 16UL );
vec1[0] = 1;
vec1[1] = 0;
vec1[2] = -2;
vec1[3] = 3;
vec1[4] = 0;
blaze::DynamicVector<int,blaze::rowVector> vec2{ 0, 4, 2, -6, 7 };
vec2 *= vec1;
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 2UL );
if( vec2[0] != 0 || vec2[1] != 0 || vec2[2] != -4 || vec2[3] != -18 || vec2[4] != 0 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Multiplication assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 0 0 -4 -18 0 )\n";
throw std::runtime_error( oss.str() );
}
}
{
test_ = "DynamicVector dense vector multiplication assignment (unaligned/unpadded)";
using blaze::unaligned;
using blaze::unpadded;
using blaze::rowVector;
typedef blaze::CustomVector<int,unaligned,unpadded,rowVector> UnalignedUnpadded;
std::unique_ptr<int[]> memory( new int[6] );
UnalignedUnpadded vec1( memory.get()+1UL, 5UL );
vec1[0] = 1;
vec1[1] = 0;
vec1[2] = -2;
vec1[3] = 3;
vec1[4] = 0;
blaze::DynamicVector<int,blaze::rowVector> vec2{ 0, 4, 2, -6, 7 };
vec2 *= vec1;
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 2UL );
if( vec2[0] != 0 || vec2[1] != 0 || vec2[2] != -4 || vec2[3] != -18 || vec2[4] != 0 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Multiplication assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 0 0 -4 -18 0 )\n";
throw std::runtime_error( oss.str() );
}
}
//=====================================================================================
// Sparse vector multiplication assignment
//=====================================================================================
{
test_ = "DynamicVector sparse vector multiplication assignment";
blaze::CompressedVector<int,blaze::rowVector> vec1( 5UL, 3UL );
vec1[0] = 1;
vec1[2] = -2;
vec1[3] = 3;
blaze::DynamicVector<int,blaze::rowVector> vec2{ 0, 4, 2, -6, 7 };
vec2 *= vec1;
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 2UL );
if( vec2[0] != 0 || vec2[1] != 0 || vec2[2] != -4 || vec2[3] != -18 || vec2[4] != 0 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Multiplication assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 0 0 -4 -18 0 )\n";
throw std::runtime_error( oss.str() );
}
}
}
//*************************************************************************************************
//*************************************************************************************************
/*!\brief Test of the DynamicVector division assignment operators.
//
// \return void
// \exception std::runtime_error Error detected.
//
// This function performs a test of the division assignment operators of the DynamicVector
// class template. In case an error is detected, a \a std::runtime_error exception is thrown.
*/
void ClassTest::testDivAssign()
{
//=====================================================================================
// Dense vector division assignment
//=====================================================================================
{
test_ = "DynamicVector dense vector division assignment (mixed type)";
blaze::DynamicVector<short,blaze::rowVector> vec1{ 1, 2, -3, 4, 1 };
blaze::DynamicVector<int,blaze::rowVector> vec2{ 2, 0, -3, 8, 0 };
vec2 /= vec1;
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 3UL );
if( vec2[0] != 2 || vec2[1] != 0 || vec2[2] != 1 || vec2[3] != 2 || vec2[4] != 0 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Division assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 2 0 1 2 0 )\n";
throw std::runtime_error( oss.str() );
}
}
{
test_ = "DynamicVector dense vector division assignment (aligned/padded)";
using blaze::aligned;
using blaze::padded;
using blaze::rowVector;
typedef blaze::CustomVector<int,aligned,padded,rowVector> AlignedPadded;
std::unique_ptr<int[],blaze::Deallocate> memory( blaze::allocate<int>( 16UL ) );
AlignedPadded vec1( memory.get(), 5UL, 16UL );
vec1[0] = 1;
vec1[1] = 2;
vec1[2] = -3;
vec1[3] = 4;
vec1[4] = 1;
blaze::DynamicVector<int,blaze::rowVector> vec2{ 2, 0, -3, 8, 0 };
vec2 /= vec1;
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 3UL );
if( vec2[0] != 2 || vec2[1] != 0 || vec2[2] != 1 || vec2[3] != 2 || vec2[4] != 0 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Division assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 2 0 1 2 0 )\n";
throw std::runtime_error( oss.str() );
}
}
{
test_ = "DynamicVector dense vector division assignment (unaligned/unpadded)";
using blaze::unaligned;
using blaze::unpadded;
using blaze::rowVector;
typedef blaze::CustomVector<int,unaligned,unpadded,rowVector> UnalignedUnpadded;
std::unique_ptr<int[]> memory( new int[6] );
UnalignedUnpadded vec1( memory.get()+1UL, 5UL );
vec1[0] = 1;
vec1[1] = 2;
vec1[2] = -3;
vec1[3] = 4;
vec1[4] = 1;
blaze::DynamicVector<int,blaze::rowVector> vec2{ 2, 0, -3, 8, 0 };
vec2 /= vec1;
checkSize ( vec2, 5UL );
checkCapacity( vec2, 5UL );
checkNonZeros( vec2, 3UL );
if( vec2[0] != 2 || vec2[1] != 0 || vec2[2] != 1 || vec2[3] != 2 || vec2[4] != 0 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Division assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 2 0 1 2 0 )\n";
throw std::runtime_error( oss.str() );
}
}
}
//*************************************************************************************************
//*************************************************************************************************
/*!\brief Test of the DynamicVector cross product assignment operators.
//
// \return void
// \exception std::runtime_error Error detected.
//
// This function performs a test of the cross product assignment operators of the DynamicVector
// class template. In case an error is detected, a \a std::runtime_error exception is thrown.
*/
void ClassTest::testCrossAssign()
{
//=====================================================================================
// Dense vector cross product assignment
//=====================================================================================
{
test_ = "DynamicVector dense vector cross product assignment (mixed type)";
blaze::DynamicVector<short,blaze::rowVector> vec1{ 1, 0, -2 };
blaze::DynamicVector<int,blaze::rowVector> vec2{ 2, 0, -1 };
vec2 %= vec1;
checkSize ( vec2, 3UL );
checkCapacity( vec2, 3UL );
checkNonZeros( vec2, 1UL );
if( vec2[0] != 0 || vec2[1] != 3 || vec2[2] != 0 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Cross product assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 0 3 0 )\n";
throw std::runtime_error( oss.str() );
}
}
{
test_ = "DynamicVector dense vector cross product assignment (aligned/padded)";
using blaze::aligned;
using blaze::padded;
using blaze::rowVector;
typedef blaze::CustomVector<int,aligned,padded,rowVector> AlignedPadded;
std::unique_ptr<int[],blaze::Deallocate> memory( blaze::allocate<int>( 16UL ) );
AlignedPadded vec1( memory.get(), 3UL, 16UL );
vec1[0] = 1;
vec1[1] = 0;
vec1[2] = -2;
blaze::DynamicVector<int,blaze::rowVector> vec2{ 2, 0, -1 };
vec2 %= vec1;
checkSize ( vec2, 3UL );
checkCapacity( vec2, 3UL );
checkNonZeros( vec2, 1UL );
if( vec2[0] != 0 || vec2[1] != 3 || vec2[2] != 0 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Cross product assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 0 3 0 )\n";
throw std::runtime_error( oss.str() );
}
}
{
test_ = "DynamicVector dense vector cross product assignment (unaligned/unpadded)";
using blaze::unaligned;
using blaze::unpadded;
using blaze::rowVector;
typedef blaze::CustomVector<int,unaligned,unpadded,rowVector> UnalignedUnpadded;
std::unique_ptr<int[]> memory( new int[4] );
UnalignedUnpadded vec1( memory.get()+1UL, 3UL );
vec1[0] = 1;
vec1[1] = 0;
vec1[2] = -2;
blaze::DynamicVector<int,blaze::rowVector> vec2{ 2, 0, -1 };
vec2 %= vec1;
checkSize ( vec2, 3UL );
checkCapacity( vec2, 3UL );
checkNonZeros( vec2, 1UL );
if( vec2[0] != 0 || vec2[1] != 3 || vec2[2] != 0 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Cross product assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 0 3 0 )\n";
throw std::runtime_error( oss.str() );
}
}
//=====================================================================================
// Sparse vector cross product assignment
//=====================================================================================
{
test_ = "DynamicVector sparse vector cross product assignment";
blaze::CompressedVector<int,blaze::rowVector> vec1( 3UL, 2UL );
vec1[0] = 1;
vec1[2] = -2;
blaze::DynamicVector<int,blaze::rowVector> vec2{ 2, 0, -1 };
vec2 %= vec1;
checkSize ( vec2, 3UL );
checkCapacity( vec2, 3UL );
checkNonZeros( vec2, 1UL );
if( vec2[0] != 0 || vec2[1] != 3 || vec2[2] != 0 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Cross product assignment failed\n"
<< " Details:\n"
<< " Result:\n" << vec2 << "\n"
<< " Expected result:\n( 0 3 0 )\n";
throw std::runtime_error( oss.str() );
}
}
}
//*************************************************************************************************
//*************************************************************************************************
/*!\brief Test of all DynamicVector (self-)scaling operations.
//
// \return void
// \exception std::runtime_error Error detected.
//
// This function performs a test of all available ways to scale an instance of the DynamicVector
// class template. In case an error is detected, a \a std::runtime_error exception is thrown.
*/
void ClassTest::testScaling()
{
//=====================================================================================
// Self-scaling (v*=s)
//=====================================================================================
{
test_ = "DynamicVector self-scaling (v*=s)";
blaze::DynamicVector<int,blaze::rowVector> vec{ 1, 0, -2, 3, 0 };
vec *= 2;
checkSize ( vec, 5UL );
checkCapacity( vec, 5UL );
checkNonZeros( vec, 3UL );
if( vec[0] != 2 || vec[1] != 0 || vec[2] != -4 || vec[3] != 6 || vec[4] != 0 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Failed self-scaling operation\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 2 0 -4 6 0 )\n";
throw std::runtime_error( oss.str() );
}
}
//=====================================================================================
// Self-scaling (v=v*s)
//=====================================================================================
{
test_ = "DynamicVector self-scaling (v=v*s)";
blaze::DynamicVector<int,blaze::rowVector> vec{ 1, 0, -2, 3, 0 };
vec = vec * 2;
checkSize ( vec, 5UL );
checkCapacity( vec, 5UL );
checkNonZeros( vec, 3UL );
if( vec[0] != 2 || vec[1] != 0 || vec[2] != -4 || vec[3] != 6 || vec[4] != 0 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Failed self-scaling operation\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 2 0 -4 6 0 )\n";
throw std::runtime_error( oss.str() );
}
}
//=====================================================================================
// Self-scaling (v=s*v)
//=====================================================================================
{
test_ = "DynamicVector self-scaling (v=s*v)";
blaze::DynamicVector<int,blaze::rowVector> vec{ 1, 0, -2, 3, 0 };
vec = 2 * vec;
checkSize ( vec, 5UL );
checkCapacity( vec, 5UL );
checkNonZeros( vec, 3UL );
if( vec[0] != 2 || vec[1] != 0 || vec[2] != -4 || vec[3] != 6 || vec[4] != 0 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Failed self-scaling operation\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 2 0 -4 6 0 )\n";
throw std::runtime_error( oss.str() );
}
}
//=====================================================================================
// Self-scaling (v/=s)
//=====================================================================================
{
test_ = "DynamicVector self-scaling (v/=s)";
blaze::DynamicVector<int,blaze::rowVector> vec{ 2, 0, -4, 6, 0 };
vec /= 2;
checkSize ( vec, 5UL );
checkCapacity( vec, 5UL );
checkNonZeros( vec, 3UL );
if( vec[0] != 1 || vec[1] != 0 || vec[2] != -2 || vec[3] != 3 || vec[4] != 0 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Failed self-scaling operation\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 1 0 -2 3 0 )\n";
throw std::runtime_error( oss.str() );
}
}
//=====================================================================================
// Self-scaling (v=v/s)
//=====================================================================================
{
test_ = "DynamicVector self-scaling (v=v/s)";
blaze::DynamicVector<int,blaze::rowVector> vec{ 2, 0, -4, 6, 0 };
vec = vec / 2;
checkSize ( vec, 5UL );
checkCapacity( vec, 5UL );
checkNonZeros( vec, 3UL );
if( vec[0] != 1 || vec[1] != 0 || vec[2] != -2 || vec[3] != 3 || vec[4] != 0 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Failed self-scaling operation\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 1 0 -2 3 0 )\n";
throw std::runtime_error( oss.str() );
}
}
//=====================================================================================
// DynamicVector::scale()
//=====================================================================================
{
test_ = "DynamicVector::scale() (int)";
// Initialization check
blaze::DynamicVector<int,blaze::rowVector> vec{ 1, 2, 3, 4 };
checkSize ( vec, 4UL );
checkCapacity( vec, 4UL );
checkNonZeros( vec, 4UL );
if( vec[0] != 1 || vec[1] != 2 || vec[2] != 3 || vec[3] != 4 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Initialization failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 1 2 3 4 )\n";
throw std::runtime_error( oss.str() );
}
// Integral scaling of the vector
vec.scale( 2 );
checkSize ( vec, 4UL );
checkCapacity( vec, 4UL );
checkNonZeros( vec, 4UL );
if( vec[0] != 2 || vec[1] != 4 || vec[2] != 6 || vec[3] != 8 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Scale operation failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 2 4 6 8 )\n";
throw std::runtime_error( oss.str() );
}
// Floating point scaling of the vector
vec.scale( 0.5 );
checkSize ( vec, 4UL );
checkCapacity( vec, 4UL );
checkNonZeros( vec, 4UL );
if( vec[0] != 1 || vec[1] != 2 || vec[2] != 3 || vec[3] != 4 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Scale operation failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 1 2 3 4 )\n";
throw std::runtime_error( oss.str() );
}
}
{
test_ = "DynamicVector::scale() (complex)";
using blaze::complex;
blaze::DynamicVector<complex<float>,blaze::rowVector> vec( 2UL );
vec[0] = complex<float>( 1.0F, 0.0F );
vec[1] = complex<float>( 2.0F, 0.0F );
vec.scale( complex<float>( 3.0F, 0.0F ) );
checkSize ( vec, 2UL );
checkCapacity( vec, 2UL );
checkNonZeros( vec, 2UL );
if( vec[0] != complex<float>( 3.0F, 0.0F ) || vec[1] != complex<float>( 6.0F, 0.0F ) ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Scale operation failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( (3,0) (6,0) )\n";
throw std::runtime_error( oss.str() );
}
}
}
//*************************************************************************************************
//*************************************************************************************************
/*!\brief Test of the DynamicVector subscript operator.
//
// \return void
// \exception std::runtime_error Error detected.
//
// This function performs a test of adding and accessing elements via the subscript operator
// of the DynamicVector class template. In case an error is detected, a \a std::runtime_error
// exception is thrown.
*/
void ClassTest::testSubscript()
{
test_ = "DynamicVector::operator[]";
// Assignment to the element at index 2
blaze::DynamicVector<int,blaze::rowVector> vec{ 0, 0, 1, 0, 0, 0, 0 };
checkSize ( vec, 7UL );
checkCapacity( vec, 7UL );
checkNonZeros( vec, 1UL );
if( vec[2] != 1 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Subscript operator failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 0 0 1 0 0 0 0 )\n";
throw std::runtime_error( oss.str() );
}
// Assignment to the element at index 5
vec[5] = 2;
checkSize ( vec, 7UL );
checkCapacity( vec, 7UL );
checkNonZeros( vec, 2UL );
if( vec[2] != 1 || vec[5] != 2 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Subscript operator failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 0 0 1 0 0 2 0 )\n";
throw std::runtime_error( oss.str() );
}
// Assignment to the element at index 3
vec[3] = 3;
checkSize ( vec, 7UL );
checkCapacity( vec, 7UL );
checkNonZeros( vec, 3UL );
if( vec[2] != 1 || vec[3] != 3 || vec[5] != 2 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Subscript operator failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 0 0 1 3 0 2 0 )\n";
throw std::runtime_error( oss.str() );
}
// Assignment to the element at index 0
vec[0] = 4;
checkSize ( vec, 7UL );
checkCapacity( vec, 7UL );
checkNonZeros( vec, 4UL );
if( vec[0] != 4 || vec[2] != 1 || vec[3] != 3 || vec[5] != 2 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Subscript operator failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 4 0 1 3 0 2 0 )\n";
throw std::runtime_error( oss.str() );
}
// Addition assignment to the element at index 2
vec[2] += vec[3];
checkSize ( vec, 7UL );
checkCapacity( vec, 7UL );
checkNonZeros( vec, 4UL );
if( vec[0] != 4 || vec[2] != 4 || vec[3] != 3 || vec[5] != 2 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Subscript operator failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 4 0 4 3 0 2 0 )\n";
throw std::runtime_error( oss.str() );
}
// Subtraction assignment to the element at index 1
vec[1] -= vec[5];
checkSize ( vec, 7UL );
checkCapacity( vec, 7UL );
checkNonZeros( vec, 5UL );
if( vec[0] != 4 || vec[1] != -2 || vec[2] != 4 || vec[3] != 3 || vec[5] != 2 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Subscript operator failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 4 -2 4 3 0 2 0 )\n";
throw std::runtime_error( oss.str() );
}
// Multiplication assignment to the element at index 3
vec[3] *= -3;
checkSize ( vec, 7UL );
checkCapacity( vec, 7UL );
checkNonZeros( vec, 5UL );
if( vec[0] != 4 || vec[1] != -2 || vec[2] != 4 || vec[3] != -9 || vec[5] != 2 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Subscript operator failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 4 -2 4 -9 0 2 0 )\n";
throw std::runtime_error( oss.str() );
}
// Division assignment to the element at index 2
vec[2] /= 2;
checkSize ( vec, 7UL );
checkCapacity( vec, 7UL );
checkNonZeros( vec, 5UL );
if( vec[0] != 4 || vec[1] != -2 || vec[2] != 2 || vec[3] != -9 || vec[5] != 2 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Subscript operator failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 4 -2 2 -9 0 2 0 )\n";
throw std::runtime_error( oss.str() );
}
}
//*************************************************************************************************
//*************************************************************************************************
/*!\brief Test of the \c at() member function of the DynamicVector class template.
//
// \return void
// \exception std::runtime_error Error detected.
//
// This function performs a test of adding and accessing elements via the \c at() member function
// of the DynamicVector class template. In case an error is detected, a \a std::runtime_error
// exception is thrown.
*/
void ClassTest::testAt()
{
test_ = "DynamicVector::at()";
// Assignment to the element at index 2
blaze::DynamicVector<int,blaze::rowVector> vec{ 0, 0, 1, 0, 0, 0, 0 };
checkSize ( vec, 7UL );
checkCapacity( vec, 7UL );
checkNonZeros( vec, 1UL );
if( vec.at(2) != 1 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Access via at() function failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 0 0 1 0 0 0 0 )\n";
throw std::runtime_error( oss.str() );
}
// Assignment to the element at index 5
vec.at(5) = 2;
checkSize ( vec, 7UL );
checkCapacity( vec, 7UL );
checkNonZeros( vec, 2UL );
if( vec.at(2) != 1 || vec.at(5) != 2 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Access via at() function failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 0 0 1 0 0 2 0 )\n";
throw std::runtime_error( oss.str() );
}
// Assignment to the element at index 3
vec.at(3) = 3;
checkSize ( vec, 7UL );
checkCapacity( vec, 7UL );
checkNonZeros( vec, 3UL );
if( vec.at(2) != 1 || vec.at(3) != 3 || vec.at(5) != 2 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Access via at() function failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 0 0 1 3 0 2 0 )\n";
throw std::runtime_error( oss.str() );
}
// Assignment to the element at index 0
vec.at(0) = 4;
checkSize ( vec, 7UL );
checkCapacity( vec, 7UL );
checkNonZeros( vec, 4UL );
if( vec.at(0) != 4 || vec.at(2) != 1 || vec.at(3) != 3 || vec.at(5) != 2 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Access via at() function failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 4 0 1 3 0 2 0 )\n";
throw std::runtime_error( oss.str() );
}
// Addition assignment to the element at index 2
vec.at(2) += vec.at(3);
checkSize ( vec, 7UL );
checkCapacity( vec, 7UL );
checkNonZeros( vec, 4UL );
if( vec.at(0) != 4 || vec.at(2) != 4 || vec.at(3) != 3 || vec.at(5) != 2 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Access via at() function failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 4 0 4 3 0 2 0 )\n";
throw std::runtime_error( oss.str() );
}
// Subtraction assignment to the element at index 1
vec.at(1) -= vec.at(5);
checkSize ( vec, 7UL );
checkCapacity( vec, 7UL );
checkNonZeros( vec, 5UL );
if( vec.at(0) != 4 || vec.at(1) != -2 || vec.at(2) != 4 || vec.at(3) != 3 || vec.at(5) != 2 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Access via at() function failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 4 -2 4 3 0 2 0 )\n";
throw std::runtime_error( oss.str() );
}
// Multiplication assignment to the element at index 3
vec.at(3) *= -3;
checkSize ( vec, 7UL );
checkCapacity( vec, 7UL );
checkNonZeros( vec, 5UL );
if( vec.at(0) != 4 || vec.at(1) != -2 || vec.at(2) != 4 || vec.at(3) != -9 || vec.at(5) != 2 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Access via at() function failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 4 -2 4 -9 0 2 0 )\n";
throw std::runtime_error( oss.str() );
}
// Division assignment to the element at index 2
vec.at(2) /= 2;
checkSize ( vec, 7UL );
checkCapacity( vec, 7UL );
checkNonZeros( vec, 5UL );
if( vec.at(0) != 4 || vec.at(1) != -2 || vec.at(2) != 2 || vec.at(3) != -9 || vec.at(5) != 2 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Access via at() function failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 4 -2 2 -9 0 2 0 )\n";
throw std::runtime_error( oss.str() );
}
// Attempt to assign to the element at index 7
try {
vec.at(7) = 2;
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Out-of-bound access succeeded\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 4 -2 2 -9 0 2 0 )\n";
throw std::runtime_error( oss.str() );
}
catch( std::out_of_range& ) {}
}
//*************************************************************************************************
//*************************************************************************************************
/*!\brief Test of the DynamicVector iterator implementation.
//
// \return void
// \exception std::runtime_error Error detected.
//
// This function performs a test of the iterator implementation of the DynamicVector class
// template. In case an error is detected, a \a std::runtime_error exception is thrown.
*/
void ClassTest::testIterator()
{
typedef blaze::DynamicVector<int> VectorType;
typedef VectorType::Iterator Iterator;
typedef VectorType::ConstIterator ConstIterator;
VectorType vec{ 1, 0, -2, -3 };
// Testing the Iterator default constructor
{
test_ = "Iterator default constructor";
Iterator it = Iterator();
if( it != Iterator() ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Failed iterator default constructor\n";
throw std::runtime_error( oss.str() );
}
}
// Testing the ConstIterator default constructor
{
test_ = "ConstIterator default constructor";
ConstIterator it = ConstIterator();
if( it != ConstIterator() ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Failed iterator default constructor\n";
throw std::runtime_error( oss.str() );
}
}
// Testing conversion from Iterator to ConstIterator
{
test_ = "Iterator/ConstIterator conversion";
ConstIterator it( begin( vec ) );
if( it == end( vec ) || *it != 1 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Failed iterator conversion detected\n";
throw std::runtime_error( oss.str() );
}
}
// Counting the number of elements via Iterator
{
test_ = "Iterator subtraction";
const size_t number( end( vec ) - begin( vec ) );
if( number != 4UL ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Invalid number of elements detected\n"
<< " Details:\n"
<< " Number of elements : " << number << "\n"
<< " Expected number of elements: 4\n";
throw std::runtime_error( oss.str() );
}
}
// Counting the number of elements via ConstIterator
{
test_ = "ConstIterator subtraction";
const size_t number( cend( vec ) - cbegin( vec ) );
if( number != 4UL ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Invalid number of elements detected\n"
<< " Details:\n"
<< " Number of elements : " << number << "\n"
<< " Expected number of elements: 4\n";
throw std::runtime_error( oss.str() );
}
}
// Testing read-only access via ConstIterator
{
test_ = "Read-only access via ConstIterator";
ConstIterator it ( cbegin( vec ) );
ConstIterator end( cend( vec ) );
if( it == end || *it != 1 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Invalid initial iterator detected\n";
throw std::runtime_error( oss.str() );
}
++it;
if( it == end || *it != 0 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Iterator pre-increment failed\n";
throw std::runtime_error( oss.str() );
}
--it;
if( it == end || *it != 1 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Iterator pre-decrement failed\n";
throw std::runtime_error( oss.str() );
}
it++;
if( it == end || *it != 0 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Iterator post-increment failed\n";
throw std::runtime_error( oss.str() );
}
it--;
if( it == end || *it != 1 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Iterator post-decrement failed\n";
throw std::runtime_error( oss.str() );
}
it += 2UL;
if( it == end || *it != -2 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Iterator addition assignment failed\n";
throw std::runtime_error( oss.str() );
}
it -= 2UL;
if( it == end || *it != 1 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Iterator subtraction assignment failed\n";
throw std::runtime_error( oss.str() );
}
it = it + 3UL;
if( it == end || *it != -3 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Iterator/scalar addition failed\n";
throw std::runtime_error( oss.str() );
}
it = it - 3UL;
if( it == end || *it != 1 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Iterator/scalar subtraction failed\n";
throw std::runtime_error( oss.str() );
}
it = 4UL + it;
if( it != end ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Scalar/iterator addition failed\n";
throw std::runtime_error( oss.str() );
}
}
// Testing assignment via Iterator
{
test_ = "Assignment via Iterator";
int value = 6;
for( Iterator it=begin( vec ); it!=end( vec ); ++it ) {
*it = value++;
}
if( vec[0] != 6 || vec[1] != 7 || vec[2] != 8 || vec[3] != 9 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Assignment via iterator failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 6 7 8 9 )\n";
throw std::runtime_error( oss.str() );
}
}
// Testing addition assignment via Iterator
{
test_ = "Addition assignment via Iterator";
int value = 2;
for( Iterator it=begin( vec ); it!=end( vec ); ++it ) {
*it += value++;
}
if( vec[0] != 8 || vec[1] != 10 || vec[2] != 12 || vec[3] != 14 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Addition assignment via iterator failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 8 10 12 14 )\n";
throw std::runtime_error( oss.str() );
}
}
// Testing subtraction assignment via Iterator
{
test_ = "Subtraction assignment via Iterator";
int value = 2;
for( Iterator it=begin( vec ); it!=end( vec ); ++it ) {
*it -= value++;
}
if( vec[0] != 6 || vec[1] != 7 || vec[2] != 8 || vec[3] != 9 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Subtraction assignment via iterator failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 6 7 8 9 )\n";
throw std::runtime_error( oss.str() );
}
}
// Testing multiplication assignment via Iterator
{
test_ = "Multiplication assignment via Iterator";
int value = 1;
for( Iterator it=begin( vec ); it!=end( vec ); ++it ) {
*it *= value++;
}
if( vec[0] != 6 || vec[1] != 14 || vec[2] != 24 || vec[3] != 36 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Multiplication assignment via iterator failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 6 14 24 36 )\n";
throw std::runtime_error( oss.str() );
}
}
// Testing division assignment via Iterator
{
test_ = "Division assignment via Iterator";
for( Iterator it=begin( vec ); it!=end( vec ); ++it ) {
*it /= 2;
}
if( vec[0] != 3 || vec[1] != 7 || vec[2] != 12 || vec[3] != 18 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Division assignment via iterator failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 3 7 12 18 )\n";
throw std::runtime_error( oss.str() );
}
}
}
//*************************************************************************************************
//*************************************************************************************************
/*!\brief Test of the \c nonZeros() member function of the DynamicVector class template.
//
// \return void
// \exception std::runtime_error Error detected.
//
// This function performs a test of the \c nonZeros() member function of the DynamicVector class
// template. In case an error is detected, a \a std::runtime_error exception is thrown.
*/
void ClassTest::testNonZeros()
{
test_ = "DynamicVector::nonZeros()";
{
blaze::DynamicVector<int,blaze::rowVector> vec( 4UL, 0 );
checkSize ( vec, 4UL );
checkCapacity( vec, 4UL );
checkNonZeros( vec, 0UL );
if( vec[0] != 0 || vec[1] != 0 || vec[2] != 0 || vec[3] != 0 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Initialization failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 0 0 0 0 )\n";
throw std::runtime_error( oss.str() );
}
}
{
blaze::DynamicVector<int,blaze::rowVector> vec{ 1, 2, 0, 3 };
checkSize ( vec, 4UL );
checkCapacity( vec, 4UL );
checkNonZeros( vec, 3UL );
if( vec[0] != 1 || vec[1] != 2 || vec[2] != 0 || vec[3] != 3 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Initialization failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 1 2 0 3 )\n";
throw std::runtime_error( oss.str() );
}
}
}
//*************************************************************************************************
//*************************************************************************************************
/*!\brief Test of the \c reset() member function of the DynamicVector class template.
//
// \return void
// \exception std::runtime_error Error detected.
//
// This function performs a test of the \c reset() member function of the DynamicVector class
// template. In case an error is detected, a \a std::runtime_error exception is thrown.
*/
void ClassTest::testReset()
{
using blaze::reset;
test_ = "DynamicVector::reset()";
// Resetting a default constructed vector
{
blaze::DynamicVector<int,blaze::rowVector> vec;
reset( vec );
checkSize ( vec, 0UL );
checkNonZeros( vec, 0UL );
}
// Resetting an initialized vector
{
// Initialization check
blaze::DynamicVector<int,blaze::rowVector> vec{ 1, 2, 3, 4 };
vec[0] = 1;
vec[1] = 2;
vec[2] = 3;
vec[3] = 4;
checkSize ( vec, 4UL );
checkCapacity( vec, 4UL );
checkNonZeros( vec, 4UL );
if( vec[0] != 1 || vec[1] != 2 || vec[2] != 3 || vec[3] != 4 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Initialization failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 1 2 3 4 )\n";
throw std::runtime_error( oss.str() );
}
// Resetting a single element
reset( vec[2] );
checkSize ( vec, 4UL );
checkCapacity( vec, 4UL );
checkNonZeros( vec, 3UL );
if( vec[0] != 1 || vec[1] != 2 || vec[2] != 0 || vec[3] != 4 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Reset operation failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 1 2 0 4 )\n";
throw std::runtime_error( oss.str() );
}
// Resetting the vector
reset( vec );
checkSize ( vec, 4UL );
checkCapacity( vec, 4UL );
checkNonZeros( vec, 0UL );
if( vec[0] != 0 || vec[1] != 0 || vec[2] != 0 || vec[3] != 0 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Reset operation failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 0 0 0 0 )\n";
throw std::runtime_error( oss.str() );
}
}
}
//*************************************************************************************************
//*************************************************************************************************
/*!\brief Test of the \c clear() member function of the DynamicVector class template.
//
// \return void
// \exception std::runtime_error Error detected.
//
// This function performs a test of the \c clear() member function of the DynamicVector class
// template. In case an error is detected, a \a std::runtime_error exception is thrown.
*/
void ClassTest::testClear()
{
using blaze::clear;
test_ = "DynamicVector::clear()";
// Clearing a default constructed vector
{
blaze::DynamicVector<int,blaze::rowVector> vec;
clear( vec );
checkSize ( vec, 0UL );
checkNonZeros( vec, 0UL );
}
// Clearing an initialized vector
{
// Initialization check
blaze::DynamicVector<int,blaze::rowVector> vec{ 1, 2, 3, 4 };
checkSize ( vec, 4UL );
checkCapacity( vec, 4UL );
checkNonZeros( vec, 4UL );
if( vec[0] != 1 || vec[1] != 2 || vec[2] != 3 || vec[3] != 4 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Initialization failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 1 2 3 4 )\n";
throw std::runtime_error( oss.str() );
}
// Clearing a single element
clear( vec[2] );
checkSize ( vec, 4UL );
checkCapacity( vec, 4UL );
checkNonZeros( vec, 3UL );
if( vec[0] != 1 || vec[1] != 2 || vec[2] != 0 || vec[3] != 4 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Clear operation failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 1 2 0 4 )\n";
throw std::runtime_error( oss.str() );
}
// Clearing the vector
clear( vec );
checkSize ( vec, 0UL );
checkNonZeros( vec, 0UL );
}
}
//*************************************************************************************************
//*************************************************************************************************
/*!\brief Test of the \c resize() member function of the DynamicVector class template.
//
// \return void
// \exception std::runtime_error Error detected.
//
// This function performs a test of the \c resize() member function of the DynamicVector class
// template. In case an error is detected, a \a std::runtime_error exception is thrown.
*/
void ClassTest::testResize()
{
test_ = "DynamicVector::resize()";
// Initialization check
blaze::DynamicVector<int,blaze::rowVector> vec;
checkSize ( vec, 0UL );
checkNonZeros( vec, 0UL );
// Resizing to 0
vec.resize( 0UL );
checkSize ( vec, 0UL );
checkNonZeros( vec, 0UL );
// Resizing to 3
vec.resize( 3UL );
checkSize ( vec, 3UL );
checkCapacity( vec, 3UL );
// Resizing to 5 and preserving the elements
vec[0] = 1;
vec[1] = 2;
vec[2] = 3;
vec.resize( 5UL, true );
checkSize ( vec, 5UL );
checkCapacity( vec, 5UL );
if( vec[0] != 1 || vec[1] != 2 || vec[2] != 3 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Resizing the vector failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 1 2 3 x x )\n";
throw std::runtime_error( oss.str() );
}
// Resizing to 2 and preserving the elements
vec.resize( 2UL, true );
checkSize ( vec, 2UL );
checkCapacity( vec, 2UL );
checkNonZeros( vec, 2UL );
if( vec[0] != 1 || vec[1] != 2 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Resizing the vector failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 1 2 )\n";
throw std::runtime_error( oss.str() );
}
// Resizing to 1
vec.resize( 1UL );
checkSize ( vec, 1UL );
checkCapacity( vec, 1UL );
// Resizing to 0
vec.resize( 0 );
checkSize ( vec, 0UL );
checkNonZeros( vec, 0UL );
}
//*************************************************************************************************
//*************************************************************************************************
/*!\brief Test of the \c extend() member function of the DynamicVector class template.
//
// \return void
// \exception std::runtime_error Error detected.
//
// This function performs a test of the \c extend() member function of the DynamicVector class
// template. In case an error is detected, a \a std::runtime_error exception is thrown.
*/
void ClassTest::testExtend()
{
test_ = "DynamicVector::extend()";
// Initialization check
blaze::DynamicVector<int,blaze::rowVector> vec;
checkSize ( vec, 0UL );
checkNonZeros( vec, 0UL );
// Increasing the size of the vector
vec.extend( 3UL );
checkSize ( vec, 3UL );
checkCapacity( vec, 3UL );
// Further increasing the size of the vector and preserving the elements
vec[0] = 1;
vec[1] = 2;
vec[2] = 3;
vec.extend( 2UL, true );
checkSize ( vec, 5UL );
checkCapacity( vec, 5UL );
if( vec[0] != 1 || vec[1] != 2 || vec[2] != 3 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Extending the vector failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 1 2 3 x x )\n";
throw std::runtime_error( oss.str() );
}
// Further increasing the size of the vector
vec.extend( 10UL, false );
checkSize ( vec, 15UL );
checkCapacity( vec, 15UL );
}
//*************************************************************************************************
//*************************************************************************************************
/*!\brief Test of the \c reserve() member function of the DynamicVector class template.
//
// \return void
// \exception std::runtime_error Error detected.
//
// This function performs a test of the \c reserve() member function of the DynamicVector class
// template. In case an error is detected, a \a std::runtime_error exception is thrown.
*/
void ClassTest::testReserve()
{
test_ = "DynamicVector::reserve()";
// Initialization check
blaze::DynamicVector<int,blaze::rowVector> vec;
checkSize ( vec, 0UL );
checkNonZeros( vec, 0UL );
// Increasing the capacity of the vector
vec.reserve( 10UL );
checkSize ( vec, 0UL );
checkCapacity( vec, 10UL );
checkNonZeros( vec, 0UL );
// Further increasing the capacity of the vector
vec.reserve( 20UL );
checkSize ( vec, 0UL );
checkCapacity( vec, 20UL );
checkNonZeros( vec, 0UL );
}
//*************************************************************************************************
//*************************************************************************************************
/*!\brief Test of the \c shrinkToFit() member function of the DynamicVector class template.
//
// \return void
// \exception std::runtime_error Error detected.
//
// This function performs a test of the \c shrinkToFit() member function of the DynamicVector
// class template. In case an error is detected, a \a std::runtime_error exception is thrown.
*/
void ClassTest::testShrinkToFit()
{
test_ = "DynamicVector::shrinkToFit()";
// Shrinking a vector without excessive capacity
{
blaze::DynamicVector<int,blaze::rowVector> vec{ 1, 2, 3, 4, 5 };
vec.shrinkToFit();
checkSize ( vec, 5UL );
checkCapacity( vec, 5UL );
checkNonZeros( vec, 5UL );
if( vec.capacity() != vec.spacing() ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Shrinking the vector failed\n"
<< " Details:\n"
<< " Capacity : " << vec.capacity() << "\n"
<< " Expected capacity: " << vec.spacing() << "\n";
throw std::runtime_error( oss.str() );
}
if( vec[0] != 1 || vec[1] != 2 || vec[2] != 3 || vec[3] != 4 || vec[4] != 5 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Shrinking the vector failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 1 2 3 4 5 )\n";
throw std::runtime_error( oss.str() );
}
}
// Shrinking a vector with excessive capacity
{
blaze::DynamicVector<int,blaze::rowVector> vec{ 1, 2, 3, 4, 5 };
vec.reserve( 100UL );
vec.shrinkToFit();
checkSize ( vec, 5UL );
checkCapacity( vec, 5UL );
checkNonZeros( vec, 5UL );
if( vec.capacity() != vec.spacing() ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Shrinking the vector failed\n"
<< " Details:\n"
<< " Capacity : " << vec.capacity() << "\n"
<< " Expected capacity: " << vec.spacing() << "\n";
throw std::runtime_error( oss.str() );
}
if( vec[0] != 1 || vec[1] != 2 || vec[2] != 3 || vec[3] != 4 || vec[4] != 5 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Shrinking the vector failed\n"
<< " Details:\n"
<< " Result:\n" << vec << "\n"
<< " Expected result:\n( 1 2 3 4 5 )\n";
throw std::runtime_error( oss.str() );
}
}
}
//*************************************************************************************************
//*************************************************************************************************
/*!\brief Test of the \c swap() functionality of the DynamicVector class template.
//
// \return void
// \exception std::runtime_error Error detected.
//
// This function performs a test of the \c swap() function of the DynamicVector class template.
// In case an error is detected, a \a std::runtime_error exception is thrown.
*/
void ClassTest::testSwap()
{
test_ = "DynamicVector swap";
blaze::DynamicVector<int,blaze::rowVector> vec1{ 1, 2, 3 };
blaze::DynamicVector<int,blaze::rowVector> vec2{ 4, 3, 2, 1 };
swap( vec1, vec2 );
checkSize ( vec1, 4UL );
checkCapacity( vec1, 4UL );
checkNonZeros( vec1, 4UL );
if( vec1[0] != 4 || vec1[1] != 3 || vec1[2] != 2 || vec1[3] != 1 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Swapping the first vector failed\n"
<< " Details:\n"
<< " Result:\n" << vec1 << "\n"
<< " Expected result:\n( 4 3 2 1 )\n";
throw std::runtime_error( oss.str() );
}
checkSize ( vec2, 3UL );
checkCapacity( vec2, 3UL );
checkNonZeros( vec2, 3UL );
if( vec2[0] != 1 || vec2[1] != 2 || vec2[2] != 3 ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Swapping the second vector failed\n"
<< " Details:\n"
<< " Result:\n" << vec1 << "\n"
<< " Expected result:\n( 1 2 3 )\n";
throw std::runtime_error( oss.str() );
}
}
//*************************************************************************************************
//*************************************************************************************************
/*!\brief Test of the \c isDefault() function with the DynamicVector class template.
//
// \return void
// \exception std::runtime_error Error detected.
//
// This function performs a test of the \c isDefault() function with the DynamicVector class
// template. In case an error is detected, a \a std::runtime_error exception is thrown.
*/
void ClassTest::testIsDefault()
{
using blaze::isDefault;
test_ = "isDefault() function";
// isDefault with vector of size 0
{
blaze::DynamicVector<int,blaze::rowVector> vec;
if( isDefault( vec ) != true ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Invalid isDefault evaluation\n"
<< " Details:\n"
<< " Vector:\n" << vec << "\n";
throw std::runtime_error( oss.str() );
}
}
// isDefault with default vector
{
blaze::DynamicVector<int,blaze::rowVector> vec{ 0, 0, 0 };
if( isDefault( vec[1] ) != true ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Invalid isDefault evaluation\n"
<< " Details:\n"
<< " Vector element: " << vec[1] << "\n";
throw std::runtime_error( oss.str() );
}
if( isDefault( vec ) != false ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Invalid isDefault evaluation\n"
<< " Details:\n"
<< " Vector:\n" << vec << "\n";
throw std::runtime_error( oss.str() );
}
}
// isDefault with non-default vector
{
blaze::DynamicVector<int,blaze::rowVector> vec{ 0, 1, 0 };
if( isDefault( vec[1] ) != false ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Invalid isDefault evaluation\n"
<< " Details:\n"
<< " Vector element: " << vec[1] << "\n";
throw std::runtime_error( oss.str() );
}
if( isDefault( vec ) != false ) {
std::ostringstream oss;
oss << " Test: " << test_ << "\n"
<< " Error: Invalid isDefault evaluation\n"
<< " Details:\n"
<< " Vector:\n" << vec << "\n";
throw std::runtime_error( oss.str() );
}
}
}
//*************************************************************************************************
} // namespace dynamicvector
} // namespace mathtest
} // namespace blazetest
//=================================================================================================
//
// MAIN FUNCTION
//
//=================================================================================================
//*************************************************************************************************
int main()
{
std::cout << " Running DynamicVector class test..." << std::endl;
try
{
RUN_DYNAMICVECTOR_CLASS_TEST;
}
catch( std::exception& ex ) {
std::cerr << "\n\n ERROR DETECTED during DynamicVector class test:\n"
<< ex.what() << "\n";
return EXIT_FAILURE;
}
return EXIT_SUCCESS;
}
//*************************************************************************************************
| [
"klaus.iglberger@gmail.com"
] | klaus.iglberger@gmail.com |
e378ca687a436b8cfb1c4a0fdd20fc8f434ed3e3 | 06e340a7c2bc8045bb51137b7ebebd31c166ed1d | /Intense_Prog/Homework/Homework5/Animation/dialog.cpp | 50605c50ed7d76f1621f1139d31f57fcefb4c381 | [] | no_license | benjacobs0518/Undergrad_Code | eaa05981b61e9afcbeb9a40b8c38c8669fcb741b | 742fdec10c3c9d89a12cd0c20e4713b14ffba5b4 | refs/heads/main | 2023-02-12T20:34:16.290514 | 2021-01-06T22:47:41 | 2021-01-06T22:47:41 | 327,418,631 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,136 | cpp | #include "dialog.h"
#include "ui_dialog.h"
#include "head.h"
#include <QObject>
Dialog::Dialog(QWidget *parent)
: QMainWindow(parent)
, ui(new Ui::Dialog)
{
ui->setupUi(this);
scene = new QGraphicsScene(this);
ui->graphicsView->setScene(scene);
ui->graphicsView->setRenderHint(QPainter::Antialiasing);
scene->setSceneRect(-200,-200,300,300); //
QPen mypen = QPen(Qt::red);
QLineF TopLine(scene->sceneRect().topLeft(),scene->sceneRect().topRight());
QLineF LeftLine(scene->sceneRect().topLeft(),scene->sceneRect().bottomLeft());
QLineF RightLine(scene->sceneRect().topRight(),scene->sceneRect().bottomRight());
QLineF BottomLine(scene->sceneRect().bottomLeft(),scene->sceneRect().bottomRight());
scene->addLine(TopLine,mypen);
scene->addLine(LeftLine,mypen);
scene->addLine(RightLine,mypen);
scene->addLine(BottomLine,mypen);
Head *head = new Head();
scene->addItem(head);
head->setFocus();
timer = new QTimer(this);
connect(timer, SIGNAL(timeout()), scene, SLOT(advance()));
timer->start(200);
}
Dialog::~Dialog()
{
delete ui;
}
| [
"noreply@github.com"
] | noreply@github.com |
684884bbfb7450e8eb8d85955290c191769d978e | 378d5285e01ccf7d9fccfd549e1ed7bafdf48d54 | /C&C++/matrix.cpp | b240ee08a28a406ddbb0ec47b1a10dce007407cd | [] | no_license | nixis-institute/practice | 0f59e74d6518a80c35c7d3a5e4281cebf0e266cc | 8d7b3f454e5103a0a5bceee034a604fcc098dbd1 | refs/heads/master | 2023-01-11T20:18:47.259472 | 2022-12-24T13:27:53 | 2022-12-24T13:27:53 | 144,467,408 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 663 | cpp | #include "iostream"
using namespace std;
int main()
{
int matrix[3][3],i,j;
for(i=0;i<3;i++)
{
cout<<"Enter "<<i+1<<"th row elements";
for(j=0;j<3;j++)
{
cin>>matrix[i][j];
}
}
cout<<"before transpose\n";
for(i=0;i<3;i++)
{
//cout<<"Enter "<<i+1<<"th row elements";
for(j=0;j<3;j++)
{
cout<<matrix[i][j]<<"\t";
}
cout<<endl;
}
cout<<"After transpose\n";
for(i=0;i<3;i++)
{
for(j=0;j<3;j++)
{
cout<<matrix[j][i]<<"\t";
}
cout<<endl;
}
}
| [
"rkrjob55@gmail.com"
] | rkrjob55@gmail.com |
2c3f80e42d5115b1e818b7395035f6c21fa14465 | e0d87965fe67857f2041e67fe787288701b773d2 | /Tools/fileWriter.cpp | 16fe07acef78c2d659c22680fad5fb9f11c35f1d | [] | no_license | avargas10/ce4302_Project1 | ea11be9d585b28a128a3575f2704b047c335a741 | 1d5f29860117f99a7cb47d2212e9d3a688d2f85c | refs/heads/master | 2022-02-19T22:56:30.426529 | 2018-09-08T01:02:45 | 2018-09-08T01:02:45 | 144,527,054 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 4,054 | cpp | //
// Created by kakaroto on 05/09/18.
//
#include "fileWriter.h"
#define SIZE 16
fileWriter::fileWriter() {
}
fileWriter::fileWriter(int pId) {
_id = pId;
parser = Json_Code_Decode();
}
void fileWriter::writeCPU(instruction pIns) {
std::ofstream out;
string id = std::to_string(_id);
out.open(path+"node"+id+"/cpu.txt", std::ios::app);
std::string str = generateInstruction(pIns);
out << str;
out.close(); // close the file
}
void fileWriter::writeCache(message msg) {
std::ofstream out;
string id = std::to_string(_id);
out.open(path+"node"+id+"/cacheActions.txt", std::ios::app);
std::string str = generateMessage(msg);
out << str;
out.close(); // close the file
}
void fileWriter::writeNofication(message msg) {
std::ofstream out;
string id = std::to_string(_id);
out.open(path+"node"+id+"/notify.txt", std::ios::app);
std::string str = generateNotification(msg)+"\n";
out << str;
out.close(); // close the file
}
void fileWriter::updateCache(msi* cache) {
std::ofstream out;
string id = std::to_string(_id);
out.open(path+"node"+id+"/cache.txt", std::ios::app);
std::string str = generateCache(cache);
out << str;
out.close(); // close the file
}
void fileWriter::updateMainMem(int* mem) {
std::ofstream out;
string id = std::to_string(_id);
out.open(path+"node5/memory.txt", std::ios::app);
std::string str = generateMem(mem);
out << str;
out.close(); // close the file
}
string fileWriter::generateInstruction(instruction pIns) {
Json::Value root;
root = parser.includeString("cpu",root,std::to_string(_id));
root = parser.includeString("action",root,std::to_string(pIns._action));
root = parser.includeString("position",root,std::to_string(pIns._pos));
root = parser.includeString("data",root,std::to_string(pIns._data));
Json::FastWriter fastWriter;
std::string output = fastWriter.write(root);
return output;
}
string fileWriter::generateMessage(message msg) {
Json::Value root;
root = parser.includeString("node",root,std::to_string(_id));
root = parser.includeString("state",root,std::to_string(msg.state));
root = parser.includeString("action",root,std::to_string(msg.action));
root = parser.includeString("position",root,std::to_string(msg.pos));
root = parser.includeString("data",root,std::to_string(msg.data));
Json::FastWriter fastWriter;
std::string output = fastWriter.write(root);
return output;
}
string fileWriter::generateNotification(message msg) {
Json::Value root;
root = parser.includeString("node",root,std::to_string(_id));
root = parser.includeString("state",root,std::to_string(msg.state));
root = parser.includeString("action",root,std::to_string(msg.action));
root = parser.includeString("position",root,std::to_string(msg.pos));
root = parser.includeString("data",root,std::to_string(msg.data));
root = parser.includeString("Message",root,msg.notifaction);
Json::FastWriter fastWriter;
std::string output = fastWriter.write(root);
return output;
}
Json::Value fileWriter::getJson(msi pMessage) {
Json::Value root;
root = parser.includeInt(pMessage.state,root,"State");
root = parser.includeInt(pMessage.pos,root,"Position");
root = parser.includeInt(pMessage._data,root,"Data");
return root;
}
string fileWriter::generateCache(msi* cache) {
Json::Value mem(Json::arrayValue);
for (int i = 0; i <SIZE; ++i) {
mem[i] = getJson(cache[i]);
}
Json::FastWriter fastWriter;
std::string output = fastWriter.write(mem);
return output;
}
string fileWriter::generateMem(int *mainMem) {
Json::Value mem(Json::arrayValue);
for (int i = 0; i <SIZE; ++i) {
Json::Value root;
root = parser.includeInt(mainMem[i],root,"Data");
root = parser.includeInt(i,root,"Position");
mem[i]= root;
}
Json::FastWriter fastWriter;
std::string output = fastWriter.write(mem);
return output;
}
| [
"afelipe.vargas.r@gmail.com"
] | afelipe.vargas.r@gmail.com |
d259b5ae01161d06430c159f04d679d66d3e58bb | 6758c19e70284d242aec0e3ba28ab2f11a8e03ce | /utils.cpp | 23bbbf844fa6b3b627680c261eef48e65db93a39 | [] | no_license | 0virax0/proj_ranz | c373e22409a1e2fbfc548338dcd290d02dc5d107 | 0a0e3a4fd266d6d18dba13923c7c26de089f6717 | refs/heads/master | 2020-04-10T10:19:10.952345 | 2019-06-15T10:58:38 | 2019-06-15T10:58:38 | 160,962,483 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,241 | cpp | #include "utils.h"
vector<float> utils::add(const vector<float>& v1, const vector<float>& v2){
return {v1[0]+v2[0], v1[1]+v2[1]};
}
void utils::add_side(vector<float>& v1, const vector<float>& v2){
v1[0] += v2[0];
v1[1] += v2[1];
}
vector<float> utils::sub(const vector<float>& v1, const vector<float>& v2){
return {v1[0]-v2[0], v1[1]-v2[1]};
}
void utils::sub_side(vector<float>& v1, const vector<float>& v2){
v1[0] -= v2[0];
v1[1] -= v2[1];
}
vector<float> utils::mul(const vector<float>& v1, float scalar){
return {v1[0]*scalar, v1[1]*scalar};
}
void utils::mul_side(vector<float>& v1, float scalar){
v1[0] *= scalar;
v1[1] *= scalar;
}
float utils::sqDist(const vector<float>& v1, const vector<float>& v2){
return (v1[0]-v2[0])*(v1[0]-v2[0]) + (v1[1]-v2[1])*(v1[1]-v2[1]);
}
float utils::sqLength(const vector<float>& v1){
return v1[0]*v1[0] + v1[1]*v1[1];
}
void utils::normalize(vector<float>& v1){
float length = sqrt(sqLength(v1));
v1[0] /= length;
v1[1] /= length;
}
float utils::dot(const vector<float>& v1, const vector<float>& v2){
return v1[0]*v2[0] + v1[1]*v2[1];
}
void utils::rotate90(vector<float>& v1){
float tmp = v1[1];
v1[1] = -v1[0];
v1[0] = tmp;
}
| [
"filippovis@outlook.it"
] | filippovis@outlook.it |
65408077029270357134569df7cf7f25e6cc514e | 7b0aa6cf70e1a1f7770f08f4628c0e6326dedf6d | /computer_vision_framework/ComputerVision/include/core/data/proto/TurnoutCommand.pb.h | 31b1d2999e9531191c2f27983eb1987702177496 | [] | no_license | FuzesiMate/ComputerVision | a6344436257e4fbc74aaf0d88341be6ccda05feb | ce217d85d73b0cf59b51b52afa859bce41ac8831 | refs/heads/master | 2020-06-13T20:15:50.144999 | 2017-09-25T17:24:53 | 2017-09-25T17:24:53 | 75,558,166 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | true | 6,620 | h | // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: TurnoutCommand.proto
#ifndef PROTOBUF_TurnoutCommand_2eproto__INCLUDED
#define PROTOBUF_TurnoutCommand_2eproto__INCLUDED
#include <string>
#include <google/protobuf/stubs/common.h>
#if GOOGLE_PROTOBUF_VERSION < 3003000
#error This file was generated by a newer version of protoc which is
#error incompatible with your Protocol Buffer headers. Please update
#error your headers.
#endif
#if 3003000 < GOOGLE_PROTOBUF_MIN_PROTOC_VERSION
#error This file was generated by an older version of protoc which is
#error incompatible with your Protocol Buffer headers. Please
#error regenerate this file with a newer version of protoc.
#endif
#include <google/protobuf/io/coded_stream.h>
#include <google/protobuf/arena.h>
#include <google/protobuf/arenastring.h>
#include <google/protobuf/generated_message_table_driven.h>
#include <google/protobuf/generated_message_util.h>
#include <google/protobuf/metadata.h>
#include <google/protobuf/message.h>
#include <google/protobuf/repeated_field.h> // IWYU pragma: export
#include <google/protobuf/extension_set.h> // IWYU pragma: export
#include <google/protobuf/unknown_field_set.h>
#include "Enums.pb.h"
// @@protoc_insertion_point(includes)
namespace modes3 {
namespace protobuf {
class TurnoutCommand;
class TurnoutCommandDefaultTypeInternal;
extern TurnoutCommandDefaultTypeInternal _TurnoutCommand_default_instance_;
} // namespace protobuf
} // namespace modes3
namespace modes3 {
namespace protobuf {
namespace protobuf_TurnoutCommand_2eproto {
// Internal implementation detail -- do not call these.
struct TableStruct {
static const ::google::protobuf::internal::ParseTableField entries[];
static const ::google::protobuf::internal::AuxillaryParseTableField aux[];
static const ::google::protobuf::internal::ParseTable schema[];
static const ::google::protobuf::uint32 offsets[];
static void InitDefaultsImpl();
static void Shutdown();
};
void AddDescriptors();
void InitDefaults();
} // namespace protobuf_TurnoutCommand_2eproto
// ===================================================================
class TurnoutCommand : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:modes3.protobuf.TurnoutCommand) */ {
public:
TurnoutCommand();
virtual ~TurnoutCommand();
TurnoutCommand(const TurnoutCommand& from);
inline TurnoutCommand& operator=(const TurnoutCommand& from) {
CopyFrom(from);
return *this;
}
static const ::google::protobuf::Descriptor* descriptor();
static const TurnoutCommand& default_instance();
static inline const TurnoutCommand* internal_default_instance() {
return reinterpret_cast<const TurnoutCommand*>(
&_TurnoutCommand_default_instance_);
}
static PROTOBUF_CONSTEXPR int const kIndexInFileMessages =
0;
void Swap(TurnoutCommand* other);
// implements Message ----------------------------------------------
inline TurnoutCommand* New() const PROTOBUF_FINAL { return New(NULL); }
TurnoutCommand* New(::google::protobuf::Arena* arena) const PROTOBUF_FINAL;
void CopyFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
void MergeFrom(const ::google::protobuf::Message& from) PROTOBUF_FINAL;
void CopyFrom(const TurnoutCommand& from);
void MergeFrom(const TurnoutCommand& from);
void Clear() PROTOBUF_FINAL;
bool IsInitialized() const PROTOBUF_FINAL;
size_t ByteSizeLong() const PROTOBUF_FINAL;
bool MergePartialFromCodedStream(
::google::protobuf::io::CodedInputStream* input) PROTOBUF_FINAL;
void SerializeWithCachedSizes(
::google::protobuf::io::CodedOutputStream* output) const PROTOBUF_FINAL;
::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray(
bool deterministic, ::google::protobuf::uint8* target) const PROTOBUF_FINAL;
int GetCachedSize() const PROTOBUF_FINAL { return _cached_size_; }
private:
void SharedCtor();
void SharedDtor();
void SetCachedSize(int size) const PROTOBUF_FINAL;
void InternalSwap(TurnoutCommand* other);
private:
inline ::google::protobuf::Arena* GetArenaNoVirtual() const {
return NULL;
}
inline void* MaybeArenaPtr() const {
return NULL;
}
public:
::google::protobuf::Metadata GetMetadata() const PROTOBUF_FINAL;
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
// uint32 turnoutID = 1;
void clear_turnoutid();
static const int kTurnoutIDFieldNumber = 1;
::google::protobuf::uint32 turnoutid() const;
void set_turnoutid(::google::protobuf::uint32 value);
// .modes3.protobuf.TurnoutStateValue state = 2;
void clear_state();
static const int kStateFieldNumber = 2;
::modes3::protobuf::TurnoutStateValue state() const;
void set_state(::modes3::protobuf::TurnoutStateValue value);
// @@protoc_insertion_point(class_scope:modes3.protobuf.TurnoutCommand)
private:
::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_;
::google::protobuf::uint32 turnoutid_;
int state_;
mutable int _cached_size_;
friend struct protobuf_TurnoutCommand_2eproto::TableStruct;
};
// ===================================================================
// ===================================================================
#if !PROTOBUF_INLINE_NOT_IN_HEADERS
// TurnoutCommand
// uint32 turnoutID = 1;
inline void TurnoutCommand::clear_turnoutid() {
turnoutid_ = 0u;
}
inline ::google::protobuf::uint32 TurnoutCommand::turnoutid() const {
// @@protoc_insertion_point(field_get:modes3.protobuf.TurnoutCommand.turnoutID)
return turnoutid_;
}
inline void TurnoutCommand::set_turnoutid(::google::protobuf::uint32 value) {
turnoutid_ = value;
// @@protoc_insertion_point(field_set:modes3.protobuf.TurnoutCommand.turnoutID)
}
// .modes3.protobuf.TurnoutStateValue state = 2;
inline void TurnoutCommand::clear_state() {
state_ = 0;
}
inline ::modes3::protobuf::TurnoutStateValue TurnoutCommand::state() const {
// @@protoc_insertion_point(field_get:modes3.protobuf.TurnoutCommand.state)
return static_cast< ::modes3::protobuf::TurnoutStateValue >(state_);
}
inline void TurnoutCommand::set_state(::modes3::protobuf::TurnoutStateValue value) {
state_ = value;
// @@protoc_insertion_point(field_set:modes3.protobuf.TurnoutCommand.state)
}
#endif // !PROTOBUF_INLINE_NOT_IN_HEADERS
// @@protoc_insertion_point(namespace_scope)
} // namespace protobuf
} // namespace modes3
// @@protoc_insertion_point(global_scope)
#endif // PROTOBUF_TurnoutCommand_2eproto__INCLUDED
| [
"mate.fuzesi@incquerylabs.com"
] | mate.fuzesi@incquerylabs.com |
bfbb8fa196ceefc3269afcfa2c7adfc0377c5e52 | 02563b419932159e85fa6043deedd1eb4d86e0e1 | /spider/spider27_old/src/contain_metro_lines.h | 735adb0edec88994498b57478c046f998df56737 | [] | no_license | alex-korobko/scad-modus-spider | a576a57e2280d49e7bf542eef9b61e03ef3270b8 | 9d7f8890dedfe260b52c14e3e91b9333d32ddcb2 | refs/heads/master | 2021-01-10T20:08:22.726969 | 2012-02-11T00:41:41 | 2012-02-11T00:41:41 | 32,656,240 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,329 | h | #ifndef __CONT_METRO_LINES_H__
#define __CONT_METRO_LINES_H__
/*****************************************************************************
Container class for metro lines -
wrapper of STL container map
*****************************************************************************/
class metro_lines_container {
private :
struct ltint
{
bool operator() (const int i1, const int i2) const
{
return (i1<i2) ;
}
};
typedef map <int, metro_line, ltint> metro_lines_map;
metro_lines_map container_metro_lines;
public :
typedef metro_lines_map::iterator iterator_metro_lines;
typedef metro_lines_map::value_type pair_metro_lines;
typedef metro_lines_map::size_type size_type_metro_lines;
private :
iterator_metro_lines current_line;
PtWidget_t *morning_start_state_indicator;
public :
metro_lines_container():
morning_start_state_indicator(NULL)
{
current_line=container_metro_lines.end();
};
/*
get_ and set_ metods for private data members
*/
iterator_metro_lines get_current_line() {return(current_line);};
void set_current_line (iterator_metro_lines new_current_line) {current_line=new_current_line;};
PtWidget_t* get_morning_start_state_indicator() {return morning_start_state_indicator;}
void set_morning_start_state_indicator( PtWidget_t *new_morning_start_state_indicator);
/*
wrappers of current STL lines`s container metods
*/
iterator_metro_lines begin() {return container_metro_lines.begin();};
iterator_metro_lines end() {return container_metro_lines.end();};
iterator_metro_lines find(const int key) { return container_metro_lines.find(key); };
iterator_metro_lines upper_bound(const int key) { return container_metro_lines.upper_bound(key); };
void erase (iterator_metro_lines iter) { container_metro_lines.erase(iter); };
void erase (iterator_metro_lines iter_beg,
iterator_metro_lines iter_end ) { container_metro_lines.erase(iter_beg, iter_end); };
iterator_metro_lines insert (iterator_metro_lines iter, const pair_metro_lines& obj)
{
return (container_metro_lines.insert(iter, obj));
}
bool empty() const { return container_metro_lines.empty();}
size_type_metro_lines size() const {return container_metro_lines.size();};
void load_line_parameters()
throw (spider_exception);
void load(string file_name)
throw (spider_exception);
};
#endif | [
"kor@34dc3d99-ab81-5ee6-7b87-ae7f7f2f6c0a"
] | kor@34dc3d99-ab81-5ee6-7b87-ae7f7f2f6c0a |
f25bd0f045c148f2a91b950dcd7e0ffb40e6ab12 | b6ba56493adca141d523b008cc0f86a7de8b5eb7 | /bindresult4.cpp | 03b737b93b536534f8d85272275de4e98c7dfc5a | [
"MIT"
] | permissive | SirNate0/PYrho3D | 0fad2f749a589056cfc218d924b38199f34f01ac | b0daa3badccd12adfcb9e7cf50d554c805cc6279 | refs/heads/master | 2021-01-07T18:22:58.104088 | 2020-03-02T00:22:45 | 2020-03-02T00:22:45 | 241,781,480 | 6 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 202,387 | cpp |
/*********************************************************
* AUTO GENERATED BINDING CODE - bind.py *
* Please Run bind.py on the source again with different *
* overrides rather than modfying this file directly. *
* Called as: *
* {callstring:50} *
*********************************************************/
#include <pybind11/pybind11.h>
#include <pybind11/numpy.h>
#include <pybind11/operators.h>
#include <memory>
namespace py = pybind11;
// Urho local
#include "String_binding.h"
#include "PtrBinding.h"
#include "PyTrampolines.h"
#include "ContainerBinding.h"
// From the bind call
#include <Urho3D/Urho3DAll.h>
// Patch Urho things (esp. function default values)
typedef Urho3D::String::Iterator Iterator;
typedef Urho3D::Renderer::ShadowMapFilter ShadowMapFilter;
const auto& RIGHT_FORWARD_UP = Urho3D::RaycastVehicle::RIGHT_FORWARD_UP;
//================================================
//Operator typedefs
//================================================
// These are needed to prevent the compiler disliking the spaces, so we make it a single word
typedef unsigned long long unsignedlonglong;
typedef unsigned int unsignedint;
typedef unsigned short unsignedshort;
typedef unsigned long unsignedlong;
typedef long long longlong;
//================================================
// Implement Classes
//================================================
void Implement_Urho3D_PropertySet2D(py::class_<Urho3D::PropertySet2D, Urho3D::SharedPtr<Urho3D::PropertySet2D>, Urho3D::RefCounted>& pyclass_Var_Urho3D_PropertySet2D)
{
// Class PropertySet2D Implementation
pyclass_Var_Urho3D_PropertySet2D
.def(py::init<>(), "todo: constructor docstring")
//.def("~PropertySet2D", (void (Urho3D::PropertySet2D::*)()) &Urho3D::PropertySet2D::~PropertySet2D, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("Load", (void (Urho3D::PropertySet2D::*)(const Urho3D::XMLElement &)) &Urho3D::PropertySet2D::Load, "todo: docstring", py::arg("element"))
.def("HasProperty", (bool (Urho3D::PropertySet2D::*)(const Urho3D::String &) const) &Urho3D::PropertySet2D::HasProperty, "todo: docstring", py::arg("name"))
.def("GetProperty", (const Urho3D::String & (Urho3D::PropertySet2D::*)(const Urho3D::String &) const) &Urho3D::PropertySet2D::GetProperty, "todo: docstring", py::arg("name"))
// Class Variables:
;
}
void Implement_Urho3D_VectorBase(py::class_<Urho3D::VectorBase, Urho3D::ExternalPtr<Urho3D::VectorBase>>& pyclass_Var_Urho3D_VectorBase)
{
// Class VectorBase Implementation
pyclass_Var_Urho3D_VectorBase
.def(py::init<>(), "todo: constructor docstring")
.def("Swap", (void (Urho3D::VectorBase::*)(Urho3D::VectorBase &)) &Urho3D::VectorBase::Swap, "todo: docstring", py::arg("rhs"))
// Class Variables:
;
}
void Implement_Urho3D_LinkedListNode(py::class_<Urho3D::LinkedListNode, Urho3D::ExternalPtr<Urho3D::LinkedListNode>>& pyclass_Var_Urho3D_LinkedListNode)
{
// Class LinkedListNode Implementation
pyclass_Var_Urho3D_LinkedListNode
.def(py::init<>(), "todo: constructor docstring")
// Class Variables:
;
}
void Implement_Urho3D_Matrix3(py::class_<Urho3D::Matrix3, Urho3D::ExternalPtr<Urho3D::Matrix3>>& pyclass_Var_Urho3D_Matrix3)
{
// Class Matrix3 Implementation
pyclass_Var_Urho3D_Matrix3
.def(py::init<>(), "todo: constructor docstring")
.def(py::init<const Urho3D::Matrix3 &>(), "todo: constructor docstring")
.def(py::init<float, float, float, float, float, float, float, float, float>(), "todo: constructor docstring")
.def(py::init<const float *>(), "todo: constructor docstring")
// .def(py::self = Urho3D::Matrix3(), "todo: docstring").def("__assign__", (Urho3D::Matrix3 & (Urho3D::Matrix3::*)(const Urho3D::Matrix3 &)) &Urho3D::Matrix3::operator=, py::operator, "todo: operator docstring. Switch to py: :self ops.")
//['Urho3D::Matrix3']; op =, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self == Urho3D::Matrix3(), "todo: docstring")
//['Urho3D::Matrix3']; op ==, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self != Urho3D::Matrix3(), "todo: docstring")
//['Urho3D::Matrix3']; op !=, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self * Urho3D::Vector3(), "todo: docstring")
//['Urho3D::Vector3']; op *, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self + Urho3D::Matrix3(), "todo: docstring")
//['Urho3D::Matrix3']; op +, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self - Urho3D::Matrix3(), "todo: docstring")
//['Urho3D::Matrix3']; op -, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self * float(), "todo: docstring")
//['float']; op *, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self * Urho3D::Matrix3(), "todo: docstring")
//['Urho3D::Matrix3']; op *, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("SetScale", (void (Urho3D::Matrix3::*)(const Urho3D::Vector3 &)) &Urho3D::Matrix3::SetScale, "todo: docstring", py::arg("scale"))
.def("SetScale", (void (Urho3D::Matrix3::*)(float)) &Urho3D::Matrix3::SetScale, "todo: docstring", py::arg("scale"))
.def("Scale", (Urho3D::Vector3 (Urho3D::Matrix3::*)() const) &Urho3D::Matrix3::Scale, "todo: docstring")
.def("SignedScale", (Urho3D::Vector3 (Urho3D::Matrix3::*)(const Urho3D::Matrix3 &) const) &Urho3D::Matrix3::SignedScale, "todo: docstring", py::arg("rotation"))
.def("Transpose", (Urho3D::Matrix3 (Urho3D::Matrix3::*)() const) &Urho3D::Matrix3::Transpose, "todo: docstring")
.def("Scaled", (Urho3D::Matrix3 (Urho3D::Matrix3::*)(const Urho3D::Vector3 &) const) &Urho3D::Matrix3::Scaled, "todo: docstring", py::arg("scale"))
.def("Equals", (bool (Urho3D::Matrix3::*)(const Urho3D::Matrix3 &) const) &Urho3D::Matrix3::Equals, "todo: docstring", py::arg("rhs"))
.def("Inverse", (Urho3D::Matrix3 (Urho3D::Matrix3::*)() const) &Urho3D::Matrix3::Inverse, "todo: docstring")
.def("Data", (const float * (Urho3D::Matrix3::*)() const) &Urho3D::Matrix3::Data, "todo: docstring")
.def("Element", (float (Urho3D::Matrix3::*)(unsigned int, unsigned int) const) &Urho3D::Matrix3::Element, "todo: docstring", py::arg("i"), py::arg("j"))
.def("Row", (Urho3D::Vector3 (Urho3D::Matrix3::*)(unsigned int) const) &Urho3D::Matrix3::Row, "todo: docstring", py::arg("i"))
.def("Column", (Urho3D::Vector3 (Urho3D::Matrix3::*)(unsigned int) const) &Urho3D::Matrix3::Column, "todo: docstring", py::arg("j"))
.def("ToString", (Urho3D::String (Urho3D::Matrix3::*)() const) &Urho3D::Matrix3::ToString, "todo: docstring")
// External Operators:
.def(float() * py::self, "todo: docstring")
// Class Variables:
.def_readwrite("m00",&Urho3D::Matrix3::m00_, "todo: var docstring")//float
.def_readwrite("m01",&Urho3D::Matrix3::m01_, "todo: var docstring")//float
.def_readwrite("m02",&Urho3D::Matrix3::m02_, "todo: var docstring")//float
.def_readwrite("m10",&Urho3D::Matrix3::m10_, "todo: var docstring")//float
.def_readwrite("m11",&Urho3D::Matrix3::m11_, "todo: var docstring")//float
.def_readwrite("m12",&Urho3D::Matrix3::m12_, "todo: var docstring")//float
.def_readwrite("m20",&Urho3D::Matrix3::m20_, "todo: var docstring")//float
.def_readwrite("m21",&Urho3D::Matrix3::m21_, "todo: var docstring")//float
.def_readwrite("m22",&Urho3D::Matrix3::m22_, "todo: var docstring")//float
.def_readonly_static("ZERO",&Urho3D::Matrix3::ZERO, "todo: var docstring")//const Urho3D::Matrix3
.def_readonly_static("IDENTITY",&Urho3D::Matrix3::IDENTITY, "todo: var docstring")//const Urho3D::Matrix3
;
}
void Implement_Urho3D_EventHandler(py::class_<Urho3D::EventHandler, Urho3D::ExternalPtr<Urho3D::EventHandler>, Urho3D::LinkedListNode>& pyclass_Var_Urho3D_EventHandler)
{
// Class EventHandler Implementation
pyclass_Var_Urho3D_EventHandler
//.def(py::init<Urho3D::Object *, void *>(), "todo: constructor docstring")
// Abstract class EventHandler -> no init
//.def("~EventHandler", (void (Urho3D::EventHandler::*)()) &Urho3D::EventHandler::~EventHandler, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("SetSenderAndEventType", (void (Urho3D::EventHandler::*)(Urho3D::Object *, Urho3D::StringHash)) &Urho3D::EventHandler::SetSenderAndEventType, "todo: docstring", py::arg("sender"), py::arg("eventType"))
.def("Invoke", (void (Urho3D::EventHandler::*)(Urho3D::HashMap<Urho3D::StringHash, Urho3D::Variant> &)) &Urho3D::EventHandler::Invoke, "todo: docstring", py::arg("eventData"))
.def("Clone", (Urho3D::EventHandler * (Urho3D::EventHandler::*)() const) &Urho3D::EventHandler::Clone, "todo: docstring")
.def("GetReceiver", (Urho3D::Object * (Urho3D::EventHandler::*)() const) &Urho3D::EventHandler::GetReceiver, "todo: docstring")
.def("GetSender", (Urho3D::Object * (Urho3D::EventHandler::*)() const) &Urho3D::EventHandler::GetSender, "todo: docstring")
.def("GetEventType", (const Urho3D::StringHash & (Urho3D::EventHandler::*)() const) &Urho3D::EventHandler::GetEventType, "todo: docstring")
.def("GetUserData", (void * (Urho3D::EventHandler::*)() const) &Urho3D::EventHandler::GetUserData, "todo: docstring")
// Class Variables:
;
}
void Implement_Urho3D_Serializable(py::class_<Urho3D::Serializable, Urho3D::SharedPtr<Urho3D::Serializable>, Urho3D::Object>& pyclass_Var_Urho3D_Serializable)
{
// Class Serializable Implementation
pyclass_Var_Urho3D_Serializable
.def("GetType", (Urho3D::StringHash (Urho3D::Serializable::*)() const) &Urho3D::Serializable::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::Serializable::*)() const) &Urho3D::Serializable::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::Serializable::*)() const) &Urho3D::Serializable::GetTypeInfo, "todo: docstring")
.def(py::init<Urho3D::Context *>(), "todo: constructor docstring")
//.def("~Serializable", (void (Urho3D::Serializable::*)()) &Urho3D::Serializable::~Serializable, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
//.def("OnSetAttribute", (void (Urho3D::Serializable::*)(const Urho3D::AttributeInfo &, const Urho3D::Variant &)) &Urho3D::Serializable::OnSetAttribute, "todo: docstring", py::arg("attr"), py::arg("src"))
//['Urho3D::AttributeInfo', 'Urho3D::Variant']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
//.def("OnGetAttribute", (void (Urho3D::Serializable::*)(const Urho3D::AttributeInfo &, Urho3D::Variant &) const) &Urho3D::Serializable::OnGetAttribute, "todo: docstring", py::arg("attr"), py::arg("dest"))
//['Urho3D::AttributeInfo', 'Urho3D::Variant']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
//.def("GetAttributes", (const Vector<Urho3D::AttributeInfo> * (Urho3D::Serializable::*)() const) &Urho3D::Serializable::GetAttributes, "todo: docstring")
//[]; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 1
//.def("GetNetworkAttributes", (const Vector<Urho3D::AttributeInfo> * (Urho3D::Serializable::*)() const) &Urho3D::Serializable::GetNetworkAttributes, "todo: docstring")
//[]; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 1
.def("Load", (bool (Urho3D::Serializable::*)(Urho3D::Deserializer &)) &Urho3D::Serializable::Load, "todo: docstring", py::arg("source"))
.def("Save", (bool (Urho3D::Serializable::*)(Urho3D::Serializer &) const) &Urho3D::Serializable::Save, "todo: docstring", py::arg("dest"))
.def("LoadXML", (bool (Urho3D::Serializable::*)(const Urho3D::XMLElement &)) &Urho3D::Serializable::LoadXML, "todo: docstring", py::arg("source"))
.def("SaveXML", (bool (Urho3D::Serializable::*)(Urho3D::XMLElement &) const) &Urho3D::Serializable::SaveXML, "todo: docstring", py::arg("dest"))
.def("LoadJSON", (bool (Urho3D::Serializable::*)(const Urho3D::JSONValue &)) &Urho3D::Serializable::LoadJSON, "todo: docstring", py::arg("source"))
.def("SaveJSON", (bool (Urho3D::Serializable::*)(Urho3D::JSONValue &) const) &Urho3D::Serializable::SaveJSON, "todo: docstring", py::arg("dest"))
.def("ApplyAttributes", (void (Urho3D::Serializable::*)()) &Urho3D::Serializable::ApplyAttributes, "todo: docstring")
.def("SaveDefaultAttributes", (bool (Urho3D::Serializable::*)() const) &Urho3D::Serializable::SaveDefaultAttributes, "todo: docstring")
.def("MarkNetworkUpdate", (void (Urho3D::Serializable::*)()) &Urho3D::Serializable::MarkNetworkUpdate, "todo: docstring")
.def("SetBasePath", (void (Urho3D::Serializable::*)(const Urho3D::String &)) &Urho3D::Serializable::SetBasePath, "todo: docstring", py::arg("basePath"))
.def("GetBasePath", (const Urho3D::String & (Urho3D::Serializable::*)() const) &Urho3D::Serializable::GetBasePath, "todo: docstring")
.def("SetAttribute", (bool (Urho3D::Serializable::*)(unsigned int, const Urho3D::Variant &)) &Urho3D::Serializable::SetAttribute, "todo: docstring", py::arg("index"), py::arg("value"))
.def("SetAttribute", (bool (Urho3D::Serializable::*)(const Urho3D::String &, const Urho3D::Variant &)) &Urho3D::Serializable::SetAttribute, "todo: docstring", py::arg("name"), py::arg("value"))
.def("SetInstanceDefault", (void (Urho3D::Serializable::*)(bool)) &Urho3D::Serializable::SetInstanceDefault, "todo: docstring", py::arg("enable"))
.def("ResetToDefault", (void (Urho3D::Serializable::*)()) &Urho3D::Serializable::ResetToDefault, "todo: docstring")
.def("RemoveInstanceDefault", (void (Urho3D::Serializable::*)()) &Urho3D::Serializable::RemoveInstanceDefault, "todo: docstring")
.def("SetTemporary", (void (Urho3D::Serializable::*)(bool)) &Urho3D::Serializable::SetTemporary, "todo: docstring", py::arg("enable"))
.def("SetInterceptNetworkUpdate", (void (Urho3D::Serializable::*)(const Urho3D::String &, bool)) &Urho3D::Serializable::SetInterceptNetworkUpdate, "todo: docstring", py::arg("attributeName"), py::arg("enable"))
.def("AllocateNetworkState", (void (Urho3D::Serializable::*)()) &Urho3D::Serializable::AllocateNetworkState, "todo: docstring")
.def("WriteInitialDeltaUpdate", (void (Urho3D::Serializable::*)(Urho3D::Serializer &, unsigned char)) &Urho3D::Serializable::WriteInitialDeltaUpdate, "todo: docstring", py::arg("dest"), py::arg("timeStamp"))
.def("WriteDeltaUpdate", (void (Urho3D::Serializable::*)(Urho3D::Serializer &, const Urho3D::DirtyBits &, unsigned char)) &Urho3D::Serializable::WriteDeltaUpdate, "todo: docstring", py::arg("dest"), py::arg("attributeBits"), py::arg("timeStamp"))
.def("WriteLatestDataUpdate", (void (Urho3D::Serializable::*)(Urho3D::Serializer &, unsigned char)) &Urho3D::Serializable::WriteLatestDataUpdate, "todo: docstring", py::arg("dest"), py::arg("timeStamp"))
.def("ReadDeltaUpdate", (bool (Urho3D::Serializable::*)(Urho3D::Deserializer &)) &Urho3D::Serializable::ReadDeltaUpdate, "todo: docstring", py::arg("source"))
.def("ReadLatestDataUpdate", (bool (Urho3D::Serializable::*)(Urho3D::Deserializer &)) &Urho3D::Serializable::ReadLatestDataUpdate, "todo: docstring", py::arg("source"))
.def("GetAttribute", (Urho3D::Variant (Urho3D::Serializable::*)(unsigned int) const) &Urho3D::Serializable::GetAttribute, "todo: docstring", py::arg("index"))
.def("GetAttribute", (Urho3D::Variant (Urho3D::Serializable::*)(const Urho3D::String &) const) &Urho3D::Serializable::GetAttribute, "todo: docstring", py::arg("name"))
.def("GetAttributeDefault", (Urho3D::Variant (Urho3D::Serializable::*)(unsigned int) const) &Urho3D::Serializable::GetAttributeDefault, "todo: docstring", py::arg("index"))
.def("GetAttributeDefault", (Urho3D::Variant (Urho3D::Serializable::*)(const Urho3D::String &) const) &Urho3D::Serializable::GetAttributeDefault, "todo: docstring", py::arg("name"))
.def("GetNumAttributes", (unsigned int (Urho3D::Serializable::*)() const) &Urho3D::Serializable::GetNumAttributes, "todo: docstring")
.def("GetNumNetworkAttributes", (unsigned int (Urho3D::Serializable::*)() const) &Urho3D::Serializable::GetNumNetworkAttributes, "todo: docstring")
.def("IsTemporary", (bool (Urho3D::Serializable::*)() const) &Urho3D::Serializable::IsTemporary, "todo: docstring")
.def("GetInterceptNetworkUpdate", (bool (Urho3D::Serializable::*)(const Urho3D::String &) const) &Urho3D::Serializable::GetInterceptNetworkUpdate, "todo: docstring", py::arg("attributeName"))
.def("GetNetworkState", (Urho3D::NetworkState * (Urho3D::Serializable::*)() const) &Urho3D::Serializable::GetNetworkState, "todo: docstring")
// Class Variables:
;
}
void Implement_Urho3D_NetworkState(py::class_<Urho3D::NetworkState, Urho3D::ExternalPtr<Urho3D::NetworkState>>& pyclass_Var_Urho3D_NetworkState)
{
// Class NetworkState Implementation
pyclass_Var_Urho3D_NetworkState
// Class Variables:
.def_readwrite("currentValues",&Urho3D::NetworkState::currentValues_, "todo: var docstring")//Urho3D::Vector<Urho3D::Variant>
.def_readwrite("previousValues",&Urho3D::NetworkState::previousValues_, "todo: var docstring")//Urho3D::Vector<Urho3D::Variant>
.def_readwrite("previousVars",&Urho3D::NetworkState::previousVars_, "todo: var docstring")//Urho3D::HashMap<Urho3D::StringHash, Urho3D::Variant>
.def_readwrite("interceptMask",&Urho3D::NetworkState::interceptMask_, "todo: var docstring")//unsigned long long
;
}
void Implement_Urho3D_Animatable(py::class_<Urho3D::Animatable, Urho3D::SharedPtr<Urho3D::Animatable>, Urho3D::Serializable>& pyclass_Var_Urho3D_Animatable)
{
// Class Animatable Implementation
pyclass_Var_Urho3D_Animatable
.def("GetType", (Urho3D::StringHash (Urho3D::Animatable::*)() const) &Urho3D::Animatable::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::Animatable::*)() const) &Urho3D::Animatable::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::Animatable::*)() const) &Urho3D::Animatable::GetTypeInfo, "todo: docstring")
//.def(py::init<Urho3D::Context *>(), "todo: constructor docstring")
// Abstract class Animatable -> no init
//.def("~Animatable", (void (Urho3D::Animatable::*)()) &Urho3D::Animatable::~Animatable, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("LoadXML", (bool (Urho3D::Animatable::*)(const Urho3D::XMLElement &)) &Urho3D::Animatable::LoadXML, "todo: docstring", py::arg("source"))
.def("SaveXML", (bool (Urho3D::Animatable::*)(Urho3D::XMLElement &) const) &Urho3D::Animatable::SaveXML, "todo: docstring", py::arg("dest"))
.def("LoadJSON", (bool (Urho3D::Animatable::*)(const Urho3D::JSONValue &)) &Urho3D::Animatable::LoadJSON, "todo: docstring", py::arg("source"))
.def("SaveJSON", (bool (Urho3D::Animatable::*)(Urho3D::JSONValue &) const) &Urho3D::Animatable::SaveJSON, "todo: docstring", py::arg("dest"))
.def("SetAnimationEnabled", (void (Urho3D::Animatable::*)(bool)) &Urho3D::Animatable::SetAnimationEnabled, "todo: docstring", py::arg("enable"))
.def("SetAnimationTime", (void (Urho3D::Animatable::*)(float)) &Urho3D::Animatable::SetAnimationTime, "todo: docstring", py::arg("time"))
.def("SetObjectAnimation", (void (Urho3D::Animatable::*)(Urho3D::ObjectAnimation *)) &Urho3D::Animatable::SetObjectAnimation, "todo: docstring", py::arg("objectAnimation"))
.def("SetAttributeAnimation", (void (Urho3D::Animatable::*)(const Urho3D::String &, Urho3D::ValueAnimation *, Urho3D::WrapMode, float)) &Urho3D::Animatable::SetAttributeAnimation, "todo: docstring", py::arg("name"), py::arg("attributeAnimation"), py::arg("wrapMode")=WM_LOOP, py::arg("speed")=1.0f)
.def("SetAttributeAnimationWrapMode", (void (Urho3D::Animatable::*)(const Urho3D::String &, Urho3D::WrapMode)) &Urho3D::Animatable::SetAttributeAnimationWrapMode, "todo: docstring", py::arg("name"), py::arg("wrapMode"))
.def("SetAttributeAnimationSpeed", (void (Urho3D::Animatable::*)(const Urho3D::String &, float)) &Urho3D::Animatable::SetAttributeAnimationSpeed, "todo: docstring", py::arg("name"), py::arg("speed"))
.def("SetAttributeAnimationTime", (void (Urho3D::Animatable::*)(const Urho3D::String &, float)) &Urho3D::Animatable::SetAttributeAnimationTime, "todo: docstring", py::arg("name"), py::arg("time"))
.def("RemoveObjectAnimation", (void (Urho3D::Animatable::*)()) &Urho3D::Animatable::RemoveObjectAnimation, "todo: docstring")
.def("RemoveAttributeAnimation", (void (Urho3D::Animatable::*)(const Urho3D::String &)) &Urho3D::Animatable::RemoveAttributeAnimation, "todo: docstring", py::arg("name"))
.def("GetAnimationEnabled", (bool (Urho3D::Animatable::*)() const) &Urho3D::Animatable::GetAnimationEnabled, "todo: docstring")
.def("GetObjectAnimation", (Urho3D::ObjectAnimation * (Urho3D::Animatable::*)() const) &Urho3D::Animatable::GetObjectAnimation, "todo: docstring")
.def("GetAttributeAnimation", (Urho3D::ValueAnimation * (Urho3D::Animatable::*)(const Urho3D::String &) const) &Urho3D::Animatable::GetAttributeAnimation, "todo: docstring", py::arg("name"))
.def("GetAttributeAnimationWrapMode", (Urho3D::WrapMode (Urho3D::Animatable::*)(const Urho3D::String &) const) &Urho3D::Animatable::GetAttributeAnimationWrapMode, "todo: docstring", py::arg("name"))
.def("GetAttributeAnimationSpeed", (float (Urho3D::Animatable::*)(const Urho3D::String &) const) &Urho3D::Animatable::GetAttributeAnimationSpeed, "todo: docstring", py::arg("name"))
.def("GetAttributeAnimationTime", (float (Urho3D::Animatable::*)(const Urho3D::String &) const) &Urho3D::Animatable::GetAttributeAnimationTime, "todo: docstring", py::arg("name"))
.def("SetObjectAnimationAttr", (void (Urho3D::Animatable::*)(const Urho3D::ResourceRef &)) &Urho3D::Animatable::SetObjectAnimationAttr, "todo: docstring", py::arg("value"))
.def("GetObjectAnimationAttr", (Urho3D::ResourceRef (Urho3D::Animatable::*)() const) &Urho3D::Animatable::GetObjectAnimationAttr, "todo: docstring")
// Class Variables:
;
}
void Implement_Urho3D_Node(py::class_<Urho3D::Node, Urho3D::SharedPtr<Urho3D::Node>, Urho3D::Animatable>& pyclass_Var_Urho3D_Node)
{
// Class Node Implementation
pyclass_Var_Urho3D_Node
.def("GetType", (Urho3D::StringHash (Urho3D::Node::*)() const) &Urho3D::Node::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::Node::*)() const) &Urho3D::Node::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::Node::*)() const) &Urho3D::Node::GetTypeInfo, "todo: docstring")
.def(py::init<Urho3D::Context *>(), "todo: constructor docstring")
//.def("~Node", (void (Urho3D::Node::*)()) &Urho3D::Node::~Node, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("Load", (bool (Urho3D::Node::*)(Urho3D::Deserializer &)) &Urho3D::Node::Load, "todo: docstring", py::arg("source"))
.def("LoadXML", (bool (Urho3D::Node::*)(const Urho3D::XMLElement &)) &Urho3D::Node::LoadXML, "todo: docstring", py::arg("source"))
.def("LoadJSON", (bool (Urho3D::Node::*)(const Urho3D::JSONValue &)) &Urho3D::Node::LoadJSON, "todo: docstring", py::arg("source"))
.def("Save", (bool (Urho3D::Node::*)(Urho3D::Serializer &) const) &Urho3D::Node::Save, "todo: docstring", py::arg("dest"))
.def("SaveXML", (bool (Urho3D::Node::*)(Urho3D::XMLElement &) const) &Urho3D::Node::SaveXML, "todo: docstring", py::arg("dest"))
.def("SaveJSON", (bool (Urho3D::Node::*)(Urho3D::JSONValue &) const) &Urho3D::Node::SaveJSON, "todo: docstring", py::arg("dest"))
.def("ApplyAttributes", (void (Urho3D::Node::*)()) &Urho3D::Node::ApplyAttributes, "todo: docstring")
.def("SaveDefaultAttributes", (bool (Urho3D::Node::*)() const) &Urho3D::Node::SaveDefaultAttributes, "todo: docstring")
.def("MarkNetworkUpdate", (void (Urho3D::Node::*)()) &Urho3D::Node::MarkNetworkUpdate, "todo: docstring")
.def("AddReplicationState", (void (Urho3D::Node::*)(Urho3D::NodeReplicationState *)) &Urho3D::Node::AddReplicationState, "todo: docstring", py::arg("state"))
.def("SaveXML", (bool (Urho3D::Node::*)(Urho3D::Serializer &, const Urho3D::String &) const) &Urho3D::Node::SaveXML, "todo: docstring", py::arg("dest"), py::arg("indentation")="\t")
.def("SaveJSON", (bool (Urho3D::Node::*)(Urho3D::Serializer &, const Urho3D::String &) const) &Urho3D::Node::SaveJSON, "todo: docstring", py::arg("dest"), py::arg("indentation")="\t")
.def("SetName", (void (Urho3D::Node::*)(const Urho3D::String &)) &Urho3D::Node::SetName, "todo: docstring", py::arg("name"))
.def("SetBasePath", (void (Urho3D::Node::*)(const Urho3D::String &)) &Urho3D::Node::SetBasePath, "todo: docstring", py::arg("basePath"))
.def("SetTags", (void (Urho3D::Node::*)(const Urho3D::Vector<Urho3D::String> &)) &Urho3D::Node::SetTags, "todo: docstring", py::arg("tags"))
.def("AddTag", (void (Urho3D::Node::*)(const Urho3D::String &)) &Urho3D::Node::AddTag, "todo: docstring", py::arg("tag"))
.def("AddTags", (void (Urho3D::Node::*)(const Urho3D::String &, char)) &Urho3D::Node::AddTags, "todo: docstring", py::arg("tags"), py::arg("separator")=';')
.def("AddTags", (void (Urho3D::Node::*)(const Urho3D::Vector<Urho3D::String> &)) &Urho3D::Node::AddTags, "todo: docstring", py::arg("tags"))
.def("RemoveTag", (bool (Urho3D::Node::*)(const Urho3D::String &)) &Urho3D::Node::RemoveTag, "todo: docstring", py::arg("tag"))
.def("RemoveAllTags", (void (Urho3D::Node::*)()) &Urho3D::Node::RemoveAllTags, "todo: docstring")
.def("SetPosition", (void (Urho3D::Node::*)(const Urho3D::Vector3 &)) &Urho3D::Node::SetPosition, "todo: docstring", py::arg("position"))
.def("SetPosition2D", (void (Urho3D::Node::*)(const Urho3D::Vector2 &)) &Urho3D::Node::SetPosition2D, "todo: docstring", py::arg("position"))
.def("SetPosition2D", (void (Urho3D::Node::*)(float, float)) &Urho3D::Node::SetPosition2D, "todo: docstring", py::arg("x"), py::arg("y"))
.def("SetRotation", (void (Urho3D::Node::*)(const Urho3D::Quaternion &)) &Urho3D::Node::SetRotation, "todo: docstring", py::arg("rotation"))
.def("SetRotation2D", (void (Urho3D::Node::*)(float)) &Urho3D::Node::SetRotation2D, "todo: docstring", py::arg("rotation"))
.def("SetDirection", (void (Urho3D::Node::*)(const Urho3D::Vector3 &)) &Urho3D::Node::SetDirection, "todo: docstring", py::arg("direction"))
.def("SetScale", (void (Urho3D::Node::*)(float)) &Urho3D::Node::SetScale, "todo: docstring", py::arg("scale"))
.def("SetScale", (void (Urho3D::Node::*)(const Urho3D::Vector3 &)) &Urho3D::Node::SetScale, "todo: docstring", py::arg("scale"))
.def("SetScale2D", (void (Urho3D::Node::*)(const Urho3D::Vector2 &)) &Urho3D::Node::SetScale2D, "todo: docstring", py::arg("scale"))
.def("SetScale2D", (void (Urho3D::Node::*)(float, float)) &Urho3D::Node::SetScale2D, "todo: docstring", py::arg("x"), py::arg("y"))
.def("SetTransform", (void (Urho3D::Node::*)(const Urho3D::Vector3 &, const Urho3D::Quaternion &)) &Urho3D::Node::SetTransform, "todo: docstring", py::arg("position"), py::arg("rotation"))
.def("SetTransform", (void (Urho3D::Node::*)(const Urho3D::Vector3 &, const Urho3D::Quaternion &, float)) &Urho3D::Node::SetTransform, "todo: docstring", py::arg("position"), py::arg("rotation"), py::arg("scale"))
.def("SetTransform", (void (Urho3D::Node::*)(const Urho3D::Vector3 &, const Urho3D::Quaternion &, const Urho3D::Vector3 &)) &Urho3D::Node::SetTransform, "todo: docstring", py::arg("position"), py::arg("rotation"), py::arg("scale"))
.def("SetTransform", (void (Urho3D::Node::*)(const Urho3D::Matrix3x4 &)) &Urho3D::Node::SetTransform, "todo: docstring", py::arg("matrix"))
.def("SetTransform2D", (void (Urho3D::Node::*)(const Urho3D::Vector2 &, float)) &Urho3D::Node::SetTransform2D, "todo: docstring", py::arg("position"), py::arg("rotation"))
.def("SetTransform2D", (void (Urho3D::Node::*)(const Urho3D::Vector2 &, float, float)) &Urho3D::Node::SetTransform2D, "todo: docstring", py::arg("position"), py::arg("rotation"), py::arg("scale"))
.def("SetTransform2D", (void (Urho3D::Node::*)(const Urho3D::Vector2 &, float, const Urho3D::Vector2 &)) &Urho3D::Node::SetTransform2D, "todo: docstring", py::arg("position"), py::arg("rotation"), py::arg("scale"))
.def("SetWorldPosition", (void (Urho3D::Node::*)(const Urho3D::Vector3 &)) &Urho3D::Node::SetWorldPosition, "todo: docstring", py::arg("position"))
.def("SetWorldPosition2D", (void (Urho3D::Node::*)(const Urho3D::Vector2 &)) &Urho3D::Node::SetWorldPosition2D, "todo: docstring", py::arg("position"))
.def("SetWorldPosition2D", (void (Urho3D::Node::*)(float, float)) &Urho3D::Node::SetWorldPosition2D, "todo: docstring", py::arg("x"), py::arg("y"))
.def("SetWorldRotation", (void (Urho3D::Node::*)(const Urho3D::Quaternion &)) &Urho3D::Node::SetWorldRotation, "todo: docstring", py::arg("rotation"))
.def("SetWorldRotation2D", (void (Urho3D::Node::*)(float)) &Urho3D::Node::SetWorldRotation2D, "todo: docstring", py::arg("rotation"))
.def("SetWorldDirection", (void (Urho3D::Node::*)(const Urho3D::Vector3 &)) &Urho3D::Node::SetWorldDirection, "todo: docstring", py::arg("direction"))
.def("SetWorldScale", (void (Urho3D::Node::*)(float)) &Urho3D::Node::SetWorldScale, "todo: docstring", py::arg("scale"))
.def("SetWorldScale", (void (Urho3D::Node::*)(const Urho3D::Vector3 &)) &Urho3D::Node::SetWorldScale, "todo: docstring", py::arg("scale"))
.def("SetWorldScale2D", (void (Urho3D::Node::*)(const Urho3D::Vector2 &)) &Urho3D::Node::SetWorldScale2D, "todo: docstring", py::arg("scale"))
.def("SetWorldScale2D", (void (Urho3D::Node::*)(float, float)) &Urho3D::Node::SetWorldScale2D, "todo: docstring", py::arg("x"), py::arg("y"))
.def("SetWorldTransform", (void (Urho3D::Node::*)(const Urho3D::Vector3 &, const Urho3D::Quaternion &)) &Urho3D::Node::SetWorldTransform, "todo: docstring", py::arg("position"), py::arg("rotation"))
.def("SetWorldTransform", (void (Urho3D::Node::*)(const Urho3D::Vector3 &, const Urho3D::Quaternion &, float)) &Urho3D::Node::SetWorldTransform, "todo: docstring", py::arg("position"), py::arg("rotation"), py::arg("scale"))
.def("SetWorldTransform", (void (Urho3D::Node::*)(const Urho3D::Vector3 &, const Urho3D::Quaternion &, const Urho3D::Vector3 &)) &Urho3D::Node::SetWorldTransform, "todo: docstring", py::arg("position"), py::arg("rotation"), py::arg("scale"))
.def("SetWorldTransform2D", (void (Urho3D::Node::*)(const Urho3D::Vector2 &, float)) &Urho3D::Node::SetWorldTransform2D, "todo: docstring", py::arg("position"), py::arg("rotation"))
.def("SetWorldTransform2D", (void (Urho3D::Node::*)(const Urho3D::Vector2 &, float, float)) &Urho3D::Node::SetWorldTransform2D, "todo: docstring", py::arg("position"), py::arg("rotation"), py::arg("scale"))
.def("SetWorldTransform2D", (void (Urho3D::Node::*)(const Urho3D::Vector2 &, float, const Urho3D::Vector2 &)) &Urho3D::Node::SetWorldTransform2D, "todo: docstring", py::arg("position"), py::arg("rotation"), py::arg("scale"))
.def("Translate", (void (Urho3D::Node::*)(const Urho3D::Vector3 &, Urho3D::TransformSpace)) &Urho3D::Node::Translate, "todo: docstring", py::arg("delta"), py::arg("space")=TS_LOCAL)
.def("Translate2D", (void (Urho3D::Node::*)(const Urho3D::Vector2 &, Urho3D::TransformSpace)) &Urho3D::Node::Translate2D, "todo: docstring", py::arg("delta"), py::arg("space")=TS_LOCAL)
.def("Rotate", (void (Urho3D::Node::*)(const Urho3D::Quaternion &, Urho3D::TransformSpace)) &Urho3D::Node::Rotate, "todo: docstring", py::arg("delta"), py::arg("space")=TS_LOCAL)
.def("Rotate2D", (void (Urho3D::Node::*)(float, Urho3D::TransformSpace)) &Urho3D::Node::Rotate2D, "todo: docstring", py::arg("delta"), py::arg("space")=TS_LOCAL)
.def("RotateAround", (void (Urho3D::Node::*)(const Urho3D::Vector3 &, const Urho3D::Quaternion &, Urho3D::TransformSpace)) &Urho3D::Node::RotateAround, "todo: docstring", py::arg("point"), py::arg("delta"), py::arg("space")=TS_LOCAL)
.def("RotateAround2D", (void (Urho3D::Node::*)(const Urho3D::Vector2 &, float, Urho3D::TransformSpace)) &Urho3D::Node::RotateAround2D, "todo: docstring", py::arg("point"), py::arg("delta"), py::arg("space")=TS_LOCAL)
.def("Pitch", (void (Urho3D::Node::*)(float, Urho3D::TransformSpace)) &Urho3D::Node::Pitch, "todo: docstring", py::arg("angle"), py::arg("space")=TS_LOCAL)
.def("Yaw", (void (Urho3D::Node::*)(float, Urho3D::TransformSpace)) &Urho3D::Node::Yaw, "todo: docstring", py::arg("angle"), py::arg("space")=TS_LOCAL)
.def("Roll", (void (Urho3D::Node::*)(float, Urho3D::TransformSpace)) &Urho3D::Node::Roll, "todo: docstring", py::arg("angle"), py::arg("space")=TS_LOCAL)
.def("LookAt", (bool (Urho3D::Node::*)(const Urho3D::Vector3 &, const Urho3D::Vector3 &, Urho3D::TransformSpace)) &Urho3D::Node::LookAt, "todo: docstring", py::arg("target"), py::arg("up")=Vector3::UP, py::arg("space")=TS_WORLD)
.def("Scale", (void (Urho3D::Node::*)(float)) &Urho3D::Node::Scale, "todo: docstring", py::arg("scale"))
.def("Scale", (void (Urho3D::Node::*)(const Urho3D::Vector3 &)) &Urho3D::Node::Scale, "todo: docstring", py::arg("scale"))
.def("Scale2D", (void (Urho3D::Node::*)(const Urho3D::Vector2 &)) &Urho3D::Node::Scale2D, "todo: docstring", py::arg("scale"))
.def("SetEnabled", (void (Urho3D::Node::*)(bool)) &Urho3D::Node::SetEnabled, "todo: docstring", py::arg("enable"))
.def("SetDeepEnabled", (void (Urho3D::Node::*)(bool)) &Urho3D::Node::SetDeepEnabled, "todo: docstring", py::arg("enable"))
.def("ResetDeepEnabled", (void (Urho3D::Node::*)()) &Urho3D::Node::ResetDeepEnabled, "todo: docstring")
.def("SetEnabledRecursive", (void (Urho3D::Node::*)(bool)) &Urho3D::Node::SetEnabledRecursive, "todo: docstring", py::arg("enable"))
.def("SetOwner", (void (Urho3D::Node::*)(Urho3D::Connection *)) &Urho3D::Node::SetOwner, "todo: docstring", py::arg("owner"))
.def("MarkDirty", (void (Urho3D::Node::*)()) &Urho3D::Node::MarkDirty, "todo: docstring")
.def("CreateChild", (Urho3D::Node * (Urho3D::Node::*)(const Urho3D::String &, Urho3D::CreateMode, unsigned int, bool)) &Urho3D::Node::CreateChild, "todo: docstring", py::arg("name")=String::EMPTY, py::arg("mode")=REPLICATED, py::arg("id")=0, py::arg("temporary")=false)
.def("CreateTemporaryChild", (Urho3D::Node * (Urho3D::Node::*)(const Urho3D::String &, Urho3D::CreateMode, unsigned int)) &Urho3D::Node::CreateTemporaryChild, "todo: docstring", py::arg("name")=String::EMPTY, py::arg("mode")=REPLICATED, py::arg("id")=0)
.def("AddChild", (void (Urho3D::Node::*)(Urho3D::Node *, unsigned int)) &Urho3D::Node::AddChild, "todo: docstring", py::arg("node"), py::arg("index")=M_MAX_UNSIGNED)
.def("RemoveChild", (void (Urho3D::Node::*)(Urho3D::Node *)) &Urho3D::Node::RemoveChild, "todo: docstring", py::arg("node"))
.def("RemoveAllChildren", (void (Urho3D::Node::*)()) &Urho3D::Node::RemoveAllChildren, "todo: docstring")
.def("RemoveChildren", (void (Urho3D::Node::*)(bool, bool, bool)) &Urho3D::Node::RemoveChildren, "todo: docstring", py::arg("removeReplicated"), py::arg("removeLocal"), py::arg("recursive"))
.def("CreateComponent", (Urho3D::Component * (Urho3D::Node::*)(Urho3D::StringHash, Urho3D::CreateMode, unsigned int)) &Urho3D::Node::CreateComponent, "todo: docstring", py::arg("type"), py::arg("mode")=REPLICATED, py::arg("id")=0)
.def("GetOrCreateComponent", (Urho3D::Component * (Urho3D::Node::*)(Urho3D::StringHash, Urho3D::CreateMode, unsigned int)) &Urho3D::Node::GetOrCreateComponent, "todo: docstring", py::arg("type"), py::arg("mode")=REPLICATED, py::arg("id")=0)
.def("CloneComponent", (Urho3D::Component * (Urho3D::Node::*)(Urho3D::Component *, unsigned int)) &Urho3D::Node::CloneComponent, "todo: docstring", py::arg("component"), py::arg("id")=0)
.def("CloneComponent", (Urho3D::Component * (Urho3D::Node::*)(Urho3D::Component *, Urho3D::CreateMode, unsigned int)) &Urho3D::Node::CloneComponent, "todo: docstring", py::arg("component"), py::arg("mode"), py::arg("id")=0)
.def("RemoveComponent", (void (Urho3D::Node::*)(Urho3D::Component *)) &Urho3D::Node::RemoveComponent, "todo: docstring", py::arg("component"))
.def("RemoveComponent", (void (Urho3D::Node::*)(Urho3D::StringHash)) &Urho3D::Node::RemoveComponent, "todo: docstring", py::arg("type"))
.def("RemoveComponents", (void (Urho3D::Node::*)(bool, bool)) &Urho3D::Node::RemoveComponents, "todo: docstring", py::arg("removeReplicated"), py::arg("removeLocal"))
.def("RemoveComponents", (void (Urho3D::Node::*)(Urho3D::StringHash)) &Urho3D::Node::RemoveComponents, "todo: docstring", py::arg("type"))
.def("RemoveAllComponents", (void (Urho3D::Node::*)()) &Urho3D::Node::RemoveAllComponents, "todo: docstring")
.def("ReorderComponent", (void (Urho3D::Node::*)(Urho3D::Component *, unsigned int)) &Urho3D::Node::ReorderComponent, "todo: docstring", py::arg("component"), py::arg("index"))
.def("Clone", (Urho3D::Node * (Urho3D::Node::*)(Urho3D::CreateMode)) &Urho3D::Node::Clone, "todo: docstring", py::arg("mode")=REPLICATED)
.def("Remove", (void (Urho3D::Node::*)()) &Urho3D::Node::Remove, "todo: docstring")
.def("SetParent", (void (Urho3D::Node::*)(Urho3D::Node *)) &Urho3D::Node::SetParent, "todo: docstring", py::arg("parent"))
.def("SetVar", (void (Urho3D::Node::*)(Urho3D::StringHash, const Urho3D::Variant &)) &Urho3D::Node::SetVar, "todo: docstring", py::arg("key"), py::arg("value"))
.def("AddListener", (void (Urho3D::Node::*)(Urho3D::Component *)) &Urho3D::Node::AddListener, "todo: docstring", py::arg("component"))
.def("RemoveListener", (void (Urho3D::Node::*)(Urho3D::Component *)) &Urho3D::Node::RemoveListener, "todo: docstring", py::arg("component"))
.def("GetID", (unsigned int (Urho3D::Node::*)() const) &Urho3D::Node::GetID, "todo: docstring")
.def("IsReplicated", (bool (Urho3D::Node::*)() const) &Urho3D::Node::IsReplicated, "todo: docstring")
.def("GetName", (const Urho3D::String & (Urho3D::Node::*)() const) &Urho3D::Node::GetName, "todo: docstring")
.def("GetNameHash", (Urho3D::StringHash (Urho3D::Node::*)() const) &Urho3D::Node::GetNameHash, "todo: docstring")
.def("GetBasePath", (const Urho3D::String & (Urho3D::Node::*)() const) &Urho3D::Node::GetBasePath, "todo: docstring")
.def("GetTags", (const Urho3D::StringVector & (Urho3D::Node::*)() const) &Urho3D::Node::GetTags, "todo: docstring")
.def("HasTag", (bool (Urho3D::Node::*)(const Urho3D::String &) const) &Urho3D::Node::HasTag, "todo: docstring", py::arg("tag"))
.def("GetParent", (Urho3D::Node * (Urho3D::Node::*)() const) &Urho3D::Node::GetParent, "todo: docstring")
.def("GetScene", (Urho3D::Scene * (Urho3D::Node::*)() const) &Urho3D::Node::GetScene, "todo: docstring")
.def("IsChildOf", (bool (Urho3D::Node::*)(Urho3D::Node *) const) &Urho3D::Node::IsChildOf, "todo: docstring", py::arg("node"))
.def("IsEnabled", (bool (Urho3D::Node::*)() const) &Urho3D::Node::IsEnabled, "todo: docstring")
.def("IsEnabledSelf", (bool (Urho3D::Node::*)() const) &Urho3D::Node::IsEnabledSelf, "todo: docstring")
.def("GetOwner", (Urho3D::Connection * (Urho3D::Node::*)() const) &Urho3D::Node::GetOwner, "todo: docstring")
.def("GetPosition", (const Urho3D::Vector3 & (Urho3D::Node::*)() const) &Urho3D::Node::GetPosition, "todo: docstring")
.def("GetPosition2D", (Urho3D::Vector2 (Urho3D::Node::*)() const) &Urho3D::Node::GetPosition2D, "todo: docstring")
.def("GetRotation", (const Urho3D::Quaternion & (Urho3D::Node::*)() const) &Urho3D::Node::GetRotation, "todo: docstring")
.def("GetRotation2D", (float (Urho3D::Node::*)() const) &Urho3D::Node::GetRotation2D, "todo: docstring")
.def("GetDirection", (Urho3D::Vector3 (Urho3D::Node::*)() const) &Urho3D::Node::GetDirection, "todo: docstring")
.def("GetUp", (Urho3D::Vector3 (Urho3D::Node::*)() const) &Urho3D::Node::GetUp, "todo: docstring")
.def("GetRight", (Urho3D::Vector3 (Urho3D::Node::*)() const) &Urho3D::Node::GetRight, "todo: docstring")
.def("GetScale", (const Urho3D::Vector3 & (Urho3D::Node::*)() const) &Urho3D::Node::GetScale, "todo: docstring")
.def("GetScale2D", (Urho3D::Vector2 (Urho3D::Node::*)() const) &Urho3D::Node::GetScale2D, "todo: docstring")
.def("GetTransform", (Urho3D::Matrix3x4 (Urho3D::Node::*)() const) &Urho3D::Node::GetTransform, "todo: docstring")
.def("GetWorldPosition", (Urho3D::Vector3 (Urho3D::Node::*)() const) &Urho3D::Node::GetWorldPosition, "todo: docstring")
.def("GetWorldPosition2D", (Urho3D::Vector2 (Urho3D::Node::*)() const) &Urho3D::Node::GetWorldPosition2D, "todo: docstring")
.def("GetWorldRotation", (Urho3D::Quaternion (Urho3D::Node::*)() const) &Urho3D::Node::GetWorldRotation, "todo: docstring")
.def("GetWorldRotation2D", (float (Urho3D::Node::*)() const) &Urho3D::Node::GetWorldRotation2D, "todo: docstring")
.def("GetWorldDirection", (Urho3D::Vector3 (Urho3D::Node::*)() const) &Urho3D::Node::GetWorldDirection, "todo: docstring")
.def("GetWorldUp", (Urho3D::Vector3 (Urho3D::Node::*)() const) &Urho3D::Node::GetWorldUp, "todo: docstring")
.def("GetWorldRight", (Urho3D::Vector3 (Urho3D::Node::*)() const) &Urho3D::Node::GetWorldRight, "todo: docstring")
.def("GetWorldScale", (Urho3D::Vector3 (Urho3D::Node::*)() const) &Urho3D::Node::GetWorldScale, "todo: docstring")
.def("GetSignedWorldScale", (Urho3D::Vector3 (Urho3D::Node::*)() const) &Urho3D::Node::GetSignedWorldScale, "todo: docstring")
.def("GetWorldScale2D", (Urho3D::Vector2 (Urho3D::Node::*)() const) &Urho3D::Node::GetWorldScale2D, "todo: docstring")
.def("GetWorldTransform", (const Urho3D::Matrix3x4 & (Urho3D::Node::*)() const) &Urho3D::Node::GetWorldTransform, "todo: docstring")
.def("LocalToWorld", (Urho3D::Vector3 (Urho3D::Node::*)(const Urho3D::Vector3 &) const) &Urho3D::Node::LocalToWorld, "todo: docstring", py::arg("position"))
.def("LocalToWorld", (Urho3D::Vector3 (Urho3D::Node::*)(const Urho3D::Vector4 &) const) &Urho3D::Node::LocalToWorld, "todo: docstring", py::arg("vector"))
.def("LocalToWorld2D", (Urho3D::Vector2 (Urho3D::Node::*)(const Urho3D::Vector2 &) const) &Urho3D::Node::LocalToWorld2D, "todo: docstring", py::arg("vector"))
.def("WorldToLocal", (Urho3D::Vector3 (Urho3D::Node::*)(const Urho3D::Vector3 &) const) &Urho3D::Node::WorldToLocal, "todo: docstring", py::arg("position"))
.def("WorldToLocal", (Urho3D::Vector3 (Urho3D::Node::*)(const Urho3D::Vector4 &) const) &Urho3D::Node::WorldToLocal, "todo: docstring", py::arg("vector"))
.def("WorldToLocal2D", (Urho3D::Vector2 (Urho3D::Node::*)(const Urho3D::Vector2 &) const) &Urho3D::Node::WorldToLocal2D, "todo: docstring", py::arg("vector"))
.def("IsDirty", (bool (Urho3D::Node::*)() const) &Urho3D::Node::IsDirty, "todo: docstring")
.def("GetNumChildren", (unsigned int (Urho3D::Node::*)(bool) const) &Urho3D::Node::GetNumChildren, "todo: docstring", py::arg("recursive")=false)
//.def("GetChildren", (const Vector<SharedPtr<Urho3D::Node> > & (Urho3D::Node::*)() const) &Urho3D::Node::GetChildren, "todo: docstring")
//[]; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 0
//.def("GetChildren", (void (Urho3D::Node::*)(Urho3D::PODVector<Urho3D::Node *> &, bool) const) &Urho3D::Node::GetChildren, "todo: docstring", py::arg("dest"), py::arg("recursive")=false)
//['Urho3D::PODVector<Urho3D::Node', 'bool']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 1
//.def("GetChildren", (PODVector<Urho3D::Node *> (Urho3D::Node::*)(bool) const) &Urho3D::Node::GetChildren, "todo: docstring", py::arg("recursive"))
//['bool']; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 1
//.def("GetChildrenWithComponent", (void (Urho3D::Node::*)(Urho3D::PODVector<Urho3D::Node *> &, Urho3D::StringHash, bool) const) &Urho3D::Node::GetChildrenWithComponent, "todo: docstring", py::arg("dest"), py::arg("type"), py::arg("recursive")=false)
//['Urho3D::PODVector<Urho3D::Node', 'Urho3D::StringHash', 'bool']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 1
//.def("GetChildrenWithComponent", (PODVector<Urho3D::Node *> (Urho3D::Node::*)(Urho3D::StringHash, bool) const) &Urho3D::Node::GetChildrenWithComponent, "todo: docstring", py::arg("type"), py::arg("recursive")=false)
//['Urho3D::StringHash', 'bool']; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 1
//.def("GetChildrenWithTag", (void (Urho3D::Node::*)(Urho3D::PODVector<Urho3D::Node *> &, const Urho3D::String &, bool) const) &Urho3D::Node::GetChildrenWithTag, "todo: docstring", py::arg("dest"), py::arg("tag"), py::arg("recursive")=false)
//['Urho3D::PODVector<Urho3D::Node', 'Urho3D::String', 'bool']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 1
//.def("GetChildrenWithTag", (PODVector<Urho3D::Node *> (Urho3D::Node::*)(const Urho3D::String &, bool) const) &Urho3D::Node::GetChildrenWithTag, "todo: docstring", py::arg("tag"), py::arg("recursive")=false)
//['Urho3D::String', 'bool']; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 1
.def("GetChild", (Urho3D::Node * (Urho3D::Node::*)(unsigned int) const) &Urho3D::Node::GetChild, "todo: docstring", py::arg("index"))
.def("GetChild", (Urho3D::Node * (Urho3D::Node::*)(const Urho3D::String &, bool) const) &Urho3D::Node::GetChild, "todo: docstring", py::arg("name"), py::arg("recursive")=false)
.def("GetChild", (Urho3D::Node * (Urho3D::Node::*)(const char *, bool) const) &Urho3D::Node::GetChild, "todo: docstring", py::arg("name"), py::arg("recursive")=false)
.def("GetChild", (Urho3D::Node * (Urho3D::Node::*)(Urho3D::StringHash, bool) const) &Urho3D::Node::GetChild, "todo: docstring", py::arg("nameHash"), py::arg("recursive")=false)
.def("GetNumComponents", (unsigned int (Urho3D::Node::*)() const) &Urho3D::Node::GetNumComponents, "todo: docstring")
.def("GetNumNetworkComponents", (unsigned int (Urho3D::Node::*)() const) &Urho3D::Node::GetNumNetworkComponents, "todo: docstring")
//.def("GetComponents", (const Vector<SharedPtr<Urho3D::Component> > & (Urho3D::Node::*)() const) &Urho3D::Node::GetComponents, "todo: docstring")
//[]; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 0
//.def("GetComponents", (void (Urho3D::Node::*)(Urho3D::PODVector<Urho3D::Component *> &, Urho3D::StringHash, bool) const) &Urho3D::Node::GetComponents, "todo: docstring", py::arg("dest"), py::arg("type"), py::arg("recursive")=false)
//['Urho3D::PODVector<Urho3D::Component', 'Urho3D::StringHash', 'bool']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 1
.def("GetComponent", (Urho3D::Component * (Urho3D::Node::*)(Urho3D::StringHash, bool) const) &Urho3D::Node::GetComponent, "todo: docstring", py::arg("type"), py::arg("recursive")=false)
.def("GetParentComponent", (Urho3D::Component * (Urho3D::Node::*)(Urho3D::StringHash, bool) const) &Urho3D::Node::GetParentComponent, "todo: docstring", py::arg("type"), py::arg("fullTraversal")=false)
.def("HasComponent", (bool (Urho3D::Node::*)(Urho3D::StringHash) const) &Urho3D::Node::HasComponent, "todo: docstring", py::arg("type"))
//.def("GetListeners", (const Vector<WeakPtr<Urho3D::Component> > (Urho3D::Node::*)() const) &Urho3D::Node::GetListeners, "todo: docstring")
//[]; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 0
.def("GetVar", (const Urho3D::Variant & (Urho3D::Node::*)(Urho3D::StringHash) const) &Urho3D::Node::GetVar, "todo: docstring", py::arg("key"))
.def("GetVars", (const Urho3D::VariantMap & (Urho3D::Node::*)() const) &Urho3D::Node::GetVars, "todo: docstring")
.def("SetID", (void (Urho3D::Node::*)(unsigned int)) &Urho3D::Node::SetID, "todo: docstring", py::arg("id"))
.def("SetScene", (void (Urho3D::Node::*)(Urho3D::Scene *)) &Urho3D::Node::SetScene, "todo: docstring", py::arg("scene"))
.def("ResetScene", (void (Urho3D::Node::*)()) &Urho3D::Node::ResetScene, "todo: docstring")
.def("SetNetPositionAttr", (void (Urho3D::Node::*)(const Urho3D::Vector3 &)) &Urho3D::Node::SetNetPositionAttr, "todo: docstring", py::arg("value"))
.def("SetNetRotationAttr", (void (Urho3D::Node::*)(const Urho3D::PODVector<unsigned char> &)) &Urho3D::Node::SetNetRotationAttr, "todo: docstring", py::arg("value"))
.def("SetNetParentAttr", (void (Urho3D::Node::*)(const Urho3D::PODVector<unsigned char> &)) &Urho3D::Node::SetNetParentAttr, "todo: docstring", py::arg("value"))
.def("GetNetPositionAttr", (const Urho3D::Vector3 & (Urho3D::Node::*)() const) &Urho3D::Node::GetNetPositionAttr, "todo: docstring")
//.def("GetNetRotationAttr", (const PODVector<unsigned char> & (Urho3D::Node::*)() const) &Urho3D::Node::GetNetRotationAttr, "todo: docstring")
//[]; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 0
//.def("GetNetParentAttr", (const PODVector<unsigned char> & (Urho3D::Node::*)() const) &Urho3D::Node::GetNetParentAttr, "todo: docstring")
//[]; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 0
.def("Load", (bool (Urho3D::Node::*)(Urho3D::Deserializer &, Urho3D::SceneResolver &, bool, bool, Urho3D::CreateMode)) &Urho3D::Node::Load, "todo: docstring", py::arg("source"), py::arg("resolver"), py::arg("loadChildren")=true, py::arg("rewriteIDs")=false, py::arg("mode")=REPLICATED)
.def("LoadXML", (bool (Urho3D::Node::*)(const Urho3D::XMLElement &, Urho3D::SceneResolver &, bool, bool, Urho3D::CreateMode)) &Urho3D::Node::LoadXML, "todo: docstring", py::arg("source"), py::arg("resolver"), py::arg("loadChildren")=true, py::arg("rewriteIDs")=false, py::arg("mode")=REPLICATED)
.def("LoadJSON", (bool (Urho3D::Node::*)(const Urho3D::JSONValue &, Urho3D::SceneResolver &, bool, bool, Urho3D::CreateMode)) &Urho3D::Node::LoadJSON, "todo: docstring", py::arg("source"), py::arg("resolver"), py::arg("loadChildren")=true, py::arg("rewriteIDs")=false, py::arg("mode")=REPLICATED)
//.def("GetDependencyNodes", (const PODVector<Urho3D::Node *> & (Urho3D::Node::*)() const) &Urho3D::Node::GetDependencyNodes, "todo: docstring")
//[]; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 1
.def("PrepareNetworkUpdate", (void (Urho3D::Node::*)()) &Urho3D::Node::PrepareNetworkUpdate, "todo: docstring")
.def("CleanupConnection", (void (Urho3D::Node::*)(Urho3D::Connection *)) &Urho3D::Node::CleanupConnection, "todo: docstring", py::arg("connection"))
.def("MarkReplicationDirty", (void (Urho3D::Node::*)()) &Urho3D::Node::MarkReplicationDirty, "todo: docstring")
.def("CreateChild", (Urho3D::Node * (Urho3D::Node::*)(unsigned int, Urho3D::CreateMode, bool)) &Urho3D::Node::CreateChild, "todo: docstring", py::arg("id"), py::arg("mode"), py::arg("temporary")=false)
.def("AddComponent", (void (Urho3D::Node::*)(Urho3D::Component *, unsigned int, Urho3D::CreateMode)) &Urho3D::Node::AddComponent, "todo: docstring", py::arg("component"), py::arg("id"), py::arg("mode"))
.def("GetNumPersistentChildren", (unsigned int (Urho3D::Node::*)() const) &Urho3D::Node::GetNumPersistentChildren, "todo: docstring")
.def("GetNumPersistentComponents", (unsigned int (Urho3D::Node::*)() const) &Urho3D::Node::GetNumPersistentComponents, "todo: docstring")
.def("SetPositionSilent", (void (Urho3D::Node::*)(const Urho3D::Vector3 &)) &Urho3D::Node::SetPositionSilent, "todo: docstring", py::arg("position"))
.def("SetRotationSilent", (void (Urho3D::Node::*)(const Urho3D::Quaternion &)) &Urho3D::Node::SetRotationSilent, "todo: docstring", py::arg("rotation"))
.def("SetScaleSilent", (void (Urho3D::Node::*)(const Urho3D::Vector3 &)) &Urho3D::Node::SetScaleSilent, "todo: docstring", py::arg("scale"))
.def("SetTransformSilent", (void (Urho3D::Node::*)(const Urho3D::Vector3 &, const Urho3D::Quaternion &, const Urho3D::Vector3 &)) &Urho3D::Node::SetTransformSilent, "todo: docstring", py::arg("position"), py::arg("rotation"), py::arg("scale"))
// Class Variables:
;
}
void Implement_Urho3D_Frustum(py::class_<Urho3D::Frustum, Urho3D::ExternalPtr<Urho3D::Frustum>>& pyclass_Var_Urho3D_Frustum)
{
// Class Frustum Implementation
pyclass_Var_Urho3D_Frustum
.def(py::init<>(), "todo: constructor docstring")
.def(py::init<const Urho3D::Frustum &>(), "todo: constructor docstring")
// .def(py::self = Urho3D::Frustum(), "todo: docstring").def("__assign__", (Urho3D::Frustum & (Urho3D::Frustum::*)(const Urho3D::Frustum &)) &Urho3D::Frustum::operator=, py::operator, "todo: operator docstring. Switch to py: :self ops.")
//['Urho3D::Frustum']; op =, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("Define", (void (Urho3D::Frustum::*)(float, float, float, float, float, const Urho3D::Matrix3x4 &)) &Urho3D::Frustum::Define, "todo: docstring", py::arg("fov"), py::arg("aspectRatio"), py::arg("zoom"), py::arg("nearZ"), py::arg("farZ"), py::arg("transform")=Matrix3x4::IDENTITY)
.def("Define", (void (Urho3D::Frustum::*)(const Urho3D::Vector3 &, const Urho3D::Vector3 &, const Urho3D::Matrix3x4 &)) &Urho3D::Frustum::Define, "todo: docstring", py::arg("near"), py::arg("far"), py::arg("transform")=Matrix3x4::IDENTITY)
.def("Define", (void (Urho3D::Frustum::*)(const Urho3D::BoundingBox &, const Urho3D::Matrix3x4 &)) &Urho3D::Frustum::Define, "todo: docstring", py::arg("box"), py::arg("transform")=Matrix3x4::IDENTITY)
.def("Define", (void (Urho3D::Frustum::*)(const Urho3D::Matrix4 &)) &Urho3D::Frustum::Define, "todo: docstring", py::arg("projection"))
.def("DefineOrtho", (void (Urho3D::Frustum::*)(float, float, float, float, float, const Urho3D::Matrix3x4 &)) &Urho3D::Frustum::DefineOrtho, "todo: docstring", py::arg("orthoSize"), py::arg("aspectRatio"), py::arg("zoom"), py::arg("nearZ"), py::arg("farZ"), py::arg("transform")=Matrix3x4::IDENTITY)
.def("DefineSplit", (void (Urho3D::Frustum::*)(const Urho3D::Matrix4 &, float, float)) &Urho3D::Frustum::DefineSplit, "todo: docstring", py::arg("projection"), py::arg("near"), py::arg("far"))
.def("Transform", (void (Urho3D::Frustum::*)(const Urho3D::Matrix3 &)) &Urho3D::Frustum::Transform, "todo: docstring", py::arg("transform"))
.def("Transform", (void (Urho3D::Frustum::*)(const Urho3D::Matrix3x4 &)) &Urho3D::Frustum::Transform, "todo: docstring", py::arg("transform"))
.def("IsInside", (Urho3D::Intersection (Urho3D::Frustum::*)(const Urho3D::Vector3 &) const) &Urho3D::Frustum::IsInside, "todo: docstring", py::arg("point"))
.def("IsInside", (Urho3D::Intersection (Urho3D::Frustum::*)(const Urho3D::Sphere &) const) &Urho3D::Frustum::IsInside, "todo: docstring", py::arg("sphere"))
.def("IsInsideFast", (Urho3D::Intersection (Urho3D::Frustum::*)(const Urho3D::Sphere &) const) &Urho3D::Frustum::IsInsideFast, "todo: docstring", py::arg("sphere"))
.def("IsInside", (Urho3D::Intersection (Urho3D::Frustum::*)(const Urho3D::BoundingBox &) const) &Urho3D::Frustum::IsInside, "todo: docstring", py::arg("box"))
.def("IsInsideFast", (Urho3D::Intersection (Urho3D::Frustum::*)(const Urho3D::BoundingBox &) const) &Urho3D::Frustum::IsInsideFast, "todo: docstring", py::arg("box"))
.def("Distance", (float (Urho3D::Frustum::*)(const Urho3D::Vector3 &) const) &Urho3D::Frustum::Distance, "todo: docstring", py::arg("point"))
.def("Transformed", (Urho3D::Frustum (Urho3D::Frustum::*)(const Urho3D::Matrix3 &) const) &Urho3D::Frustum::Transformed, "todo: docstring", py::arg("transform"))
.def("Transformed", (Urho3D::Frustum (Urho3D::Frustum::*)(const Urho3D::Matrix3x4 &) const) &Urho3D::Frustum::Transformed, "todo: docstring", py::arg("transform"))
.def("Projected", (Urho3D::Rect (Urho3D::Frustum::*)(const Urho3D::Matrix4 &) const) &Urho3D::Frustum::Projected, "todo: docstring", py::arg("projection"))
.def("UpdatePlanes", (void (Urho3D::Frustum::*)()) &Urho3D::Frustum::UpdatePlanes, "todo: docstring")
// Class Variables:
;
}
void Implement_Urho3D_RayOctreeQuery(py::class_<Urho3D::RayOctreeQuery, Urho3D::ExternalPtr<Urho3D::RayOctreeQuery>>& pyclass_Var_Urho3D_RayOctreeQuery)
{
// Class RayOctreeQuery Implementation
pyclass_Var_Urho3D_RayOctreeQuery
//.def(py::init<Urho3D::PODVector<Urho3D::RayQueryResult> &, const Urho3D::Ray &, Urho3D::RayQueryLevel, float, unsigned char, unsigned int>(), "todo: constructor docstring")
//['Urho3D::PODVector<Urho3D::RayQueryResult>', 'Urho3D::Ray', 'Urho3D::RayQueryLevel', 'float', 'unsigned char', 'unsigned int']; op False, ctor True, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
//.def(py::init<const Urho3D::RayOctreeQuery &>(), "todo: constructor docstring")
//['Urho3D::RayOctreeQuery']; op False, ctor True, dtor False, variadic False, deleted True, ret bad False, param bad False, max ptr 0
// .def(py::self = Urho3D::RayOctreeQuery(), "todo: docstring").def("__assign__", (Urho3D::RayOctreeQuery & (Urho3D::RayOctreeQuery::*)(const Urho3D::RayOctreeQuery &)) &Urho3D::RayOctreeQuery::operator=, py::operator, "todo: operator docstring. Switch to py: :self ops.")
//['Urho3D::RayOctreeQuery']; op =, ctor False, dtor False, variadic False, deleted True, ret bad False, param bad False, max ptr 0
// Class Variables:
.def_readwrite("ray",&Urho3D::RayOctreeQuery::ray_, "todo: var docstring")//Urho3D::Ray
.def_readwrite("drawableFlags",&Urho3D::RayOctreeQuery::drawableFlags_, "todo: var docstring")//unsigned char
.def_readwrite("viewMask",&Urho3D::RayOctreeQuery::viewMask_, "todo: var docstring")//unsigned int
.def_readwrite("maxDistance",&Urho3D::RayOctreeQuery::maxDistance_, "todo: var docstring")//float
.def_readwrite("level",&Urho3D::RayOctreeQuery::level_, "todo: var docstring")//Urho3D::RayQueryLevel
;
}
void Implement_Urho3D_Timer(py::class_<Urho3D::Timer, Urho3D::ExternalPtr<Urho3D::Timer>>& pyclass_Var_Urho3D_Timer)
{
// Class Timer Implementation
pyclass_Var_Urho3D_Timer
.def(py::init<>(), "todo: constructor docstring")
.def("GetMSec", (unsigned int (Urho3D::Timer::*)(bool)) &Urho3D::Timer::GetMSec, "todo: docstring", py::arg("reset"))
.def("Reset", (void (Urho3D::Timer::*)()) &Urho3D::Timer::Reset, "todo: docstring")
// Class Variables:
;
}
void Implement_Urho3D_Log(py::class_<Urho3D::Log, Urho3D::SharedPtr<Urho3D::Log>, Urho3D::Object>& pyclass_Var_Urho3D_Log)
{
// Class Log Implementation
pyclass_Var_Urho3D_Log
.def("GetType", (Urho3D::StringHash (Urho3D::Log::*)() const) &Urho3D::Log::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::Log::*)() const) &Urho3D::Log::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::Log::*)() const) &Urho3D::Log::GetTypeInfo, "todo: docstring")
.def(py::init<Urho3D::Context *>(), "todo: constructor docstring")
//.def("~Log", (void (Urho3D::Log::*)()) &Urho3D::Log::~Log, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("Open", (void (Urho3D::Log::*)(const Urho3D::String &)) &Urho3D::Log::Open, "todo: docstring", py::arg("fileName"))
.def("Close", (void (Urho3D::Log::*)()) &Urho3D::Log::Close, "todo: docstring")
.def("SetLevel", (void (Urho3D::Log::*)(int)) &Urho3D::Log::SetLevel, "todo: docstring", py::arg("level"))
.def("SetTimeStamp", (void (Urho3D::Log::*)(bool)) &Urho3D::Log::SetTimeStamp, "todo: docstring", py::arg("enable"))
.def("SetQuiet", (void (Urho3D::Log::*)(bool)) &Urho3D::Log::SetQuiet, "todo: docstring", py::arg("quiet"))
.def("GetLevel", (int (Urho3D::Log::*)() const) &Urho3D::Log::GetLevel, "todo: docstring")
.def("GetTimeStamp", (bool (Urho3D::Log::*)() const) &Urho3D::Log::GetTimeStamp, "todo: docstring")
.def("GetLastMessage", (Urho3D::String (Urho3D::Log::*)() const) &Urho3D::Log::GetLastMessage, "todo: docstring")
.def("IsQuiet", (bool (Urho3D::Log::*)() const) &Urho3D::Log::IsQuiet, "todo: docstring")
// Class Variables:
;
}
void Implement_Urho3D_CascadeParameters(py::class_<Urho3D::CascadeParameters, Urho3D::ExternalPtr<Urho3D::CascadeParameters>>& pyclass_Var_Urho3D_CascadeParameters)
{
// Class CascadeParameters Implementation
pyclass_Var_Urho3D_CascadeParameters
.def(py::init<>(), "todo: constructor docstring")
.def(py::init<float, float, float, float, float, float>(), "todo: constructor docstring")
.def("Validate", (void (Urho3D::CascadeParameters::*)()) &Urho3D::CascadeParameters::Validate, "todo: docstring")
.def("GetShadowRange", (float (Urho3D::CascadeParameters::*)() const) &Urho3D::CascadeParameters::GetShadowRange, "todo: docstring")
// Class Variables:
.def_readwrite("splits",&Urho3D::CascadeParameters::splits_, "todo: var docstring")//Urho3D::Vector4
.def_readwrite("fadeStart",&Urho3D::CascadeParameters::fadeStart_, "todo: var docstring")//float
.def_readwrite("biasAutoAdjust",&Urho3D::CascadeParameters::biasAutoAdjust_, "todo: var docstring")//float
;
}
void Implement_Urho3D_UIElement(py::class_<Urho3D::UIElement, Urho3D::SharedPtr<Urho3D::UIElement>, Urho3D::Animatable>& pyclass_Var_Urho3D_UIElement)
{
// Class UIElement Implementation
pyclass_Var_Urho3D_UIElement
.def("GetType", (Urho3D::StringHash (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetTypeInfo, "todo: docstring")
.def(py::init<Urho3D::Context *>(), "todo: constructor docstring")
//.def("~UIElement", (void (Urho3D::UIElement::*)()) &Urho3D::UIElement::~UIElement, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("ApplyAttributes", (void (Urho3D::UIElement::*)()) &Urho3D::UIElement::ApplyAttributes, "todo: docstring")
.def("LoadXML", (bool (Urho3D::UIElement::*)(const Urho3D::XMLElement &)) &Urho3D::UIElement::LoadXML, "todo: docstring", py::arg("source"))
.def("LoadXML", (bool (Urho3D::UIElement::*)(const Urho3D::XMLElement &, Urho3D::XMLFile *)) &Urho3D::UIElement::LoadXML, "todo: docstring", py::arg("source"), py::arg("styleFile"))
.def("LoadChildXML", (Urho3D::UIElement * (Urho3D::UIElement::*)(const Urho3D::XMLElement &, Urho3D::XMLFile *)) &Urho3D::UIElement::LoadChildXML, "todo: docstring", py::arg("childElem"), py::arg("styleFile"))
.def("SaveXML", (bool (Urho3D::UIElement::*)(Urho3D::XMLElement &) const) &Urho3D::UIElement::SaveXML, "todo: docstring", py::arg("dest"))
.def("Update", (void (Urho3D::UIElement::*)(float)) &Urho3D::UIElement::Update, "todo: docstring", py::arg("timeStep"))
.def("IsWithinScissor", (bool (Urho3D::UIElement::*)(const Urho3D::IntRect &)) &Urho3D::UIElement::IsWithinScissor, "todo: docstring", py::arg("currentScissor"))
.def("GetScreenPosition", (const Urho3D::IntVector2 & (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetScreenPosition, "todo: docstring")
//.def("GetBatches", (void (Urho3D::UIElement::*)(Urho3D::PODVector<Urho3D::UIBatch> &, Urho3D::PODVector<float> &, const Urho3D::IntRect &)) &Urho3D::UIElement::GetBatches, "todo: docstring", py::arg("batches"), py::arg("vertexData"), py::arg("currentScissor"))
//['Urho3D::PODVector<Urho3D::UIBatch>', 'Urho3D::PODVector<float>', 'Urho3D::IntRect']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
//.def("GetDebugDrawBatches", (void (Urho3D::UIElement::*)(Urho3D::PODVector<Urho3D::UIBatch> &, Urho3D::PODVector<float> &, const Urho3D::IntRect &)) &Urho3D::UIElement::GetDebugDrawBatches, "todo: docstring", py::arg("batches"), py::arg("vertexData"), py::arg("currentScissor"))
//['Urho3D::PODVector<Urho3D::UIBatch>', 'Urho3D::PODVector<float>', 'Urho3D::IntRect']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
.def("OnHover", (void (Urho3D::UIElement::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, Urho3D::Cursor *)) &Urho3D::UIElement::OnHover, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("buttons"), py::arg("qualifiers"), py::arg("cursor"))
.def("OnClickBegin", (void (Urho3D::UIElement::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, int, Urho3D::Cursor *)) &Urho3D::UIElement::OnClickBegin, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("button"), py::arg("buttons"), py::arg("qualifiers"), py::arg("cursor"))
.def("OnClickEnd", (void (Urho3D::UIElement::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, int, Urho3D::Cursor *, Urho3D::UIElement *)) &Urho3D::UIElement::OnClickEnd, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("button"), py::arg("buttons"), py::arg("qualifiers"), py::arg("cursor"), py::arg("beginElement"))
.def("OnDoubleClick", (void (Urho3D::UIElement::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, int, Urho3D::Cursor *)) &Urho3D::UIElement::OnDoubleClick, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("button"), py::arg("buttons"), py::arg("qualifiers"), py::arg("cursor"))
.def("OnDragBegin", (void (Urho3D::UIElement::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, Urho3D::Cursor *)) &Urho3D::UIElement::OnDragBegin, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("buttons"), py::arg("qualifiers"), py::arg("cursor"))
.def("OnDragMove", (void (Urho3D::UIElement::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, Urho3D::Cursor *)) &Urho3D::UIElement::OnDragMove, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("deltaPos"), py::arg("buttons"), py::arg("qualifiers"), py::arg("cursor"))
.def("OnDragEnd", (void (Urho3D::UIElement::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, Urho3D::Cursor *)) &Urho3D::UIElement::OnDragEnd, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("dragButtons"), py::arg("releaseButton"), py::arg("cursor"))
.def("OnDragCancel", (void (Urho3D::UIElement::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, Urho3D::Cursor *)) &Urho3D::UIElement::OnDragCancel, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("dragButtons"), py::arg("cancelButton"), py::arg("cursor"))
.def("OnDragDropTest", (bool (Urho3D::UIElement::*)(Urho3D::UIElement *)) &Urho3D::UIElement::OnDragDropTest, "todo: docstring", py::arg("source"))
.def("OnDragDropFinish", (bool (Urho3D::UIElement::*)(Urho3D::UIElement *)) &Urho3D::UIElement::OnDragDropFinish, "todo: docstring", py::arg("source"))
//.def("OnWheel", (void (Urho3D::UIElement::*)(int, Urho3D::FlagSet<Urho3D::MouseButton, void>, Urho3D::FlagSet<Urho3D::Qualifier, void>)) &Urho3D::UIElement::OnWheel, "todo: docstring", py::arg("delta"), py::arg("buttons"), py::arg("qualifiers"))
//['int', 'Urho3D::FlagSet<Urho3D::MouseButton, void>', 'Urho3D::FlagSet<Urho3D::Qualifier, void>']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
//.def("OnKey", (void (Urho3D::UIElement::*)(Urho3D::Key, Urho3D::FlagSet<Urho3D::MouseButton, void>, Urho3D::FlagSet<Urho3D::Qualifier, void>)) &Urho3D::UIElement::OnKey, "todo: docstring", py::arg("key"), py::arg("buttons"), py::arg("qualifiers"))
//['Urho3D::Key', 'Urho3D::FlagSet<Urho3D::MouseButton, void>', 'Urho3D::FlagSet<Urho3D::Qualifier, void>']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
.def("OnTextInput", (void (Urho3D::UIElement::*)(const Urho3D::String &)) &Urho3D::UIElement::OnTextInput, "todo: docstring", py::arg("text"))
.def("OnResize", (void (Urho3D::UIElement::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &)) &Urho3D::UIElement::OnResize, "todo: docstring", py::arg("newSize"), py::arg("delta"))
.def("OnPositionSet", (void (Urho3D::UIElement::*)(const Urho3D::IntVector2 &)) &Urho3D::UIElement::OnPositionSet, "todo: docstring", py::arg("newPosition"))
.def("OnSetEditable", (void (Urho3D::UIElement::*)()) &Urho3D::UIElement::OnSetEditable, "todo: docstring")
.def("OnIndentSet", (void (Urho3D::UIElement::*)()) &Urho3D::UIElement::OnIndentSet, "todo: docstring")
.def("ScreenToElement", (Urho3D::IntVector2 (Urho3D::UIElement::*)(const Urho3D::IntVector2 &)) &Urho3D::UIElement::ScreenToElement, "todo: docstring", py::arg("screenPosition"))
.def("ElementToScreen", (Urho3D::IntVector2 (Urho3D::UIElement::*)(const Urho3D::IntVector2 &)) &Urho3D::UIElement::ElementToScreen, "todo: docstring", py::arg("position"))
.def("IsWheelHandler", (bool (Urho3D::UIElement::*)() const) &Urho3D::UIElement::IsWheelHandler, "todo: docstring")
.def("LoadXML", (bool (Urho3D::UIElement::*)(Urho3D::Deserializer &)) &Urho3D::UIElement::LoadXML, "todo: docstring", py::arg("source"))
.def("SaveXML", (bool (Urho3D::UIElement::*)(Urho3D::Serializer &, const Urho3D::String &) const) &Urho3D::UIElement::SaveXML, "todo: docstring", py::arg("dest"), py::arg("indentation")="\t")
.def("FilterAttributes", (bool (Urho3D::UIElement::*)(Urho3D::XMLElement &) const) &Urho3D::UIElement::FilterAttributes, "todo: docstring", py::arg("dest"))
.def("SetName", (void (Urho3D::UIElement::*)(const Urho3D::String &)) &Urho3D::UIElement::SetName, "todo: docstring", py::arg("name"))
.def("SetPosition", (void (Urho3D::UIElement::*)(const Urho3D::IntVector2 &)) &Urho3D::UIElement::SetPosition, "todo: docstring", py::arg("position"))
.def("SetPosition", (void (Urho3D::UIElement::*)(int, int)) &Urho3D::UIElement::SetPosition, "todo: docstring", py::arg("x"), py::arg("y"))
.def("SetSize", (void (Urho3D::UIElement::*)(const Urho3D::IntVector2 &)) &Urho3D::UIElement::SetSize, "todo: docstring", py::arg("size"))
.def("SetSize", (void (Urho3D::UIElement::*)(int, int)) &Urho3D::UIElement::SetSize, "todo: docstring", py::arg("width"), py::arg("height"))
.def("SetWidth", (void (Urho3D::UIElement::*)(int)) &Urho3D::UIElement::SetWidth, "todo: docstring", py::arg("width"))
.def("SetHeight", (void (Urho3D::UIElement::*)(int)) &Urho3D::UIElement::SetHeight, "todo: docstring", py::arg("height"))
.def("SetMinSize", (void (Urho3D::UIElement::*)(const Urho3D::IntVector2 &)) &Urho3D::UIElement::SetMinSize, "todo: docstring", py::arg("minSize"))
.def("SetMinSize", (void (Urho3D::UIElement::*)(int, int)) &Urho3D::UIElement::SetMinSize, "todo: docstring", py::arg("width"), py::arg("height"))
.def("SetMinWidth", (void (Urho3D::UIElement::*)(int)) &Urho3D::UIElement::SetMinWidth, "todo: docstring", py::arg("width"))
.def("SetMinHeight", (void (Urho3D::UIElement::*)(int)) &Urho3D::UIElement::SetMinHeight, "todo: docstring", py::arg("height"))
.def("SetMaxSize", (void (Urho3D::UIElement::*)(const Urho3D::IntVector2 &)) &Urho3D::UIElement::SetMaxSize, "todo: docstring", py::arg("maxSize"))
.def("SetMaxSize", (void (Urho3D::UIElement::*)(int, int)) &Urho3D::UIElement::SetMaxSize, "todo: docstring", py::arg("width"), py::arg("height"))
.def("SetMaxWidth", (void (Urho3D::UIElement::*)(int)) &Urho3D::UIElement::SetMaxWidth, "todo: docstring", py::arg("width"))
.def("SetMaxHeight", (void (Urho3D::UIElement::*)(int)) &Urho3D::UIElement::SetMaxHeight, "todo: docstring", py::arg("height"))
.def("SetFixedSize", (void (Urho3D::UIElement::*)(const Urho3D::IntVector2 &)) &Urho3D::UIElement::SetFixedSize, "todo: docstring", py::arg("size"))
.def("SetFixedSize", (void (Urho3D::UIElement::*)(int, int)) &Urho3D::UIElement::SetFixedSize, "todo: docstring", py::arg("width"), py::arg("height"))
.def("SetFixedWidth", (void (Urho3D::UIElement::*)(int)) &Urho3D::UIElement::SetFixedWidth, "todo: docstring", py::arg("width"))
.def("SetFixedHeight", (void (Urho3D::UIElement::*)(int)) &Urho3D::UIElement::SetFixedHeight, "todo: docstring", py::arg("height"))
.def("SetAlignment", (void (Urho3D::UIElement::*)(Urho3D::HorizontalAlignment, Urho3D::VerticalAlignment)) &Urho3D::UIElement::SetAlignment, "todo: docstring", py::arg("hAlign"), py::arg("vAlign"))
.def("SetHorizontalAlignment", (void (Urho3D::UIElement::*)(Urho3D::HorizontalAlignment)) &Urho3D::UIElement::SetHorizontalAlignment, "todo: docstring", py::arg("align"))
.def("SetVerticalAlignment", (void (Urho3D::UIElement::*)(Urho3D::VerticalAlignment)) &Urho3D::UIElement::SetVerticalAlignment, "todo: docstring", py::arg("align"))
.def("SetEnableAnchor", (void (Urho3D::UIElement::*)(bool)) &Urho3D::UIElement::SetEnableAnchor, "todo: docstring", py::arg("enable"))
.def("SetMinAnchor", (void (Urho3D::UIElement::*)(const Urho3D::Vector2 &)) &Urho3D::UIElement::SetMinAnchor, "todo: docstring", py::arg("anchor"))
.def("SetMinAnchor", (void (Urho3D::UIElement::*)(float, float)) &Urho3D::UIElement::SetMinAnchor, "todo: docstring", py::arg("x"), py::arg("y"))
.def("SetMaxAnchor", (void (Urho3D::UIElement::*)(const Urho3D::Vector2 &)) &Urho3D::UIElement::SetMaxAnchor, "todo: docstring", py::arg("anchor"))
.def("SetMaxAnchor", (void (Urho3D::UIElement::*)(float, float)) &Urho3D::UIElement::SetMaxAnchor, "todo: docstring", py::arg("x"), py::arg("y"))
.def("SetMinOffset", (void (Urho3D::UIElement::*)(const Urho3D::IntVector2 &)) &Urho3D::UIElement::SetMinOffset, "todo: docstring", py::arg("offset"))
.def("SetMaxOffset", (void (Urho3D::UIElement::*)(const Urho3D::IntVector2 &)) &Urho3D::UIElement::SetMaxOffset, "todo: docstring", py::arg("offset"))
.def("SetPivot", (void (Urho3D::UIElement::*)(const Urho3D::Vector2 &)) &Urho3D::UIElement::SetPivot, "todo: docstring", py::arg("pivot"))
.def("SetPivot", (void (Urho3D::UIElement::*)(float, float)) &Urho3D::UIElement::SetPivot, "todo: docstring", py::arg("x"), py::arg("y"))
.def("SetClipBorder", (void (Urho3D::UIElement::*)(const Urho3D::IntRect &)) &Urho3D::UIElement::SetClipBorder, "todo: docstring", py::arg("rect"))
.def("SetColor", (void (Urho3D::UIElement::*)(const Urho3D::Color &)) &Urho3D::UIElement::SetColor, "todo: docstring", py::arg("color"))
.def("SetColor", (void (Urho3D::UIElement::*)(Urho3D::Corner, const Urho3D::Color &)) &Urho3D::UIElement::SetColor, "todo: docstring", py::arg("corner"), py::arg("color"))
.def("SetPriority", (void (Urho3D::UIElement::*)(int)) &Urho3D::UIElement::SetPriority, "todo: docstring", py::arg("priority"))
.def("SetOpacity", (void (Urho3D::UIElement::*)(float)) &Urho3D::UIElement::SetOpacity, "todo: docstring", py::arg("opacity"))
.def("SetBringToFront", (void (Urho3D::UIElement::*)(bool)) &Urho3D::UIElement::SetBringToFront, "todo: docstring", py::arg("enable"))
.def("SetBringToBack", (void (Urho3D::UIElement::*)(bool)) &Urho3D::UIElement::SetBringToBack, "todo: docstring", py::arg("enable"))
.def("SetClipChildren", (void (Urho3D::UIElement::*)(bool)) &Urho3D::UIElement::SetClipChildren, "todo: docstring", py::arg("enable"))
.def("SetSortChildren", (void (Urho3D::UIElement::*)(bool)) &Urho3D::UIElement::SetSortChildren, "todo: docstring", py::arg("enable"))
.def("SetUseDerivedOpacity", (void (Urho3D::UIElement::*)(bool)) &Urho3D::UIElement::SetUseDerivedOpacity, "todo: docstring", py::arg("enable"))
.def("SetEnabled", (void (Urho3D::UIElement::*)(bool)) &Urho3D::UIElement::SetEnabled, "todo: docstring", py::arg("enable"))
.def("SetDeepEnabled", (void (Urho3D::UIElement::*)(bool)) &Urho3D::UIElement::SetDeepEnabled, "todo: docstring", py::arg("enable"))
.def("ResetDeepEnabled", (void (Urho3D::UIElement::*)()) &Urho3D::UIElement::ResetDeepEnabled, "todo: docstring")
.def("SetEnabledRecursive", (void (Urho3D::UIElement::*)(bool)) &Urho3D::UIElement::SetEnabledRecursive, "todo: docstring", py::arg("enable"))
.def("SetEditable", (void (Urho3D::UIElement::*)(bool)) &Urho3D::UIElement::SetEditable, "todo: docstring", py::arg("enable"))
.def("SetFocus", (void (Urho3D::UIElement::*)(bool)) &Urho3D::UIElement::SetFocus, "todo: docstring", py::arg("enable"))
.def("SetSelected", (void (Urho3D::UIElement::*)(bool)) &Urho3D::UIElement::SetSelected, "todo: docstring", py::arg("enable"))
.def("SetVisible", (void (Urho3D::UIElement::*)(bool)) &Urho3D::UIElement::SetVisible, "todo: docstring", py::arg("enable"))
.def("SetFocusMode", (void (Urho3D::UIElement::*)(Urho3D::FocusMode)) &Urho3D::UIElement::SetFocusMode, "todo: docstring", py::arg("mode"))
//.def("SetDragDropMode", (void (Urho3D::UIElement::*)(Urho3D::FlagSet<Urho3D::DragAndDropMode, void>)) &Urho3D::UIElement::SetDragDropMode, "todo: docstring", py::arg("mode"))
//['Urho3D::FlagSet<Urho3D::DragAndDropMode, void>']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
.def("SetStyle", (bool (Urho3D::UIElement::*)(const Urho3D::String &, Urho3D::XMLFile *)) &Urho3D::UIElement::SetStyle, "todo: docstring", py::arg("styleName"), py::arg("file")=nullptr)
.def("SetStyle", (bool (Urho3D::UIElement::*)(const Urho3D::XMLElement &)) &Urho3D::UIElement::SetStyle, "todo: docstring", py::arg("element"))
.def("SetStyleAuto", (bool (Urho3D::UIElement::*)(Urho3D::XMLFile *)) &Urho3D::UIElement::SetStyleAuto, "todo: docstring", py::arg("file")=nullptr)
.def("SetDefaultStyle", (void (Urho3D::UIElement::*)(Urho3D::XMLFile *)) &Urho3D::UIElement::SetDefaultStyle, "todo: docstring", py::arg("style"))
.def("SetLayout", (void (Urho3D::UIElement::*)(Urho3D::LayoutMode, int, const Urho3D::IntRect &)) &Urho3D::UIElement::SetLayout, "todo: docstring", py::arg("mode"), py::arg("spacing")=0, py::arg("border")=IntRect::ZERO)
.def("SetLayoutMode", (void (Urho3D::UIElement::*)(Urho3D::LayoutMode)) &Urho3D::UIElement::SetLayoutMode, "todo: docstring", py::arg("mode"))
.def("SetLayoutSpacing", (void (Urho3D::UIElement::*)(int)) &Urho3D::UIElement::SetLayoutSpacing, "todo: docstring", py::arg("spacing"))
.def("SetLayoutBorder", (void (Urho3D::UIElement::*)(const Urho3D::IntRect &)) &Urho3D::UIElement::SetLayoutBorder, "todo: docstring", py::arg("border"))
.def("SetLayoutFlexScale", (void (Urho3D::UIElement::*)(const Urho3D::Vector2 &)) &Urho3D::UIElement::SetLayoutFlexScale, "todo: docstring", py::arg("scale"))
.def("SetIndent", (void (Urho3D::UIElement::*)(int)) &Urho3D::UIElement::SetIndent, "todo: docstring", py::arg("indent"))
.def("SetIndentSpacing", (void (Urho3D::UIElement::*)(int)) &Urho3D::UIElement::SetIndentSpacing, "todo: docstring", py::arg("indentSpacing"))
.def("UpdateLayout", (void (Urho3D::UIElement::*)()) &Urho3D::UIElement::UpdateLayout, "todo: docstring")
.def("DisableLayoutUpdate", (void (Urho3D::UIElement::*)()) &Urho3D::UIElement::DisableLayoutUpdate, "todo: docstring")
.def("EnableLayoutUpdate", (void (Urho3D::UIElement::*)()) &Urho3D::UIElement::EnableLayoutUpdate, "todo: docstring")
.def("BringToFront", (void (Urho3D::UIElement::*)()) &Urho3D::UIElement::BringToFront, "todo: docstring")
.def("CreateChild", (Urho3D::UIElement * (Urho3D::UIElement::*)(Urho3D::StringHash, const Urho3D::String &, unsigned int)) &Urho3D::UIElement::CreateChild, "todo: docstring", py::arg("type"), py::arg("name")=String::EMPTY, py::arg("index")=M_MAX_UNSIGNED)
.def("AddChild", (void (Urho3D::UIElement::*)(Urho3D::UIElement *)) &Urho3D::UIElement::AddChild, "todo: docstring", py::arg("element"))
.def("InsertChild", (void (Urho3D::UIElement::*)(unsigned int, Urho3D::UIElement *)) &Urho3D::UIElement::InsertChild, "todo: docstring", py::arg("index"), py::arg("element"))
.def("RemoveChild", (void (Urho3D::UIElement::*)(Urho3D::UIElement *, unsigned int)) &Urho3D::UIElement::RemoveChild, "todo: docstring", py::arg("element"), py::arg("index")=0)
.def("RemoveChildAtIndex", (void (Urho3D::UIElement::*)(unsigned int)) &Urho3D::UIElement::RemoveChildAtIndex, "todo: docstring", py::arg("index"))
.def("RemoveAllChildren", (void (Urho3D::UIElement::*)()) &Urho3D::UIElement::RemoveAllChildren, "todo: docstring")
.def("Remove", (void (Urho3D::UIElement::*)()) &Urho3D::UIElement::Remove, "todo: docstring")
.def("FindChild", (unsigned int (Urho3D::UIElement::*)(Urho3D::UIElement *) const) &Urho3D::UIElement::FindChild, "todo: docstring", py::arg("element"))
.def("SetParent", (void (Urho3D::UIElement::*)(Urho3D::UIElement *, unsigned int)) &Urho3D::UIElement::SetParent, "todo: docstring", py::arg("parent"), py::arg("index")=M_MAX_UNSIGNED)
.def("SetVar", (void (Urho3D::UIElement::*)(Urho3D::StringHash, const Urho3D::Variant &)) &Urho3D::UIElement::SetVar, "todo: docstring", py::arg("key"), py::arg("value"))
.def("SetInternal", (void (Urho3D::UIElement::*)(bool)) &Urho3D::UIElement::SetInternal, "todo: docstring", py::arg("enable"))
.def("SetTraversalMode", (void (Urho3D::UIElement::*)(Urho3D::TraversalMode)) &Urho3D::UIElement::SetTraversalMode, "todo: docstring", py::arg("traversalMode"))
.def("SetElementEventSender", (void (Urho3D::UIElement::*)(bool)) &Urho3D::UIElement::SetElementEventSender, "todo: docstring", py::arg("flag"))
.def("SetBasePath", (void (Urho3D::UIElement::*)(const Urho3D::String &)) &Urho3D::UIElement::SetBasePath, "todo: docstring", py::arg("basePath"))
.def("SetTags", (void (Urho3D::UIElement::*)(const Urho3D::Vector<Urho3D::String> &)) &Urho3D::UIElement::SetTags, "todo: docstring", py::arg("tags"))
.def("AddTag", (void (Urho3D::UIElement::*)(const Urho3D::String &)) &Urho3D::UIElement::AddTag, "todo: docstring", py::arg("tag"))
.def("AddTags", (void (Urho3D::UIElement::*)(const Urho3D::String &, char)) &Urho3D::UIElement::AddTags, "todo: docstring", py::arg("tags"), py::arg("separator")=';')
.def("AddTags", (void (Urho3D::UIElement::*)(const Urho3D::Vector<Urho3D::String> &)) &Urho3D::UIElement::AddTags, "todo: docstring", py::arg("tags"))
.def("RemoveTag", (bool (Urho3D::UIElement::*)(const Urho3D::String &)) &Urho3D::UIElement::RemoveTag, "todo: docstring", py::arg("tag"))
.def("RemoveAllTags", (void (Urho3D::UIElement::*)()) &Urho3D::UIElement::RemoveAllTags, "todo: docstring")
.def("GetName", (const Urho3D::String & (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetName, "todo: docstring")
.def("GetPosition", (const Urho3D::IntVector2 & (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetPosition, "todo: docstring")
.def("GetSize", (const Urho3D::IntVector2 & (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetSize, "todo: docstring")
.def("GetWidth", (int (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetWidth, "todo: docstring")
.def("GetHeight", (int (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetHeight, "todo: docstring")
.def("GetMinSize", (const Urho3D::IntVector2 & (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetMinSize, "todo: docstring")
.def("GetMinWidth", (int (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetMinWidth, "todo: docstring")
.def("GetMinHeight", (int (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetMinHeight, "todo: docstring")
.def("GetMaxSize", (const Urho3D::IntVector2 & (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetMaxSize, "todo: docstring")
.def("GetMaxWidth", (int (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetMaxWidth, "todo: docstring")
.def("GetMaxHeight", (int (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetMaxHeight, "todo: docstring")
.def("IsFixedSize", (bool (Urho3D::UIElement::*)() const) &Urho3D::UIElement::IsFixedSize, "todo: docstring")
.def("IsFixedWidth", (bool (Urho3D::UIElement::*)() const) &Urho3D::UIElement::IsFixedWidth, "todo: docstring")
.def("IsFixedHeight", (bool (Urho3D::UIElement::*)() const) &Urho3D::UIElement::IsFixedHeight, "todo: docstring")
.def("GetChildOffset", (const Urho3D::IntVector2 & (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetChildOffset, "todo: docstring")
.def("GetHorizontalAlignment", (Urho3D::HorizontalAlignment (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetHorizontalAlignment, "todo: docstring")
.def("GetVerticalAlignment", (Urho3D::VerticalAlignment (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetVerticalAlignment, "todo: docstring")
.def("GetEnableAnchor", (bool (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetEnableAnchor, "todo: docstring")
.def("GetMinAnchor", (const Urho3D::Vector2 & (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetMinAnchor, "todo: docstring")
.def("GetMaxAnchor", (const Urho3D::Vector2 & (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetMaxAnchor, "todo: docstring")
.def("GetMinOffset", (const Urho3D::IntVector2 & (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetMinOffset, "todo: docstring")
.def("GetMaxOffset", (const Urho3D::IntVector2 & (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetMaxOffset, "todo: docstring")
.def("GetPivot", (const Urho3D::Vector2 & (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetPivot, "todo: docstring")
.def("GetClipBorder", (const Urho3D::IntRect & (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetClipBorder, "todo: docstring")
.def("GetColor", (const Urho3D::Color & (Urho3D::UIElement::*)(Urho3D::Corner) const) &Urho3D::UIElement::GetColor, "todo: docstring", py::arg("corner"))
.def("GetPriority", (int (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetPriority, "todo: docstring")
.def("GetOpacity", (float (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetOpacity, "todo: docstring")
.def("GetDerivedOpacity", (float (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetDerivedOpacity, "todo: docstring")
.def("GetBringToFront", (bool (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetBringToFront, "todo: docstring")
.def("GetBringToBack", (bool (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetBringToBack, "todo: docstring")
.def("GetClipChildren", (bool (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetClipChildren, "todo: docstring")
.def("GetSortChildren", (bool (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetSortChildren, "todo: docstring")
.def("GetUseDerivedOpacity", (bool (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetUseDerivedOpacity, "todo: docstring")
.def("HasFocus", (bool (Urho3D::UIElement::*)() const) &Urho3D::UIElement::HasFocus, "todo: docstring")
.def("IsChildOf", (bool (Urho3D::UIElement::*)(Urho3D::UIElement *) const) &Urho3D::UIElement::IsChildOf, "todo: docstring", py::arg("element"))
.def("IsEnabled", (bool (Urho3D::UIElement::*)() const) &Urho3D::UIElement::IsEnabled, "todo: docstring")
.def("IsEnabledSelf", (bool (Urho3D::UIElement::*)() const) &Urho3D::UIElement::IsEnabledSelf, "todo: docstring")
.def("IsEditable", (bool (Urho3D::UIElement::*)() const) &Urho3D::UIElement::IsEditable, "todo: docstring")
.def("IsSelected", (bool (Urho3D::UIElement::*)() const) &Urho3D::UIElement::IsSelected, "todo: docstring")
.def("IsVisible", (bool (Urho3D::UIElement::*)() const) &Urho3D::UIElement::IsVisible, "todo: docstring")
.def("IsVisibleEffective", (bool (Urho3D::UIElement::*)() const) &Urho3D::UIElement::IsVisibleEffective, "todo: docstring")
.def("IsHovering", (bool (Urho3D::UIElement::*)() const) &Urho3D::UIElement::IsHovering, "todo: docstring")
.def("IsInternal", (bool (Urho3D::UIElement::*)() const) &Urho3D::UIElement::IsInternal, "todo: docstring")
.def("HasColorGradient", (bool (Urho3D::UIElement::*)() const) &Urho3D::UIElement::HasColorGradient, "todo: docstring")
.def("GetFocusMode", (Urho3D::FocusMode (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetFocusMode, "todo: docstring")
//.def("GetDragDropMode", (Urho3D::DragAndDropModeFlags (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetDragDropMode, "todo: docstring")
//[]; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 0
.def("GetAppliedStyle", (const Urho3D::String & (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetAppliedStyle, "todo: docstring")
.def("GetDefaultStyle", (Urho3D::XMLFile * (Urho3D::UIElement::*)(bool) const) &Urho3D::UIElement::GetDefaultStyle, "todo: docstring", py::arg("recursiveUp")=true)
.def("GetLayoutMode", (Urho3D::LayoutMode (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetLayoutMode, "todo: docstring")
.def("GetLayoutSpacing", (int (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetLayoutSpacing, "todo: docstring")
.def("GetLayoutBorder", (const Urho3D::IntRect & (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetLayoutBorder, "todo: docstring")
.def("GetLayoutFlexScale", (const Urho3D::Vector2 & (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetLayoutFlexScale, "todo: docstring")
.def("GetNumChildren", (unsigned int (Urho3D::UIElement::*)(bool) const) &Urho3D::UIElement::GetNumChildren, "todo: docstring", py::arg("recursive")=false)
.def("GetChild", (Urho3D::UIElement * (Urho3D::UIElement::*)(unsigned int) const) &Urho3D::UIElement::GetChild, "todo: docstring", py::arg("index"))
.def("GetChild", (Urho3D::UIElement * (Urho3D::UIElement::*)(const Urho3D::String &, bool) const) &Urho3D::UIElement::GetChild, "todo: docstring", py::arg("name"), py::arg("recursive")=false)
.def("GetChild", (Urho3D::UIElement * (Urho3D::UIElement::*)(const Urho3D::StringHash &, const Urho3D::Variant &, bool) const) &Urho3D::UIElement::GetChild, "todo: docstring", py::arg("key"), py::arg("value")=Variant::EMPTY, py::arg("recursive")=false)
//.def("GetChildren", (const Vector<SharedPtr<Urho3D::UIElement> > & (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetChildren, "todo: docstring")
//[]; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 0
//.def("GetChildren", (void (Urho3D::UIElement::*)(Urho3D::PODVector<Urho3D::UIElement *> &, bool) const) &Urho3D::UIElement::GetChildren, "todo: docstring", py::arg("dest"), py::arg("recursive")=false)
//['Urho3D::PODVector<Urho3D::UIElement', 'bool']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 1
.def("GetParent", (Urho3D::UIElement * (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetParent, "todo: docstring")
.def("GetRoot", (Urho3D::UIElement * (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetRoot, "todo: docstring")
.def("GetDerivedColor", (const Urho3D::Color & (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetDerivedColor, "todo: docstring")
.def("GetVar", (const Urho3D::Variant & (Urho3D::UIElement::*)(const Urho3D::StringHash &) const) &Urho3D::UIElement::GetVar, "todo: docstring", py::arg("key"))
.def("GetVars", (const Urho3D::VariantMap & (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetVars, "todo: docstring")
.def("GetBasePath", (const Urho3D::String & (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetBasePath, "todo: docstring")
.def("HasTag", (bool (Urho3D::UIElement::*)(const Urho3D::String &) const) &Urho3D::UIElement::HasTag, "todo: docstring", py::arg("tag"))
.def("GetTags", (const Urho3D::StringVector & (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetTags, "todo: docstring")
//.def("GetChildrenWithTag", (void (Urho3D::UIElement::*)(Urho3D::PODVector<Urho3D::UIElement *> &, const Urho3D::String &, bool) const) &Urho3D::UIElement::GetChildrenWithTag, "todo: docstring", py::arg("dest"), py::arg("tag"), py::arg("recursive")=false)
//['Urho3D::PODVector<Urho3D::UIElement', 'Urho3D::String', 'bool']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 1
//.def("GetChildrenWithTag", (PODVector<Urho3D::UIElement *> (Urho3D::UIElement::*)(const Urho3D::String &, bool) const) &Urho3D::UIElement::GetChildrenWithTag, "todo: docstring", py::arg("tag"), py::arg("recursive")=false)
//['Urho3D::String', 'bool']; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 1
.def("GetDragButtonCombo", (int (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetDragButtonCombo, "todo: docstring")
.def("GetDragButtonCount", (unsigned int (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetDragButtonCount, "todo: docstring")
.def("IsInside", (bool (Urho3D::UIElement::*)(Urho3D::IntVector2, bool)) &Urho3D::UIElement::IsInside, "todo: docstring", py::arg("position"), py::arg("isScreen"))
.def("IsInsideCombined", (bool (Urho3D::UIElement::*)(Urho3D::IntVector2, bool)) &Urho3D::UIElement::IsInsideCombined, "todo: docstring", py::arg("position"), py::arg("isScreen"))
.def("GetCombinedScreenRect", (Urho3D::IntRect (Urho3D::UIElement::*)()) &Urho3D::UIElement::GetCombinedScreenRect, "todo: docstring")
.def("SortChildren", (void (Urho3D::UIElement::*)()) &Urho3D::UIElement::SortChildren, "todo: docstring")
.def("GetLayoutElementMaxSize", (int (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetLayoutElementMaxSize, "todo: docstring")
.def("GetIndent", (int (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetIndent, "todo: docstring")
.def("GetIndentSpacing", (int (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetIndentSpacing, "todo: docstring")
.def("GetIndentWidth", (int (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetIndentWidth, "todo: docstring")
.def("SetChildOffset", (void (Urho3D::UIElement::*)(const Urho3D::IntVector2 &)) &Urho3D::UIElement::SetChildOffset, "todo: docstring", py::arg("offset"))
.def("SetHovering", (void (Urho3D::UIElement::*)(bool)) &Urho3D::UIElement::SetHovering, "todo: docstring", py::arg("enable"))
.def("AdjustScissor", (void (Urho3D::UIElement::*)(Urho3D::IntRect &)) &Urho3D::UIElement::AdjustScissor, "todo: docstring", py::arg("currentScissor"))
//.def("GetBatchesWithOffset", (void (Urho3D::UIElement::*)(Urho3D::IntVector2 &, Urho3D::PODVector<Urho3D::UIBatch> &, Urho3D::PODVector<float> &, Urho3D::IntRect)) &Urho3D::UIElement::GetBatchesWithOffset, "todo: docstring", py::arg("offset"), py::arg("batches"), py::arg("vertexData"), py::arg("currentScissor"))
//['Urho3D::IntVector2', 'Urho3D::PODVector<Urho3D::UIBatch>', 'Urho3D::PODVector<float>', 'Urho3D::IntRect']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
.def("GetColorAttr", (const Urho3D::Color & (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetColorAttr, "todo: docstring")
.def("GetTraversalMode", (Urho3D::TraversalMode (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetTraversalMode, "todo: docstring")
.def("IsElementEventSender", (bool (Urho3D::UIElement::*)() const) &Urho3D::UIElement::IsElementEventSender, "todo: docstring")
.def("GetElementEventSender", (Urho3D::UIElement * (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetElementEventSender, "todo: docstring")
.def("GetEffectiveMinSize", (Urho3D::IntVector2 (Urho3D::UIElement::*)() const) &Urho3D::UIElement::GetEffectiveMinSize, "todo: docstring")
.def("SetRenderTexture", (void (Urho3D::UIElement::*)(Urho3D::Texture2D *)) &Urho3D::UIElement::SetRenderTexture, "todo: docstring", py::arg("texture"))
// Class Variables:
;
}
void Implement_Urho3D_BorderImage(py::class_<Urho3D::BorderImage, Urho3D::SharedPtr<Urho3D::BorderImage>, Urho3D::UIElement>& pyclass_Var_Urho3D_BorderImage)
{
// Class BorderImage Implementation
pyclass_Var_Urho3D_BorderImage
.def("GetType", (Urho3D::StringHash (Urho3D::BorderImage::*)() const) &Urho3D::BorderImage::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::BorderImage::*)() const) &Urho3D::BorderImage::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::BorderImage::*)() const) &Urho3D::BorderImage::GetTypeInfo, "todo: docstring")
.def(py::init<Urho3D::Context *>(), "todo: constructor docstring")
//.def("~BorderImage", (void (Urho3D::BorderImage::*)()) &Urho3D::BorderImage::~BorderImage, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
//.def("GetBatches", (void (Urho3D::BorderImage::*)(Urho3D::PODVector<Urho3D::UIBatch> &, Urho3D::PODVector<float> &, const Urho3D::IntRect &)) &Urho3D::BorderImage::GetBatches, "todo: docstring", py::arg("batches"), py::arg("vertexData"), py::arg("currentScissor"))
//['Urho3D::PODVector<Urho3D::UIBatch>', 'Urho3D::PODVector<float>', 'Urho3D::IntRect']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
.def("SetTexture", (void (Urho3D::BorderImage::*)(Urho3D::Texture *)) &Urho3D::BorderImage::SetTexture, "todo: docstring", py::arg("texture"))
.def("SetImageRect", (void (Urho3D::BorderImage::*)(const Urho3D::IntRect &)) &Urho3D::BorderImage::SetImageRect, "todo: docstring", py::arg("rect"))
.def("SetFullImageRect", (void (Urho3D::BorderImage::*)()) &Urho3D::BorderImage::SetFullImageRect, "todo: docstring")
.def("SetBorder", (void (Urho3D::BorderImage::*)(const Urho3D::IntRect &)) &Urho3D::BorderImage::SetBorder, "todo: docstring", py::arg("rect"))
.def("SetImageBorder", (void (Urho3D::BorderImage::*)(const Urho3D::IntRect &)) &Urho3D::BorderImage::SetImageBorder, "todo: docstring", py::arg("rect"))
.def("SetHoverOffset", (void (Urho3D::BorderImage::*)(const Urho3D::IntVector2 &)) &Urho3D::BorderImage::SetHoverOffset, "todo: docstring", py::arg("offset"))
.def("SetHoverOffset", (void (Urho3D::BorderImage::*)(int, int)) &Urho3D::BorderImage::SetHoverOffset, "todo: docstring", py::arg("x"), py::arg("y"))
.def("SetBlendMode", (void (Urho3D::BorderImage::*)(Urho3D::BlendMode)) &Urho3D::BorderImage::SetBlendMode, "todo: docstring", py::arg("mode"))
.def("SetTiled", (void (Urho3D::BorderImage::*)(bool)) &Urho3D::BorderImage::SetTiled, "todo: docstring", py::arg("enable"))
.def("SetMaterial", (void (Urho3D::BorderImage::*)(Urho3D::Material *)) &Urho3D::BorderImage::SetMaterial, "todo: docstring", py::arg("material"))
.def("GetTexture", (Urho3D::Texture * (Urho3D::BorderImage::*)() const) &Urho3D::BorderImage::GetTexture, "todo: docstring")
.def("GetImageRect", (const Urho3D::IntRect & (Urho3D::BorderImage::*)() const) &Urho3D::BorderImage::GetImageRect, "todo: docstring")
.def("GetBorder", (const Urho3D::IntRect & (Urho3D::BorderImage::*)() const) &Urho3D::BorderImage::GetBorder, "todo: docstring")
.def("GetImageBorder", (const Urho3D::IntRect & (Urho3D::BorderImage::*)() const) &Urho3D::BorderImage::GetImageBorder, "todo: docstring")
.def("GetHoverOffset", (const Urho3D::IntVector2 & (Urho3D::BorderImage::*)() const) &Urho3D::BorderImage::GetHoverOffset, "todo: docstring")
.def("GetBlendMode", (Urho3D::BlendMode (Urho3D::BorderImage::*)() const) &Urho3D::BorderImage::GetBlendMode, "todo: docstring")
.def("IsTiled", (bool (Urho3D::BorderImage::*)() const) &Urho3D::BorderImage::IsTiled, "todo: docstring")
.def("GetMaterial", (Urho3D::Material * (Urho3D::BorderImage::*)() const) &Urho3D::BorderImage::GetMaterial, "todo: docstring")
.def("SetTextureAttr", (void (Urho3D::BorderImage::*)(const Urho3D::ResourceRef &)) &Urho3D::BorderImage::SetTextureAttr, "todo: docstring", py::arg("value"))
.def("GetTextureAttr", (Urho3D::ResourceRef (Urho3D::BorderImage::*)() const) &Urho3D::BorderImage::GetTextureAttr, "todo: docstring")
.def("SetMaterialAttr", (void (Urho3D::BorderImage::*)(const Urho3D::ResourceRef &)) &Urho3D::BorderImage::SetMaterialAttr, "todo: docstring", py::arg("value"))
.def("GetMaterialAttr", (Urho3D::ResourceRef (Urho3D::BorderImage::*)() const) &Urho3D::BorderImage::GetMaterialAttr, "todo: docstring")
// Class Variables:
;
}
void Implement_Urho3D_Profiler(py::class_<Urho3D::Profiler, Urho3D::SharedPtr<Urho3D::Profiler>, Urho3D::Object>& pyclass_Var_Urho3D_Profiler)
{
// Class Profiler Implementation
pyclass_Var_Urho3D_Profiler
.def("GetType", (Urho3D::StringHash (Urho3D::Profiler::*)() const) &Urho3D::Profiler::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::Profiler::*)() const) &Urho3D::Profiler::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::Profiler::*)() const) &Urho3D::Profiler::GetTypeInfo, "todo: docstring")
.def(py::init<Urho3D::Context *>(), "todo: constructor docstring")
//.def("~Profiler", (void (Urho3D::Profiler::*)()) &Urho3D::Profiler::~Profiler, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("BeginBlock", (void (Urho3D::Profiler::*)(const char *)) &Urho3D::Profiler::BeginBlock, "todo: docstring", py::arg("name"))
.def("EndBlock", (void (Urho3D::Profiler::*)()) &Urho3D::Profiler::EndBlock, "todo: docstring")
.def("BeginFrame", (void (Urho3D::Profiler::*)()) &Urho3D::Profiler::BeginFrame, "todo: docstring")
.def("EndFrame", (void (Urho3D::Profiler::*)()) &Urho3D::Profiler::EndFrame, "todo: docstring")
.def("BeginInterval", (void (Urho3D::Profiler::*)()) &Urho3D::Profiler::BeginInterval, "todo: docstring")
.def("PrintData", (const Urho3D::String & (Urho3D::Profiler::*)(bool, bool, unsigned int) const) &Urho3D::Profiler::PrintData, "todo: docstring", py::arg("showUnused")=false, py::arg("showTotal")=false, py::arg("maxDepth")=M_MAX_UNSIGNED)
.def("GetCurrentBlock", (const Urho3D::ProfilerBlock * (Urho3D::Profiler::*)()) &Urho3D::Profiler::GetCurrentBlock, "todo: docstring")
.def("GetRootBlock", (const Urho3D::ProfilerBlock * (Urho3D::Profiler::*)()) &Urho3D::Profiler::GetRootBlock, "todo: docstring")
// Class Variables:
;
}
void Implement_Urho3D_Console(py::class_<Urho3D::Console, Urho3D::SharedPtr<Urho3D::Console>, Urho3D::Object>& pyclass_Var_Urho3D_Console)
{
// Class Console Implementation
pyclass_Var_Urho3D_Console
.def("GetType", (Urho3D::StringHash (Urho3D::Console::*)() const) &Urho3D::Console::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::Console::*)() const) &Urho3D::Console::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::Console::*)() const) &Urho3D::Console::GetTypeInfo, "todo: docstring")
.def(py::init<Urho3D::Context *>(), "todo: constructor docstring")
//.def("~Console", (void (Urho3D::Console::*)()) &Urho3D::Console::~Console, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("SetDefaultStyle", (void (Urho3D::Console::*)(Urho3D::XMLFile *)) &Urho3D::Console::SetDefaultStyle, "todo: docstring", py::arg("style"))
.def("SetVisible", (void (Urho3D::Console::*)(bool)) &Urho3D::Console::SetVisible, "todo: docstring", py::arg("enable"))
.def("Toggle", (void (Urho3D::Console::*)()) &Urho3D::Console::Toggle, "todo: docstring")
.def("SetAutoVisibleOnError", (void (Urho3D::Console::*)(bool)) &Urho3D::Console::SetAutoVisibleOnError, "todo: docstring", py::arg("enable"))
.def("SetCommandInterpreter", (void (Urho3D::Console::*)(const Urho3D::String &)) &Urho3D::Console::SetCommandInterpreter, "todo: docstring", py::arg("interpreter"))
.def("SetNumBufferedRows", (void (Urho3D::Console::*)(unsigned int)) &Urho3D::Console::SetNumBufferedRows, "todo: docstring", py::arg("rows"))
.def("SetNumRows", (void (Urho3D::Console::*)(unsigned int)) &Urho3D::Console::SetNumRows, "todo: docstring", py::arg("rows"))
.def("SetNumHistoryRows", (void (Urho3D::Console::*)(unsigned int)) &Urho3D::Console::SetNumHistoryRows, "todo: docstring", py::arg("rows"))
.def("SetFocusOnShow", (void (Urho3D::Console::*)(bool)) &Urho3D::Console::SetFocusOnShow, "todo: docstring", py::arg("enable"))
.def("AddAutoComplete", (void (Urho3D::Console::*)(const Urho3D::String &)) &Urho3D::Console::AddAutoComplete, "todo: docstring", py::arg("option"))
.def("RemoveAutoComplete", (void (Urho3D::Console::*)(const Urho3D::String &)) &Urho3D::Console::RemoveAutoComplete, "todo: docstring", py::arg("option"))
.def("UpdateElements", (void (Urho3D::Console::*)()) &Urho3D::Console::UpdateElements, "todo: docstring")
.def("GetDefaultStyle", (Urho3D::XMLFile * (Urho3D::Console::*)() const) &Urho3D::Console::GetDefaultStyle, "todo: docstring")
.def("GetBackground", (Urho3D::BorderImage * (Urho3D::Console::*)() const) &Urho3D::Console::GetBackground, "todo: docstring")
.def("GetLineEdit", (Urho3D::LineEdit * (Urho3D::Console::*)() const) &Urho3D::Console::GetLineEdit, "todo: docstring")
.def("GetCloseButton", (Urho3D::Button * (Urho3D::Console::*)() const) &Urho3D::Console::GetCloseButton, "todo: docstring")
.def("IsVisible", (bool (Urho3D::Console::*)() const) &Urho3D::Console::IsVisible, "todo: docstring")
.def("IsAutoVisibleOnError", (bool (Urho3D::Console::*)() const) &Urho3D::Console::IsAutoVisibleOnError, "todo: docstring")
.def("GetCommandInterpreter", (const Urho3D::String & (Urho3D::Console::*)() const) &Urho3D::Console::GetCommandInterpreter, "todo: docstring")
.def("GetNumBufferedRows", (unsigned int (Urho3D::Console::*)() const) &Urho3D::Console::GetNumBufferedRows, "todo: docstring")
.def("GetNumRows", (unsigned int (Urho3D::Console::*)() const) &Urho3D::Console::GetNumRows, "todo: docstring")
.def("CopySelectedRows", (void (Urho3D::Console::*)() const) &Urho3D::Console::CopySelectedRows, "todo: docstring")
.def("GetNumHistoryRows", (unsigned int (Urho3D::Console::*)() const) &Urho3D::Console::GetNumHistoryRows, "todo: docstring")
.def("GetHistoryPosition", (unsigned int (Urho3D::Console::*)() const) &Urho3D::Console::GetHistoryPosition, "todo: docstring")
.def("GetHistoryRow", (const Urho3D::String & (Urho3D::Console::*)(unsigned int) const) &Urho3D::Console::GetHistoryRow, "todo: docstring", py::arg("index"))
.def("GetFocusOnShow", (bool (Urho3D::Console::*)() const) &Urho3D::Console::GetFocusOnShow, "todo: docstring")
// Class Variables:
;
}
void Implement_Urho3D_Button(py::class_<Urho3D::Button, Urho3D::SharedPtr<Urho3D::Button>, Urho3D::BorderImage>& pyclass_Var_Urho3D_Button)
{
// Class Button Implementation
pyclass_Var_Urho3D_Button
.def("GetType", (Urho3D::StringHash (Urho3D::Button::*)() const) &Urho3D::Button::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::Button::*)() const) &Urho3D::Button::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::Button::*)() const) &Urho3D::Button::GetTypeInfo, "todo: docstring")
.def(py::init<Urho3D::Context *>(), "todo: constructor docstring")
//.def("~Button", (void (Urho3D::Button::*)()) &Urho3D::Button::~Button, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("Update", (void (Urho3D::Button::*)(float)) &Urho3D::Button::Update, "todo: docstring", py::arg("timeStep"))
//.def("GetBatches", (void (Urho3D::Button::*)(Urho3D::PODVector<Urho3D::UIBatch> &, Urho3D::PODVector<float> &, const Urho3D::IntRect &)) &Urho3D::Button::GetBatches, "todo: docstring", py::arg("batches"), py::arg("vertexData"), py::arg("currentScissor"))
//['Urho3D::PODVector<Urho3D::UIBatch>', 'Urho3D::PODVector<float>', 'Urho3D::IntRect']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
.def("OnClickBegin", (void (Urho3D::Button::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, int, Urho3D::Cursor *)) &Urho3D::Button::OnClickBegin, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("button"), py::arg("buttons"), py::arg("qualifiers"), py::arg("cursor"))
.def("OnClickEnd", (void (Urho3D::Button::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, int, Urho3D::Cursor *, Urho3D::UIElement *)) &Urho3D::Button::OnClickEnd, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("button"), py::arg("buttons"), py::arg("qualifiers"), py::arg("cursor"), py::arg("beginElement"))
.def("OnDragMove", (void (Urho3D::Button::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, Urho3D::Cursor *)) &Urho3D::Button::OnDragMove, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("deltaPos"), py::arg("buttons"), py::arg("qualifiers"), py::arg("cursor"))
//.def("OnKey", (void (Urho3D::Button::*)(Urho3D::Key, Urho3D::FlagSet<Urho3D::MouseButton, void>, Urho3D::FlagSet<Urho3D::Qualifier, void>)) &Urho3D::Button::OnKey, "todo: docstring", py::arg("key"), py::arg("buttons"), py::arg("qualifiers"))
//['Urho3D::Key', 'Urho3D::FlagSet<Urho3D::MouseButton, void>', 'Urho3D::FlagSet<Urho3D::Qualifier, void>']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
.def("SetPressedOffset", (void (Urho3D::Button::*)(const Urho3D::IntVector2 &)) &Urho3D::Button::SetPressedOffset, "todo: docstring", py::arg("offset"))
.def("SetPressedOffset", (void (Urho3D::Button::*)(int, int)) &Urho3D::Button::SetPressedOffset, "todo: docstring", py::arg("x"), py::arg("y"))
.def("SetDisabledOffset", (void (Urho3D::Button::*)(const Urho3D::IntVector2 &)) &Urho3D::Button::SetDisabledOffset, "todo: docstring", py::arg("offset"))
.def("SetDisabledOffset", (void (Urho3D::Button::*)(int, int)) &Urho3D::Button::SetDisabledOffset, "todo: docstring", py::arg("x"), py::arg("y"))
.def("SetPressedChildOffset", (void (Urho3D::Button::*)(const Urho3D::IntVector2 &)) &Urho3D::Button::SetPressedChildOffset, "todo: docstring", py::arg("offset"))
.def("SetPressedChildOffset", (void (Urho3D::Button::*)(int, int)) &Urho3D::Button::SetPressedChildOffset, "todo: docstring", py::arg("x"), py::arg("y"))
.def("SetRepeat", (void (Urho3D::Button::*)(float, float)) &Urho3D::Button::SetRepeat, "todo: docstring", py::arg("delay"), py::arg("rate"))
.def("SetRepeatDelay", (void (Urho3D::Button::*)(float)) &Urho3D::Button::SetRepeatDelay, "todo: docstring", py::arg("delay"))
.def("SetRepeatRate", (void (Urho3D::Button::*)(float)) &Urho3D::Button::SetRepeatRate, "todo: docstring", py::arg("rate"))
.def("GetPressedOffset", (const Urho3D::IntVector2 & (Urho3D::Button::*)() const) &Urho3D::Button::GetPressedOffset, "todo: docstring")
.def("GetDisabledOffset", (const Urho3D::IntVector2 & (Urho3D::Button::*)() const) &Urho3D::Button::GetDisabledOffset, "todo: docstring")
.def("GetPressedChildOffset", (const Urho3D::IntVector2 & (Urho3D::Button::*)() const) &Urho3D::Button::GetPressedChildOffset, "todo: docstring")
.def("GetRepeatDelay", (float (Urho3D::Button::*)() const) &Urho3D::Button::GetRepeatDelay, "todo: docstring")
.def("GetRepeatRate", (float (Urho3D::Button::*)() const) &Urho3D::Button::GetRepeatRate, "todo: docstring")
.def("IsPressed", (bool (Urho3D::Button::*)() const) &Urho3D::Button::IsPressed, "todo: docstring")
// Class Variables:
;
}
void Implement_Urho3D_LineEdit(py::class_<Urho3D::LineEdit, Urho3D::SharedPtr<Urho3D::LineEdit>, Urho3D::BorderImage>& pyclass_Var_Urho3D_LineEdit)
{
// Class LineEdit Implementation
pyclass_Var_Urho3D_LineEdit
.def("GetType", (Urho3D::StringHash (Urho3D::LineEdit::*)() const) &Urho3D::LineEdit::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::LineEdit::*)() const) &Urho3D::LineEdit::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::LineEdit::*)() const) &Urho3D::LineEdit::GetTypeInfo, "todo: docstring")
.def(py::init<Urho3D::Context *>(), "todo: constructor docstring")
//.def("~LineEdit", (void (Urho3D::LineEdit::*)()) &Urho3D::LineEdit::~LineEdit, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("ApplyAttributes", (void (Urho3D::LineEdit::*)()) &Urho3D::LineEdit::ApplyAttributes, "todo: docstring")
.def("Update", (void (Urho3D::LineEdit::*)(float)) &Urho3D::LineEdit::Update, "todo: docstring", py::arg("timeStep"))
.def("OnClickBegin", (void (Urho3D::LineEdit::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, int, Urho3D::Cursor *)) &Urho3D::LineEdit::OnClickBegin, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("button"), py::arg("buttons"), py::arg("qualifiers"), py::arg("cursor"))
.def("OnDoubleClick", (void (Urho3D::LineEdit::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, int, Urho3D::Cursor *)) &Urho3D::LineEdit::OnDoubleClick, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("button"), py::arg("buttons"), py::arg("qualifiers"), py::arg("cursor"))
.def("OnDragBegin", (void (Urho3D::LineEdit::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, Urho3D::Cursor *)) &Urho3D::LineEdit::OnDragBegin, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("buttons"), py::arg("qualifiers"), py::arg("cursor"))
.def("OnDragMove", (void (Urho3D::LineEdit::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, Urho3D::Cursor *)) &Urho3D::LineEdit::OnDragMove, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("deltaPos"), py::arg("buttons"), py::arg("qualifiers"), py::arg("cursor"))
.def("OnDragDropTest", (bool (Urho3D::LineEdit::*)(Urho3D::UIElement *)) &Urho3D::LineEdit::OnDragDropTest, "todo: docstring", py::arg("source"))
.def("OnDragDropFinish", (bool (Urho3D::LineEdit::*)(Urho3D::UIElement *)) &Urho3D::LineEdit::OnDragDropFinish, "todo: docstring", py::arg("source"))
//.def("OnKey", (void (Urho3D::LineEdit::*)(Urho3D::Key, Urho3D::FlagSet<Urho3D::MouseButton, void>, Urho3D::FlagSet<Urho3D::Qualifier, void>)) &Urho3D::LineEdit::OnKey, "todo: docstring", py::arg("key"), py::arg("buttons"), py::arg("qualifiers"))
//['Urho3D::Key', 'Urho3D::FlagSet<Urho3D::MouseButton, void>', 'Urho3D::FlagSet<Urho3D::Qualifier, void>']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
.def("OnTextInput", (void (Urho3D::LineEdit::*)(const Urho3D::String &)) &Urho3D::LineEdit::OnTextInput, "todo: docstring", py::arg("text"))
.def("SetText", (void (Urho3D::LineEdit::*)(const Urho3D::String &)) &Urho3D::LineEdit::SetText, "todo: docstring", py::arg("text"))
.def("SetCursorPosition", (void (Urho3D::LineEdit::*)(unsigned int)) &Urho3D::LineEdit::SetCursorPosition, "todo: docstring", py::arg("position"))
.def("SetCursorBlinkRate", (void (Urho3D::LineEdit::*)(float)) &Urho3D::LineEdit::SetCursorBlinkRate, "todo: docstring", py::arg("rate"))
.def("SetMaxLength", (void (Urho3D::LineEdit::*)(unsigned int)) &Urho3D::LineEdit::SetMaxLength, "todo: docstring", py::arg("length"))
.def("SetEchoCharacter", (void (Urho3D::LineEdit::*)(unsigned int)) &Urho3D::LineEdit::SetEchoCharacter, "todo: docstring", py::arg("c"))
.def("SetCursorMovable", (void (Urho3D::LineEdit::*)(bool)) &Urho3D::LineEdit::SetCursorMovable, "todo: docstring", py::arg("enable"))
.def("SetTextSelectable", (void (Urho3D::LineEdit::*)(bool)) &Urho3D::LineEdit::SetTextSelectable, "todo: docstring", py::arg("enable"))
.def("SetTextCopyable", (void (Urho3D::LineEdit::*)(bool)) &Urho3D::LineEdit::SetTextCopyable, "todo: docstring", py::arg("enable"))
.def("GetText", (const Urho3D::String & (Urho3D::LineEdit::*)() const) &Urho3D::LineEdit::GetText, "todo: docstring")
.def("GetCursorPosition", (unsigned int (Urho3D::LineEdit::*)() const) &Urho3D::LineEdit::GetCursorPosition, "todo: docstring")
.def("GetCursorBlinkRate", (float (Urho3D::LineEdit::*)() const) &Urho3D::LineEdit::GetCursorBlinkRate, "todo: docstring")
.def("GetMaxLength", (unsigned int (Urho3D::LineEdit::*)() const) &Urho3D::LineEdit::GetMaxLength, "todo: docstring")
.def("GetEchoCharacter", (unsigned int (Urho3D::LineEdit::*)() const) &Urho3D::LineEdit::GetEchoCharacter, "todo: docstring")
.def("IsCursorMovable", (bool (Urho3D::LineEdit::*)() const) &Urho3D::LineEdit::IsCursorMovable, "todo: docstring")
.def("IsTextSelectable", (bool (Urho3D::LineEdit::*)() const) &Urho3D::LineEdit::IsTextSelectable, "todo: docstring")
.def("IsTextCopyable", (bool (Urho3D::LineEdit::*)() const) &Urho3D::LineEdit::IsTextCopyable, "todo: docstring")
.def("GetTextElement", (Urho3D::Text * (Urho3D::LineEdit::*)() const) &Urho3D::LineEdit::GetTextElement, "todo: docstring")
.def("GetCursor", (Urho3D::BorderImage * (Urho3D::LineEdit::*)() const) &Urho3D::LineEdit::GetCursor, "todo: docstring")
// Class Variables:
;
}
void Implement_Urho3D_VertexBuffer(py::class_<Urho3D::VertexBuffer, Urho3D::SharedPtr<Urho3D::VertexBuffer>, Urho3D::Object, Urho3D::GPUObject>& pyclass_Var_Urho3D_VertexBuffer)
{
// Class VertexBuffer Implementation
pyclass_Var_Urho3D_VertexBuffer
.def("GetType", (Urho3D::StringHash (Urho3D::VertexBuffer::*)() const) &Urho3D::VertexBuffer::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::VertexBuffer::*)() const) &Urho3D::VertexBuffer::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::VertexBuffer::*)() const) &Urho3D::VertexBuffer::GetTypeInfo, "todo: docstring")
.def(py::init<Urho3D::Context *, bool>(), "todo: constructor docstring")
//.def("~VertexBuffer", (void (Urho3D::VertexBuffer::*)()) &Urho3D::VertexBuffer::~VertexBuffer, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("OnDeviceLost", (void (Urho3D::VertexBuffer::*)()) &Urho3D::VertexBuffer::OnDeviceLost, "todo: docstring")
.def("OnDeviceReset", (void (Urho3D::VertexBuffer::*)()) &Urho3D::VertexBuffer::OnDeviceReset, "todo: docstring")
.def("Release", (void (Urho3D::VertexBuffer::*)()) &Urho3D::VertexBuffer::Release, "todo: docstring")
.def("SetShadowed", (void (Urho3D::VertexBuffer::*)(bool)) &Urho3D::VertexBuffer::SetShadowed, "todo: docstring", py::arg("enable"))
//.def("SetSize", (bool (Urho3D::VertexBuffer::*)(unsigned int, const Urho3D::PODVector<Urho3D::VertexElement> &, bool)) &Urho3D::VertexBuffer::SetSize, "todo: docstring", py::arg("vertexCount"), py::arg("elements"), py::arg("dynamic")=false)
//['unsigned int', 'Urho3D::PODVector<Urho3D::VertexElement>', 'bool']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
.def("SetSize", (bool (Urho3D::VertexBuffer::*)(unsigned int, unsigned int, bool)) &Urho3D::VertexBuffer::SetSize, "todo: docstring", py::arg("vertexCount"), py::arg("elementMask"), py::arg("dynamic")=false)
.def("SetData", (bool (Urho3D::VertexBuffer::*)(const void *)) &Urho3D::VertexBuffer::SetData, "todo: docstring", py::arg("data"))
.def("SetDataRange", (bool (Urho3D::VertexBuffer::*)(const void *, unsigned int, unsigned int, bool)) &Urho3D::VertexBuffer::SetDataRange, "todo: docstring", py::arg("data"), py::arg("start"), py::arg("count"), py::arg("discard")=false)
.def("Lock", (void * (Urho3D::VertexBuffer::*)(unsigned int, unsigned int, bool)) &Urho3D::VertexBuffer::Lock, "todo: docstring", py::arg("start"), py::arg("count"), py::arg("discard")=false)
.def("Unlock", (void (Urho3D::VertexBuffer::*)()) &Urho3D::VertexBuffer::Unlock, "todo: docstring")
.def("IsShadowed", (bool (Urho3D::VertexBuffer::*)() const) &Urho3D::VertexBuffer::IsShadowed, "todo: docstring")
.def("IsDynamic", (bool (Urho3D::VertexBuffer::*)() const) &Urho3D::VertexBuffer::IsDynamic, "todo: docstring")
.def("IsLocked", (bool (Urho3D::VertexBuffer::*)() const) &Urho3D::VertexBuffer::IsLocked, "todo: docstring")
.def("GetVertexCount", (unsigned int (Urho3D::VertexBuffer::*)() const) &Urho3D::VertexBuffer::GetVertexCount, "todo: docstring")
.def("GetVertexSize", (unsigned int (Urho3D::VertexBuffer::*)() const) &Urho3D::VertexBuffer::GetVertexSize, "todo: docstring")
//.def("GetElements", (const PODVector<Urho3D::VertexElement> & (Urho3D::VertexBuffer::*)() const) &Urho3D::VertexBuffer::GetElements, "todo: docstring")
//[]; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 0
.def("GetElement", (const Urho3D::VertexElement * (Urho3D::VertexBuffer::*)(Urho3D::VertexElementSemantic, unsigned char) const) &Urho3D::VertexBuffer::GetElement, "todo: docstring", py::arg("semantic"), py::arg("index")=0)
.def("GetElement", (const Urho3D::VertexElement * (Urho3D::VertexBuffer::*)(Urho3D::VertexElementType, Urho3D::VertexElementSemantic, unsigned char) const) &Urho3D::VertexBuffer::GetElement, "todo: docstring", py::arg("type"), py::arg("semantic"), py::arg("index")=0)
.def("HasElement", (bool (Urho3D::VertexBuffer::*)(Urho3D::VertexElementSemantic, unsigned char) const) &Urho3D::VertexBuffer::HasElement, "todo: docstring", py::arg("semantic"), py::arg("index")=0)
.def("HasElement", (bool (Urho3D::VertexBuffer::*)(Urho3D::VertexElementType, Urho3D::VertexElementSemantic, unsigned char) const) &Urho3D::VertexBuffer::HasElement, "todo: docstring", py::arg("type"), py::arg("semantic"), py::arg("index")=0)
.def("GetElementOffset", (unsigned int (Urho3D::VertexBuffer::*)(Urho3D::VertexElementSemantic, unsigned char) const) &Urho3D::VertexBuffer::GetElementOffset, "todo: docstring", py::arg("semantic"), py::arg("index")=0)
.def("GetElementOffset", (unsigned int (Urho3D::VertexBuffer::*)(Urho3D::VertexElementType, Urho3D::VertexElementSemantic, unsigned char) const) &Urho3D::VertexBuffer::GetElementOffset, "todo: docstring", py::arg("type"), py::arg("semantic"), py::arg("index")=0)
//.def("GetElementMask", (Urho3D::VertexMaskFlags (Urho3D::VertexBuffer::*)() const) &Urho3D::VertexBuffer::GetElementMask, "todo: docstring")
//[]; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 0
.def("GetShadowData", (unsigned char * (Urho3D::VertexBuffer::*)() const) &Urho3D::VertexBuffer::GetShadowData, "todo: docstring")
//.def("GetShadowDataShared", (SharedArrayPtr<unsigned char> (Urho3D::VertexBuffer::*)() const) &Urho3D::VertexBuffer::GetShadowDataShared, "todo: docstring")
//[]; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 0
.def("GetBufferHash", (unsigned long long (Urho3D::VertexBuffer::*)(unsigned int)) &Urho3D::VertexBuffer::GetBufferHash, "todo: docstring", py::arg("streamIndex"))
// Class Variables:
;
}
void Implement_Urho3D_BoxOctreeQuery(py::class_<Urho3D::BoxOctreeQuery, Urho3D::ExternalPtr<Urho3D::BoxOctreeQuery>, Urho3D::OctreeQuery>& pyclass_Var_Urho3D_BoxOctreeQuery)
{
// Class BoxOctreeQuery Implementation
pyclass_Var_Urho3D_BoxOctreeQuery
//.def(py::init<Urho3D::PODVector<Urho3D::Drawable *> &, const Urho3D::BoundingBox &, unsigned char, unsigned int>(), "todo: constructor docstring")
//['Urho3D::PODVector<Urho3D::Drawable', 'Urho3D::BoundingBox', 'unsigned char', 'unsigned int']; op False, ctor True, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 1
.def("TestOctant", (Urho3D::Intersection (Urho3D::BoxOctreeQuery::*)(const Urho3D::BoundingBox &, bool)) &Urho3D::BoxOctreeQuery::TestOctant, "todo: docstring", py::arg("box"), py::arg("inside"))
//.def("TestDrawables", (void (Urho3D::BoxOctreeQuery::*)(Urho3D::Drawable **, Urho3D::Drawable **, bool)) &Urho3D::BoxOctreeQuery::TestDrawables, "todo: docstring", py::arg("start"), py::arg("end"), py::arg("inside"))
//['Urho3D::Drawable', 'Urho3D::Drawable', 'bool']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 2
// Class Variables:
.def_readwrite("box",&Urho3D::BoxOctreeQuery::box_, "todo: var docstring")//Urho3D::BoundingBox
;
}
void Implement_Urho3D_Viewport(py::class_<Urho3D::Viewport, Urho3D::SharedPtr<Urho3D::Viewport>, Urho3D::Object>& pyclass_Var_Urho3D_Viewport)
{
// Class Viewport Implementation
pyclass_Var_Urho3D_Viewport
.def("GetType", (Urho3D::StringHash (Urho3D::Viewport::*)() const) &Urho3D::Viewport::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::Viewport::*)() const) &Urho3D::Viewport::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::Viewport::*)() const) &Urho3D::Viewport::GetTypeInfo, "todo: docstring")
.def(py::init<Urho3D::Context *>(), "todo: constructor docstring")
.def(py::init<Urho3D::Context *, Urho3D::Scene *, Urho3D::Camera *, Urho3D::RenderPath *>(), "todo: constructor docstring")
.def(py::init<Urho3D::Context *, Urho3D::Scene *, Urho3D::Camera *, const Urho3D::IntRect &, Urho3D::RenderPath *>(), "todo: constructor docstring")
//.def("~Viewport", (void (Urho3D::Viewport::*)()) &Urho3D::Viewport::~Viewport, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("SetScene", (void (Urho3D::Viewport::*)(Urho3D::Scene *)) &Urho3D::Viewport::SetScene, "todo: docstring", py::arg("scene"))
.def("SetCamera", (void (Urho3D::Viewport::*)(Urho3D::Camera *)) &Urho3D::Viewport::SetCamera, "todo: docstring", py::arg("camera"))
.def("SetRect", (void (Urho3D::Viewport::*)(const Urho3D::IntRect &)) &Urho3D::Viewport::SetRect, "todo: docstring", py::arg("rect"))
.def("SetRenderPath", (void (Urho3D::Viewport::*)(Urho3D::RenderPath *)) &Urho3D::Viewport::SetRenderPath, "todo: docstring", py::arg("renderPath"))
.def("SetRenderPath", (void (Urho3D::Viewport::*)(Urho3D::XMLFile *)) &Urho3D::Viewport::SetRenderPath, "todo: docstring", py::arg("file"))
.def("SetDrawDebug", (void (Urho3D::Viewport::*)(bool)) &Urho3D::Viewport::SetDrawDebug, "todo: docstring", py::arg("enable"))
.def("SetCullCamera", (void (Urho3D::Viewport::*)(Urho3D::Camera *)) &Urho3D::Viewport::SetCullCamera, "todo: docstring", py::arg("camera"))
.def("GetScene", (Urho3D::Scene * (Urho3D::Viewport::*)() const) &Urho3D::Viewport::GetScene, "todo: docstring")
.def("GetCamera", (Urho3D::Camera * (Urho3D::Viewport::*)() const) &Urho3D::Viewport::GetCamera, "todo: docstring")
.def("GetView", (Urho3D::View * (Urho3D::Viewport::*)() const) &Urho3D::Viewport::GetView, "todo: docstring")
.def("GetRect", (const Urho3D::IntRect & (Urho3D::Viewport::*)() const) &Urho3D::Viewport::GetRect, "todo: docstring")
.def("GetRenderPath", (Urho3D::RenderPath * (Urho3D::Viewport::*)() const) &Urho3D::Viewport::GetRenderPath, "todo: docstring")
.def("GetDrawDebug", (bool (Urho3D::Viewport::*)() const) &Urho3D::Viewport::GetDrawDebug, "todo: docstring")
.def("GetCullCamera", (Urho3D::Camera * (Urho3D::Viewport::*)() const) &Urho3D::Viewport::GetCullCamera, "todo: docstring")
.def("GetScreenRay", (Urho3D::Ray (Urho3D::Viewport::*)(int, int) const) &Urho3D::Viewport::GetScreenRay, "todo: docstring", py::arg("x"), py::arg("y"))
.def("WorldToScreenPoint", (Urho3D::IntVector2 (Urho3D::Viewport::*)(const Urho3D::Vector3 &) const) &Urho3D::Viewport::WorldToScreenPoint, "todo: docstring", py::arg("worldPos"))
.def("ScreenToWorldPoint", (Urho3D::Vector3 (Urho3D::Viewport::*)(int, int, float) const) &Urho3D::Viewport::ScreenToWorldPoint, "todo: docstring", py::arg("x"), py::arg("y"), py::arg("depth"))
.def("AllocateView", (void (Urho3D::Viewport::*)()) &Urho3D::Viewport::AllocateView, "todo: docstring")
// Class Variables:
;
}
void Implement_Urho3D_FileWatcher(py::class_<Urho3D::FileWatcher, Urho3D::SharedPtr<Urho3D::FileWatcher>, Urho3D::Object, Urho3D::Thread>& pyclass_Var_Urho3D_FileWatcher)
{
// Class FileWatcher Implementation
pyclass_Var_Urho3D_FileWatcher
.def("GetType", (Urho3D::StringHash (Urho3D::FileWatcher::*)() const) &Urho3D::FileWatcher::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::FileWatcher::*)() const) &Urho3D::FileWatcher::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::FileWatcher::*)() const) &Urho3D::FileWatcher::GetTypeInfo, "todo: docstring")
.def(py::init<Urho3D::Context *>(), "todo: constructor docstring")
//.def("~FileWatcher", (void (Urho3D::FileWatcher::*)()) &Urho3D::FileWatcher::~FileWatcher, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("ThreadFunction", (void (Urho3D::FileWatcher::*)()) &Urho3D::FileWatcher::ThreadFunction, "todo: docstring")
.def("StartWatching", (bool (Urho3D::FileWatcher::*)(const Urho3D::String &, bool)) &Urho3D::FileWatcher::StartWatching, "todo: docstring", py::arg("pathName"), py::arg("watchSubDirs"))
.def("StopWatching", (void (Urho3D::FileWatcher::*)()) &Urho3D::FileWatcher::StopWatching, "todo: docstring")
.def("SetDelay", (void (Urho3D::FileWatcher::*)(float)) &Urho3D::FileWatcher::SetDelay, "todo: docstring", py::arg("interval"))
.def("AddChange", (void (Urho3D::FileWatcher::*)(const Urho3D::String &)) &Urho3D::FileWatcher::AddChange, "todo: docstring", py::arg("fileName"))
.def("GetNextChange", (bool (Urho3D::FileWatcher::*)(Urho3D::String &)) &Urho3D::FileWatcher::GetNextChange, "todo: docstring", py::arg("dest"))
.def("GetPath", (const Urho3D::String & (Urho3D::FileWatcher::*)() const) &Urho3D::FileWatcher::GetPath, "todo: docstring")
.def("GetDelay", (float (Urho3D::FileWatcher::*)() const) &Urho3D::FileWatcher::GetDelay, "todo: docstring")
// Class Variables:
;
}
void Implement_Urho3D_Input(py::class_<Urho3D::Input, Urho3D::SharedPtr<Urho3D::Input>, Urho3D::Object>& pyclass_Var_Urho3D_Input)
{
// Class Input Implementation
pyclass_Var_Urho3D_Input
.def("GetType", (Urho3D::StringHash (Urho3D::Input::*)() const) &Urho3D::Input::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::Input::*)() const) &Urho3D::Input::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::Input::*)() const) &Urho3D::Input::GetTypeInfo, "todo: docstring")
.def(py::init<Urho3D::Context *>(), "todo: constructor docstring")
//.def("~Input", (void (Urho3D::Input::*)()) &Urho3D::Input::~Input, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("Update", (void (Urho3D::Input::*)()) &Urho3D::Input::Update, "todo: docstring")
.def("SetToggleFullscreen", (void (Urho3D::Input::*)(bool)) &Urho3D::Input::SetToggleFullscreen, "todo: docstring", py::arg("enable"))
.def("SetMouseVisible", (void (Urho3D::Input::*)(bool, bool)) &Urho3D::Input::SetMouseVisible, "todo: docstring", py::arg("enable"), py::arg("suppressEvent")=false)
.def("ResetMouseVisible", (void (Urho3D::Input::*)()) &Urho3D::Input::ResetMouseVisible, "todo: docstring")
.def("SetMouseGrabbed", (void (Urho3D::Input::*)(bool, bool)) &Urho3D::Input::SetMouseGrabbed, "todo: docstring", py::arg("grab"), py::arg("suppressEvent")=false)
.def("ResetMouseGrabbed", (void (Urho3D::Input::*)()) &Urho3D::Input::ResetMouseGrabbed, "todo: docstring")
.def("SetMouseMode", (void (Urho3D::Input::*)(Urho3D::MouseMode, bool)) &Urho3D::Input::SetMouseMode, "todo: docstring", py::arg("mode"), py::arg("suppressEvent")=false)
.def("ResetMouseMode", (void (Urho3D::Input::*)()) &Urho3D::Input::ResetMouseMode, "todo: docstring")
//.def("AddScreenJoystick", (SDL_JoystickID (Urho3D::Input::*)()) &Urho3D::Input::AddScreenJoystick, "todo: docstring")
//[]; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 0
.def("RemoveScreenJoystick", (bool (Urho3D::Input::*)(int)) &Urho3D::Input::RemoveScreenJoystick, "todo: docstring", py::arg("id"))
.def("SetScreenJoystickVisible", (void (Urho3D::Input::*)(int, bool)) &Urho3D::Input::SetScreenJoystickVisible, "todo: docstring", py::arg("id"), py::arg("enable"))
.def("SetScreenKeyboardVisible", (void (Urho3D::Input::*)(bool)) &Urho3D::Input::SetScreenKeyboardVisible, "todo: docstring", py::arg("enable"))
.def("SetTouchEmulation", (void (Urho3D::Input::*)(bool)) &Urho3D::Input::SetTouchEmulation, "todo: docstring", py::arg("enable"))
.def("RecordGesture", (bool (Urho3D::Input::*)()) &Urho3D::Input::RecordGesture, "todo: docstring")
.def("SaveGestures", (bool (Urho3D::Input::*)(Urho3D::Serializer &)) &Urho3D::Input::SaveGestures, "todo: docstring", py::arg("dest"))
.def("SaveGesture", (bool (Urho3D::Input::*)(Urho3D::Serializer &, unsigned int)) &Urho3D::Input::SaveGesture, "todo: docstring", py::arg("dest"), py::arg("gestureID"))
.def("LoadGestures", (unsigned int (Urho3D::Input::*)(Urho3D::Deserializer &)) &Urho3D::Input::LoadGestures, "todo: docstring", py::arg("source"))
.def("RemoveGesture", (bool (Urho3D::Input::*)(unsigned int)) &Urho3D::Input::RemoveGesture, "todo: docstring", py::arg("gestureID"))
.def("RemoveAllGestures", (void (Urho3D::Input::*)()) &Urho3D::Input::RemoveAllGestures, "todo: docstring")
.def("SetMousePosition", (void (Urho3D::Input::*)(const Urho3D::IntVector2 &)) &Urho3D::Input::SetMousePosition, "todo: docstring", py::arg("position"))
.def("CenterMousePosition", (void (Urho3D::Input::*)()) &Urho3D::Input::CenterMousePosition, "todo: docstring")
.def("GetKeyFromName", (Urho3D::Key (Urho3D::Input::*)(const Urho3D::String &) const) &Urho3D::Input::GetKeyFromName, "todo: docstring", py::arg("name"))
.def("GetKeyFromScancode", (Urho3D::Key (Urho3D::Input::*)(Urho3D::Scancode) const) &Urho3D::Input::GetKeyFromScancode, "todo: docstring", py::arg("scancode"))
.def("GetKeyName", (Urho3D::String (Urho3D::Input::*)(Urho3D::Key) const) &Urho3D::Input::GetKeyName, "todo: docstring", py::arg("key"))
.def("GetScancodeFromKey", (Urho3D::Scancode (Urho3D::Input::*)(Urho3D::Key) const) &Urho3D::Input::GetScancodeFromKey, "todo: docstring", py::arg("key"))
.def("GetScancodeFromName", (Urho3D::Scancode (Urho3D::Input::*)(const Urho3D::String &) const) &Urho3D::Input::GetScancodeFromName, "todo: docstring", py::arg("name"))
.def("GetScancodeName", (Urho3D::String (Urho3D::Input::*)(Urho3D::Scancode) const) &Urho3D::Input::GetScancodeName, "todo: docstring", py::arg("scancode"))
.def("GetKeyDown", (bool (Urho3D::Input::*)(Urho3D::Key) const) &Urho3D::Input::GetKeyDown, "todo: docstring", py::arg("key"))
.def("GetKeyPress", (bool (Urho3D::Input::*)(Urho3D::Key) const) &Urho3D::Input::GetKeyPress, "todo: docstring", py::arg("key"))
.def("GetScancodeDown", (bool (Urho3D::Input::*)(Urho3D::Scancode) const) &Urho3D::Input::GetScancodeDown, "todo: docstring", py::arg("scancode"))
.def("GetScancodePress", (bool (Urho3D::Input::*)(Urho3D::Scancode) const) &Urho3D::Input::GetScancodePress, "todo: docstring", py::arg("scancode"))
//.def("GetMouseButtonDown", (bool (Urho3D::Input::*)(Urho3D::FlagSet<Urho3D::MouseButton, void>) const) &Urho3D::Input::GetMouseButtonDown, "todo: docstring", py::arg("button"))
//['Urho3D::FlagSet<Urho3D::MouseButton, void>']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
//.def("GetMouseButtonPress", (bool (Urho3D::Input::*)(Urho3D::FlagSet<Urho3D::MouseButton, void>) const) &Urho3D::Input::GetMouseButtonPress, "todo: docstring", py::arg("button"))
//['Urho3D::FlagSet<Urho3D::MouseButton, void>']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
.def("GetQualifierDown", (bool (Urho3D::Input::*)(Urho3D::Qualifier) const) &Urho3D::Input::GetQualifierDown, "todo: docstring", py::arg("qualifier"))
.def("GetQualifierPress", (bool (Urho3D::Input::*)(Urho3D::Qualifier) const) &Urho3D::Input::GetQualifierPress, "todo: docstring", py::arg("qualifier"))
//.def("GetQualifiers", (Urho3D::QualifierFlags (Urho3D::Input::*)() const) &Urho3D::Input::GetQualifiers, "todo: docstring")
//[]; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 0
.def("GetMousePosition", (Urho3D::IntVector2 (Urho3D::Input::*)() const) &Urho3D::Input::GetMousePosition, "todo: docstring")
.def("GetMouseMove", (Urho3D::IntVector2 (Urho3D::Input::*)() const) &Urho3D::Input::GetMouseMove, "todo: docstring")
.def("GetMouseMoveX", (int (Urho3D::Input::*)() const) &Urho3D::Input::GetMouseMoveX, "todo: docstring")
.def("GetMouseMoveY", (int (Urho3D::Input::*)() const) &Urho3D::Input::GetMouseMoveY, "todo: docstring")
.def("GetMouseMoveWheel", (int (Urho3D::Input::*)() const) &Urho3D::Input::GetMouseMoveWheel, "todo: docstring")
.def("GetInputScale", (Urho3D::Vector2 (Urho3D::Input::*)() const) &Urho3D::Input::GetInputScale, "todo: docstring")
.def("GetNumTouches", (unsigned int (Urho3D::Input::*)() const) &Urho3D::Input::GetNumTouches, "todo: docstring")
//.def("GetTouch", (Urho3D::TouchState * (Urho3D::Input::*)(unsigned int) const) &Urho3D::Input::GetTouch, "todo: docstring", py::arg("index"))
//['unsigned int']; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 1
.def("GetNumJoysticks", (unsigned int (Urho3D::Input::*)() const) &Urho3D::Input::GetNumJoysticks, "todo: docstring")
//.def("GetJoystick", (Urho3D::JoystickState * (Urho3D::Input::*)(int)) &Urho3D::Input::GetJoystick, "todo: docstring", py::arg("id"))
//['int']; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 1
//.def("GetJoystickByIndex", (Urho3D::JoystickState * (Urho3D::Input::*)(unsigned int)) &Urho3D::Input::GetJoystickByIndex, "todo: docstring", py::arg("index"))
//['unsigned int']; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 1
//.def("GetJoystickByName", (Urho3D::JoystickState * (Urho3D::Input::*)(const Urho3D::String &)) &Urho3D::Input::GetJoystickByName, "todo: docstring", py::arg("name"))
//['Urho3D::String']; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 1
.def("GetToggleFullscreen", (bool (Urho3D::Input::*)() const) &Urho3D::Input::GetToggleFullscreen, "todo: docstring")
.def("IsScreenJoystickVisible", (bool (Urho3D::Input::*)(int) const) &Urho3D::Input::IsScreenJoystickVisible, "todo: docstring", py::arg("id"))
.def("GetScreenKeyboardSupport", (bool (Urho3D::Input::*)() const) &Urho3D::Input::GetScreenKeyboardSupport, "todo: docstring")
.def("IsScreenKeyboardVisible", (bool (Urho3D::Input::*)() const) &Urho3D::Input::IsScreenKeyboardVisible, "todo: docstring")
.def("GetTouchEmulation", (bool (Urho3D::Input::*)() const) &Urho3D::Input::GetTouchEmulation, "todo: docstring")
.def("IsMouseVisible", (bool (Urho3D::Input::*)() const) &Urho3D::Input::IsMouseVisible, "todo: docstring")
.def("IsMouseGrabbed", (bool (Urho3D::Input::*)() const) &Urho3D::Input::IsMouseGrabbed, "todo: docstring")
.def("IsMouseLocked", (bool (Urho3D::Input::*)() const) &Urho3D::Input::IsMouseLocked, "todo: docstring")
.def("GetMouseMode", (Urho3D::MouseMode (Urho3D::Input::*)() const) &Urho3D::Input::GetMouseMode, "todo: docstring")
.def("HasFocus", (bool (Urho3D::Input::*)()) &Urho3D::Input::HasFocus, "todo: docstring")
.def("IsMinimized", (bool (Urho3D::Input::*)() const) &Urho3D::Input::IsMinimized, "todo: docstring")
// Class Variables:
;
}
void Implement_Urho3D_LuaScript(py::class_<Urho3D::LuaScript, Urho3D::SharedPtr<Urho3D::LuaScript>, Urho3D::Object, Urho3D::LuaScriptEventListener>& pyclass_Var_Urho3D_LuaScript)
{
// Class LuaScript Implementation
pyclass_Var_Urho3D_LuaScript
.def("GetType", (Urho3D::StringHash (Urho3D::LuaScript::*)() const) &Urho3D::LuaScript::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::LuaScript::*)() const) &Urho3D::LuaScript::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::LuaScript::*)() const) &Urho3D::LuaScript::GetTypeInfo, "todo: docstring")
.def(py::init<Urho3D::Context *>(), "todo: constructor docstring")
//.def("~LuaScript", (void (Urho3D::LuaScript::*)()) &Urho3D::LuaScript::~LuaScript, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("AddEventHandler", (void (Urho3D::LuaScript::*)(const Urho3D::String &, int)) &Urho3D::LuaScript::AddEventHandler, "todo: docstring", py::arg("eventName"), py::arg("index"))
.def("AddEventHandler", (void (Urho3D::LuaScript::*)(const Urho3D::String &, const Urho3D::String &)) &Urho3D::LuaScript::AddEventHandler, "todo: docstring", py::arg("eventName"), py::arg("functionName"))
.def("AddEventHandler", (void (Urho3D::LuaScript::*)(Urho3D::Object *, const Urho3D::String &, int)) &Urho3D::LuaScript::AddEventHandler, "todo: docstring", py::arg("sender"), py::arg("eventName"), py::arg("index"))
.def("AddEventHandler", (void (Urho3D::LuaScript::*)(Urho3D::Object *, const Urho3D::String &, const Urho3D::String &)) &Urho3D::LuaScript::AddEventHandler, "todo: docstring", py::arg("sender"), py::arg("eventName"), py::arg("functionName"))
.def("RemoveEventHandler", (void (Urho3D::LuaScript::*)(const Urho3D::String &)) &Urho3D::LuaScript::RemoveEventHandler, "todo: docstring", py::arg("eventName"))
.def("RemoveEventHandler", (void (Urho3D::LuaScript::*)(Urho3D::Object *, const Urho3D::String &)) &Urho3D::LuaScript::RemoveEventHandler, "todo: docstring", py::arg("sender"), py::arg("eventName"))
.def("RemoveEventHandlers", (void (Urho3D::LuaScript::*)(Urho3D::Object *)) &Urho3D::LuaScript::RemoveEventHandlers, "todo: docstring", py::arg("sender"))
.def("RemoveAllEventHandlers", (void (Urho3D::LuaScript::*)()) &Urho3D::LuaScript::RemoveAllEventHandlers, "todo: docstring")
.def("RemoveEventHandlersExcept", (void (Urho3D::LuaScript::*)(const Urho3D::Vector<Urho3D::String> &)) &Urho3D::LuaScript::RemoveEventHandlersExcept, "todo: docstring", py::arg("exceptionNames"))
.def("HasEventHandler", (bool (Urho3D::LuaScript::*)(const Urho3D::String &) const) &Urho3D::LuaScript::HasEventHandler, "todo: docstring", py::arg("eventName"))
.def("HasEventHandler", (bool (Urho3D::LuaScript::*)(Urho3D::Object *, const Urho3D::String &) const) &Urho3D::LuaScript::HasEventHandler, "todo: docstring", py::arg("sender"), py::arg("eventName"))
.def("ExecuteFile", (bool (Urho3D::LuaScript::*)(const Urho3D::String &)) &Urho3D::LuaScript::ExecuteFile, "todo: docstring", py::arg("fileName"))
.def("ExecuteString", (bool (Urho3D::LuaScript::*)(const Urho3D::String &)) &Urho3D::LuaScript::ExecuteString, "todo: docstring", py::arg("string"))
.def("LoadRawFile", (bool (Urho3D::LuaScript::*)(const Urho3D::String &)) &Urho3D::LuaScript::LoadRawFile, "todo: docstring", py::arg("fileName"))
.def("ExecuteRawFile", (bool (Urho3D::LuaScript::*)(const Urho3D::String &)) &Urho3D::LuaScript::ExecuteRawFile, "todo: docstring", py::arg("fileName"))
.def("ExecuteFunction", (bool (Urho3D::LuaScript::*)(const Urho3D::String &)) &Urho3D::LuaScript::ExecuteFunction, "todo: docstring", py::arg("functionName"))
.def("SetExecuteConsoleCommands", (void (Urho3D::LuaScript::*)(bool)) &Urho3D::LuaScript::SetExecuteConsoleCommands, "todo: docstring", py::arg("enable"))
//.def("GetState", (lua_State * (Urho3D::LuaScript::*)() const) &Urho3D::LuaScript::GetState, "todo: docstring")
//[]; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 1
.def("GetFunction", (Urho3D::LuaFunction * (Urho3D::LuaScript::*)(int)) &Urho3D::LuaScript::GetFunction, "todo: docstring", py::arg("index"))
.def("GetFunction", (Urho3D::LuaFunction * (Urho3D::LuaScript::*)(const Urho3D::String &, bool)) &Urho3D::LuaScript::GetFunction, "todo: docstring", py::arg("functionName"), py::arg("silentIfNotFound")=false)
.def("GetExecuteConsoleCommands", (bool (Urho3D::LuaScript::*)() const) &Urho3D::LuaScript::GetExecuteConsoleCommands, "todo: docstring")
// Class Variables:
;
}
void Implement_Urho3D_Matrix2(py::class_<Urho3D::Matrix2, Urho3D::ExternalPtr<Urho3D::Matrix2>>& pyclass_Var_Urho3D_Matrix2)
{
// Class Matrix2 Implementation
pyclass_Var_Urho3D_Matrix2
.def(py::init<>(), "todo: constructor docstring")
.def(py::init<const Urho3D::Matrix2 &>(), "todo: constructor docstring")
.def(py::init<float, float, float, float>(), "todo: constructor docstring")
.def(py::init<const float *>(), "todo: constructor docstring")
// .def(py::self = Urho3D::Matrix2(), "todo: docstring").def("__assign__", (Urho3D::Matrix2 & (Urho3D::Matrix2::*)(const Urho3D::Matrix2 &)) &Urho3D::Matrix2::operator=, py::operator, "todo: operator docstring. Switch to py: :self ops.")
//['Urho3D::Matrix2']; op =, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self == Urho3D::Matrix2(), "todo: docstring")
//['Urho3D::Matrix2']; op ==, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self != Urho3D::Matrix2(), "todo: docstring")
//['Urho3D::Matrix2']; op !=, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self * Urho3D::Vector2(), "todo: docstring")
//['Urho3D::Vector2']; op *, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self + Urho3D::Matrix2(), "todo: docstring")
//['Urho3D::Matrix2']; op +, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self - Urho3D::Matrix2(), "todo: docstring")
//['Urho3D::Matrix2']; op -, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self * float(), "todo: docstring")
//['float']; op *, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self * Urho3D::Matrix2(), "todo: docstring")
//['Urho3D::Matrix2']; op *, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("SetScale", (void (Urho3D::Matrix2::*)(const Urho3D::Vector2 &)) &Urho3D::Matrix2::SetScale, "todo: docstring", py::arg("scale"))
.def("SetScale", (void (Urho3D::Matrix2::*)(float)) &Urho3D::Matrix2::SetScale, "todo: docstring", py::arg("scale"))
.def("Scale", (Urho3D::Vector2 (Urho3D::Matrix2::*)() const) &Urho3D::Matrix2::Scale, "todo: docstring")
.def("Transpose", (Urho3D::Matrix2 (Urho3D::Matrix2::*)() const) &Urho3D::Matrix2::Transpose, "todo: docstring")
.def("Scaled", (Urho3D::Matrix2 (Urho3D::Matrix2::*)(const Urho3D::Vector2 &) const) &Urho3D::Matrix2::Scaled, "todo: docstring", py::arg("scale"))
.def("Equals", (bool (Urho3D::Matrix2::*)(const Urho3D::Matrix2 &) const) &Urho3D::Matrix2::Equals, "todo: docstring", py::arg("rhs"))
.def("Inverse", (Urho3D::Matrix2 (Urho3D::Matrix2::*)() const) &Urho3D::Matrix2::Inverse, "todo: docstring")
.def("Data", (const float * (Urho3D::Matrix2::*)() const) &Urho3D::Matrix2::Data, "todo: docstring")
.def("ToString", (Urho3D::String (Urho3D::Matrix2::*)() const) &Urho3D::Matrix2::ToString, "todo: docstring")
// External Operators:
.def(float() * py::self, "todo: docstring")
// Class Variables:
.def_readwrite("m00",&Urho3D::Matrix2::m00_, "todo: var docstring")//float
.def_readwrite("m01",&Urho3D::Matrix2::m01_, "todo: var docstring")//float
.def_readwrite("m10",&Urho3D::Matrix2::m10_, "todo: var docstring")//float
.def_readwrite("m11",&Urho3D::Matrix2::m11_, "todo: var docstring")//float
.def_readonly_static("ZERO",&Urho3D::Matrix2::ZERO, "todo: var docstring")//const Urho3D::Matrix2
.def_readonly_static("IDENTITY",&Urho3D::Matrix2::IDENTITY, "todo: var docstring")//const Urho3D::Matrix2
;
}
void Implement_Urho3D_Network(py::class_<Urho3D::Network, Urho3D::SharedPtr<Urho3D::Network>, Urho3D::Object>& pyclass_Var_Urho3D_Network)
{
// Class Network Implementation
pyclass_Var_Urho3D_Network
.def("GetType", (Urho3D::StringHash (Urho3D::Network::*)() const) &Urho3D::Network::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::Network::*)() const) &Urho3D::Network::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::Network::*)() const) &Urho3D::Network::GetTypeInfo, "todo: docstring")
.def(py::init<Urho3D::Context *>(), "todo: constructor docstring")
//.def("~Network", (void (Urho3D::Network::*)()) &Urho3D::Network::~Network, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
//.def("HandleMessage", (void (Urho3D::Network::*)(const SLNet::AddressOrGUID &, int, int, const char *, unsigned long)) &Urho3D::Network::HandleMessage, "todo: docstring", py::arg("source"), py::arg("packetID"), py::arg("msgID"), py::arg("data"), py::arg("numBytes"))
//['SLNet::AddressOrGUID', 'int', 'int', 'char', 'unsigned long']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 1
//.def("NewConnectionEstablished", (void (Urho3D::Network::*)(const SLNet::AddressOrGUID &)) &Urho3D::Network::NewConnectionEstablished, "todo: docstring", py::arg("connection"))
//['SLNet::AddressOrGUID']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
//.def("ClientDisconnected", (void (Urho3D::Network::*)(const SLNet::AddressOrGUID &)) &Urho3D::Network::ClientDisconnected, "todo: docstring", py::arg("connection"))
//['SLNet::AddressOrGUID']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
.def("SetDiscoveryBeacon", (void (Urho3D::Network::*)(const Urho3D::HashMap<Urho3D::StringHash, Urho3D::Variant> &)) &Urho3D::Network::SetDiscoveryBeacon, "todo: docstring", py::arg("data"))
.def("DiscoverHosts", (void (Urho3D::Network::*)(unsigned int)) &Urho3D::Network::DiscoverHosts, "todo: docstring", py::arg("port"))
.def("SetPassword", (void (Urho3D::Network::*)(const Urho3D::String &)) &Urho3D::Network::SetPassword, "todo: docstring", py::arg("password"))
.def("SetNATServerInfo", (void (Urho3D::Network::*)(const Urho3D::String &, unsigned short)) &Urho3D::Network::SetNATServerInfo, "todo: docstring", py::arg("address"), py::arg("port"))
.def("Connect", (bool (Urho3D::Network::*)(const Urho3D::String &, unsigned short, Urho3D::Scene *, const Urho3D::HashMap<Urho3D::StringHash, Urho3D::Variant> &)) &Urho3D::Network::Connect, "todo: docstring", py::arg("address"), py::arg("port"), py::arg("scene"), py::arg("identity")=Variant::emptyVariantMap)
.def("Disconnect", (void (Urho3D::Network::*)(int)) &Urho3D::Network::Disconnect, "todo: docstring", py::arg("waitMSec")=0)
.def("StartServer", (bool (Urho3D::Network::*)(unsigned short)) &Urho3D::Network::StartServer, "todo: docstring", py::arg("port"))
.def("StopServer", (void (Urho3D::Network::*)()) &Urho3D::Network::StopServer, "todo: docstring")
.def("StartNATClient", (void (Urho3D::Network::*)()) &Urho3D::Network::StartNATClient, "todo: docstring")
.def("GetGUID", (const Urho3D::String & (Urho3D::Network::*)() const) &Urho3D::Network::GetGUID, "todo: docstring")
.def("AttemptNATPunchtrough", (void (Urho3D::Network::*)(const Urho3D::String &, Urho3D::Scene *, const Urho3D::HashMap<Urho3D::StringHash, Urho3D::Variant> &)) &Urho3D::Network::AttemptNATPunchtrough, "todo: docstring", py::arg("guid"), py::arg("scene"), py::arg("identity")=Variant::emptyVariantMap)
.def("BroadcastMessage", (void (Urho3D::Network::*)(int, bool, bool, const Urho3D::VectorBuffer &, unsigned int)) &Urho3D::Network::BroadcastMessage, "todo: docstring", py::arg("msgID"), py::arg("reliable"), py::arg("inOrder"), py::arg("msg"), py::arg("contentID")=0)
.def("BroadcastMessage", (void (Urho3D::Network::*)(int, bool, bool, const unsigned char *, unsigned int, unsigned int)) &Urho3D::Network::BroadcastMessage, "todo: docstring", py::arg("msgID"), py::arg("reliable"), py::arg("inOrder"), py::arg("data"), py::arg("numBytes"), py::arg("contentID")=0)
.def("BroadcastRemoteEvent", (void (Urho3D::Network::*)(Urho3D::StringHash, bool, const Urho3D::HashMap<Urho3D::StringHash, Urho3D::Variant> &)) &Urho3D::Network::BroadcastRemoteEvent, "todo: docstring", py::arg("eventType"), py::arg("inOrder"), py::arg("eventData")=Variant::emptyVariantMap)
.def("BroadcastRemoteEvent", (void (Urho3D::Network::*)(Urho3D::Scene *, Urho3D::StringHash, bool, const Urho3D::HashMap<Urho3D::StringHash, Urho3D::Variant> &)) &Urho3D::Network::BroadcastRemoteEvent, "todo: docstring", py::arg("scene"), py::arg("eventType"), py::arg("inOrder"), py::arg("eventData")=Variant::emptyVariantMap)
.def("BroadcastRemoteEvent", (void (Urho3D::Network::*)(Urho3D::Node *, Urho3D::StringHash, bool, const Urho3D::HashMap<Urho3D::StringHash, Urho3D::Variant> &)) &Urho3D::Network::BroadcastRemoteEvent, "todo: docstring", py::arg("node"), py::arg("eventType"), py::arg("inOrder"), py::arg("eventData")=Variant::emptyVariantMap)
.def("SetUpdateFps", (void (Urho3D::Network::*)(int)) &Urho3D::Network::SetUpdateFps, "todo: docstring", py::arg("fps"))
.def("SetSimulatedLatency", (void (Urho3D::Network::*)(int)) &Urho3D::Network::SetSimulatedLatency, "todo: docstring", py::arg("ms"))
.def("SetSimulatedPacketLoss", (void (Urho3D::Network::*)(float)) &Urho3D::Network::SetSimulatedPacketLoss, "todo: docstring", py::arg("probability"))
.def("RegisterRemoteEvent", (void (Urho3D::Network::*)(Urho3D::StringHash)) &Urho3D::Network::RegisterRemoteEvent, "todo: docstring", py::arg("eventType"))
.def("UnregisterRemoteEvent", (void (Urho3D::Network::*)(Urho3D::StringHash)) &Urho3D::Network::UnregisterRemoteEvent, "todo: docstring", py::arg("eventType"))
.def("UnregisterAllRemoteEvents", (void (Urho3D::Network::*)()) &Urho3D::Network::UnregisterAllRemoteEvents, "todo: docstring")
.def("SetPackageCacheDir", (void (Urho3D::Network::*)(const Urho3D::String &)) &Urho3D::Network::SetPackageCacheDir, "todo: docstring", py::arg("path"))
.def("SendPackageToClients", (void (Urho3D::Network::*)(Urho3D::Scene *, Urho3D::PackageFile *)) &Urho3D::Network::SendPackageToClients, "todo: docstring", py::arg("scene"), py::arg("package"))
//.def("MakeHttpRequest", (SharedPtr<Urho3D::HttpRequest> (Urho3D::Network::*)(const Urho3D::String &, const Urho3D::String &, const Urho3D::Vector<Urho3D::String> &, const Urho3D::String &)) &Urho3D::Network::MakeHttpRequest, "todo: docstring", py::arg("url"), py::arg("verb")=String::EMPTY, py::arg("headers")=Vector<String>(), py::arg("postData")=String::EMPTY)
//['Urho3D::String', 'Urho3D::String', 'Urho3D::Vector<Urho3D::String>', 'Urho3D::String']; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 0
.def("BanAddress", (void (Urho3D::Network::*)(const Urho3D::String &)) &Urho3D::Network::BanAddress, "todo: docstring", py::arg("address"))
.def("GetUpdateFps", (int (Urho3D::Network::*)() const) &Urho3D::Network::GetUpdateFps, "todo: docstring")
.def("GetSimulatedLatency", (int (Urho3D::Network::*)() const) &Urho3D::Network::GetSimulatedLatency, "todo: docstring")
.def("GetSimulatedPacketLoss", (float (Urho3D::Network::*)() const) &Urho3D::Network::GetSimulatedPacketLoss, "todo: docstring")
//.def("GetConnection", (Urho3D::Connection * (Urho3D::Network::*)(const SLNet::AddressOrGUID &) const) &Urho3D::Network::GetConnection, "todo: docstring", py::arg("connection"))
//['SLNet::AddressOrGUID']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 1
.def("GetServerConnection", (Urho3D::Connection * (Urho3D::Network::*)() const) &Urho3D::Network::GetServerConnection, "todo: docstring")
//.def("GetClientConnections", (Vector<SharedPtr<Urho3D::Connection> > (Urho3D::Network::*)() const) &Urho3D::Network::GetClientConnections, "todo: docstring")
//[]; op False, ctor False, dtor False, variadic False, deleted False, ret bad True, param bad False, max ptr 0
.def("IsServerRunning", (bool (Urho3D::Network::*)() const) &Urho3D::Network::IsServerRunning, "todo: docstring")
.def("CheckRemoteEvent", (bool (Urho3D::Network::*)(Urho3D::StringHash) const) &Urho3D::Network::CheckRemoteEvent, "todo: docstring", py::arg("eventType"))
.def("GetPackageCacheDir", (const Urho3D::String & (Urho3D::Network::*)() const) &Urho3D::Network::GetPackageCacheDir, "todo: docstring")
.def("Update", (void (Urho3D::Network::*)(float)) &Urho3D::Network::Update, "todo: docstring", py::arg("timeStep"))
.def("PostUpdate", (void (Urho3D::Network::*)(float)) &Urho3D::Network::PostUpdate, "todo: docstring", py::arg("timeStep"))
// Class Variables:
;
}
void Implement_Urho3D_CheckBox(py::class_<Urho3D::CheckBox, Urho3D::SharedPtr<Urho3D::CheckBox>, Urho3D::BorderImage>& pyclass_Var_Urho3D_CheckBox)
{
// Class CheckBox Implementation
pyclass_Var_Urho3D_CheckBox
.def("GetType", (Urho3D::StringHash (Urho3D::CheckBox::*)() const) &Urho3D::CheckBox::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::CheckBox::*)() const) &Urho3D::CheckBox::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::CheckBox::*)() const) &Urho3D::CheckBox::GetTypeInfo, "todo: docstring")
.def(py::init<Urho3D::Context *>(), "todo: constructor docstring")
//.def("~CheckBox", (void (Urho3D::CheckBox::*)()) &Urho3D::CheckBox::~CheckBox, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
//.def("GetBatches", (void (Urho3D::CheckBox::*)(Urho3D::PODVector<Urho3D::UIBatch> &, Urho3D::PODVector<float> &, const Urho3D::IntRect &)) &Urho3D::CheckBox::GetBatches, "todo: docstring", py::arg("batches"), py::arg("vertexData"), py::arg("currentScissor"))
//['Urho3D::PODVector<Urho3D::UIBatch>', 'Urho3D::PODVector<float>', 'Urho3D::IntRect']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
.def("OnClickBegin", (void (Urho3D::CheckBox::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, int, Urho3D::Cursor *)) &Urho3D::CheckBox::OnClickBegin, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("button"), py::arg("buttons"), py::arg("qualifiers"), py::arg("cursor"))
//.def("OnKey", (void (Urho3D::CheckBox::*)(Urho3D::Key, Urho3D::FlagSet<Urho3D::MouseButton, void>, Urho3D::FlagSet<Urho3D::Qualifier, void>)) &Urho3D::CheckBox::OnKey, "todo: docstring", py::arg("key"), py::arg("buttons"), py::arg("qualifiers"))
//['Urho3D::Key', 'Urho3D::FlagSet<Urho3D::MouseButton, void>', 'Urho3D::FlagSet<Urho3D::Qualifier, void>']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
.def("SetChecked", (void (Urho3D::CheckBox::*)(bool)) &Urho3D::CheckBox::SetChecked, "todo: docstring", py::arg("enable"))
.def("SetCheckedOffset", (void (Urho3D::CheckBox::*)(const Urho3D::IntVector2 &)) &Urho3D::CheckBox::SetCheckedOffset, "todo: docstring", py::arg("offset"))
.def("SetCheckedOffset", (void (Urho3D::CheckBox::*)(int, int)) &Urho3D::CheckBox::SetCheckedOffset, "todo: docstring", py::arg("x"), py::arg("y"))
.def("IsChecked", (bool (Urho3D::CheckBox::*)() const) &Urho3D::CheckBox::IsChecked, "todo: docstring")
.def("GetCheckedOffset", (const Urho3D::IntVector2 & (Urho3D::CheckBox::*)() const) &Urho3D::CheckBox::GetCheckedOffset, "todo: docstring")
// Class Variables:
;
}
void Implement_Urho3D_Window(py::class_<Urho3D::Window, Urho3D::SharedPtr<Urho3D::Window>, Urho3D::BorderImage>& pyclass_Var_Urho3D_Window)
{
// Class Window Implementation
pyclass_Var_Urho3D_Window
.def("GetType", (Urho3D::StringHash (Urho3D::Window::*)() const) &Urho3D::Window::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::Window::*)() const) &Urho3D::Window::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::Window::*)() const) &Urho3D::Window::GetTypeInfo, "todo: docstring")
.def(py::init<Urho3D::Context *>(), "todo: constructor docstring")
//.def("~Window", (void (Urho3D::Window::*)()) &Urho3D::Window::~Window, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
//.def("GetBatches", (void (Urho3D::Window::*)(Urho3D::PODVector<Urho3D::UIBatch> &, Urho3D::PODVector<float> &, const Urho3D::IntRect &)) &Urho3D::Window::GetBatches, "todo: docstring", py::arg("batches"), py::arg("vertexData"), py::arg("currentScissor"))
//['Urho3D::PODVector<Urho3D::UIBatch>', 'Urho3D::PODVector<float>', 'Urho3D::IntRect']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
.def("OnHover", (void (Urho3D::Window::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, Urho3D::Cursor *)) &Urho3D::Window::OnHover, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("buttons"), py::arg("qualifiers"), py::arg("cursor"))
.def("OnDragBegin", (void (Urho3D::Window::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, Urho3D::Cursor *)) &Urho3D::Window::OnDragBegin, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("buttons"), py::arg("qualifiers"), py::arg("cursor"))
.def("OnDragMove", (void (Urho3D::Window::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, Urho3D::Cursor *)) &Urho3D::Window::OnDragMove, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("deltaPos"), py::arg("buttons"), py::arg("qualifiers"), py::arg("cursor"))
.def("OnDragEnd", (void (Urho3D::Window::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, Urho3D::Cursor *)) &Urho3D::Window::OnDragEnd, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("dragButtons"), py::arg("buttons"), py::arg("cursor"))
.def("OnDragCancel", (void (Urho3D::Window::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, Urho3D::Cursor *)) &Urho3D::Window::OnDragCancel, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("dragButtons"), py::arg("buttons"), py::arg("cursor"))
.def("SetMovable", (void (Urho3D::Window::*)(bool)) &Urho3D::Window::SetMovable, "todo: docstring", py::arg("enable"))
.def("SetResizable", (void (Urho3D::Window::*)(bool)) &Urho3D::Window::SetResizable, "todo: docstring", py::arg("enable"))
.def("SetFixedWidthResizing", (void (Urho3D::Window::*)(bool)) &Urho3D::Window::SetFixedWidthResizing, "todo: docstring", py::arg("enable"))
.def("SetFixedHeightResizing", (void (Urho3D::Window::*)(bool)) &Urho3D::Window::SetFixedHeightResizing, "todo: docstring", py::arg("enable"))
.def("SetResizeBorder", (void (Urho3D::Window::*)(const Urho3D::IntRect &)) &Urho3D::Window::SetResizeBorder, "todo: docstring", py::arg("rect"))
.def("SetModal", (void (Urho3D::Window::*)(bool)) &Urho3D::Window::SetModal, "todo: docstring", py::arg("modal"))
.def("SetModalShadeColor", (void (Urho3D::Window::*)(const Urho3D::Color &)) &Urho3D::Window::SetModalShadeColor, "todo: docstring", py::arg("color"))
.def("SetModalFrameColor", (void (Urho3D::Window::*)(const Urho3D::Color &)) &Urho3D::Window::SetModalFrameColor, "todo: docstring", py::arg("color"))
.def("SetModalFrameSize", (void (Urho3D::Window::*)(const Urho3D::IntVector2 &)) &Urho3D::Window::SetModalFrameSize, "todo: docstring", py::arg("size"))
.def("SetModalAutoDismiss", (void (Urho3D::Window::*)(bool)) &Urho3D::Window::SetModalAutoDismiss, "todo: docstring", py::arg("enable"))
.def("IsMovable", (bool (Urho3D::Window::*)() const) &Urho3D::Window::IsMovable, "todo: docstring")
.def("IsResizable", (bool (Urho3D::Window::*)() const) &Urho3D::Window::IsResizable, "todo: docstring")
.def("GetFixedWidthResizing", (bool (Urho3D::Window::*)() const) &Urho3D::Window::GetFixedWidthResizing, "todo: docstring")
.def("GetFixedHeightResizing", (bool (Urho3D::Window::*)() const) &Urho3D::Window::GetFixedHeightResizing, "todo: docstring")
.def("GetResizeBorder", (const Urho3D::IntRect & (Urho3D::Window::*)() const) &Urho3D::Window::GetResizeBorder, "todo: docstring")
.def("IsModal", (bool (Urho3D::Window::*)() const) &Urho3D::Window::IsModal, "todo: docstring")
.def("GetModalShadeColor", (const Urho3D::Color & (Urho3D::Window::*)() const) &Urho3D::Window::GetModalShadeColor, "todo: docstring")
.def("GetModalFrameColor", (const Urho3D::Color & (Urho3D::Window::*)() const) &Urho3D::Window::GetModalFrameColor, "todo: docstring")
.def("GetModalFrameSize", (const Urho3D::IntVector2 & (Urho3D::Window::*)() const) &Urho3D::Window::GetModalFrameSize, "todo: docstring")
.def("GetModalAutoDismiss", (bool (Urho3D::Window::*)() const) &Urho3D::Window::GetModalAutoDismiss, "todo: docstring")
// Class Variables:
;
}
void Implement_Urho3D_ScrollBar(py::class_<Urho3D::ScrollBar, Urho3D::SharedPtr<Urho3D::ScrollBar>, Urho3D::BorderImage>& pyclass_Var_Urho3D_ScrollBar)
{
// Class ScrollBar Implementation
pyclass_Var_Urho3D_ScrollBar
.def("GetType", (Urho3D::StringHash (Urho3D::ScrollBar::*)() const) &Urho3D::ScrollBar::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::ScrollBar::*)() const) &Urho3D::ScrollBar::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::ScrollBar::*)() const) &Urho3D::ScrollBar::GetTypeInfo, "todo: docstring")
.def(py::init<Urho3D::Context *>(), "todo: constructor docstring")
//.def("~ScrollBar", (void (Urho3D::ScrollBar::*)()) &Urho3D::ScrollBar::~ScrollBar, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("ApplyAttributes", (void (Urho3D::ScrollBar::*)()) &Urho3D::ScrollBar::ApplyAttributes, "todo: docstring")
.def("OnResize", (void (Urho3D::ScrollBar::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &)) &Urho3D::ScrollBar::OnResize, "todo: docstring", py::arg("newSize"), py::arg("delta"))
.def("OnSetEditable", (void (Urho3D::ScrollBar::*)()) &Urho3D::ScrollBar::OnSetEditable, "todo: docstring")
.def("SetOrientation", (void (Urho3D::ScrollBar::*)(Urho3D::Orientation)) &Urho3D::ScrollBar::SetOrientation, "todo: docstring", py::arg("orientation"))
.def("SetRange", (void (Urho3D::ScrollBar::*)(float)) &Urho3D::ScrollBar::SetRange, "todo: docstring", py::arg("range"))
.def("SetValue", (void (Urho3D::ScrollBar::*)(float)) &Urho3D::ScrollBar::SetValue, "todo: docstring", py::arg("value"))
.def("ChangeValue", (void (Urho3D::ScrollBar::*)(float)) &Urho3D::ScrollBar::ChangeValue, "todo: docstring", py::arg("delta"))
.def("SetScrollStep", (void (Urho3D::ScrollBar::*)(float)) &Urho3D::ScrollBar::SetScrollStep, "todo: docstring", py::arg("step"))
.def("SetStepFactor", (void (Urho3D::ScrollBar::*)(float)) &Urho3D::ScrollBar::SetStepFactor, "todo: docstring", py::arg("factor"))
.def("StepBack", (void (Urho3D::ScrollBar::*)()) &Urho3D::ScrollBar::StepBack, "todo: docstring")
.def("StepForward", (void (Urho3D::ScrollBar::*)()) &Urho3D::ScrollBar::StepForward, "todo: docstring")
.def("GetOrientation", (Urho3D::Orientation (Urho3D::ScrollBar::*)() const) &Urho3D::ScrollBar::GetOrientation, "todo: docstring")
.def("GetRange", (float (Urho3D::ScrollBar::*)() const) &Urho3D::ScrollBar::GetRange, "todo: docstring")
.def("GetValue", (float (Urho3D::ScrollBar::*)() const) &Urho3D::ScrollBar::GetValue, "todo: docstring")
.def("GetScrollStep", (float (Urho3D::ScrollBar::*)() const) &Urho3D::ScrollBar::GetScrollStep, "todo: docstring")
.def("GetStepFactor", (float (Urho3D::ScrollBar::*)() const) &Urho3D::ScrollBar::GetStepFactor, "todo: docstring")
.def("GetEffectiveScrollStep", (float (Urho3D::ScrollBar::*)() const) &Urho3D::ScrollBar::GetEffectiveScrollStep, "todo: docstring")
.def("GetBackButton", (Urho3D::Button * (Urho3D::ScrollBar::*)() const) &Urho3D::ScrollBar::GetBackButton, "todo: docstring")
.def("GetForwardButton", (Urho3D::Button * (Urho3D::ScrollBar::*)() const) &Urho3D::ScrollBar::GetForwardButton, "todo: docstring")
.def("GetSlider", (Urho3D::Slider * (Urho3D::ScrollBar::*)() const) &Urho3D::ScrollBar::GetSlider, "todo: docstring")
// Class Variables:
;
}
void Implement_Urho3D_UISelectable(py::class_<Urho3D::UISelectable, Urho3D::SharedPtr<Urho3D::UISelectable>, Urho3D::UIElement>& pyclass_Var_Urho3D_UISelectable)
{
// Class UISelectable Implementation
pyclass_Var_Urho3D_UISelectable
.def("GetType", (Urho3D::StringHash (Urho3D::UISelectable::*)() const) &Urho3D::UISelectable::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::UISelectable::*)() const) &Urho3D::UISelectable::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::UISelectable::*)() const) &Urho3D::UISelectable::GetTypeInfo, "todo: docstring")
//.def("~UISelectable", (void (Urho3D::UISelectable::*)()) &Urho3D::UISelectable::~UISelectable, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
//.def("GetBatches", (void (Urho3D::UISelectable::*)(Urho3D::PODVector<Urho3D::UIBatch> &, Urho3D::PODVector<float> &, const Urho3D::IntRect &)) &Urho3D::UISelectable::GetBatches, "todo: docstring", py::arg("batches"), py::arg("vertexData"), py::arg("currentScissor"))
//['Urho3D::PODVector<Urho3D::UIBatch>', 'Urho3D::PODVector<float>', 'Urho3D::IntRect']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
.def("SetSelectionColor", (void (Urho3D::UISelectable::*)(const Urho3D::Color &)) &Urho3D::UISelectable::SetSelectionColor, "todo: docstring", py::arg("color"))
.def("SetHoverColor", (void (Urho3D::UISelectable::*)(const Urho3D::Color &)) &Urho3D::UISelectable::SetHoverColor, "todo: docstring", py::arg("color"))
.def("GetSelectionColor", (const Urho3D::Color & (Urho3D::UISelectable::*)() const) &Urho3D::UISelectable::GetSelectionColor, "todo: docstring")
.def("GetHoverColor", (const Urho3D::Color & (Urho3D::UISelectable::*)() const) &Urho3D::UISelectable::GetHoverColor, "todo: docstring")
// Class Variables:
;
}
void Implement_Urho3D_Slider(py::class_<Urho3D::Slider, Urho3D::SharedPtr<Urho3D::Slider>, Urho3D::BorderImage>& pyclass_Var_Urho3D_Slider)
{
// Class Slider Implementation
pyclass_Var_Urho3D_Slider
.def("GetType", (Urho3D::StringHash (Urho3D::Slider::*)() const) &Urho3D::Slider::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::Slider::*)() const) &Urho3D::Slider::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::Slider::*)() const) &Urho3D::Slider::GetTypeInfo, "todo: docstring")
.def(py::init<Urho3D::Context *>(), "todo: constructor docstring")
//.def("~Slider", (void (Urho3D::Slider::*)()) &Urho3D::Slider::~Slider, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("Update", (void (Urho3D::Slider::*)(float)) &Urho3D::Slider::Update, "todo: docstring", py::arg("timeStep"))
.def("OnHover", (void (Urho3D::Slider::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, Urho3D::Cursor *)) &Urho3D::Slider::OnHover, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("buttons"), py::arg("qualifiers"), py::arg("cursor"))
.def("OnClickBegin", (void (Urho3D::Slider::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, int, Urho3D::Cursor *)) &Urho3D::Slider::OnClickBegin, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("button"), py::arg("buttons"), py::arg("qualifiers"), py::arg("cursor"))
.def("OnClickEnd", (void (Urho3D::Slider::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, int, Urho3D::Cursor *, Urho3D::UIElement *)) &Urho3D::Slider::OnClickEnd, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("button"), py::arg("buttons"), py::arg("qualifiers"), py::arg("cursor"), py::arg("beginElement"))
.def("OnDragBegin", (void (Urho3D::Slider::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, Urho3D::Cursor *)) &Urho3D::Slider::OnDragBegin, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("buttons"), py::arg("qualifiers"), py::arg("cursor"))
.def("OnDragMove", (void (Urho3D::Slider::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, Urho3D::Cursor *)) &Urho3D::Slider::OnDragMove, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("deltaPos"), py::arg("buttons"), py::arg("qualifiers"), py::arg("cursor"))
.def("OnDragEnd", (void (Urho3D::Slider::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &, int, int, Urho3D::Cursor *)) &Urho3D::Slider::OnDragEnd, "todo: docstring", py::arg("position"), py::arg("screenPosition"), py::arg("dragButtons"), py::arg("buttons"), py::arg("cursor"))
.def("OnResize", (void (Urho3D::Slider::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &)) &Urho3D::Slider::OnResize, "todo: docstring", py::arg("newSize"), py::arg("delta"))
.def("SetOrientation", (void (Urho3D::Slider::*)(Urho3D::Orientation)) &Urho3D::Slider::SetOrientation, "todo: docstring", py::arg("orientation"))
.def("SetRange", (void (Urho3D::Slider::*)(float)) &Urho3D::Slider::SetRange, "todo: docstring", py::arg("range"))
.def("SetValue", (void (Urho3D::Slider::*)(float)) &Urho3D::Slider::SetValue, "todo: docstring", py::arg("value"))
.def("ChangeValue", (void (Urho3D::Slider::*)(float)) &Urho3D::Slider::ChangeValue, "todo: docstring", py::arg("delta"))
.def("SetRepeatRate", (void (Urho3D::Slider::*)(float)) &Urho3D::Slider::SetRepeatRate, "todo: docstring", py::arg("rate"))
.def("GetOrientation", (Urho3D::Orientation (Urho3D::Slider::*)() const) &Urho3D::Slider::GetOrientation, "todo: docstring")
.def("GetRange", (float (Urho3D::Slider::*)() const) &Urho3D::Slider::GetRange, "todo: docstring")
.def("GetValue", (float (Urho3D::Slider::*)() const) &Urho3D::Slider::GetValue, "todo: docstring")
.def("GetKnob", (Urho3D::BorderImage * (Urho3D::Slider::*)() const) &Urho3D::Slider::GetKnob, "todo: docstring")
.def("GetRepeatRate", (float (Urho3D::Slider::*)() const) &Urho3D::Slider::GetRepeatRate, "todo: docstring")
// Class Variables:
;
}
void Implement_Urho3D_ToolTip(py::class_<Urho3D::ToolTip, Urho3D::SharedPtr<Urho3D::ToolTip>, Urho3D::UIElement>& pyclass_Var_Urho3D_ToolTip)
{
// Class ToolTip Implementation
pyclass_Var_Urho3D_ToolTip
.def("GetType", (Urho3D::StringHash (Urho3D::ToolTip::*)() const) &Urho3D::ToolTip::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::ToolTip::*)() const) &Urho3D::ToolTip::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::ToolTip::*)() const) &Urho3D::ToolTip::GetTypeInfo, "todo: docstring")
.def(py::init<Urho3D::Context *>(), "todo: constructor docstring")
//.def("~ToolTip", (void (Urho3D::ToolTip::*)()) &Urho3D::ToolTip::~ToolTip, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("Update", (void (Urho3D::ToolTip::*)(float)) &Urho3D::ToolTip::Update, "todo: docstring", py::arg("timeStep"))
.def("Reset", (void (Urho3D::ToolTip::*)()) &Urho3D::ToolTip::Reset, "todo: docstring")
.def("AddAltTarget", (void (Urho3D::ToolTip::*)(Urho3D::UIElement *)) &Urho3D::ToolTip::AddAltTarget, "todo: docstring", py::arg("target"))
.def("SetDelay", (void (Urho3D::ToolTip::*)(float)) &Urho3D::ToolTip::SetDelay, "todo: docstring", py::arg("delay"))
.def("GetDelay", (float (Urho3D::ToolTip::*)() const) &Urho3D::ToolTip::GetDelay, "todo: docstring")
// Class Variables:
;
}
void Implement_Urho3D_View3D(py::class_<Urho3D::View3D, Urho3D::SharedPtr<Urho3D::View3D>, Urho3D::Window>& pyclass_Var_Urho3D_View3D)
{
// Class View3D Implementation
pyclass_Var_Urho3D_View3D
.def("GetType", (Urho3D::StringHash (Urho3D::View3D::*)() const) &Urho3D::View3D::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::View3D::*)() const) &Urho3D::View3D::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::View3D::*)() const) &Urho3D::View3D::GetTypeInfo, "todo: docstring")
.def(py::init<Urho3D::Context *>(), "todo: constructor docstring")
//.def("~View3D", (void (Urho3D::View3D::*)()) &Urho3D::View3D::~View3D, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("OnResize", (void (Urho3D::View3D::*)(const Urho3D::IntVector2 &, const Urho3D::IntVector2 &)) &Urho3D::View3D::OnResize, "todo: docstring", py::arg("newSize"), py::arg("delta"))
.def("SetView", (void (Urho3D::View3D::*)(Urho3D::Scene *, Urho3D::Camera *, bool)) &Urho3D::View3D::SetView, "todo: docstring", py::arg("scene"), py::arg("camera"), py::arg("ownScene")=true)
.def("SetFormat", (void (Urho3D::View3D::*)(unsigned int)) &Urho3D::View3D::SetFormat, "todo: docstring", py::arg("format"))
.def("SetAutoUpdate", (void (Urho3D::View3D::*)(bool)) &Urho3D::View3D::SetAutoUpdate, "todo: docstring", py::arg("enable"))
.def("QueueUpdate", (void (Urho3D::View3D::*)()) &Urho3D::View3D::QueueUpdate, "todo: docstring")
.def("GetFormat", (unsigned int (Urho3D::View3D::*)() const) &Urho3D::View3D::GetFormat, "todo: docstring")
.def("GetAutoUpdate", (bool (Urho3D::View3D::*)() const) &Urho3D::View3D::GetAutoUpdate, "todo: docstring")
.def("GetScene", (Urho3D::Scene * (Urho3D::View3D::*)() const) &Urho3D::View3D::GetScene, "todo: docstring")
.def("GetCameraNode", (Urho3D::Node * (Urho3D::View3D::*)() const) &Urho3D::View3D::GetCameraNode, "todo: docstring")
.def("GetRenderTexture", (Urho3D::Texture2D * (Urho3D::View3D::*)() const) &Urho3D::View3D::GetRenderTexture, "todo: docstring")
.def("GetDepthTexture", (Urho3D::Texture2D * (Urho3D::View3D::*)() const) &Urho3D::View3D::GetDepthTexture, "todo: docstring")
.def("GetViewport", (Urho3D::Viewport * (Urho3D::View3D::*)() const) &Urho3D::View3D::GetViewport, "todo: docstring")
// Class Variables:
;
}
void Implement_Urho3D_TileMapObject2D(py::class_<Urho3D::TileMapObject2D, Urho3D::SharedPtr<Urho3D::TileMapObject2D>, Urho3D::RefCounted>& pyclass_Var_Urho3D_TileMapObject2D)
{
// Class TileMapObject2D Implementation
pyclass_Var_Urho3D_TileMapObject2D
.def(py::init<>(), "todo: constructor docstring")
.def("GetObjectType", (Urho3D::TileMapObjectType2D (Urho3D::TileMapObject2D::*)() const) &Urho3D::TileMapObject2D::GetObjectType, "todo: docstring")
.def("GetName", (const Urho3D::String & (Urho3D::TileMapObject2D::*)() const) &Urho3D::TileMapObject2D::GetName, "todo: docstring")
.def("GetType", (const Urho3D::String & (Urho3D::TileMapObject2D::*)() const) &Urho3D::TileMapObject2D::GetType, "todo: docstring")
.def("GetPosition", (const Urho3D::Vector2 & (Urho3D::TileMapObject2D::*)() const) &Urho3D::TileMapObject2D::GetPosition, "todo: docstring")
.def("GetSize", (const Urho3D::Vector2 & (Urho3D::TileMapObject2D::*)() const) &Urho3D::TileMapObject2D::GetSize, "todo: docstring")
.def("GetNumPoints", (unsigned int (Urho3D::TileMapObject2D::*)() const) &Urho3D::TileMapObject2D::GetNumPoints, "todo: docstring")
.def("GetPoint", (const Urho3D::Vector2 & (Urho3D::TileMapObject2D::*)(unsigned int) const) &Urho3D::TileMapObject2D::GetPoint, "todo: docstring", py::arg("index"))
.def("GetTileGid", (unsigned int (Urho3D::TileMapObject2D::*)() const) &Urho3D::TileMapObject2D::GetTileGid, "todo: docstring")
.def("GetTileFlipX", (bool (Urho3D::TileMapObject2D::*)() const) &Urho3D::TileMapObject2D::GetTileFlipX, "todo: docstring")
.def("GetTileFlipY", (bool (Urho3D::TileMapObject2D::*)() const) &Urho3D::TileMapObject2D::GetTileFlipY, "todo: docstring")
.def("GetTileSwapXY", (bool (Urho3D::TileMapObject2D::*)() const) &Urho3D::TileMapObject2D::GetTileSwapXY, "todo: docstring")
.def("GetTileSprite", (Urho3D::Sprite2D * (Urho3D::TileMapObject2D::*)() const) &Urho3D::TileMapObject2D::GetTileSprite, "todo: docstring")
.def("HasProperty", (bool (Urho3D::TileMapObject2D::*)(const Urho3D::String &) const) &Urho3D::TileMapObject2D::HasProperty, "todo: docstring", py::arg("name"))
.def("GetProperty", (const Urho3D::String & (Urho3D::TileMapObject2D::*)(const Urho3D::String &) const) &Urho3D::TileMapObject2D::GetProperty, "todo: docstring", py::arg("name"))
// Class Variables:
;
}
void Implement_Urho3D_CScriptDictValue(py::class_<Urho3D::CScriptDictValue, Urho3D::ExternalPtr<Urho3D::CScriptDictValue>>& pyclass_Var_Urho3D_CScriptDictValue)
{
// Class CScriptDictValue Implementation
pyclass_Var_Urho3D_CScriptDictValue
.def(py::init<>(), "todo: constructor docstring")
//.def(py::init<asIScriptEngine *, void *, int>(), "todo: constructor docstring")
//['asIScriptEngine', 'void', 'int']; op False, ctor True, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 1
//.def("~CScriptDictValue", (void (Urho3D::CScriptDictValue::*)()) &Urho3D::CScriptDictValue::~CScriptDictValue, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
//.def("Set", (void (Urho3D::CScriptDictValue::*)(asIScriptEngine *, void *, int)) &Urho3D::CScriptDictValue::Set, "todo: docstring", py::arg("engine"), py::arg("value"), py::arg("typeId"))
//['asIScriptEngine', 'void', 'int']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 1
//.def("Set", (void (Urho3D::CScriptDictValue::*)(asIScriptEngine *, const long &)) &Urho3D::CScriptDictValue::Set, "todo: docstring", py::arg("engine"), py::arg("value"))
//['asIScriptEngine', 'long']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 1
//.def("Set", (void (Urho3D::CScriptDictValue::*)(asIScriptEngine *, const double &)) &Urho3D::CScriptDictValue::Set, "todo: docstring", py::arg("engine"), py::arg("value"))
//['asIScriptEngine', 'double']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 1
//.def("Get", (bool (Urho3D::CScriptDictValue::*)(asIScriptEngine *, void *, int) const) &Urho3D::CScriptDictValue::Get, "todo: docstring", py::arg("engine"), py::arg("value"), py::arg("typeId"))
//['asIScriptEngine', 'void', 'int']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 1
//.def("Get", (bool (Urho3D::CScriptDictValue::*)(asIScriptEngine *, long &) const) &Urho3D::CScriptDictValue::Get, "todo: docstring", py::arg("engine"), py::arg("value"))
//['asIScriptEngine', 'long']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 1
//.def("Get", (bool (Urho3D::CScriptDictValue::*)(asIScriptEngine *, double &) const) &Urho3D::CScriptDictValue::Get, "todo: docstring", py::arg("engine"), py::arg("value"))
//['asIScriptEngine', 'double']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 1
.def("GetTypeId", (int (Urho3D::CScriptDictValue::*)() const) &Urho3D::CScriptDictValue::GetTypeId, "todo: docstring")
//.def("FreeValue", (void (Urho3D::CScriptDictValue::*)(asIScriptEngine *)) &Urho3D::CScriptDictValue::FreeValue, "todo: docstring", py::arg("engine"))
//['asIScriptEngine']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 1
// Class Variables:
;
}
void Implement_Urho3D_Rect(py::class_<Urho3D::Rect, Urho3D::ExternalPtr<Urho3D::Rect>>& pyclass_Var_Urho3D_Rect)
{
// Class Rect Implementation
pyclass_Var_Urho3D_Rect
.def(py::init<>(), "todo: constructor docstring")
.def(py::init<const Urho3D::Vector2 &, const Urho3D::Vector2 &>(), "todo: constructor docstring")
.def(py::init<float, float, float, float>(), "todo: constructor docstring")
.def(py::init<const Urho3D::Vector4 &>(), "todo: constructor docstring")
.def(py::init<const float *>(), "todo: constructor docstring")
.def(py::init<const Urho3D::Rect &>(), "todo: constructor docstring")
// .def(py::self = Urho3D::Rect(), "todo: docstring").def("__assign__", (Urho3D::Rect & (Urho3D::Rect::*)(const Urho3D::Rect &)) &Urho3D::Rect::operator=, py::operator, "todo: operator docstring. Switch to py: :self ops.")
//['Urho3D::Rect']; op =, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self == Urho3D::Rect(), "todo: docstring")
//['Urho3D::Rect']; op ==, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self != Urho3D::Rect(), "todo: docstring")
//['Urho3D::Rect']; op !=, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self += Urho3D::Rect(), "todo: docstring")
//['Urho3D::Rect']; op +=, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self -= Urho3D::Rect(), "todo: docstring")
//['Urho3D::Rect']; op -=, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self /= float(), "todo: docstring")
//['float']; op /=, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self *= float(), "todo: docstring")
//['float']; op *=, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self / float(), "todo: docstring")
//['float']; op /, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self * float(), "todo: docstring")
//['float']; op *, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self + Urho3D::Rect(), "todo: docstring")
//['Urho3D::Rect']; op +, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def(py::self - Urho3D::Rect(), "todo: docstring")
//['Urho3D::Rect']; op -, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("Define", (void (Urho3D::Rect::*)(const Urho3D::Rect &)) &Urho3D::Rect::Define, "todo: docstring", py::arg("rect"))
.def("Define", (void (Urho3D::Rect::*)(const Urho3D::Vector2 &, const Urho3D::Vector2 &)) &Urho3D::Rect::Define, "todo: docstring", py::arg("min"), py::arg("max"))
.def("Define", (void (Urho3D::Rect::*)(const Urho3D::Vector2 &)) &Urho3D::Rect::Define, "todo: docstring", py::arg("point"))
.def("Merge", (void (Urho3D::Rect::*)(const Urho3D::Vector2 &)) &Urho3D::Rect::Merge, "todo: docstring", py::arg("point"))
.def("Merge", (void (Urho3D::Rect::*)(const Urho3D::Rect &)) &Urho3D::Rect::Merge, "todo: docstring", py::arg("rect"))
.def("Clear", (void (Urho3D::Rect::*)()) &Urho3D::Rect::Clear, "todo: docstring")
.def("Clip", (void (Urho3D::Rect::*)(const Urho3D::Rect &)) &Urho3D::Rect::Clip, "todo: docstring", py::arg("rect"))
.def("Defined", (bool (Urho3D::Rect::*)() const) &Urho3D::Rect::Defined, "todo: docstring")
.def("Center", (Urho3D::Vector2 (Urho3D::Rect::*)() const) &Urho3D::Rect::Center, "todo: docstring")
.def("Size", (Urho3D::Vector2 (Urho3D::Rect::*)() const) &Urho3D::Rect::Size, "todo: docstring")
.def("HalfSize", (Urho3D::Vector2 (Urho3D::Rect::*)() const) &Urho3D::Rect::HalfSize, "todo: docstring")
.def("Equals", (bool (Urho3D::Rect::*)(const Urho3D::Rect &) const) &Urho3D::Rect::Equals, "todo: docstring", py::arg("rhs"))
.def("IsInside", (Urho3D::Intersection (Urho3D::Rect::*)(const Urho3D::Vector2 &) const) &Urho3D::Rect::IsInside, "todo: docstring", py::arg("point"))
.def("IsInside", (Urho3D::Intersection (Urho3D::Rect::*)(const Urho3D::Rect &) const) &Urho3D::Rect::IsInside, "todo: docstring", py::arg("rect"))
.def("Data", (const void * (Urho3D::Rect::*)() const) &Urho3D::Rect::Data, "todo: docstring")
.def("ToVector4", (Urho3D::Vector4 (Urho3D::Rect::*)() const) &Urho3D::Rect::ToVector4, "todo: docstring")
.def("ToString", (Urho3D::String (Urho3D::Rect::*)() const) &Urho3D::Rect::ToString, "todo: docstring")
.def("Min", (Urho3D::Vector2 (Urho3D::Rect::*)() const) &Urho3D::Rect::Min, "todo: docstring")
.def("Max", (Urho3D::Vector2 (Urho3D::Rect::*)() const) &Urho3D::Rect::Max, "todo: docstring")
.def("Left", (float (Urho3D::Rect::*)() const) &Urho3D::Rect::Left, "todo: docstring")
.def("Top", (float (Urho3D::Rect::*)() const) &Urho3D::Rect::Top, "todo: docstring")
.def("Right", (float (Urho3D::Rect::*)() const) &Urho3D::Rect::Right, "todo: docstring")
.def("Bottom", (float (Urho3D::Rect::*)() const) &Urho3D::Rect::Bottom, "todo: docstring")
// Class Variables:
.def_readwrite("min",&Urho3D::Rect::min_, "todo: var docstring")//Urho3D::Vector2
.def_readwrite("max",&Urho3D::Rect::max_, "todo: var docstring")//Urho3D::Vector2
.def_readonly_static("FULL",&Urho3D::Rect::FULL, "todo: var docstring")//const Urho3D::Rect
.def_readonly_static("POSITIVE",&Urho3D::Rect::POSITIVE, "todo: var docstring")//const Urho3D::Rect
.def_readonly_static("ZERO",&Urho3D::Rect::ZERO, "todo: var docstring")//const Urho3D::Rect
;
}
void Implement_Urho3D_ResourceRouter(py::class_<Urho3D::ResourceRouter, Urho3D::SharedPtr<Urho3D::ResourceRouter>, Urho3D::Object>& pyclass_Var_Urho3D_ResourceRouter)
{
// Class ResourceRouter Implementation
pyclass_Var_Urho3D_ResourceRouter
//.def(py::init<Urho3D::Context *>(), "todo: constructor docstring")
// Abstract class ResourceRouter -> no init
.def("Route", (void (Urho3D::ResourceRouter::*)(Urho3D::String &, Urho3D::ResourceRequest)) &Urho3D::ResourceRouter::Route, "todo: docstring", py::arg("name"), py::arg("requestType"))
// Class Variables:
;
}
void Implement_Urho3D_Serializer(py::class_<Urho3D::Serializer, Urho3D::ExternalPtr<Urho3D::Serializer>>& pyclass_Var_Urho3D_Serializer)
{
// Class Serializer Implementation
pyclass_Var_Urho3D_Serializer
//.def("~Serializer", (void (Urho3D::Serializer::*)()) &Urho3D::Serializer::~Serializer, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("Write", (unsigned int (Urho3D::Serializer::*)(const void *, unsigned int)) &Urho3D::Serializer::Write, "todo: docstring", py::arg("data"), py::arg("size"))
.def("WriteInt64", (bool (Urho3D::Serializer::*)(long long)) &Urho3D::Serializer::WriteInt64, "todo: docstring", py::arg("value"))
.def("WriteInt", (bool (Urho3D::Serializer::*)(int)) &Urho3D::Serializer::WriteInt, "todo: docstring", py::arg("value"))
//.def("WriteShort", (bool (Urho3D::Serializer::*)(short)) &Urho3D::Serializer::WriteShort, "todo: docstring", py::arg("value"))
//['short']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
//.def("WriteByte", (bool (Urho3D::Serializer::*)(signed char)) &Urho3D::Serializer::WriteByte, "todo: docstring", py::arg("value"))
//['signed char']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 0
.def("WriteUInt64", (bool (Urho3D::Serializer::*)(unsigned long long)) &Urho3D::Serializer::WriteUInt64, "todo: docstring", py::arg("value"))
.def("WriteUInt", (bool (Urho3D::Serializer::*)(unsigned int)) &Urho3D::Serializer::WriteUInt, "todo: docstring", py::arg("value"))
.def("WriteUShort", (bool (Urho3D::Serializer::*)(unsigned short)) &Urho3D::Serializer::WriteUShort, "todo: docstring", py::arg("value"))
.def("WriteUByte", (bool (Urho3D::Serializer::*)(unsigned char)) &Urho3D::Serializer::WriteUByte, "todo: docstring", py::arg("value"))
.def("WriteBool", (bool (Urho3D::Serializer::*)(bool)) &Urho3D::Serializer::WriteBool, "todo: docstring", py::arg("value"))
.def("WriteFloat", (bool (Urho3D::Serializer::*)(float)) &Urho3D::Serializer::WriteFloat, "todo: docstring", py::arg("value"))
.def("WriteDouble", (bool (Urho3D::Serializer::*)(double)) &Urho3D::Serializer::WriteDouble, "todo: docstring", py::arg("value"))
.def("WriteIntRect", (bool (Urho3D::Serializer::*)(const Urho3D::IntRect &)) &Urho3D::Serializer::WriteIntRect, "todo: docstring", py::arg("value"))
.def("WriteIntVector2", (bool (Urho3D::Serializer::*)(const Urho3D::IntVector2 &)) &Urho3D::Serializer::WriteIntVector2, "todo: docstring", py::arg("value"))
.def("WriteIntVector3", (bool (Urho3D::Serializer::*)(const Urho3D::IntVector3 &)) &Urho3D::Serializer::WriteIntVector3, "todo: docstring", py::arg("value"))
.def("WriteRect", (bool (Urho3D::Serializer::*)(const Urho3D::Rect &)) &Urho3D::Serializer::WriteRect, "todo: docstring", py::arg("value"))
.def("WriteVector2", (bool (Urho3D::Serializer::*)(const Urho3D::Vector2 &)) &Urho3D::Serializer::WriteVector2, "todo: docstring", py::arg("value"))
.def("WriteVector3", (bool (Urho3D::Serializer::*)(const Urho3D::Vector3 &)) &Urho3D::Serializer::WriteVector3, "todo: docstring", py::arg("value"))
.def("WritePackedVector3", (bool (Urho3D::Serializer::*)(const Urho3D::Vector3 &, float)) &Urho3D::Serializer::WritePackedVector3, "todo: docstring", py::arg("value"), py::arg("maxAbsCoord"))
.def("WriteVector4", (bool (Urho3D::Serializer::*)(const Urho3D::Vector4 &)) &Urho3D::Serializer::WriteVector4, "todo: docstring", py::arg("value"))
.def("WriteQuaternion", (bool (Urho3D::Serializer::*)(const Urho3D::Quaternion &)) &Urho3D::Serializer::WriteQuaternion, "todo: docstring", py::arg("value"))
.def("WritePackedQuaternion", (bool (Urho3D::Serializer::*)(const Urho3D::Quaternion &)) &Urho3D::Serializer::WritePackedQuaternion, "todo: docstring", py::arg("value"))
.def("WriteMatrix3", (bool (Urho3D::Serializer::*)(const Urho3D::Matrix3 &)) &Urho3D::Serializer::WriteMatrix3, "todo: docstring", py::arg("value"))
.def("WriteMatrix3x4", (bool (Urho3D::Serializer::*)(const Urho3D::Matrix3x4 &)) &Urho3D::Serializer::WriteMatrix3x4, "todo: docstring", py::arg("value"))
.def("WriteMatrix4", (bool (Urho3D::Serializer::*)(const Urho3D::Matrix4 &)) &Urho3D::Serializer::WriteMatrix4, "todo: docstring", py::arg("value"))
.def("WriteColor", (bool (Urho3D::Serializer::*)(const Urho3D::Color &)) &Urho3D::Serializer::WriteColor, "todo: docstring", py::arg("value"))
.def("WriteBoundingBox", (bool (Urho3D::Serializer::*)(const Urho3D::BoundingBox &)) &Urho3D::Serializer::WriteBoundingBox, "todo: docstring", py::arg("value"))
.def("WriteString", (bool (Urho3D::Serializer::*)(const Urho3D::String &)) &Urho3D::Serializer::WriteString, "todo: docstring", py::arg("value"))
.def("WriteFileID", (bool (Urho3D::Serializer::*)(const Urho3D::String &)) &Urho3D::Serializer::WriteFileID, "todo: docstring", py::arg("value"))
.def("WriteStringHash", (bool (Urho3D::Serializer::*)(const Urho3D::StringHash &)) &Urho3D::Serializer::WriteStringHash, "todo: docstring", py::arg("value"))
.def("WriteBuffer", (bool (Urho3D::Serializer::*)(const Urho3D::PODVector<unsigned char> &)) &Urho3D::Serializer::WriteBuffer, "todo: docstring", py::arg("value"))
.def("WriteResourceRef", (bool (Urho3D::Serializer::*)(const Urho3D::ResourceRef &)) &Urho3D::Serializer::WriteResourceRef, "todo: docstring", py::arg("value"))
.def("WriteResourceRefList", (bool (Urho3D::Serializer::*)(const Urho3D::ResourceRefList &)) &Urho3D::Serializer::WriteResourceRefList, "todo: docstring", py::arg("value"))
.def("WriteVariant", (bool (Urho3D::Serializer::*)(const Urho3D::Variant &)) &Urho3D::Serializer::WriteVariant, "todo: docstring", py::arg("value"))
.def("WriteVariantData", (bool (Urho3D::Serializer::*)(const Urho3D::Variant &)) &Urho3D::Serializer::WriteVariantData, "todo: docstring", py::arg("value"))
.def("WriteVariantVector", (bool (Urho3D::Serializer::*)(const Urho3D::Vector<Urho3D::Variant> &)) &Urho3D::Serializer::WriteVariantVector, "todo: docstring", py::arg("value"))
.def("WriteStringVector", (bool (Urho3D::Serializer::*)(const Urho3D::Vector<Urho3D::String> &)) &Urho3D::Serializer::WriteStringVector, "todo: docstring", py::arg("value"))
.def("WriteVariantMap", (bool (Urho3D::Serializer::*)(const Urho3D::HashMap<Urho3D::StringHash, Urho3D::Variant> &)) &Urho3D::Serializer::WriteVariantMap, "todo: docstring", py::arg("value"))
.def("WriteVLE", (bool (Urho3D::Serializer::*)(unsigned int)) &Urho3D::Serializer::WriteVLE, "todo: docstring", py::arg("value"))
.def("WriteNetID", (bool (Urho3D::Serializer::*)(unsigned int)) &Urho3D::Serializer::WriteNetID, "todo: docstring", py::arg("value"))
.def("WriteLine", (bool (Urho3D::Serializer::*)(const Urho3D::String &)) &Urho3D::Serializer::WriteLine, "todo: docstring", py::arg("value"))
// Class Variables:
;
}
void Implement_Urho3D_Component(py::class_<Urho3D::Component, Urho3D::SharedPtr<Urho3D::Component>, Urho3D::Animatable>& pyclass_Var_Urho3D_Component)
{
// Class Component Implementation
pyclass_Var_Urho3D_Component
.def("GetType", (Urho3D::StringHash (Urho3D::Component::*)() const) &Urho3D::Component::GetType, "todo: docstring")
.def("GetTypeName", (const Urho3D::String & (Urho3D::Component::*)() const) &Urho3D::Component::GetTypeName, "todo: docstring")
.def("GetTypeInfo", (const Urho3D::TypeInfo * (Urho3D::Component::*)() const) &Urho3D::Component::GetTypeInfo, "todo: docstring")
.def(py::init<Urho3D::Context *>(), "todo: constructor docstring")
//.def("~Component", (void (Urho3D::Component::*)()) &Urho3D::Component::~Component, "todo: docstring")
//[]; op False, ctor False, dtor True, variadic False, deleted False, ret bad False, param bad False, max ptr 0
.def("OnSetEnabled", (void (Urho3D::Component::*)()) &Urho3D::Component::OnSetEnabled, "todo: docstring")
.def("Save", (bool (Urho3D::Component::*)(Urho3D::Serializer &) const) &Urho3D::Component::Save, "todo: docstring", py::arg("dest"))
.def("SaveXML", (bool (Urho3D::Component::*)(Urho3D::XMLElement &) const) &Urho3D::Component::SaveXML, "todo: docstring", py::arg("dest"))
.def("SaveJSON", (bool (Urho3D::Component::*)(Urho3D::JSONValue &) const) &Urho3D::Component::SaveJSON, "todo: docstring", py::arg("dest"))
.def("MarkNetworkUpdate", (void (Urho3D::Component::*)()) &Urho3D::Component::MarkNetworkUpdate, "todo: docstring")
//.def("GetDependencyNodes", (void (Urho3D::Component::*)(Urho3D::PODVector<Urho3D::Node *> &)) &Urho3D::Component::GetDependencyNodes, "todo: docstring", py::arg("dest"))
//['Urho3D::PODVector<Urho3D::Node']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 1
.def("DrawDebugGeometry", (void (Urho3D::Component::*)(Urho3D::DebugRenderer *, bool)) &Urho3D::Component::DrawDebugGeometry, "todo: docstring", py::arg("debug"), py::arg("depthTest"))
.def("SetEnabled", (void (Urho3D::Component::*)(bool)) &Urho3D::Component::SetEnabled, "todo: docstring", py::arg("enable"))
.def("Remove", (void (Urho3D::Component::*)()) &Urho3D::Component::Remove, "todo: docstring")
.def("GetID", (unsigned int (Urho3D::Component::*)() const) &Urho3D::Component::GetID, "todo: docstring")
.def("IsReplicated", (bool (Urho3D::Component::*)() const) &Urho3D::Component::IsReplicated, "todo: docstring")
.def("GetNode", (Urho3D::Node * (Urho3D::Component::*)() const) &Urho3D::Component::GetNode, "todo: docstring")
.def("GetScene", (Urho3D::Scene * (Urho3D::Component::*)() const) &Urho3D::Component::GetScene, "todo: docstring")
.def("IsEnabled", (bool (Urho3D::Component::*)() const) &Urho3D::Component::IsEnabled, "todo: docstring")
.def("IsEnabledEffective", (bool (Urho3D::Component::*)() const) &Urho3D::Component::IsEnabledEffective, "todo: docstring")
.def("GetComponent", (Urho3D::Component * (Urho3D::Component::*)(Urho3D::StringHash) const) &Urho3D::Component::GetComponent, "todo: docstring", py::arg("type"))
//.def("GetComponents", (void (Urho3D::Component::*)(Urho3D::PODVector<Urho3D::Component *> &, Urho3D::StringHash) const) &Urho3D::Component::GetComponents, "todo: docstring", py::arg("dest"), py::arg("type"))
//['Urho3D::PODVector<Urho3D::Component', 'Urho3D::StringHash']; op False, ctor False, dtor False, variadic False, deleted False, ret bad False, param bad True, max ptr 1
.def("AddReplicationState", (void (Urho3D::Component::*)(Urho3D::ComponentReplicationState *)) &Urho3D::Component::AddReplicationState, "todo: docstring", py::arg("state"))
.def("PrepareNetworkUpdate", (void (Urho3D::Component::*)()) &Urho3D::Component::PrepareNetworkUpdate, "todo: docstring")
.def("CleanupConnection", (void (Urho3D::Component::*)(Urho3D::Connection *)) &Urho3D::Component::CleanupConnection, "todo: docstring", py::arg("connection"))
.def("GetBasePath", (const Urho3D::String & (Urho3D::Component::*)() const) &Urho3D::Component::GetBasePath, "todo: docstring")
// Class Variables:
;
}
| [
"SirNate0.gmail.com"
] | SirNate0.gmail.com |
257a1d349516164b2ef84e71c42e6266d5bff76f | 27d5670a7739a866c3ad97a71c0fc9334f6875f2 | /CPP/Targets/SupportWFLib/symbian/BTGPS/BluetoothEngine.cpp | 96f51bf61bd1cc04c1e24f5ca0b07af7c63eb455 | [
"BSD-3-Clause"
] | permissive | ravustaja/Wayfinder-S60-Navigator | ef506c418b8c2e6498ece6dcae67e583fb8a4a95 | 14d1b729b2cea52f726874687e78f17492949585 | refs/heads/master | 2021-01-16T20:53:37.630909 | 2010-06-28T09:51:10 | 2010-06-28T09:51:10 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 16,236 | cpp | /*
Copyright (c) 1999 - 2010, Vodafone Group Services Ltd
All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
* Neither the name of the Vodafone Group Services Ltd nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#include "BluetoothEngine.h"
#include "BtSelector.h"
#include "BtGpsConnector.h"
#include "SdpExaminer.h"
#include "BtSocketsEngine.h"
#include "BtPower.h"
#include "SdpRepeater.h"
#include "DiscoveryUtils.h"
#include "Log.h"
#define LOGPOINTER if(iLog)iLog
#include "LogMacros.h"
#define DBG_ACTIVE(p__) \
DBG(#p__ " is%s present %s", \
p__ ? "" : " not", \
p__ ? (p__->IsActive() ? "and active" : "but not active") : "")
#ifdef NAV2_CLIENT_SERIES60_V1
static const TInt KSerialPortUUID = 0x1101;
#endif
_LIT(KBtEngine, "BtEngine");
enum TBtEnginePanics {
EUndefinedState = 1,
ESdpFailedOnKnownDevice = 2,
};
template<class T>
void DeleteAndNull(T*& aPtr)
{
delete aPtr;
aPtr = NULL;
}
template<class T>
void SwapAndDelete(T*& aDst, T*& aSrc)
{
delete aDst;
aDst = aSrc;
aSrc = NULL;
}
template<class T>
void SwapAndReset(T& aDst, T& aSrc)
{
aDst = aSrc;
aSrc = T();
}
inline TPtrC OrNullDesC(const HBufC* aBuf)
{
return aBuf ? *aBuf : KNullDesC();
}
CBluetoothEngine::CBluetoothEngine(class MBluetoothEngineObserver& aObserver) :
CActiveLog(EPriorityStandard, "BtEngine"), iObserver(aObserver)
{
CActiveScheduler::Add(this);
}
void CBluetoothEngine::ConstructL()
{
}
class CBluetoothEngine*
CBluetoothEngine::NewL(class MBluetoothEngineObserver& aObserver)
{
class CBluetoothEngine* self = CBluetoothEngine::NewLC(aObserver);
CleanupStack::Pop(self);
return self;
}
class CBluetoothEngine*
CBluetoothEngine::NewLC(class MBluetoothEngineObserver& aObserver)
{
class CBluetoothEngine* self = new (ELeave) CBluetoothEngine(aObserver);
CleanupStack::PushL(self);
self->ConstructL();
return self;
}
CBluetoothEngine::~CBluetoothEngine()
{
DBG("Destructor");
if(IsActive()){
DBG("Destroyed while active.");
Cancel();
DBG("Cancel done");
}
delete iMaybeDeviceName;
delete iDeviceName;
delete iDelayedSelector;
delete iSdpExaminer;
delete iSocketsEngine;
delete iPower;
DBG("Destructor done");
}
TBool CBluetoothEngine::IsConnected()
{
return iSocketsEngine && iSocketsEngine->IsConnected();
}
TBool CBluetoothEngine::IsBusy()
{
//XXX is this enough?
return IsActive();
}
void CBluetoothEngine::GetDeviceName(TDes& aName) const
{
aName = iDeviceName ? *iDeviceName : KNullDesC();
}
void CBluetoothEngine::GetDeviceAddr(TDes8& aAddr) const
{
aAddr = iDeviceAddr.Des();
}
const class TBTDevAddr CBluetoothEngine::GetDeviceAddress() const
{
return iDeviceAddr;
}
void CBluetoothEngine::SetDeviceAddr(const class TBTDevAddr& aAddr)
{
DBG("DeviceAddress set to "PRIxBTADDR, PRIxBTEXPAND(aAddr));
iDeviceAddr = aAddr;
}
TInt CBluetoothEngine::ConnectL(const class TSdpRepeatSettings& aRepeats)
{
if(IsBusy() && iRepeater){
DBG("IsBusy with SdpRepeater.");
DBG("Our address: "PRIxBTADDR", Sdp's address: "PRIxBTADDR,
PRIxBTEXPAND(iDeviceAddr), PRIxBTEXPAND(iRepeater->GetAddress()));
Cancel();
DBG("Not busy anymore, and no SdpRepeater either");
}
if(!IsBusy() && !IsConnected()){
iRepeatSettings = aRepeats;
if(iDeviceAddr == TBTDevAddr()){
DBG("Connect to new device, start with selectnotifier");
//no known bt address, start the selection of a new device.
StartBtSelectorL();
} else if(IsS60Symbian7s()){
StartSdpRepeaterL();
} else {
//TODO: check if bt is on or not so we can restore that state on
//TODO: exit.
//we know which device we want. Make sure BT is turned on.
DBG("Connect to known device, start with power check.");
iPower = CBtPowerChecker::NewL();
UpdateLogMastersL();
iPower->PowerCheck(&iStatus, ETrue);
SetActive();
}
return KErrNone;
}
WARN("ConnectL returns KErrInUse since it is busy or connected!");
LogComponents();
return KErrInUse;
}
void CBluetoothEngine::DisconnectL()
{
if(!IsBusy()){
if(iSocketsEngine && iSocketsEngine->IsConnected()){
DBG("Starting disconnect");
iSocketsEngine->Disconnect(&iStatus);
SetActive();
}
}
}
TInt CBluetoothEngine::SendDataL(const TDesC8& aData)
{
if(IsConnected()){
iSocketsEngine->WriteL(aData);
} else {
ERR("Trying to write data when no device is connected.");
return KErrNotReady;
}
return KErrNone;
}
void CBluetoothEngine::DoCancel()
{
WARN("I have no idea what to do here!");
WARN("iStatus: 0x%x", unsigned(iStatus.Int()));
if(iDelayedSelector){
DBG_ACTIVE(iDelayedSelector);
iDelayedSelector->CancelDelayedCall();
DeleteAndNull(iDelayedSelector);
DBG("CBtSelector destroyed.");
} else if(iSdpExaminer){
DBG_ACTIVE(iSdpExaminer);
iSdpExaminer->CancelFind();
DeleteAndNull(iSdpExaminer);
DBG("CSdpExaminer destroyed");
} else if(iSocketsEngine){
DBG_ACTIVE(iSocketsEngine);
if(iSocketsEngine->IsActive()){
iSocketsEngine->CancelAll();
}
DeleteAndNull(iSocketsEngine);
DBG("CBTSocketsEngine destroyed");
} else if(iPower){
DBG_ACTIVE(iPower);
iPower->CancelPowerCheck();
DeleteAndNull(iPower);
DBG("CBtPower destroyed");
} else if(iRepeater){
DBG_ACTIVE(iRepeater);
iRepeater->CancelFind();
DeleteAndNull(iRepeater);
DBG("CSdpRepeater destroyed.");
}
}
void CBluetoothEngine::StartBtSelectorL()
{
class CBtSelector* selector = CBtSelector::NewL();
UpdateLogMastersL();
#ifdef NAV2_CLIENT_SERIES60_V2
DBG("Starting delayed selector");
iDelayedSelector = CActiveDelay<CBtSelector>::NewL(selector,
TTimeIntervalSeconds(5));
#else
DBG("Starting selector now.");
iDelayedSelector = CActiveDelay<CBtSelector>::NewL(selector,
TTimeIntervalSeconds(0));
#endif
iDelayedSelector->Start(&CBtSelector::SelectSerialDeviceL,
&CBtSelector::CancelSelection, &iStatus);
SetActive();
iRepeatSettings = TSdpRepeatSettings();
}
void CBluetoothEngine::StartSdpExaminerL(const class TBTDevAddr& aAddress)
{
DBG("Start Sdp for: "PRIxBTADDR, PRIxBTEXPAND(aAddress));
iSdpExaminer = CSdpExaminer::NewL(aAddress);
UpdateLogMastersL();
iSdpExaminer->FindSerialPortL(&iStatus);
SetActive();
}
void CBluetoothEngine::StartSocketsEngineL(const class TBTDevAddr& aAddr,
TInt aPort)
{
iSocketsEngine = CBtSocketsEngine::NewL(*this, aAddr, aPort);
UpdateLogMastersL();
iSocketsEngine->ConnectL(&iStatus);
SetActive();
}
void CBluetoothEngine::StartSdpRepeaterL()
{
iRepeater = CSdpRepeater::NewL(*this, iDeviceAddr);
UpdateLogMastersL();
iRepeater->SetRepeatSettings(iRepeatSettings);
iRepeatSettings = TSdpRepeatSettings();
iRepeater->FindSerialPortL(&iStatus);
SetActive();
}
void CBluetoothEngine::RunL()
{
if(iDelayedSelector){
class CBtSelector* selector = iDelayedSelector->Other();
if(iStatus == KErrNone){
DBG("CBtSelector done OK, user has selected a device.");
//the user has selected a device.
//XXX need to handle any leaves gracefully.
iMaybeDeviceAddr = selector->Address();
DeleteAndNull(iMaybeDeviceName);
iMaybeDeviceName = selector->Name().Alloc();
StartSdpExaminerL(iMaybeDeviceAddr);
} else if(iStatus == KErrHardwareNotAvailable){
DBG("CBtSelector returned KErrHardwareNotAvailable");
//error message.
iObserver.BtEngineInfo(EBtEngineSelectionFailed);
} else if(iStatus == KErrCancel){
DBG("CBtSelector KErrCancel-ed.");
//probably user cancel. no error message.
} else {
DBG("CBtSelector not OK, BTError(EB...NotFound, %d)", iStatus.Int());
//error message.
iObserver.BtEngineInfo(EBtEngineSelectionFailed);
}
delete selector;
DeleteAndNull(iDelayedSelector);
} else if(iSdpExaminer){
if(iStatus == KErrNone){
if(iDeviceAddr == TBTDevAddr()){
DBG("CSdpSelector has a serial port on a new device.");
//The user has selected a new device, and a serial port has
//been found on that device. It's time to connect.
StartSocketsEngineL(iMaybeDeviceAddr, iSdpExaminer->Port());
} else {
//this case shouldn't happen anymore as connections to
//known devices are handled through CSdpRepeater.
DBG("CSdpSelector has found the serial port on a known device.");
StartSocketsEngineL(iDeviceAddr, iSdpExaminer->Port());
}
} else if(iStatus == KErrHardwareNotAvailable){
DBG("Low battery or flight mode.");
iObserver.BtEngineInfo(EBtEngineHardwareUnavailable);
} else if(iStatus == KErrTimedOut){
DBG("SpdExaminer timeout."); //L2CAP or HCI
iObserver.BtEngineInfo(EBtEngineHardwareUnavailable);
} else {
WARN("SdpExaminer op failed: %d", iStatus.Int());
if(iDeviceAddr == TBTDevAddr()){
iObserver.BtEngineInfo(EBtEngineSelectionSdpFailed);
} else {
//this should never happen
User::Panic(KBtEngine, ESdpFailedOnKnownDevice);
}
}
DeleteAndNull(iSdpExaminer);
} else if(iRepeater){
if(iStatus == KErrNone){
DBG("CSdpRepeater has found the serial port on a known device.");
StartSocketsEngineL(iDeviceAddr, iRepeater->Port());
} else if(iStatus == KErrHardwareNotAvailable){
DBG("Low battery or flight mode.");
iObserver.BtEngineInfo(EBtEngineHardwareUnavailable);
} else {
DBG("CSdpRepeater has run out of retries.");
iObserver.BtEngineInfo(EBtEngineRepeatedSearchFailed);
}
DeleteAndNull(iRepeater);
} else if(iPower){
if(iStatus == KErrNone){
if(iPower->IsPoweredOn()){
//we have power!
DBG("We have power!");
StartSdpRepeaterL();
} else {
WARN("We have no power!");
iObserver.BtEngineInfo(EBtEnginePowerOnCancelled);
}
} else {
ERR("CBtPower op failed.");
iObserver.BtEngineInfo(EBtEnginePowerOnFailed);
}
DeleteAndNull(iPower);
} else if(iSocketsEngine){
if(iStatus == KErrNone){
if(iSocketsEngine->IsConnected()){
//connection is complete. Reading has started, we are ready
//to write.
DBG("SocketsEngine connection complete.");
if(iDeviceAddr == TBTDevAddr()){
DBG("Setting device address "PRIxBTADDR" and name.",
PRIxBTEXPAND(iMaybeDeviceAddr));
SwapAndReset(iDeviceAddr, iMaybeDeviceAddr);
SwapAndDelete(iDeviceName, iMaybeDeviceName);
} else {
//XXX No need to do anything?
}
iObserver.BtEngineInfo(EBtEngineConnectionComplete);
iObserver.BtEngineDevice(iDeviceAddr, OrNullDesC(iDeviceName));
} else {
//disconnection complete
DBG("SocketsEngine disconnect complete.");
DeleteAndNull(iSocketsEngine);
iObserver.BtEngineInfo(EBtEngineDisconnectionComplete);
}
//XXX what?
} else {
ERR("SocketsEngine operation failed: %d", iStatus.Int());
DeleteAndNull(iSocketsEngine);
iObserver.BtEngineInfo(EBtEngineSocketConnectionFailed);
}
} else {
ERR("Unhandled state");
User::Panic(KBtEngine, EUndefinedState);
}
}
TInt CBluetoothEngine::RunError( TInt aError )
{
ERR("RunL left with code %d", aError);
if(iRepeater){
if(aError == KErrNotSupported){
DeleteAndNull(iRepeater);
iObserver.BtEngineInfo(EBtEngineHardwareUnavailable); //XXX
aError = KErrNone; //cancel out the error dialog
}
}
return aError;
}
void CBluetoothEngine::SdpRepeatInfo(TInt aNum, TInt aTotal)
{
iObserver.BtEngineSearching(aNum, aTotal);
}
void CBluetoothEngine::ConnectionLost(TBool aReconnect)
{
WARN("The socket was disconnected!");
DeleteAndNull(iSocketsEngine);
if(aReconnect){
iRepeatSettings = TSdpRepeatSettings(TTimeIntervalSeconds(30));
StartSdpRepeaterL();
} else {
//XXX do something here?
}
}
void CBluetoothEngine::ConnectionCancelled()
{
DBG("ConnectionCancelled");
}
void CBluetoothEngine::ReceiveMessageL(const class TDesC8& aData)
{
//DBG("Received %d bytes of data", aData.Length());
//iReciver.ReceiveBTData(aData); //receiveddata
DBG("Read %d bytes from socket", aData.Length());
iObserver.BtEngineData(aData);
}
void CBluetoothEngine::ErrorNotify(enum TBtSocketsErrors aError,
TInt aStatus)
{
WARN("ErrorNotify(%d, %d)", int(aError), aStatus);
switch(aError){
case EBtSocketsReadError:
iObserver.BtEngineInfo(EBtEngineConnectionLostReadError); //???
break;
case EBtSocketsReadHardwareFail:
iObserver.BtEngineInfo(EBtEngineConnectionLostHardwareFailed); //???
break;
case EBtSocketsWriteTimeout:
iObserver.BtEngineInfo(EBtEngineConnectionLostWriteTimeout); //???
break;
case EBtSocketsWriteError:
iObserver.BtEngineInfo(EBtEngineConnectionLostWriteError); //???
break;
}
}
CArrayPtr<CActiveLog>* CBluetoothEngine::SubLogArrayLC()
{
CArrayPtr<CActiveLog>* array = new (ELeave) CArrayPtrFlat<CActiveLog>(4);
CleanupStack::PushL(array);
class CActiveLog* logs[] =
{ iDelayedSelector ? iDelayedSelector->Other() : NULL,
iSdpExaminer, iPower, iSocketsEngine, iRepeater };
array->AppendL(logs, sizeof(logs)/sizeof(*logs));
return array;
}
void CBluetoothEngine::LogComponents()
{
#ifndef NO_LOG_OUTPUT
DBG("BluetoothEngine subcomponents:");
DBG_ACTIVE(this);
DBG_ACTIVE(iDelayedSelector);
DBG_ACTIVE(iSdpExaminer);
DBG_ACTIVE(iPower);
DBG_ACTIVE(iSocketsEngine);
DBG_ACTIVE(iRepeater);
DBG("All cubcomponents accounted for.");
#endif
}
| [
"hlars@sema-ovpn-morpheus.itinerary.com"
] | hlars@sema-ovpn-morpheus.itinerary.com |
a66fc1f5f836c67301dcf6fec83ff722af6b1d38 | d1a8c3598ef73126332a5db449544419ff9b5907 | /DirectX/3DGraphicsProgrammingCD/chap04/lighting_directional/render_dx10.cpp | 94edabdc13bd993e35ec81dac4e5690eecec0494 | [] | no_license | gustavosrey/3dlearn | b7e83497b4e80e21916ea1d5be11764c55543e8d | f50cdfe2b8fbbdfcd71a22f3cc369d972c46fcb9 | refs/heads/master | 2021-01-10T11:03:17.104641 | 2012-02-08T07:54:50 | 2012-02-08T07:54:50 | 54,849,462 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 5,981 | cpp | #ifdef _ENABLE_DX10_
#include "Gut.h"
#include "render_data.h"
static ID3D10Device *g_pDevice = NULL;
static ID3D10InputLayout *g_pVertexLayout = NULL;
static ID3D10Buffer *g_pVertexBuffer = NULL;
static ID3D10Buffer *g_pIndexBuffer = NULL;
static ID3D10Buffer *g_pConstantBuffer = NULL;
static ID3D10VertexShader *g_pVertexShader = NULL;
static ID3D10PixelShader *g_pPixelShader = NULL;
static ID3D10RasterizerState *g_pRasterizerState= NULL;
static Matrix4x4 g_proj_matrix;
static Matrix4x4 g_view_matrix;
bool InitResourceDX10(void)
{
g_pDevice = GutGetGraphicsDeviceDX10();
ID3D10Blob *pVSCode = NULL;
// 載入Vertex Shader
g_pVertexShader = GutLoadVertexShaderDX10_HLSL("../../shaders/vertex_color_dx10.hlsl", "VS", "vs_4_0", &pVSCode);
if ( NULL==g_pVertexShader )
return false;
// 載入Pixel Shader
g_pPixelShader = GutLoadPixelShaderDX10_HLSL("../../shaders/vertex_color_dx10.hlsl", "PS", "ps_4_0");
if ( NULL==g_pPixelShader )
return false;
// 設定Vertex資料格式
D3D10_INPUT_ELEMENT_DESC layout[] =
{
{ "POSITION", 0, DXGI_FORMAT_R32G32B32A32_FLOAT, 0, 0, D3D10_INPUT_PER_VERTEX_DATA, 0 },
{ "COLOR", 0, DXGI_FORMAT_R32G32B32A32_FLOAT, 0, 16, D3D10_INPUT_PER_VERTEX_DATA, 0 }
};
if ( D3D_OK != g_pDevice->CreateInputLayout( layout, sizeof(layout)/sizeof(D3D10_INPUT_ELEMENT_DESC), pVSCode->GetBufferPointer(), pVSCode->GetBufferSize(), &g_pVertexLayout ) )
return false;
SAFE_RELEASE(pVSCode);
D3D10_BUFFER_DESC cbDesc;
// vertex buffer
cbDesc.ByteWidth = sizeof(Vertex_VCN) * 4;
cbDesc.Usage = D3D10_USAGE_DYNAMIC ;
cbDesc.BindFlags = D3D10_BIND_VERTEX_BUFFER;
cbDesc.CPUAccessFlags = D3D10_CPU_ACCESS_WRITE;
cbDesc.MiscFlags = 0;
// 配置一塊可以存放Vertex的記憶體, 也就是Vertex Buffer.
if ( D3D_OK != g_pDevice->CreateBuffer( &cbDesc, NULL, &g_pVertexBuffer ) )
return false;
// 配置Shader讀取參數的記憶體空間
cbDesc.ByteWidth = sizeof(Matrix4x4);
cbDesc.Usage = D3D10_USAGE_DYNAMIC;
cbDesc.BindFlags = D3D10_BIND_CONSTANT_BUFFER;
cbDesc.CPUAccessFlags = D3D10_CPU_ACCESS_WRITE;
cbDesc.MiscFlags = 0;
if ( D3D_OK != g_pDevice->CreateBuffer( &cbDesc, NULL, &g_pConstantBuffer ) )
return false;
// 計算投影矩陣
g_proj_matrix = GutMatrixPerspectiveRH_DirectX(g_fFovW, 1.0f, 0.1f, 100.0f);
// rasterizer state物件
D3D10_RASTERIZER_DESC rasterizer_state_desc;
rasterizer_state_desc.FillMode = D3D10_FILL_SOLID;
rasterizer_state_desc.CullMode = D3D10_CULL_NONE;
rasterizer_state_desc.FrontCounterClockwise = true;
rasterizer_state_desc.DepthBias = 0;
rasterizer_state_desc.DepthBiasClamp = 0.0f;
rasterizer_state_desc.SlopeScaledDepthBias = 0.0f;
rasterizer_state_desc.DepthClipEnable = false;
rasterizer_state_desc.ScissorEnable = false;
rasterizer_state_desc.MultisampleEnable = false;
rasterizer_state_desc.AntialiasedLineEnable = false;
if ( D3D_OK != g_pDevice->CreateRasterizerState(&rasterizer_state_desc, &g_pRasterizerState) )
return false;
g_pDevice->RSSetState(g_pRasterizerState);
g_view_matrix = GutMatrixLookAtRH(g_eye, g_lookat, g_up);
return true;
}
bool ReleaseResourceDX10(void)
{
SAFE_RELEASE(g_pVertexLayout);
SAFE_RELEASE(g_pVertexBuffer);
SAFE_RELEASE(g_pIndexBuffer);
SAFE_RELEASE(g_pConstantBuffer);
SAFE_RELEASE(g_pVertexShader);
SAFE_RELEASE(g_pPixelShader);
SAFE_RELEASE(g_pRasterizerState);
return true;
}
void ResizeWindowDX10(int width, int height)
{
GutResetGraphicsDeviceDX10();
float aspect = (float) height / (float) width;
g_proj_matrix = GutMatrixPerspectiveRH_DirectX(g_fFovW, aspect, 0.1f, 100.0f);
}
void RenderFrameDX10(void)
{
Vector4 vClearColor(0.0f, 0.0f, 0.0f, 0.0f);
UINT stride = sizeof(Vertex_VCN);
UINT offset = 0;
// 取得呼叫GutCreateGraphicsDeviceDX10時所產生的D3D10物件
ID3D10RenderTargetView *pRenderTargetView = GutGetDX10RenderTargetView(); //frame buffer
ID3D10DepthStencilView *pDepthStencilView = GutGetDX10DepthStencilView(); //depth/stencil buffer
IDXGISwapChain *pSwapChain = GutGetDX10SwapChain(); // front/back buffer
// 清除顏色
g_pDevice->ClearRenderTargetView(pRenderTargetView, (float *)&vClearColor);
// 清除Depth/Stencil buffer
g_pDevice->ClearDepthStencilView(pDepthStencilView, D3D10_CLEAR_DEPTH | D3D10_CLEAR_STENCIL, 1.0f, 0);
// 設定vertex shader
g_pDevice->VSSetShader(g_pVertexShader);
// 設定pixel shader
g_pDevice->PSSetShader(g_pPixelShader);
// 設定vertex shader讀取參數的記憶體位罝
g_pDevice->VSSetConstantBuffers(0, 1, &g_pConstantBuffer);
// 設定vertex資料格式
g_pDevice->IASetInputLayout(g_pVertexLayout);
// 設定vertex buffer
g_pDevice->IASetVertexBuffers(0, 1, &g_pVertexBuffer, &stride, &offset);
// 設定index buffer
g_pDevice->IASetIndexBuffer(g_pIndexBuffer, DXGI_FORMAT_R16_UINT, 0);
// 設定三角形頂點索引值資料排列是triangle strip
g_pDevice->IASetPrimitiveTopology(D3D10_PRIMITIVE_TOPOLOGY_TRIANGLESTRIP);
// 計算矩陣
Matrix4x4 view_proj_matrix = g_view_matrix * g_proj_matrix;
Matrix4x4 world_view_proj_matrix = g_world_matrix * view_proj_matrix;
// 設定shader參數
Matrix4x4 *pConstData;
g_pConstantBuffer->Map( D3D10_MAP_WRITE_DISCARD, NULL, (void **) &pConstData );
*pConstData = world_view_proj_matrix;
g_pConstantBuffer->Unmap();
// 更新頂點資料
Vertex_VCN *pVertex;
g_pVertexBuffer->Map( D3D10_MAP_WRITE_DISCARD, NULL, (void **) &pVertex );
memcpy(pVertex, g_Quad, sizeof(Vertex_VCN) * 4);
g_pVertexBuffer->Unmap();
// 畫出格子
g_pDevice->Draw(4, 0);
// 等待硬體掃描結束, 然後才更新畫面
pSwapChain->Present(1, 0);
}
#else
void ResizeWindowDX10(int width, int height) {}
void RenderFrameDX10(void) {}
bool ReleaseResourceDX10(void) { return false; }
bool InitResourceDX10(void) { return false; }
#endif // _ENABLE_DX10_ | [
"augustus4400@gmail.com"
] | augustus4400@gmail.com |
bf87c17b3470defd4c84601ce219005853c95e7b | 484423d2e52788a63fd4a0c4eb11a46f64cd4592 | /develop/source/KernelControl/KernelControl.cpp | 498985b1d089abd6721b3a15e994212f0df28b0d | [] | no_license | SuperCaterpillar/HostMgr | 75feeaf1e4d24a61ff476660cc9a8f60f8a35e01 | 505f05967e810eafb71849f9bf5dab7a7f423a87 | refs/heads/master | 2020-04-28T17:24:21.073592 | 2019-04-07T09:59:44 | 2019-04-07T09:59:44 | 175,445,128 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 124 | cpp | #include "KernelControl.h"
bool StartKernelControl()
{
return true;
}
bool StopKernelControl()
{
return true;
}
| [
"779734784@qq.com"
] | 779734784@qq.com |
bd4eba97f395c428217f27e10f4993917d9fa9f8 | a89c4db894ee7e720469d2337d986eb9a97bbd4c | /SHOOTUBER/Timer.cpp | 11af2da7fc9c5a645ac5151ee63f472a93374285 | [] | no_license | Gorbylord/grovylib | 4408abb1ed4071a950f778e02f4f94dbb13f3e1b | 0c48ad8e9a8e486d0ae5d0d72ac2e7286db4f9b0 | refs/heads/master | 2021-03-02T15:20:01.208416 | 2020-03-08T19:57:01 | 2020-03-08T19:57:01 | 245,878,824 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 528 | cpp | #include "Timer.h"
#include <windows.h>
void STimer::Reset () {
QueryPerformanceFrequency( ( LARGE_INTEGER* )&CountsPerSecond );
SecondsPerCount = (1.0 / (CountsPerSecond));
QueryPerformanceCounter( ( LARGE_INTEGER* )&PrevTimeStamp );
LastTime = 0;
}
void STimer::Frame () {
QueryPerformanceCounter( ( LARGE_INTEGER* ) &CurrentTimeStamp );
LastTime = (float)(( CurrentTimeStamp - PrevTimeStamp )* SecondsPerCount);
PrevTimeStamp = CurrentTimeStamp;
}
| [
"gorbylord@gmail.com"
] | gorbylord@gmail.com |
c51107f0a5fd8ac8ae7236805f130aac9e96590e | 4f525fbca7085ef6b614d8f87f65185820cc1910 | /Headers/Lib/Pair2D.h | 34cc967f8985b8c707902ea1b3459348592fff71 | [] | no_license | rohinkumar/CosmoBolognaLib | aa7ca4497481454acc25c74af1073c92f392719f | ebc3136b86501437d033e72c720875fae7ee4cc4 | refs/heads/master | 2021-01-18T12:30:52.524797 | 2016-06-30T13:09:26 | 2016-06-30T13:09:26 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 59,666 | h | /*******************************************************************
* Copyright (C) 2015 by Federico Marulli *
* federico.marulli3@unibo.it *
* *
* This program is free software; you can redistribute it and/or *
* modify it under the terms of the GNU General Public License as *
* published by the Free Software Foundation; either version 2 of *
* the License, or (at your option) any later version. *
* *
* This program is distributed in the hope that it will be useful,*
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
* GNU General Public License for more details. *
* *
* You should have received a copy of the GNU General Public *
* License along with this program; if not, write to the Free *
* Software Foundation, Inc., *
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
*******************************************************************/
/**
* @file Headers/Lib/Pair2D.h
*
* @brief The classes Pair2D*
*
* This file defines the interface of the base class Pair2D, used to
* handle 2D pairs of objects of any kind
*
* @authors Federico Marulli
*
* @authors federico.marulli3@unbo.it
*/
#ifndef __PAIR2D__
#define __PAIR2D__
#include "Pair.h"
// ===================================================================================================
namespace cosmobl {
namespace pairs {
/**
* @class Pair2D Pair2D.h "Headers/Lib/Pair2D.h"
*
* @brief The class Pair2D
*
* This class is used to handle objects of type <EM> Pair2D
* </EM>.
*/
class Pair2D : public Pair {
private:
/**
* @name Member functions used to set the binning parameters (customized in all the derived classes)
*/
///@{
/**
* @brief set the binning parameters given the number of bins
* @return none
*/
virtual void m_set_parameters_nbins () = 0;
/**
* @brief set the binning parameters given the bin size
* @return none
*/
virtual void m_set_parameters_binSize () = 0;
///@}
protected:
/// the binned scales in the first dimension
vector<double> m_scale_D1;
/// the binned scales in the second dimension
vector<double> m_scale_D2;
/// the number of binned pairs
vector<vector<double> > m_PP2D;
/**
* @name Binning parameters
*/
///@{
/// the inverse of the bin size in the first dimension
double m_binSize_inv_D1;
/// number of bins in the first dimension
int m_nbins_D1;
/// radial shift used to centre the output bins in the first dimension
double m_shift_D1;
/// the inverse of the bin size in the second dimension
double m_binSize_inv_D2;
/// number of bins in the second dimension
int m_nbins_D2;
/// radial shift used to centre the output bins in the second dimension
double m_shift_D2;
///@}
public:
/**
* @name Constructors/destructors
*/
///@{
/**
* @brief default constuctor
* @return object of class Pair2D
*/
Pair2D ()
: m_binSize_inv_D1(1.), m_nbins_D1(50), m_shift_D1(0.5), m_binSize_inv_D2(1.), m_nbins_D2(50), m_shift_D2(0.5)
{ m_pairDim = _2D_; m_angularUnits = _radians_; m_angularWeight = nullptr; }
/**
* @brief constuctor
* @param binSize_D1 the bin size in the first dimension
* @param nbins_D1 number of bins in the first dimension
* @param shift_D1 radial shift used to centre the output bins
* in the first dimension
* @param binSize_D2 the bin size in the second dimension
* @param nbins_D2 number of bins in the second dimension
* @param shift_D2 radial shift used to centre the output bins
* in the second dimension
* @param angularUnits angular units
* @param angularWeight angular weight function
* @return object of class Pair2D
*/
Pair2D (const double binSize_D1, const int nbins_D1, const double shift_D1, const double binSize_D2, const int nbins_D2, const double shift_D2, const CoordUnits angularUnits=_radians_, function<double(double)> angularWeight=nullptr)
: m_binSize_inv_D1(1./binSize_D1), m_nbins_D1(nbins_D1), m_shift_D1(shift_D1), m_binSize_inv_D2(1./binSize_D2), m_nbins_D2(nbins_D2), m_shift_D2(shift_D2)
{ m_pairDim = _2D_; m_angularUnits = angularUnits; m_angularWeight = angularWeight; }
/**
* @brief default destructor
* @return none
*/
virtual ~Pair2D () = default;
///@}
/**
* @name Member functions to get the protected members
*/
///@{
/**
* @brief get the protected member \e m_scale_D1[i]
* @param i the bin index in the first dimension
* @return the i-th binned scale
*/
double scale_D1 (const int i) const override { return m_scale_D1[i]; }
/**
* @brief get the protected member \e m_scale_D1
* @return the vector containing the binned scales
*/
vector<double> scale_D1 () const override { return m_scale_D1; }
/**
* @brief get the protected member \e m_scale_D2[i]
* @param i the bin index in the first dimension
* @return the i-th binned scale
*/
double scale_D2 (const int i) const override { return m_scale_D2[i]; }
/**
* @brief get the protected member \e m_scale_D2
* @return the vector containing the binned scales
*/
vector<double> scale_D2 () const override { return m_scale_D2; }
/**
* @brief get the protected member \e m_PP2D[i]
* @param i the bin index in the first dimension
* @param j the bin index in the second dimension
* @return the number of pairs in the i-th bin
*/
double PP2D (const int i, const int j) const override { return m_PP2D[i][j]; }
/**
* @brief get the protected member \e m_PP2D
* @return the vector containing the binned number of pairs
*/
vector<vector<double> > PP2D () const override { return m_PP2D; }
/**
* @brief get the protected member Pair2D::m_binSize_inv_D1
* @return the inverse of the bin size in the first dimension
*/
double binSize_inv_D1 () const override { return m_binSize_inv_D1; }
/**
* @brief get the protected member Pair2D::m_nbins_D1
* @return the number of bins in the first dimension
*/
int nbins_D1 () const override { return m_nbins_D1; }
/**
* @brief get the protected member Pair2D::m_shift_D1
* @return the radial shift in the first dimension used to centre
* the output bins
*/
double shift_D1 () const override { return m_shift_D1; }
/**
* @brief get the protected member Pair2D::m_binSize_inv_D2
* @return the inverse of the bin size in the second dimension
*/
double binSize_inv_D2 () const override { return m_binSize_inv_D2; }
/**
* @brief get the protected member Pair2D::m_nbins_D2
* @return the number of bins in the second dimension
*/
int nbins_D2 () const override { return m_nbins_D2; }
/**
* @brief get the protected member Pair2D::m_shift_D2
* @return the radial shift in the second dimension used to centre
* the output bins
*/
double shift_D2 () const override { return m_shift_D2; }
///@}
/**
* @name Member functions used to set the protected members
*/
///@{
/**
* @brief set the protected member Pair2D::m_scale_D1[i]
* @param i the bin index in the first dimension
* @param pp the binned scales
* @return none
*/
void set_scale_D1 (const int i, const double pp) { checkDim(m_scale_D1, i, "m_scale_D1"); m_scale_D1[i] = pp; }
/**
* @brief set the protected member Pair2D::m_scale_D2[i]
* @param i the bin index in the first dimension
* @param pp the binned scales
* @return none
*/
void set_scale_D2 (const int i, const double pp) { checkDim(m_scale_D2, i, "m_scale_D2"); m_scale_D2[i] = pp; }
/**
* @brief set the protected member Pair2D::m_PP2D[i][j]
* @param i the bin index in the first dimension
* @param j the bin index in the second dimension
* @param pp the number of pairs in the bin
* @return none
*/
void set_PP2D (const int i, const int j, const double pp) { checkDim(m_PP2D, i, j, "m_PP2D"); m_PP2D[i][j] = pp; }
/**
* @brief set the protected member PairD1::m_PP2D[i][j] adding
* the number of pairs
* @param i the bin index in the first dimension
* @param j the bin index in the second dimension
* @param pp the number of pairs in the bin
* @return none
*/
void add_PP2D (const int i, const int j, const double pp) { checkDim(m_PP2D, i, j, "m_PP2D"); m_PP2D[i][j] += pp; }
///@}
/**
* @name Member functions used to handle pairs
*/
///@{
/**
* @brief sum the number of binned pairs
* @param pp an object of class Pair
* @param ww the weight
* @return none
*/
void Sum (const shared_ptr<Pair> pp, const double ww=1) override;
///@}
};
// ============================================================================================
// ============================================================================================
/**
* @class Pair2D_comovingCartesian Pair2D.h
* "Headers/Lib/Pair2D.h"
*
* @brief The class Pair2D_comovingCartesian
*
* This class is used to handle objects of type <EM>
* Pair2D_comovingCartesian </EM>.
*/
class Pair2D_comovingCartesian : public Pair2D {
private:
/**
* @name Member functions used to set the binning parameters (customized in all the derived classes)
*/
///@{
/**
* @brief set the binning parameters given the number of bins
* @return none
*/
virtual void m_set_parameters_nbins () = 0;
/**
* @brief set the binning parameters given the bin size
* @return none
*/
virtual void m_set_parameters_binSize () = 0;
///@}
protected:
/**
* @name Binning parameters
*/
///@{
/// minimum perpendicular separation used to count the pairs
double m_rpMin;
/// maximum perpendicular separation used to count the pairs
double m_rpMax;
/// minimum parallel separation used to count the pairs
double m_piMin;
/// maximum parallel separation used to count the pairs
double m_piMax;
///@}
public:
/**
* @name Constructors/destructors
*/
///@{
/**
* @brief default constuctor
* @return object of class Pair2D_comovingCartesian
*/
Pair2D_comovingCartesian () : m_rpMin(0.1), m_rpMax(50.), m_piMin(0.1), m_piMax(50.) {}
/**
* @brief constuctor
* @param rpMin minimum perpendicular separation used to count
* the pairs
* @param rpMax maximum perpendicular separation used to count
* the pairs
* @param nbins_rp number of bins in the perpendicular separation
* @param shift_rp shift parameter in the perpendicular
* separation, i.e. the shift is binSize*shift
* @param piMin minimum parallel separation used to count the pairs
* @param piMax maximum parallel separation used to count the pairs
* @param nbins_pi number of bins in the parallel separation
* @param shift_pi shift parameter in the parallel separation,
* i.e. the shift is binSize*shift
* @param angularUnits angular units
* @param angularWeight angular weight function
* @return object of class Pair2D_comovingCartesian
*/
Pair2D_comovingCartesian (const double rpMin, const double rpMax, const int nbins_rp, const double shift_rp, const double piMin, const double piMax, const int nbins_pi, const double shift_pi, const CoordUnits angularUnits=_radians_, function<double(double)> angularWeight=nullptr)
: Pair2D(1., nbins_rp, shift_rp, 1., nbins_pi, shift_pi, angularUnits, angularWeight), m_rpMin(rpMin), m_rpMax(rpMax), m_piMin(piMin), m_piMax(piMax) {}
/**
* @brief constuctor
* @param rpMin minimum perpendicular separation used to count
* the pairs
* @param rpMax maximum perpendicular separation used to count
* the pairs
* @param binSize_rp size of the bins in the perpendicular
* separation
* @param shift_rp shift parameter in the perpendicular
* separation, i.e. the shift is binSize*shift
* @param piMin minimum parallel separation used to count the pairs
* @param piMax maximum parallel separation used to count the pairs
* @param binSize_pi size of the bins in the parallel separation
* @param shift_pi shift parameter in the parallel separation,
* i.e. the shift is binSize*shift
* @param angularUnits angular units
* @param angularWeight angular weight function
* @return object of class Pair2D_comovingCartesian
*/
Pair2D_comovingCartesian (const double rpMin, const double rpMax, const double binSize_rp, const double shift_rp, const double piMin, const double piMax, const double binSize_pi, const double shift_pi, const CoordUnits angularUnits=_radians_, function<double(double)> angularWeight=nullptr)
: Pair2D(binSize_rp, 50, shift_rp, binSize_pi, 50, shift_pi, angularUnits, angularWeight), m_rpMin(rpMin), m_rpMax(rpMax), m_piMin(piMin), m_piMax(piMax) {}
/**
* @brief default destructor
* @return none
*/
virtual ~Pair2D_comovingCartesian () = default;
///@}
/**
* @name Member functions used to get the protected parameters
*/
///@{
/**
* @brief get the protected member Pair2D::m_rpMin
* @return the minimum perpendicular separation used to count the
* pairs
*/
double sMin_D1 () const override { return m_rpMin; }
/**
* @brief get the protected member Pair2D::m_rpMax
* @return the maximum perpendicular separation used to count the
* pairs
*/
double sMax_D1 () const override { return m_rpMax; }
/**
* @brief get the protected member Pair2D::m_piMin
* @return the minimum parallel separation used to count the
* pairs
*/
double sMin_D2 () const override { return m_piMin; }
/**
* @brief get the protected member Pair2D::m_piMax
* @return the maximum parallel separation used to count the
* pairs
*/
double sMax_D2 () const override { return m_piMax; }
///@}
};
// ============================================================================================
// ============================================================================================
/**
* @class Pair2D_comovingCartesian_linlin Pair2D.h
* "Headers/Lib/Pair2D.h"
*
* @brief The class Pair2D_comovingCartesian_linlin
*
* This class is used to handle objects of type <EM>
* Pair2D_comovingCartesian_linlin </EM>.
*/
class Pair2D_comovingCartesian_linlin : public Pair2D_comovingCartesian {
private:
/**
* @name Member functions used to set the binning parameters
*/
///@{
/**
* @brief set the binning parameters given the number of bins
* @return none
*/
void m_set_parameters_nbins () override;
/**
* @brief set the binning parameters given the bin size
* @return none
*/
void m_set_parameters_binSize () override;
///@}
public:
/**
* @name Constructors/destructors
*/
///@{
/**
* @brief default constuctor
* @return object of class Pair2D_comovingCartesian_linlin
*/
Pair2D_comovingCartesian_linlin () { m_pairType = _comovingCartesian_linlin_; }
/**
* @brief constuctor
* @param rpMin minimum perpendicular separation used to count the
* pairs
* @param rpMax maximum perpendicular separation used to count the
* pairs
* @param nbins_rp number of bins in the perpendicular separation
* @param shift_rp shift parameter in the perpendicular separation,
* i.e. the shift is binSize*shift
* @param piMin minimum parallel separation used to count the pairs
* @param piMax maximum parallel separation used to count the pairs
* @param nbins_pi number of bins in the parallel separation
* @param shift_pi shift parameter in the parallel separation,
* i.e. the shift is binSize*shift
* @param angularUnits angular units
* @param angularWeight angular weight function
* @return object of class Pair2D_comovingCartesian
*/
Pair2D_comovingCartesian_linlin (const double rpMin, const double rpMax, const int nbins_rp, const double shift_rp, const double piMin, const double piMax, const int nbins_pi, const double shift_pi, const CoordUnits angularUnits=_radians_, function<double(double)> angularWeight=nullptr)
: Pair2D_comovingCartesian(rpMin, rpMax, nbins_rp, shift_rp, piMin, piMax, nbins_pi, shift_pi, angularUnits, angularWeight)
{ m_pairType = _comovingCartesian_linlin_; m_set_parameters_nbins(); m_PP2D.resize(m_nbins_D1+1, vector<double>(m_nbins_D2+1, 0.)); }
/**
* @brief constuctor
* @param rpMin minimum perpendicular separation used to count the
* pairs
* @param rpMax maximum perpendicular separation used to count the
* pairs
* @param binSize_rp size of the bins in the perpendicular separation
* @param shift_rp shift parameter in the perpendicular separation,
* i.e. the shift is binSize*shift
* @param piMin minimum parallel separation used to count the pairs
* @param piMax maximum parallel separation used to count the pairs
* @param binSize_pi size of the bins in the parallel separation
* @param shift_pi shift parameter in the parallel separation,
* i.e. the shift is binSize*shift
* @param angularUnits angular units
* @param angularWeight angular weight function
* @return object of class Pair2D_comovingCartesian
*/
Pair2D_comovingCartesian_linlin (const double rpMin, const double rpMax, const double binSize_rp, const double shift_rp, const double piMin, const double piMax, const double binSize_pi, const double shift_pi, const CoordUnits angularUnits=_radians_, function<double(double)> angularWeight=nullptr)
: Pair2D_comovingCartesian(rpMin, rpMax, binSize_rp, shift_rp, piMin, piMax, binSize_pi, shift_pi, angularUnits, angularWeight)
{ m_pairType = _comovingCartesian_linlin_; m_set_parameters_binSize(); m_PP2D.resize(m_nbins_D1+1, vector<double>(m_nbins_D2+1, 0.)); }
/**
* @brief default destructor
* @return none
*/
~Pair2D_comovingCartesian_linlin () = default;
///@}
/**
* @name Member functions used to handle pairs
*/
///@{
/**
* @brief estimate the distance between two objects and update the
* pair vector accordingly
* @param obj1 pointer to an object of class Object
* @param obj2 pointer to an object of class Object
* @return none
*/
void put (const shared_ptr<catalogue::Object> obj1, const shared_ptr<catalogue::Object> obj2) override;
///@}
};
// ============================================================================================
// ============================================================================================
/**
* @class Pair2D_comovingCartesian_loglin Pair2D.h
* "Headers/Lib/Pair2D.h"
*
* @brief The class Pair2D_comovingCartesian_loglin
*
* This class is used to handle objects of type <EM>
* Pair2D_comovingCartesian_loglin </EM>.
*/
class Pair2D_comovingCartesian_loglin : public Pair2D_comovingCartesian {
private:
/**
* @name Member functions used to set the binning parameters
*/
///@{
/**
* @brief set the binning parameters given the number of bins
* @return none
*/
void m_set_parameters_nbins () override;
/**
* @brief set the binning parameters given the bin size
* @return none
*/
void m_set_parameters_binSize () override;
///@}
public:
/**
* @name Constructors/destructors
*/
///@{
/**
* @brief default constuctor
* @return object of class Pair2D_comovingCartesian_loglin
*/
Pair2D_comovingCartesian_loglin () { m_pairType = _comovingCartesian_loglin_; m_PP2D.resize(m_nbins_D1+1, vector<double>(m_nbins_D2+1, 0.)); }
/**
* @brief constuctor
* @param rpMin minimum perpendicular separation used to count the
* pairs
* @param rpMax maximum perpendicular separation used to count the
* pairs
* @param nbins_rp number of bins in the perpendicular separation
* @param shift_rp shift parameter in the perpendicular separation,
* i.e. the shift is binSize*shift
* @param piMin minimum parallel separation used to count the pairs
* @param piMax maximum parallel separation used to count the pairs
* @param nbins_pi number of bins in the parallel separation
* @param shift_pi shift parameter in the parallel separation,
* i.e. the shift is binSize*shift
* @param angularUnits angular units
* @param angularWeight angular weight function
* @return object of class Pair2D_comovingCartesian
*/
Pair2D_comovingCartesian_loglin (const double rpMin, const double rpMax, const int nbins_rp, const double shift_rp, const double piMin, const double piMax, const int nbins_pi, const double shift_pi, const CoordUnits angularUnits=_radians_, function<double(double)> angularWeight=nullptr)
: Pair2D_comovingCartesian(rpMin, rpMax, nbins_rp, shift_rp, piMin, piMax, nbins_pi, shift_pi, angularUnits, angularWeight)
{ m_pairType = _comovingCartesian_loglin_; m_set_parameters_nbins(); m_PP2D.resize(m_nbins_D1+1, vector<double>(m_nbins_D2+1, 0.)); }
/**
* @brief constuctor
* @param rpMin minimum perpendicular separation used to count the
* pairs
* @param rpMax maximum perpendicular separation used to count the
* pairs
* @param binSize_rp size of the bins in the perpendicular separation
* @param shift_rp shift parameter in the perpendicular separation,
* i.e. the shift is binSize*shift
* @param piMin minimum parallel separation used to count the pairs
* @param piMax maximum parallel separation used to count the pairs
* @param binSize_pi size of the bins in the parallel separation
* @param shift_pi shift parameter in the parallel separation,
* i.e. the shift is binSize*shift
* @param angularUnits angular units
* @param angularWeight angular weight function
* @return object of class Pair2D_comovingCartesian
*/
Pair2D_comovingCartesian_loglin (const double rpMin, const double rpMax, const double binSize_rp, const double shift_rp, const double piMin, const double piMax, const double binSize_pi, const double shift_pi, const CoordUnits angularUnits=_radians_, function<double(double)> angularWeight=nullptr)
: Pair2D_comovingCartesian(rpMin, rpMax, binSize_rp, shift_rp, piMin, piMax, binSize_pi, shift_pi, angularUnits, angularWeight)
{ m_pairType = _comovingCartesian_loglin_; m_set_parameters_binSize(); m_PP2D.resize(m_nbins_D1+1, vector<double>(m_nbins_D2+1, 0.)); }
/**
* @brief default destructor
* @return none
*/
~Pair2D_comovingCartesian_loglin () = default;
///@}
/**
* @name Member functions used to handle pairs
*/
///@{
/**
* @brief estimate the distance between two objects and update the
* pair vector accordingly
* @param obj1 pointer to an object of class Object
* @param obj2 pointer to an object of class Object
* @return none
*/
void put (const shared_ptr<catalogue::Object> obj1, const shared_ptr<catalogue::Object> obj2) override;
///@}
};
// ============================================================================================
// ============================================================================================
/**
* @class Pair2D_comovingCartesian_linlog Pair2D.h
* "Headers/Lib/Pair2D.h"
*
* @brief The class Pair2D_comovingCartesian_linlog
*
* This class is used to handle objects of type <EM>
* Pair2D_comovingCartesian_linlog </EM>.
*/
class Pair2D_comovingCartesian_linlog : public Pair2D_comovingCartesian {
private:
/**
* @name Member functions used to set the binning parameters
*/
///@{
/**
* @brief set the binning parameters given the number of bins
* @return none
*/
void m_set_parameters_nbins () override;
/**
* @brief set the binning parameters given the bin size
* @return none
*/
void m_set_parameters_binSize () override;
///@}
public:
/**
* @name Constructors/destructors
*/
///@{
/**
* @brief default constuctor
* @return object of class Pair2D_comovingCartesian_linlog
*/
Pair2D_comovingCartesian_linlog () { m_pairType = _comovingCartesian_linlog_; m_PP2D.resize(m_nbins_D1+1, vector<double>(m_nbins_D2+1, 0.)); }
/**
* @brief constuctor
* @param rpMin minimum perpendicular separation used to count the
* pairs
* @param rpMax maximum perpendicular separation used to count the
* pairs
* @param nbins_rp number of bins in the perpendicular separation
* @param shift_rp shift parameter in the perpendicular separation,
* i.e. the shift is binSize*shift
* @param piMin minimum parallel separation used to count the pairs
* @param piMax maximum parallel separation used to count the pairs
* @param nbins_pi number of bins in the parallel separation
* @param shift_pi shift parameter in the parallel separation,
* i.e. the shift is binSize*shift
* @param angularUnits angular units
* @param angularWeight angular weight function
* @return object of class Pair2D_comovingCartesian
*/
Pair2D_comovingCartesian_linlog (const double rpMin, const double rpMax, const int nbins_rp, const double shift_rp, const double piMin, const double piMax, const int nbins_pi, const double shift_pi, const CoordUnits angularUnits=_radians_, function<double(double)> angularWeight=nullptr)
: Pair2D_comovingCartesian(rpMin, rpMax, nbins_rp, shift_rp, piMin, piMax, nbins_pi, shift_pi, angularUnits, angularWeight)
{ m_pairType = _comovingCartesian_linlog_; m_set_parameters_nbins(); m_PP2D.resize(m_nbins_D1+1, vector<double>(m_nbins_D2+1, 0.)); }
/**
* @brief constuctor
* @param rpMin minimum perpendicular separation used to count the
* pairs
* @param rpMax maximum perpendicular separation used to count the
* pairs
* @param binSize_rp size of the bins in the perpendicular separation
* @param shift_rp shift parameter in the perpendicular separation,
* i.e. the shift is binSize*shift
* @param piMin minimum parallel separation used to count the pairs
* @param piMax maximum parallel separation used to count the pairs
* @param binSize_pi size of the bins in the parallel separation
* @param shift_pi shift parameter in the parallel separation,
* i.e. the shift is binSize*shift
* @param angularUnits angular units
* @param angularWeight angular weight function
* @return object of class Pair2D_comovingCartesian
*/
Pair2D_comovingCartesian_linlog (const double rpMin, const double rpMax, const double binSize_rp, const double shift_rp, const double piMin, const double piMax, const double binSize_pi, const double shift_pi, const CoordUnits angularUnits=_radians_, function<double(double)> angularWeight=nullptr)
: Pair2D_comovingCartesian(rpMin, rpMax, binSize_rp, shift_rp, piMin, piMax, binSize_pi, shift_pi, angularUnits, angularWeight)
{ m_pairType = _comovingCartesian_linlog_; m_set_parameters_binSize(); m_PP2D.resize(m_nbins_D1+1, vector<double>(m_nbins_D2+1, 0.)); }
/**
* @brief default destructor
* @return none
*/
~Pair2D_comovingCartesian_linlog () = default;
///@}
/**
* @name Member functions used to handle pairs
*/
///@{
/**
* @brief estimate the distance between two objects and update the
* pair vector accordingly
* @param obj1 pointer to an object of class Object
* @param obj2 pointer to an object of class Object
* @return none
*/
void put (const shared_ptr<catalogue::Object> obj1, const shared_ptr<catalogue::Object> obj2) override;
///@}
};
// ============================================================================================
// ============================================================================================
/**
* @class Pair2D_comovingCartesian_loglog Pair2D.h
* "Headers/Lib/Pair2D.h"
*
* @brief The class Pair2D_comovingCartesian_loglog
*
* This class is used to handle objects of type <EM>
* Pair2D_comovingCartesian_loglog </EM>.
*/
class Pair2D_comovingCartesian_loglog : public Pair2D_comovingCartesian {
private:
/**
* @name Member functions used to set the binning parameters
*/
///@{
/**
* @brief set the binning parameters given the number of bins
* @return none
*/
void m_set_parameters_nbins () override;
/**
* @brief set the binning parameters given the bin size
* @return none
*/
void m_set_parameters_binSize () override;
///@}
public:
/**
* @name Constructors/destructors
*/
///@{
/**
* @brief default constuctor
* @return object of class Pair2D_comovingCartesian_loglog
*/
Pair2D_comovingCartesian_loglog () { m_pairType = _comovingCartesian_loglog_; m_PP2D.resize(m_nbins_D1+1, vector<double>(m_nbins_D2+1, 0.)); }
/**
* @brief constuctor
* @param rpMin minimum perpendicular separation used to count the
* pairs
* @param rpMax maximum perpendicular separation used to count the
* pairs
* @param nbins_rp number of bins in the perpendicular separation
* @param shift_rp shift parameter in the perpendicular separation,
* i.e. the shift is binSize*shift
* @param piMin minimum parallel separation used to count the pairs
* @param piMax maximum parallel separation used to count the pairs
* @param nbins_pi number of bins in the parallel separation
* @param shift_pi shift parameter in the parallel separation,
* i.e. the shift is binSize*shift
* @param angularUnits angular units
* @param angularWeight angular weight function
* @return object of class Pair2D_comovingCartesian
*/
Pair2D_comovingCartesian_loglog (const double rpMin, const double rpMax, const int nbins_rp, const double shift_rp, const double piMin, const double piMax, const int nbins_pi, const double shift_pi, const CoordUnits angularUnits=_radians_, function<double(double)> angularWeight=nullptr)
: Pair2D_comovingCartesian(rpMin, rpMax, nbins_rp, shift_rp, piMin, piMax, nbins_pi, shift_pi, angularUnits, angularWeight)
{ m_pairType = _comovingCartesian_loglog_; m_set_parameters_nbins(); m_PP2D.resize(m_nbins_D1+1, vector<double>(m_nbins_D2+1, 0.)); }
/**
* @brief constuctor
* @param rpMin minimum perpendicular separation used to count the
* pairs
* @param rpMax maximum perpendicular separation used to count the
* pairs
* @param binSize_rp size of the bins in the perpendicular separation
* @param shift_rp shift parameter in the perpendicular separation,
* i.e. the shift is binSize*shift
* @param piMin minimum parallel separation used to count the pairs
* @param piMax maximum parallel separation used to count the pairs
* @param binSize_pi size of the bins in the parallel separation
* @param shift_pi shift parameter in the parallel separation,
* i.e. the shift is binSize*shift
* @param angularUnits angular units
* @param angularWeight angular weight function
* @return object of class Pair2D_comovingCartesian
*/
Pair2D_comovingCartesian_loglog (const double rpMin, const double rpMax, const double binSize_rp, const double shift_rp, const double piMin, const double piMax, const double binSize_pi, const double shift_pi, const CoordUnits angularUnits=_radians_, function<double(double)> angularWeight=nullptr)
: Pair2D_comovingCartesian(rpMin, rpMax, binSize_rp, shift_rp, piMin, piMax, binSize_pi, shift_pi, angularUnits, angularWeight)
{ m_pairType = _comovingCartesian_loglog_; m_set_parameters_binSize(); m_PP2D.resize(m_nbins_D1+1, vector<double>(m_nbins_D2+1, 0.)); }
/**
* @brief default destructor
* @return none
*/
~Pair2D_comovingCartesian_loglog () = default;
///@}
/**
* @name Member functions used to handle pairs
*/
///@{
/**
* @brief estimate the distance between two objects and update the
* pair vector accordingly
* @param obj1 pointer to an object of class Object
* @param obj2 pointer to an object of class Object
* @return none
*/
void put (const shared_ptr<catalogue::Object> obj1, const shared_ptr<catalogue::Object> obj2) override;
///@}
};
// ============================================================================================
// ============================================================================================
/**
* @class Pair2D_comovingPolar Pair2D.h "Headers/Lib/Pair2D.h"
*
* @brief The class Pair2D_comovingPolar
*
* This class is used to handle objects of type <EM>
* Pair2D_comovingPolar </EM>.
*/
class Pair2D_comovingPolar : public Pair2D {
private:
/**
* @name Member functions used to set the binning parameters (customized in all the derived classes)
*/
///@{
/**
* @brief set the binning parameters given the number of bins
* @return none
*/
virtual void m_set_parameters_nbins () = 0;
/**
* @brief set the binning parameters given the bin size
* @return none
*/
virtual void m_set_parameters_binSize () = 0;
///@}
protected:
/**
* @name Binning parameters
*/
///@{
/// minimum separation used to count the pairs
double m_rMin;
/// maximum separation used to count the pairs
double m_rMax;
/// minimum angle used to count the pairs
double m_muMin;
/// maximum angle used to count the pairs
double m_muMax;
///@}
public:
/**
* @name Constructors/destructors
*/
///@{
/**
* @brief default constuctor
* @return object of class Pair2D_comovingPolar
*/
Pair2D_comovingPolar () : m_rMin(0.1), m_rMax(50.), m_muMin(0.1), m_muMax(50.) {}
/**
* @brief constuctor
* @param rMin minimum separation used to count the pairs
* @param rMax maximum separation used to count the pairs
* @param nbins_D1 number of bins in the first dimension
* @param shift_D1 shift parameter in the first dimension,
* i.e. the radial shift is binSize*shift
* @param muMin minimum angle used to count the pairs
* @param muMax maximum angle used to count the pairs
* @param nbins_D2 number of bins in the second dimension
* @param shift_D2 shift parameter in the second dimension,
* i.e. the radial shift is binSize*shift
* @param angularUnits angular units
* @param angularWeight angular weight function
* @return object of class Pair2D_comovingPolar
*/
Pair2D_comovingPolar (const double rMin, const double rMax, const int nbins_D1, const double shift_D1, const double muMin, const double muMax, const int nbins_D2, const double shift_D2, const CoordUnits angularUnits=_radians_, function<double(double)> angularWeight=nullptr)
: Pair2D(1., nbins_D1, shift_D1, 1., nbins_D2, shift_D2, angularUnits, angularWeight), m_rMin(rMin), m_rMax(rMax), m_muMin(muMin), m_muMax(muMax) {}
/**
* @brief constuctor
* @param rMin minimum separation used to count the pairs
* @param rMax maximum separation used to count the pairs
* @param binSize_D1 size of the bins in the first dimension
* @param shift_D1 shift parameter in the first dimension,
* i.e. the radial shift is binSize*shift
* @param muMin minimum angle used to count the pairs
* @param muMax maximum angle used to count the pairs
* @param binSize_D2 size of the bins in the second dimension
* @param shift_D2 shift parameter in the second dimension,
* i.e. the radial shift is binSize*shift
* @param angularUnits angular units
* @param angularWeight angular weight function
* @return object of class Pair2D_comovingPolar
*/
Pair2D_comovingPolar (const double rMin, const double rMax, const double binSize_D1, const double shift_D1, const double muMin, const double muMax, const double binSize_D2, const double shift_D2, const CoordUnits angularUnits=_radians_, function<double(double)> angularWeight=nullptr)
: Pair2D(binSize_D1, 50, shift_D1, binSize_D2, 50, shift_D2, angularUnits, angularWeight), m_rMin(rMin), m_rMax(rMax), m_muMin(muMin), m_muMax(muMax) {}
/**
* @brief default destructor
* @return none
*/
virtual ~Pair2D_comovingPolar () = default;
///@}
/**
* @name Member functions used to get the protected parameters
*/
///@{
/**
* @brief get the protected member Pair2D::m_rMin
* @return the minimum separation used to count the pairs
*/
double sMin_D1 () const override { return m_rMin; }
/**
* @brief get the protected member Pair2D::m_rMax
* @return the maximum separation used to count the pairs
*/
double sMax_D1 () const override { return m_rMax; }
/**
* @brief get the protected member Pair2D::m_muMin
* @return the minimum angle used to count the pairs
*/
double sMin_D2 () const override { return m_muMin; }
/**
* @brief get the protected member Pair2D::m_muMax
* @return the maximum angle used to count the pairs
*/
double sMax_D2 () const override { return m_muMax; }
///@}
};
// ============================================================================================
// ============================================================================================
/**
* @class Pair2D_comovingPolar_linlin Pair2D.h
* "Headers/Lib/Pair2D.h"
*
* @brief The class Pair2D_comovingPolar_linlin
*
* This class is used to handle objects of type <EM>
* Pair2D_comovingPolar_linlin </EM>.
*/
class Pair2D_comovingPolar_linlin : public Pair2D_comovingPolar {
private:
/**
* @name Member functions used to set the binning parameters
*/
///@{
/**
* @brief set the binning parameters given the number of bins
* @return none
*/
void m_set_parameters_nbins () override;
/**
* @brief set the binning parameters given the bin size
* @return none
*/
void m_set_parameters_binSize () override;
///@}
public:
/**
* @name Constructors/destructors
*/
///@{
/**
* @brief default constuctor
* @return object of class Pair2D_comovingPolar_linlin
*/
Pair2D_comovingPolar_linlin () { m_pairType = _comovingPolar_linlin_; }
/**
* @brief constuctor
* @param rMin minimum separation used to count the pairs
* @param rMax maximum separation used to count the pairs
* @param nbins_D1 number of bins in the first dimension
* @param shift_D1 shift parameter in the first dimension,
* i.e. the radial shift is binSize*shift
* @param muMin minimum angle used to count the pairs
* @param muMax maximum angle used to count the pairs
* @param nbins_D2 number of bins in the second dimension
* @param shift_D2 shift parameter in the second dimension,
* i.e. the radial shift is binSize*shift
* @param angularUnits angular units
* @param angularWeight angular weight function
* @return object of class Pair2D_comovingPolar
*/
Pair2D_comovingPolar_linlin (const double rMin, const double rMax, const int nbins_D1, const double shift_D1, const double muMin, const double muMax, const int nbins_D2, const double shift_D2, const CoordUnits angularUnits=_radians_, function<double(double)> angularWeight=nullptr)
: Pair2D_comovingPolar(rMin, rMax, nbins_D1, shift_D1, muMin, muMax, nbins_D2, shift_D2, angularUnits, angularWeight)
{ m_pairType = _comovingPolar_linlin_; m_set_parameters_nbins(); m_PP2D.resize(m_nbins_D1+1, vector<double>(m_nbins_D2+1, 0.)); }
/**
* @brief constuctor
* @param rMin minimum separation used to count the pairs
* @param rMax maximum separation used to count the pairs
* @param binSize_D1 size of the bins in the first dimension
* @param shift_D1 shift parameter in the first dimension,
* i.e. the radial shift is binSize*shift
* @param muMin minimum angle used to count the pairs
* @param muMax maximum angle used to count the pairs
* @param binSize_D2 size of the bins in the second dimension
* @param shift_D2 shift parameter in the second dimension,
* i.e. the radial shift is binSize*shift
* @param angularUnits angular units
* @param angularWeight angular weight function
* @return object of class Pair2D_comovingPolar
*/
Pair2D_comovingPolar_linlin (const double rMin, const double rMax, const double binSize_D1, const double shift_D1, const double muMin, const double muMax, const double binSize_D2, const double shift_D2, const CoordUnits angularUnits=_radians_, function<double(double)> angularWeight=nullptr)
: Pair2D_comovingPolar(rMin, rMax, binSize_D1, shift_D1, muMin, muMax, binSize_D2, shift_D2, angularUnits, angularWeight)
{ m_pairType = _comovingPolar_linlin_; m_set_parameters_binSize(); m_PP2D.resize(m_nbins_D1+1, vector<double>(m_nbins_D2+1, 0.)); }
/**
* @brief default destructor
* @return none
*/
~Pair2D_comovingPolar_linlin () = default;
///@}
/**
* @name Member functions used to handle pairs
*/
///@{
/**
* @brief estimate the distance between two objects and update the
* pair vector accordingly
* @param obj1 pointer to an object of class Object
* @param obj2 pointer to an object of class Object
* @return none
*/
void put (const shared_ptr<catalogue::Object> obj1, const shared_ptr<catalogue::Object> obj2) override;
///@}
};
// ============================================================================================
// ============================================================================================
/**
* @class Pair2D_comovingPolar_loglin Pair2D.h
* "Headers/Lib/Pair2D.h"
*
* @brief The class Pair2D_comovingPolar_loglin
*
* This class is used to handle objects of type <EM>
* Pair2D_comovingPolar_loglin </EM>.
*/
class Pair2D_comovingPolar_loglin : public Pair2D_comovingPolar {
private:
/**
* @name Member functions used to set the binning parameters
*/
///@{
/**
* @brief set the binning parameters given the number of bins
* @return none
*/
void m_set_parameters_nbins () override;
/**
* @brief set the binning parameters given the bin size
* @return none
*/
void m_set_parameters_binSize () override;
///@}
public:
/**
* @name Constructors/destructors
*/
///@{
/**
* @brief default constuctor
* @return object of class Pair2D_comovingPolar_loglin
*/
Pair2D_comovingPolar_loglin () { m_pairType = _comovingPolar_loglin_; m_PP2D.resize(m_nbins_D1+1, vector<double>(m_nbins_D2+1, 0.)); }
/**
* @brief constuctor
* @param rMin minimum separation used to count the pairs
* @param rMax maximum separation used to count the pairs
* @param nbins_D1 number of bins in the first dimension
* @param shift_D1 shift parameter in the first dimension,
* i.e. the radial shift is binSize*shift
* @param muMin minimum angle used to count the pairs
* @param muMax maximum angle used to count the pairs
* @param nbins_D2 number of bins in the second dimension
* @param shift_D2 shift parameter in the second dimension,
* i.e. the radial shift is binSize*shift
* @param angularUnits angular units
* @param angularWeight angular weight function
* @return object of class Pair2D_comovingPolar
*/
Pair2D_comovingPolar_loglin (const double rMin, const double rMax, const int nbins_D1, const double shift_D1, const double muMin, const double muMax, const int nbins_D2, const double shift_D2, const CoordUnits angularUnits=_radians_, function<double(double)> angularWeight=nullptr)
: Pair2D_comovingPolar(rMin, rMax, nbins_D1, shift_D1, muMin, muMax, nbins_D2, shift_D2, angularUnits, angularWeight)
{ m_pairType = _comovingPolar_loglin_; m_set_parameters_nbins(); m_PP2D.resize(m_nbins_D1+1, vector<double>(m_nbins_D2+1, 0.)); }
/**
* @brief constuctor
* @param rMin minimum separation used to count the pairs
* @param rMax maximum separation used to count the pairs
* @param binSize_D1 size of the bins in the first dimension
* @param shift_D1 shift parameter in the first dimension,
* i.e. the radial shift is binSize*shift
* @param muMin minimum angle used to count the pairs
* @param muMax maximum angle used to count the pairs
* @param binSize_D2 size of the bins in the second dimension
* @param shift_D2 shift parameter in the second dimension,
* i.e. the radial shift is binSize*shift
* @param angularUnits angular units
* @param angularWeight angular weight function
* @return object of class Pair2D_comovingPolar
*/
Pair2D_comovingPolar_loglin (const double rMin, const double rMax, const double binSize_D1, const double shift_D1, const double muMin, const double muMax, const double binSize_D2, const double shift_D2, const CoordUnits angularUnits=_radians_, function<double(double)> angularWeight=nullptr)
: Pair2D_comovingPolar(rMin, rMax, binSize_D1, shift_D1, muMin, muMax, binSize_D2, shift_D2, angularUnits, angularWeight)
{ m_pairType = _comovingPolar_loglin_; m_set_parameters_binSize(); m_PP2D.resize(m_nbins_D1+1, vector<double>(m_nbins_D2+1, 0.)); }
/**
* @brief default destructor
* @return none
*/
~Pair2D_comovingPolar_loglin () = default;
///@}
/**
* @name Member functions used to handle pairs
*/
///@{
/**
* @brief estimate the distance between two objects and update the
* pair vector accordingly
* @param obj1 pointer to an object of class Object
* @param obj2 pointer to an object of class Object
* @return none
*/
void put (const shared_ptr<catalogue::Object> obj1, const shared_ptr<catalogue::Object> obj2) override;
///@}
};
// ============================================================================================
// ============================================================================================
/**
* @class Pair2D_comovingPolar_linlog Pair2D.h
* "Headers/Lib/Pair2D.h"
*
* @brief The class Pair2D_comovingPolar_linlog
*
* This class is used to handle objects of type <EM>
* Pair2D_comovingPolar_linlog </EM>.
*/
class Pair2D_comovingPolar_linlog : public Pair2D_comovingPolar {
private:
/**
* @name Member functions used to set the binning parameters
*/
///@{
/**
* @brief set the binning parameters given the number of bins
* @return none
*/
void m_set_parameters_nbins () override;
/**
* @brief set the binning parameters given the bin size
* @return none
*/
void m_set_parameters_binSize () override;
///@}
public:
/**
* @name Constructors/destructors
*/
///@{
/**
* @brief default constuctor
* @return object of class Pair2D_comovingPolar_linlog
*/
Pair2D_comovingPolar_linlog () { m_pairType = _comovingPolar_linlog_; m_PP2D.resize(m_nbins_D1+1, vector<double>(m_nbins_D2+1, 0.)); }
/**
* @brief constuctor
* @param rMin minimum separation used to count the pairs
* @param rMax maximum separation used to count the pairs
* @param nbins_D1 number of bins in the first dimension
* @param shift_D1 shift parameter in the first dimension,
* i.e. the radial shift is binSize*shift
* @param muMin minimum angle used to count the pairs
* @param muMax maximum angle used to count the pairs
* @param nbins_D2 number of bins in the second dimension
* @param shift_D2 shift parameter in the second dimension,
* i.e. the radial shift is binSize*shift
* @param angularUnits angular units
* @param angularWeight angular weight function
* @return object of class Pair2D_comovingPolar
*/
Pair2D_comovingPolar_linlog (const double rMin, const double rMax, const int nbins_D1, const double shift_D1, const double muMin, const double muMax, const int nbins_D2, const double shift_D2, const CoordUnits angularUnits=_radians_, function<double(double)> angularWeight=nullptr)
: Pair2D_comovingPolar(rMin, rMax, nbins_D1, shift_D1, muMin, muMax, nbins_D2, shift_D2, angularUnits, angularWeight)
{ m_pairType = _comovingPolar_linlog_; m_set_parameters_nbins(); m_PP2D.resize(m_nbins_D1+1, vector<double>(m_nbins_D2+1, 0.)); }
/**
* @brief constuctor
* @param rMin minimum separation used to count the pairs
* @param rMax maximum separation used to count the pairs
* @param binSize_D1 size of the bins in the first dimension
* @param shift_D1 shift parameter in the first dimension,
* i.e. the radial shift is binSize*shift
* @param muMin minimum angle used to count the pairs
* @param muMax maximum angle used to count the pairs
* @param binSize_D2 size of the bins in the second dimension
* @param shift_D2 shift parameter in the second dimension,
* i.e. the radial shift is binSize*shift
* @param angularUnits angular units
* @param angularWeight angular weight function
* @return object of class Pair2D_comovingPolar
*/
Pair2D_comovingPolar_linlog (const double rMin, const double rMax, const double binSize_D1, const double shift_D1, const double muMin, const double muMax, const double binSize_D2, const double shift_D2, const CoordUnits angularUnits=_radians_, function<double(double)> angularWeight=nullptr)
: Pair2D_comovingPolar(rMin, rMax, binSize_D1, shift_D1, muMin, muMax, binSize_D2, shift_D2, angularUnits, angularWeight)
{ m_pairType = _comovingPolar_linlog_; m_set_parameters_binSize(); m_PP2D.resize(m_nbins_D1+1, vector<double>(m_nbins_D2+1, 0.)); }
/**
* @brief default destructor
* @return none
*/
~Pair2D_comovingPolar_linlog () = default;
///@}
/**
* @name Member functions used to handle pairs
*/
///@{
/**
* @brief estimate the distance between two objects and update the
* pair vector accordingly
* @param obj1 pointer to an object of class Object
* @param obj2 pointer to an object of class Object
* @return none
*/
void put (const shared_ptr<catalogue::Object> obj1, const shared_ptr<catalogue::Object> obj2) override;
///@}
};
// ============================================================================================
// ============================================================================================
/**
* @class Pair2D_comovingPolar_loglog Pair2D.h
* "Headers/Lib/Pair2D.h"
*
* @brief The class Pair2D_comovingPolar_loglog
*
* This class is used to handle objects of type <EM>
* Pair2D_comovingPolar_loglog </EM>.
*/
class Pair2D_comovingPolar_loglog : public Pair2D_comovingPolar {
private:
/**
* @name Member functions used to set the binning parameters
*/
///@{
/**
* @brief set the binning parameters given the number of bins
* @return none
*/
void m_set_parameters_nbins () override;
/**
* @brief set the binning parameters given the bin size
* @return none
*/
void m_set_parameters_binSize () override;
///@}
public:
/**
* @name Constructors/destructors
*/
///@{
/**
* @brief default constuctor
* @return object of class Pair2D_comovingPolar_loglog
*/
Pair2D_comovingPolar_loglog () { m_pairType = _comovingPolar_loglog_; m_PP2D.resize(m_nbins_D1+1, vector<double>(m_nbins_D2+1, 0.)); }
/**
* @brief constuctor
* @param rMin minimum separation used to count the pairs
* @param rMax maximum separation used to count the pairs
* @param nbins_D1 number of bins in the first dimension
* @param shift_D1 shift parameter in the first dimension,
* i.e. the radial shift is binSize*shift
* @param muMin minimum angle used to count the pairs
* @param muMax maximum angle used to count the pairs
* @param nbins_D2 number of bins in the second dimension
* @param shift_D2 shift parameter in the second dimension,
* i.e. the radial shift is binSize*shift
* @param angularUnits angular units
* @param angularWeight angular weight function
* @return object of class Pair2D_comovingPolar
*/
Pair2D_comovingPolar_loglog (const double rMin, const double rMax, const int nbins_D1, const double shift_D1, const double muMin, const double muMax, const int nbins_D2, const double shift_D2, const CoordUnits angularUnits=_radians_, function<double(double)> angularWeight=nullptr)
: Pair2D_comovingPolar(rMin, rMax, nbins_D1, shift_D1, muMin, muMax, nbins_D2, shift_D2, angularUnits, angularWeight)
{ m_pairType = _comovingPolar_loglog_; m_set_parameters_nbins(); m_PP2D.resize(m_nbins_D1+1, vector<double>(m_nbins_D2+1, 0.)); }
/**
* @brief constuctor
* @param rMin minimum separation used to count the pairs
* @param rMax maximum separation used to count the pairs
* @param binSize_D1 size of the bins in the first dimension
* @param shift_D1 shift parameter in the first dimension,
* i.e. the radial shift is binSize*shift
* @param muMin minimum angle used to count the pairs
* @param muMax maximum angle used to count the pairs
* @param binSize_D2 size of the bins in the second dimension
* @param shift_D2 shift parameter in the second dimension,
* i.e. the radial shift is binSize*shift
* @param angularUnits angular units
* @param angularWeight angular weight function
* @return object of class Pair2D_comovingPolar
*/
Pair2D_comovingPolar_loglog (const double rMin, const double rMax, const double binSize_D1, const double shift_D1, const double muMin, const double muMax, const double binSize_D2, const double shift_D2, const CoordUnits angularUnits=_radians_, function<double(double)> angularWeight=nullptr)
: Pair2D_comovingPolar(rMin, rMax, binSize_D1, shift_D1, muMin, muMax, binSize_D2, shift_D2, angularUnits, angularWeight)
{ m_pairType = _comovingPolar_loglog_; m_set_parameters_binSize(); m_PP2D.resize(m_nbins_D1+1, vector<double>(m_nbins_D2+1, 0.)); }
/**
* @brief default destructor
* @return none
*/
~Pair2D_comovingPolar_loglog () = default;
///@}
/**
* @name Member functions used to handle pairs
*/
///@{
/**
* @brief estimate the distance between two objects and update the
* pair vector accordingly
* @param obj1 pointer to an object of class Object
* @param obj2 pointer to an object of class Object
* @return none
*/
void put (const shared_ptr<catalogue::Object> obj1, const shared_ptr<catalogue::Object> obj2) override;
///@}
};
}
}
#endif
| [
"federico.marulli3@unibo.it"
] | federico.marulli3@unibo.it |
34020a9c0a1a94ffaedd65204a531c1c26a3ff8b | c67f449dc7187f154df7093a95ddcc14a3f0a18f | /youngseokcoin/src/core_memusage.h | b86f9fb6a82816f76c7cbdc151b5b8307b448b48 | [
"MIT"
] | permissive | youngseokaaa-presentation/A_system_to_ensure_the_integrity_of_Internet_of_things_by_using_Blockchain | cee9ba19e9d029759fc2fe4a43235c56fd9abe43 | b2a47bc63386b5a115fc3ce62997034ebd8d4a1e | refs/heads/master | 2023-02-17T07:58:43.043470 | 2021-01-11T05:40:28 | 2021-01-11T05:40:28 | 295,317,246 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,619 | h | // Copyright (c) 2015-2016 The Youngseokcoin Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#ifndef YOUNGSEOKCOIN_CORE_MEMUSAGE_H
#define YOUNGSEOKCOIN_CORE_MEMUSAGE_H
#include "primitives/transaction.h"
#include "primitives/block.h"
#include "memusage.h"
static inline size_t RecursiveDynamicUsage(const CScript& script) {
return memusage::DynamicUsage(script);
}
static inline size_t RecursiveDynamicUsage(const COutPoint& out) {
return 0;
}
static inline size_t RecursiveDynamicUsage(const CTxIn& in) {
size_t mem = RecursiveDynamicUsage(in.scriptSig) + RecursiveDynamicUsage(in.prevout) + memusage::DynamicUsage(in.scriptWitness.stack);
for (std::vector<std::vector<unsigned char> >::const_iterator it = in.scriptWitness.stack.begin(); it != in.scriptWitness.stack.end(); it++) {
mem += memusage::DynamicUsage(*it);
}
return mem;
}
static inline size_t RecursiveDynamicUsage(const CTxOut& out) {
return RecursiveDynamicUsage(out.scriptPubKey);
}
static inline size_t RecursiveDynamicUsage(const CTransaction& tx) {
size_t mem = memusage::DynamicUsage(tx.vin) + memusage::DynamicUsage(tx.vout);
for (std::vector<CTxIn>::const_iterator it = tx.vin.begin(); it != tx.vin.end(); it++) {
mem += RecursiveDynamicUsage(*it);
}
for (std::vector<CTxOut>::const_iterator it = tx.vout.begin(); it != tx.vout.end(); it++) {
mem += RecursiveDynamicUsage(*it);
}
return mem;
}
static inline size_t RecursiveDynamicUsage(const CMutableTransaction& tx) {
size_t mem = memusage::DynamicUsage(tx.vin) + memusage::DynamicUsage(tx.vout);
for (std::vector<CTxIn>::const_iterator it = tx.vin.begin(); it != tx.vin.end(); it++) {
mem += RecursiveDynamicUsage(*it);
}
for (std::vector<CTxOut>::const_iterator it = tx.vout.begin(); it != tx.vout.end(); it++) {
mem += RecursiveDynamicUsage(*it);
}
return mem;
}
static inline size_t RecursiveDynamicUsage(const CBlock& block) {
size_t mem = memusage::DynamicUsage(block.vtx);
for (const auto& tx : block.vtx) {
mem += memusage::DynamicUsage(tx) + RecursiveDynamicUsage(*tx);
}
return mem;
}
static inline size_t RecursiveDynamicUsage(const CBlockLocator& locator) {
return memusage::DynamicUsage(locator.vHave);
}
template<typename X>
static inline size_t RecursiveDynamicUsage(const std::shared_ptr<X>& p) {
return p ? memusage::DynamicUsage(p) + RecursiveDynamicUsage(*p) : 0;
}
#endif // YOUNGSEOKCOIN_CORE_MEMUSAGE_H
| [
"youngseokaaa@gmail.com"
] | youngseokaaa@gmail.com |
81f6471cf590469ae8a28f8ee3b45bd7d74a7df6 | 84dbfab22acd93cd6ba628e63178e2933523d554 | /3rdparty/include/caffe/proto/caffe.pb.h | 943dffe07c76e1f2c4d86d2ddacc925dd53c4190 | [
"MulanPSL-2.0",
"LicenseRef-scancode-mulanpsl-2.0-en",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | windowxiaoming/ubiquitous-perception | c75d4441f008cef5df5e8c9dd9aee190434a7656 | 1f9ca8947523e71259c9736eed7c62c525eb77d8 | refs/heads/main | 2023-03-28T02:25:07.733542 | 2021-03-14T05:33:30 | 2021-03-14T05:33:30 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | true | 1,988,365 | h | // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: caffe.proto
#ifndef GOOGLE_PROTOBUF_INCLUDED_caffe_2eproto
#define GOOGLE_PROTOBUF_INCLUDED_caffe_2eproto
#include <limits>
#include <string>
#include <google/protobuf/port_def.inc>
#if PROTOBUF_VERSION < 3013000
#error This file was generated by a newer version of protoc which is
#error incompatible with your Protocol Buffer headers. Please update
#error your headers.
#endif
#if 3013000 < PROTOBUF_MIN_PROTOC_VERSION
#error This file was generated by an older version of protoc which is
#error incompatible with your Protocol Buffer headers. Please
#error regenerate this file with a newer version of protoc.
#endif
#include <google/protobuf/port_undef.inc>
#include <google/protobuf/io/coded_stream.h>
#include <google/protobuf/arena.h>
#include <google/protobuf/arenastring.h>
#include <google/protobuf/generated_message_table_driven.h>
#include <google/protobuf/generated_message_util.h>
#include <google/protobuf/inlined_string_field.h>
#include <google/protobuf/metadata_lite.h>
#include <google/protobuf/generated_message_reflection.h>
#include <google/protobuf/message.h>
#include <google/protobuf/repeated_field.h> // IWYU pragma: export
#include <google/protobuf/extension_set.h> // IWYU pragma: export
#include <google/protobuf/generated_enum_reflection.h>
#include <google/protobuf/unknown_field_set.h>
// @@protoc_insertion_point(includes)
#include <google/protobuf/port_def.inc>
#define PROTOBUF_INTERNAL_EXPORT_caffe_2eproto
PROTOBUF_NAMESPACE_OPEN
namespace internal {
class AnyMetadata;
} // namespace internal
PROTOBUF_NAMESPACE_CLOSE
// Internal implementation detail -- do not use these members.
struct TableStruct_caffe_2eproto {
static const ::PROTOBUF_NAMESPACE_ID::internal::ParseTableField entries[]
PROTOBUF_SECTION_VARIABLE(protodesc_cold);
static const ::PROTOBUF_NAMESPACE_ID::internal::AuxiliaryParseTableField aux[]
PROTOBUF_SECTION_VARIABLE(protodesc_cold);
static const ::PROTOBUF_NAMESPACE_ID::internal::ParseTable schema[91]
PROTOBUF_SECTION_VARIABLE(protodesc_cold);
static const ::PROTOBUF_NAMESPACE_ID::internal::FieldMetadata field_metadata[];
static const ::PROTOBUF_NAMESPACE_ID::internal::SerializationTable serialization_table[];
static const ::PROTOBUF_NAMESPACE_ID::uint32 offsets[];
};
extern const ::PROTOBUF_NAMESPACE_ID::internal::DescriptorTable descriptor_table_caffe_2eproto;
namespace caffe {
class AccuracyParameter;
class AccuracyParameterDefaultTypeInternal;
extern AccuracyParameterDefaultTypeInternal _AccuracyParameter_default_instance_;
class AnnotatedDataParameter;
class AnnotatedDataParameterDefaultTypeInternal;
extern AnnotatedDataParameterDefaultTypeInternal _AnnotatedDataParameter_default_instance_;
class AnnotatedDatum;
class AnnotatedDatumDefaultTypeInternal;
extern AnnotatedDatumDefaultTypeInternal _AnnotatedDatum_default_instance_;
class Annotation;
class AnnotationDefaultTypeInternal;
extern AnnotationDefaultTypeInternal _Annotation_default_instance_;
class AnnotationGroup;
class AnnotationGroupDefaultTypeInternal;
extern AnnotationGroupDefaultTypeInternal _AnnotationGroup_default_instance_;
class ArgMaxParameter;
class ArgMaxParameterDefaultTypeInternal;
extern ArgMaxParameterDefaultTypeInternal _ArgMaxParameter_default_instance_;
class BatchNormParameter;
class BatchNormParameterDefaultTypeInternal;
extern BatchNormParameterDefaultTypeInternal _BatchNormParameter_default_instance_;
class BatchSampler;
class BatchSamplerDefaultTypeInternal;
extern BatchSamplerDefaultTypeInternal _BatchSampler_default_instance_;
class BiasParameter;
class BiasParameterDefaultTypeInternal;
extern BiasParameterDefaultTypeInternal _BiasParameter_default_instance_;
class BlobProto;
class BlobProtoDefaultTypeInternal;
extern BlobProtoDefaultTypeInternal _BlobProto_default_instance_;
class BlobProtoVector;
class BlobProtoVectorDefaultTypeInternal;
extern BlobProtoVectorDefaultTypeInternal _BlobProtoVector_default_instance_;
class BlobShape;
class BlobShapeDefaultTypeInternal;
extern BlobShapeDefaultTypeInternal _BlobShape_default_instance_;
class ConcatParameter;
class ConcatParameterDefaultTypeInternal;
extern ConcatParameterDefaultTypeInternal _ConcatParameter_default_instance_;
class ConnectParameter;
class ConnectParameterDefaultTypeInternal;
extern ConnectParameterDefaultTypeInternal _ConnectParameter_default_instance_;
class ContrastiveLossParameter;
class ContrastiveLossParameterDefaultTypeInternal;
extern ContrastiveLossParameterDefaultTypeInternal _ContrastiveLossParameter_default_instance_;
class ConvolutionParameter;
class ConvolutionParameterDefaultTypeInternal;
extern ConvolutionParameterDefaultTypeInternal _ConvolutionParameter_default_instance_;
class CropParameter;
class CropParameterDefaultTypeInternal;
extern CropParameterDefaultTypeInternal _CropParameter_default_instance_;
class DataParameter;
class DataParameterDefaultTypeInternal;
extern DataParameterDefaultTypeInternal _DataParameter_default_instance_;
class Datum;
class DatumDefaultTypeInternal;
extern DatumDefaultTypeInternal _Datum_default_instance_;
class DetectionEvaluateParameter;
class DetectionEvaluateParameterDefaultTypeInternal;
extern DetectionEvaluateParameterDefaultTypeInternal _DetectionEvaluateParameter_default_instance_;
class DetectionOutputParameter;
class DetectionOutputParameterDefaultTypeInternal;
extern DetectionOutputParameterDefaultTypeInternal _DetectionOutputParameter_default_instance_;
class DropoutParameter;
class DropoutParameterDefaultTypeInternal;
extern DropoutParameterDefaultTypeInternal _DropoutParameter_default_instance_;
class DummyDataParameter;
class DummyDataParameterDefaultTypeInternal;
extern DummyDataParameterDefaultTypeInternal _DummyDataParameter_default_instance_;
class ELUParameter;
class ELUParameterDefaultTypeInternal;
extern ELUParameterDefaultTypeInternal _ELUParameter_default_instance_;
class EltwiseParameter;
class EltwiseParameterDefaultTypeInternal;
extern EltwiseParameterDefaultTypeInternal _EltwiseParameter_default_instance_;
class EmbedParameter;
class EmbedParameterDefaultTypeInternal;
extern EmbedParameterDefaultTypeInternal _EmbedParameter_default_instance_;
class EmitConstraint;
class EmitConstraintDefaultTypeInternal;
extern EmitConstraintDefaultTypeInternal _EmitConstraint_default_instance_;
class ExpParameter;
class ExpParameterDefaultTypeInternal;
extern ExpParameterDefaultTypeInternal _ExpParameter_default_instance_;
class FaceDataParameter;
class FaceDataParameterDefaultTypeInternal;
extern FaceDataParameterDefaultTypeInternal _FaceDataParameter_default_instance_;
class FillerParameter;
class FillerParameterDefaultTypeInternal;
extern FillerParameterDefaultTypeInternal _FillerParameter_default_instance_;
class FlattenParameter;
class FlattenParameterDefaultTypeInternal;
extern FlattenParameterDefaultTypeInternal _FlattenParameter_default_instance_;
class HDF5DataParameter;
class HDF5DataParameterDefaultTypeInternal;
extern HDF5DataParameterDefaultTypeInternal _HDF5DataParameter_default_instance_;
class HDF5OutputParameter;
class HDF5OutputParameterDefaultTypeInternal;
extern HDF5OutputParameterDefaultTypeInternal _HDF5OutputParameter_default_instance_;
class HingeLossParameter;
class HingeLossParameterDefaultTypeInternal;
extern HingeLossParameterDefaultTypeInternal _HingeLossParameter_default_instance_;
class ImageDataParameter;
class ImageDataParameterDefaultTypeInternal;
extern ImageDataParameterDefaultTypeInternal _ImageDataParameter_default_instance_;
class InfogainLossParameter;
class InfogainLossParameterDefaultTypeInternal;
extern InfogainLossParameterDefaultTypeInternal _InfogainLossParameter_default_instance_;
class InnerProductParameter;
class InnerProductParameterDefaultTypeInternal;
extern InnerProductParameterDefaultTypeInternal _InnerProductParameter_default_instance_;
class InputParameter;
class InputParameterDefaultTypeInternal;
extern InputParameterDefaultTypeInternal _InputParameter_default_instance_;
class LRNParameter;
class LRNParameterDefaultTypeInternal;
extern LRNParameterDefaultTypeInternal _LRNParameter_default_instance_;
class LabelMap;
class LabelMapDefaultTypeInternal;
extern LabelMapDefaultTypeInternal _LabelMap_default_instance_;
class LabelMapItem;
class LabelMapItemDefaultTypeInternal;
extern LabelMapItemDefaultTypeInternal _LabelMapItem_default_instance_;
class LayerParameter;
class LayerParameterDefaultTypeInternal;
extern LayerParameterDefaultTypeInternal _LayerParameter_default_instance_;
class LogParameter;
class LogParameterDefaultTypeInternal;
extern LogParameterDefaultTypeInternal _LogParameter_default_instance_;
class LossParameter;
class LossParameterDefaultTypeInternal;
extern LossParameterDefaultTypeInternal _LossParameter_default_instance_;
class MILDataParameter;
class MILDataParameterDefaultTypeInternal;
extern MILDataParameterDefaultTypeInternal _MILDataParameter_default_instance_;
class MILParameter;
class MILParameterDefaultTypeInternal;
extern MILParameterDefaultTypeInternal _MILParameter_default_instance_;
class MVNParameter;
class MVNParameterDefaultTypeInternal;
extern MVNParameterDefaultTypeInternal _MVNParameter_default_instance_;
class MemoryDataParameter;
class MemoryDataParameterDefaultTypeInternal;
extern MemoryDataParameterDefaultTypeInternal _MemoryDataParameter_default_instance_;
class MultiBoxLossParameter;
class MultiBoxLossParameterDefaultTypeInternal;
extern MultiBoxLossParameterDefaultTypeInternal _MultiBoxLossParameter_default_instance_;
class NetParameter;
class NetParameterDefaultTypeInternal;
extern NetParameterDefaultTypeInternal _NetParameter_default_instance_;
class NetState;
class NetStateDefaultTypeInternal;
extern NetStateDefaultTypeInternal _NetState_default_instance_;
class NetStateRule;
class NetStateRuleDefaultTypeInternal;
extern NetStateRuleDefaultTypeInternal _NetStateRule_default_instance_;
class NoiseParameter;
class NoiseParameterDefaultTypeInternal;
extern NoiseParameterDefaultTypeInternal _NoiseParameter_default_instance_;
class NonMaximumSuppressionParameter;
class NonMaximumSuppressionParameterDefaultTypeInternal;
extern NonMaximumSuppressionParameterDefaultTypeInternal _NonMaximumSuppressionParameter_default_instance_;
class NormalizeParameter;
class NormalizeParameterDefaultTypeInternal;
extern NormalizeParameterDefaultTypeInternal _NormalizeParameter_default_instance_;
class NormalizedBBox;
class NormalizedBBoxDefaultTypeInternal;
extern NormalizedBBoxDefaultTypeInternal _NormalizedBBox_default_instance_;
class PReLUParameter;
class PReLUParameterDefaultTypeInternal;
extern PReLUParameterDefaultTypeInternal _PReLUParameter_default_instance_;
class ParamSpec;
class ParamSpecDefaultTypeInternal;
extern ParamSpecDefaultTypeInternal _ParamSpec_default_instance_;
class ParameterParameter;
class ParameterParameterDefaultTypeInternal;
extern ParameterParameterDefaultTypeInternal _ParameterParameter_default_instance_;
class PermuteParameter;
class PermuteParameterDefaultTypeInternal;
extern PermuteParameterDefaultTypeInternal _PermuteParameter_default_instance_;
class PoolingParameter;
class PoolingParameterDefaultTypeInternal;
extern PoolingParameterDefaultTypeInternal _PoolingParameter_default_instance_;
class PowerParameter;
class PowerParameterDefaultTypeInternal;
extern PowerParameterDefaultTypeInternal _PowerParameter_default_instance_;
class PriorBoxParameter;
class PriorBoxParameterDefaultTypeInternal;
extern PriorBoxParameterDefaultTypeInternal _PriorBoxParameter_default_instance_;
class PythonParameter;
class PythonParameterDefaultTypeInternal;
extern PythonParameterDefaultTypeInternal _PythonParameter_default_instance_;
class ROIPoolingParameter;
class ROIPoolingParameterDefaultTypeInternal;
extern ROIPoolingParameterDefaultTypeInternal _ROIPoolingParameter_default_instance_;
class ReLUParameter;
class ReLUParameterDefaultTypeInternal;
extern ReLUParameterDefaultTypeInternal _ReLUParameter_default_instance_;
class RecurrentParameter;
class RecurrentParameterDefaultTypeInternal;
extern RecurrentParameterDefaultTypeInternal _RecurrentParameter_default_instance_;
class ReductionParameter;
class ReductionParameterDefaultTypeInternal;
extern ReductionParameterDefaultTypeInternal _ReductionParameter_default_instance_;
class ReshapeParameter;
class ReshapeParameterDefaultTypeInternal;
extern ReshapeParameterDefaultTypeInternal _ReshapeParameter_default_instance_;
class ResizeParameter;
class ResizeParameterDefaultTypeInternal;
extern ResizeParameterDefaultTypeInternal _ResizeParameter_default_instance_;
class SPPParameter;
class SPPParameterDefaultTypeInternal;
extern SPPParameterDefaultTypeInternal _SPPParameter_default_instance_;
class SaltPepperParameter;
class SaltPepperParameterDefaultTypeInternal;
extern SaltPepperParameterDefaultTypeInternal _SaltPepperParameter_default_instance_;
class SampleConstraint;
class SampleConstraintDefaultTypeInternal;
extern SampleConstraintDefaultTypeInternal _SampleConstraint_default_instance_;
class Sampler;
class SamplerDefaultTypeInternal;
extern SamplerDefaultTypeInternal _Sampler_default_instance_;
class SaveOutputParameter;
class SaveOutputParameterDefaultTypeInternal;
extern SaveOutputParameterDefaultTypeInternal _SaveOutputParameter_default_instance_;
class ScaleParameter;
class ScaleParameterDefaultTypeInternal;
extern ScaleParameterDefaultTypeInternal _ScaleParameter_default_instance_;
class SigmoidParameter;
class SigmoidParameterDefaultTypeInternal;
extern SigmoidParameterDefaultTypeInternal _SigmoidParameter_default_instance_;
class SliceParameter;
class SliceParameterDefaultTypeInternal;
extern SliceParameterDefaultTypeInternal _SliceParameter_default_instance_;
class SmoothL1LossParameter;
class SmoothL1LossParameterDefaultTypeInternal;
extern SmoothL1LossParameterDefaultTypeInternal _SmoothL1LossParameter_default_instance_;
class SoftmaxParameter;
class SoftmaxParameterDefaultTypeInternal;
extern SoftmaxParameterDefaultTypeInternal _SoftmaxParameter_default_instance_;
class SolverParameter;
class SolverParameterDefaultTypeInternal;
extern SolverParameterDefaultTypeInternal _SolverParameter_default_instance_;
class SolverState;
class SolverStateDefaultTypeInternal;
extern SolverStateDefaultTypeInternal _SolverState_default_instance_;
class TanHParameter;
class TanHParameterDefaultTypeInternal;
extern TanHParameterDefaultTypeInternal _TanHParameter_default_instance_;
class ThresholdParameter;
class ThresholdParameterDefaultTypeInternal;
extern ThresholdParameterDefaultTypeInternal _ThresholdParameter_default_instance_;
class TileParameter;
class TileParameterDefaultTypeInternal;
extern TileParameterDefaultTypeInternal _TileParameter_default_instance_;
class TransformationParameter;
class TransformationParameterDefaultTypeInternal;
extern TransformationParameterDefaultTypeInternal _TransformationParameter_default_instance_;
class UpsampleParameter;
class UpsampleParameterDefaultTypeInternal;
extern UpsampleParameterDefaultTypeInternal _UpsampleParameter_default_instance_;
class V0LayerParameter;
class V0LayerParameterDefaultTypeInternal;
extern V0LayerParameterDefaultTypeInternal _V0LayerParameter_default_instance_;
class V1LayerParameter;
class V1LayerParameterDefaultTypeInternal;
extern V1LayerParameterDefaultTypeInternal _V1LayerParameter_default_instance_;
class VideoDataParameter;
class VideoDataParameterDefaultTypeInternal;
extern VideoDataParameterDefaultTypeInternal _VideoDataParameter_default_instance_;
class WindowDataParameter;
class WindowDataParameterDefaultTypeInternal;
extern WindowDataParameterDefaultTypeInternal _WindowDataParameter_default_instance_;
} // namespace caffe
PROTOBUF_NAMESPACE_OPEN
template<> ::caffe::AccuracyParameter* Arena::CreateMaybeMessage<::caffe::AccuracyParameter>(Arena*);
template<> ::caffe::AnnotatedDataParameter* Arena::CreateMaybeMessage<::caffe::AnnotatedDataParameter>(Arena*);
template<> ::caffe::AnnotatedDatum* Arena::CreateMaybeMessage<::caffe::AnnotatedDatum>(Arena*);
template<> ::caffe::Annotation* Arena::CreateMaybeMessage<::caffe::Annotation>(Arena*);
template<> ::caffe::AnnotationGroup* Arena::CreateMaybeMessage<::caffe::AnnotationGroup>(Arena*);
template<> ::caffe::ArgMaxParameter* Arena::CreateMaybeMessage<::caffe::ArgMaxParameter>(Arena*);
template<> ::caffe::BatchNormParameter* Arena::CreateMaybeMessage<::caffe::BatchNormParameter>(Arena*);
template<> ::caffe::BatchSampler* Arena::CreateMaybeMessage<::caffe::BatchSampler>(Arena*);
template<> ::caffe::BiasParameter* Arena::CreateMaybeMessage<::caffe::BiasParameter>(Arena*);
template<> ::caffe::BlobProto* Arena::CreateMaybeMessage<::caffe::BlobProto>(Arena*);
template<> ::caffe::BlobProtoVector* Arena::CreateMaybeMessage<::caffe::BlobProtoVector>(Arena*);
template<> ::caffe::BlobShape* Arena::CreateMaybeMessage<::caffe::BlobShape>(Arena*);
template<> ::caffe::ConcatParameter* Arena::CreateMaybeMessage<::caffe::ConcatParameter>(Arena*);
template<> ::caffe::ConnectParameter* Arena::CreateMaybeMessage<::caffe::ConnectParameter>(Arena*);
template<> ::caffe::ContrastiveLossParameter* Arena::CreateMaybeMessage<::caffe::ContrastiveLossParameter>(Arena*);
template<> ::caffe::ConvolutionParameter* Arena::CreateMaybeMessage<::caffe::ConvolutionParameter>(Arena*);
template<> ::caffe::CropParameter* Arena::CreateMaybeMessage<::caffe::CropParameter>(Arena*);
template<> ::caffe::DataParameter* Arena::CreateMaybeMessage<::caffe::DataParameter>(Arena*);
template<> ::caffe::Datum* Arena::CreateMaybeMessage<::caffe::Datum>(Arena*);
template<> ::caffe::DetectionEvaluateParameter* Arena::CreateMaybeMessage<::caffe::DetectionEvaluateParameter>(Arena*);
template<> ::caffe::DetectionOutputParameter* Arena::CreateMaybeMessage<::caffe::DetectionOutputParameter>(Arena*);
template<> ::caffe::DropoutParameter* Arena::CreateMaybeMessage<::caffe::DropoutParameter>(Arena*);
template<> ::caffe::DummyDataParameter* Arena::CreateMaybeMessage<::caffe::DummyDataParameter>(Arena*);
template<> ::caffe::ELUParameter* Arena::CreateMaybeMessage<::caffe::ELUParameter>(Arena*);
template<> ::caffe::EltwiseParameter* Arena::CreateMaybeMessage<::caffe::EltwiseParameter>(Arena*);
template<> ::caffe::EmbedParameter* Arena::CreateMaybeMessage<::caffe::EmbedParameter>(Arena*);
template<> ::caffe::EmitConstraint* Arena::CreateMaybeMessage<::caffe::EmitConstraint>(Arena*);
template<> ::caffe::ExpParameter* Arena::CreateMaybeMessage<::caffe::ExpParameter>(Arena*);
template<> ::caffe::FaceDataParameter* Arena::CreateMaybeMessage<::caffe::FaceDataParameter>(Arena*);
template<> ::caffe::FillerParameter* Arena::CreateMaybeMessage<::caffe::FillerParameter>(Arena*);
template<> ::caffe::FlattenParameter* Arena::CreateMaybeMessage<::caffe::FlattenParameter>(Arena*);
template<> ::caffe::HDF5DataParameter* Arena::CreateMaybeMessage<::caffe::HDF5DataParameter>(Arena*);
template<> ::caffe::HDF5OutputParameter* Arena::CreateMaybeMessage<::caffe::HDF5OutputParameter>(Arena*);
template<> ::caffe::HingeLossParameter* Arena::CreateMaybeMessage<::caffe::HingeLossParameter>(Arena*);
template<> ::caffe::ImageDataParameter* Arena::CreateMaybeMessage<::caffe::ImageDataParameter>(Arena*);
template<> ::caffe::InfogainLossParameter* Arena::CreateMaybeMessage<::caffe::InfogainLossParameter>(Arena*);
template<> ::caffe::InnerProductParameter* Arena::CreateMaybeMessage<::caffe::InnerProductParameter>(Arena*);
template<> ::caffe::InputParameter* Arena::CreateMaybeMessage<::caffe::InputParameter>(Arena*);
template<> ::caffe::LRNParameter* Arena::CreateMaybeMessage<::caffe::LRNParameter>(Arena*);
template<> ::caffe::LabelMap* Arena::CreateMaybeMessage<::caffe::LabelMap>(Arena*);
template<> ::caffe::LabelMapItem* Arena::CreateMaybeMessage<::caffe::LabelMapItem>(Arena*);
template<> ::caffe::LayerParameter* Arena::CreateMaybeMessage<::caffe::LayerParameter>(Arena*);
template<> ::caffe::LogParameter* Arena::CreateMaybeMessage<::caffe::LogParameter>(Arena*);
template<> ::caffe::LossParameter* Arena::CreateMaybeMessage<::caffe::LossParameter>(Arena*);
template<> ::caffe::MILDataParameter* Arena::CreateMaybeMessage<::caffe::MILDataParameter>(Arena*);
template<> ::caffe::MILParameter* Arena::CreateMaybeMessage<::caffe::MILParameter>(Arena*);
template<> ::caffe::MVNParameter* Arena::CreateMaybeMessage<::caffe::MVNParameter>(Arena*);
template<> ::caffe::MemoryDataParameter* Arena::CreateMaybeMessage<::caffe::MemoryDataParameter>(Arena*);
template<> ::caffe::MultiBoxLossParameter* Arena::CreateMaybeMessage<::caffe::MultiBoxLossParameter>(Arena*);
template<> ::caffe::NetParameter* Arena::CreateMaybeMessage<::caffe::NetParameter>(Arena*);
template<> ::caffe::NetState* Arena::CreateMaybeMessage<::caffe::NetState>(Arena*);
template<> ::caffe::NetStateRule* Arena::CreateMaybeMessage<::caffe::NetStateRule>(Arena*);
template<> ::caffe::NoiseParameter* Arena::CreateMaybeMessage<::caffe::NoiseParameter>(Arena*);
template<> ::caffe::NonMaximumSuppressionParameter* Arena::CreateMaybeMessage<::caffe::NonMaximumSuppressionParameter>(Arena*);
template<> ::caffe::NormalizeParameter* Arena::CreateMaybeMessage<::caffe::NormalizeParameter>(Arena*);
template<> ::caffe::NormalizedBBox* Arena::CreateMaybeMessage<::caffe::NormalizedBBox>(Arena*);
template<> ::caffe::PReLUParameter* Arena::CreateMaybeMessage<::caffe::PReLUParameter>(Arena*);
template<> ::caffe::ParamSpec* Arena::CreateMaybeMessage<::caffe::ParamSpec>(Arena*);
template<> ::caffe::ParameterParameter* Arena::CreateMaybeMessage<::caffe::ParameterParameter>(Arena*);
template<> ::caffe::PermuteParameter* Arena::CreateMaybeMessage<::caffe::PermuteParameter>(Arena*);
template<> ::caffe::PoolingParameter* Arena::CreateMaybeMessage<::caffe::PoolingParameter>(Arena*);
template<> ::caffe::PowerParameter* Arena::CreateMaybeMessage<::caffe::PowerParameter>(Arena*);
template<> ::caffe::PriorBoxParameter* Arena::CreateMaybeMessage<::caffe::PriorBoxParameter>(Arena*);
template<> ::caffe::PythonParameter* Arena::CreateMaybeMessage<::caffe::PythonParameter>(Arena*);
template<> ::caffe::ROIPoolingParameter* Arena::CreateMaybeMessage<::caffe::ROIPoolingParameter>(Arena*);
template<> ::caffe::ReLUParameter* Arena::CreateMaybeMessage<::caffe::ReLUParameter>(Arena*);
template<> ::caffe::RecurrentParameter* Arena::CreateMaybeMessage<::caffe::RecurrentParameter>(Arena*);
template<> ::caffe::ReductionParameter* Arena::CreateMaybeMessage<::caffe::ReductionParameter>(Arena*);
template<> ::caffe::ReshapeParameter* Arena::CreateMaybeMessage<::caffe::ReshapeParameter>(Arena*);
template<> ::caffe::ResizeParameter* Arena::CreateMaybeMessage<::caffe::ResizeParameter>(Arena*);
template<> ::caffe::SPPParameter* Arena::CreateMaybeMessage<::caffe::SPPParameter>(Arena*);
template<> ::caffe::SaltPepperParameter* Arena::CreateMaybeMessage<::caffe::SaltPepperParameter>(Arena*);
template<> ::caffe::SampleConstraint* Arena::CreateMaybeMessage<::caffe::SampleConstraint>(Arena*);
template<> ::caffe::Sampler* Arena::CreateMaybeMessage<::caffe::Sampler>(Arena*);
template<> ::caffe::SaveOutputParameter* Arena::CreateMaybeMessage<::caffe::SaveOutputParameter>(Arena*);
template<> ::caffe::ScaleParameter* Arena::CreateMaybeMessage<::caffe::ScaleParameter>(Arena*);
template<> ::caffe::SigmoidParameter* Arena::CreateMaybeMessage<::caffe::SigmoidParameter>(Arena*);
template<> ::caffe::SliceParameter* Arena::CreateMaybeMessage<::caffe::SliceParameter>(Arena*);
template<> ::caffe::SmoothL1LossParameter* Arena::CreateMaybeMessage<::caffe::SmoothL1LossParameter>(Arena*);
template<> ::caffe::SoftmaxParameter* Arena::CreateMaybeMessage<::caffe::SoftmaxParameter>(Arena*);
template<> ::caffe::SolverParameter* Arena::CreateMaybeMessage<::caffe::SolverParameter>(Arena*);
template<> ::caffe::SolverState* Arena::CreateMaybeMessage<::caffe::SolverState>(Arena*);
template<> ::caffe::TanHParameter* Arena::CreateMaybeMessage<::caffe::TanHParameter>(Arena*);
template<> ::caffe::ThresholdParameter* Arena::CreateMaybeMessage<::caffe::ThresholdParameter>(Arena*);
template<> ::caffe::TileParameter* Arena::CreateMaybeMessage<::caffe::TileParameter>(Arena*);
template<> ::caffe::TransformationParameter* Arena::CreateMaybeMessage<::caffe::TransformationParameter>(Arena*);
template<> ::caffe::UpsampleParameter* Arena::CreateMaybeMessage<::caffe::UpsampleParameter>(Arena*);
template<> ::caffe::V0LayerParameter* Arena::CreateMaybeMessage<::caffe::V0LayerParameter>(Arena*);
template<> ::caffe::V1LayerParameter* Arena::CreateMaybeMessage<::caffe::V1LayerParameter>(Arena*);
template<> ::caffe::VideoDataParameter* Arena::CreateMaybeMessage<::caffe::VideoDataParameter>(Arena*);
template<> ::caffe::WindowDataParameter* Arena::CreateMaybeMessage<::caffe::WindowDataParameter>(Arena*);
PROTOBUF_NAMESPACE_CLOSE
namespace caffe {
enum EmitConstraint_EmitType : int {
EmitConstraint_EmitType_CENTER = 0,
EmitConstraint_EmitType_MIN_OVERLAP = 1
};
bool EmitConstraint_EmitType_IsValid(int value);
constexpr EmitConstraint_EmitType EmitConstraint_EmitType_EmitType_MIN = EmitConstraint_EmitType_CENTER;
constexpr EmitConstraint_EmitType EmitConstraint_EmitType_EmitType_MAX = EmitConstraint_EmitType_MIN_OVERLAP;
constexpr int EmitConstraint_EmitType_EmitType_ARRAYSIZE = EmitConstraint_EmitType_EmitType_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* EmitConstraint_EmitType_descriptor();
template<typename T>
inline const std::string& EmitConstraint_EmitType_Name(T enum_t_value) {
static_assert(::std::is_same<T, EmitConstraint_EmitType>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function EmitConstraint_EmitType_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
EmitConstraint_EmitType_descriptor(), enum_t_value);
}
inline bool EmitConstraint_EmitType_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, EmitConstraint_EmitType* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<EmitConstraint_EmitType>(
EmitConstraint_EmitType_descriptor(), name, value);
}
enum AnnotatedDatum_AnnotationType : int {
AnnotatedDatum_AnnotationType_BBOX = 0
};
bool AnnotatedDatum_AnnotationType_IsValid(int value);
constexpr AnnotatedDatum_AnnotationType AnnotatedDatum_AnnotationType_AnnotationType_MIN = AnnotatedDatum_AnnotationType_BBOX;
constexpr AnnotatedDatum_AnnotationType AnnotatedDatum_AnnotationType_AnnotationType_MAX = AnnotatedDatum_AnnotationType_BBOX;
constexpr int AnnotatedDatum_AnnotationType_AnnotationType_ARRAYSIZE = AnnotatedDatum_AnnotationType_AnnotationType_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* AnnotatedDatum_AnnotationType_descriptor();
template<typename T>
inline const std::string& AnnotatedDatum_AnnotationType_Name(T enum_t_value) {
static_assert(::std::is_same<T, AnnotatedDatum_AnnotationType>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function AnnotatedDatum_AnnotationType_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
AnnotatedDatum_AnnotationType_descriptor(), enum_t_value);
}
inline bool AnnotatedDatum_AnnotationType_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, AnnotatedDatum_AnnotationType* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<AnnotatedDatum_AnnotationType>(
AnnotatedDatum_AnnotationType_descriptor(), name, value);
}
enum FillerParameter_VarianceNorm : int {
FillerParameter_VarianceNorm_FAN_IN = 0,
FillerParameter_VarianceNorm_FAN_OUT = 1,
FillerParameter_VarianceNorm_AVERAGE = 2
};
bool FillerParameter_VarianceNorm_IsValid(int value);
constexpr FillerParameter_VarianceNorm FillerParameter_VarianceNorm_VarianceNorm_MIN = FillerParameter_VarianceNorm_FAN_IN;
constexpr FillerParameter_VarianceNorm FillerParameter_VarianceNorm_VarianceNorm_MAX = FillerParameter_VarianceNorm_AVERAGE;
constexpr int FillerParameter_VarianceNorm_VarianceNorm_ARRAYSIZE = FillerParameter_VarianceNorm_VarianceNorm_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* FillerParameter_VarianceNorm_descriptor();
template<typename T>
inline const std::string& FillerParameter_VarianceNorm_Name(T enum_t_value) {
static_assert(::std::is_same<T, FillerParameter_VarianceNorm>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function FillerParameter_VarianceNorm_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
FillerParameter_VarianceNorm_descriptor(), enum_t_value);
}
inline bool FillerParameter_VarianceNorm_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, FillerParameter_VarianceNorm* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<FillerParameter_VarianceNorm>(
FillerParameter_VarianceNorm_descriptor(), name, value);
}
enum SolverParameter_SnapshotFormat : int {
SolverParameter_SnapshotFormat_HDF5 = 0,
SolverParameter_SnapshotFormat_BINARYPROTO = 1
};
bool SolverParameter_SnapshotFormat_IsValid(int value);
constexpr SolverParameter_SnapshotFormat SolverParameter_SnapshotFormat_SnapshotFormat_MIN = SolverParameter_SnapshotFormat_HDF5;
constexpr SolverParameter_SnapshotFormat SolverParameter_SnapshotFormat_SnapshotFormat_MAX = SolverParameter_SnapshotFormat_BINARYPROTO;
constexpr int SolverParameter_SnapshotFormat_SnapshotFormat_ARRAYSIZE = SolverParameter_SnapshotFormat_SnapshotFormat_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* SolverParameter_SnapshotFormat_descriptor();
template<typename T>
inline const std::string& SolverParameter_SnapshotFormat_Name(T enum_t_value) {
static_assert(::std::is_same<T, SolverParameter_SnapshotFormat>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function SolverParameter_SnapshotFormat_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
SolverParameter_SnapshotFormat_descriptor(), enum_t_value);
}
inline bool SolverParameter_SnapshotFormat_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, SolverParameter_SnapshotFormat* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<SolverParameter_SnapshotFormat>(
SolverParameter_SnapshotFormat_descriptor(), name, value);
}
enum SolverParameter_SolverMode : int {
SolverParameter_SolverMode_CPU = 0,
SolverParameter_SolverMode_GPU = 1
};
bool SolverParameter_SolverMode_IsValid(int value);
constexpr SolverParameter_SolverMode SolverParameter_SolverMode_SolverMode_MIN = SolverParameter_SolverMode_CPU;
constexpr SolverParameter_SolverMode SolverParameter_SolverMode_SolverMode_MAX = SolverParameter_SolverMode_GPU;
constexpr int SolverParameter_SolverMode_SolverMode_ARRAYSIZE = SolverParameter_SolverMode_SolverMode_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* SolverParameter_SolverMode_descriptor();
template<typename T>
inline const std::string& SolverParameter_SolverMode_Name(T enum_t_value) {
static_assert(::std::is_same<T, SolverParameter_SolverMode>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function SolverParameter_SolverMode_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
SolverParameter_SolverMode_descriptor(), enum_t_value);
}
inline bool SolverParameter_SolverMode_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, SolverParameter_SolverMode* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<SolverParameter_SolverMode>(
SolverParameter_SolverMode_descriptor(), name, value);
}
enum SolverParameter_SolverType : int {
SolverParameter_SolverType_SGD = 0,
SolverParameter_SolverType_NESTEROV = 1,
SolverParameter_SolverType_ADAGRAD = 2,
SolverParameter_SolverType_RMSPROP = 3,
SolverParameter_SolverType_ADADELTA = 4,
SolverParameter_SolverType_ADAM = 5
};
bool SolverParameter_SolverType_IsValid(int value);
constexpr SolverParameter_SolverType SolverParameter_SolverType_SolverType_MIN = SolverParameter_SolverType_SGD;
constexpr SolverParameter_SolverType SolverParameter_SolverType_SolverType_MAX = SolverParameter_SolverType_ADAM;
constexpr int SolverParameter_SolverType_SolverType_ARRAYSIZE = SolverParameter_SolverType_SolverType_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* SolverParameter_SolverType_descriptor();
template<typename T>
inline const std::string& SolverParameter_SolverType_Name(T enum_t_value) {
static_assert(::std::is_same<T, SolverParameter_SolverType>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function SolverParameter_SolverType_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
SolverParameter_SolverType_descriptor(), enum_t_value);
}
inline bool SolverParameter_SolverType_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, SolverParameter_SolverType* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<SolverParameter_SolverType>(
SolverParameter_SolverType_descriptor(), name, value);
}
enum ParamSpec_DimCheckMode : int {
ParamSpec_DimCheckMode_STRICT = 0,
ParamSpec_DimCheckMode_PERMISSIVE = 1
};
bool ParamSpec_DimCheckMode_IsValid(int value);
constexpr ParamSpec_DimCheckMode ParamSpec_DimCheckMode_DimCheckMode_MIN = ParamSpec_DimCheckMode_STRICT;
constexpr ParamSpec_DimCheckMode ParamSpec_DimCheckMode_DimCheckMode_MAX = ParamSpec_DimCheckMode_PERMISSIVE;
constexpr int ParamSpec_DimCheckMode_DimCheckMode_ARRAYSIZE = ParamSpec_DimCheckMode_DimCheckMode_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* ParamSpec_DimCheckMode_descriptor();
template<typename T>
inline const std::string& ParamSpec_DimCheckMode_Name(T enum_t_value) {
static_assert(::std::is_same<T, ParamSpec_DimCheckMode>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function ParamSpec_DimCheckMode_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
ParamSpec_DimCheckMode_descriptor(), enum_t_value);
}
inline bool ParamSpec_DimCheckMode_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, ParamSpec_DimCheckMode* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<ParamSpec_DimCheckMode>(
ParamSpec_DimCheckMode_descriptor(), name, value);
}
enum ResizeParameter_Resize_mode : int {
ResizeParameter_Resize_mode_WARP = 1,
ResizeParameter_Resize_mode_FIT_SMALL_SIZE = 2,
ResizeParameter_Resize_mode_FIT_LARGE_SIZE_AND_PAD = 3
};
bool ResizeParameter_Resize_mode_IsValid(int value);
constexpr ResizeParameter_Resize_mode ResizeParameter_Resize_mode_Resize_mode_MIN = ResizeParameter_Resize_mode_WARP;
constexpr ResizeParameter_Resize_mode ResizeParameter_Resize_mode_Resize_mode_MAX = ResizeParameter_Resize_mode_FIT_LARGE_SIZE_AND_PAD;
constexpr int ResizeParameter_Resize_mode_Resize_mode_ARRAYSIZE = ResizeParameter_Resize_mode_Resize_mode_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* ResizeParameter_Resize_mode_descriptor();
template<typename T>
inline const std::string& ResizeParameter_Resize_mode_Name(T enum_t_value) {
static_assert(::std::is_same<T, ResizeParameter_Resize_mode>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function ResizeParameter_Resize_mode_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
ResizeParameter_Resize_mode_descriptor(), enum_t_value);
}
inline bool ResizeParameter_Resize_mode_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, ResizeParameter_Resize_mode* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<ResizeParameter_Resize_mode>(
ResizeParameter_Resize_mode_descriptor(), name, value);
}
enum ResizeParameter_Pad_mode : int {
ResizeParameter_Pad_mode_CONSTANT = 1,
ResizeParameter_Pad_mode_MIRRORED = 2,
ResizeParameter_Pad_mode_REPEAT_NEAREST = 3
};
bool ResizeParameter_Pad_mode_IsValid(int value);
constexpr ResizeParameter_Pad_mode ResizeParameter_Pad_mode_Pad_mode_MIN = ResizeParameter_Pad_mode_CONSTANT;
constexpr ResizeParameter_Pad_mode ResizeParameter_Pad_mode_Pad_mode_MAX = ResizeParameter_Pad_mode_REPEAT_NEAREST;
constexpr int ResizeParameter_Pad_mode_Pad_mode_ARRAYSIZE = ResizeParameter_Pad_mode_Pad_mode_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* ResizeParameter_Pad_mode_descriptor();
template<typename T>
inline const std::string& ResizeParameter_Pad_mode_Name(T enum_t_value) {
static_assert(::std::is_same<T, ResizeParameter_Pad_mode>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function ResizeParameter_Pad_mode_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
ResizeParameter_Pad_mode_descriptor(), enum_t_value);
}
inline bool ResizeParameter_Pad_mode_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, ResizeParameter_Pad_mode* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<ResizeParameter_Pad_mode>(
ResizeParameter_Pad_mode_descriptor(), name, value);
}
enum ResizeParameter_Interp_mode : int {
ResizeParameter_Interp_mode_LINEAR = 1,
ResizeParameter_Interp_mode_AREA = 2,
ResizeParameter_Interp_mode_NEAREST = 3,
ResizeParameter_Interp_mode_CUBIC = 4,
ResizeParameter_Interp_mode_LANCZOS4 = 5
};
bool ResizeParameter_Interp_mode_IsValid(int value);
constexpr ResizeParameter_Interp_mode ResizeParameter_Interp_mode_Interp_mode_MIN = ResizeParameter_Interp_mode_LINEAR;
constexpr ResizeParameter_Interp_mode ResizeParameter_Interp_mode_Interp_mode_MAX = ResizeParameter_Interp_mode_LANCZOS4;
constexpr int ResizeParameter_Interp_mode_Interp_mode_ARRAYSIZE = ResizeParameter_Interp_mode_Interp_mode_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* ResizeParameter_Interp_mode_descriptor();
template<typename T>
inline const std::string& ResizeParameter_Interp_mode_Name(T enum_t_value) {
static_assert(::std::is_same<T, ResizeParameter_Interp_mode>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function ResizeParameter_Interp_mode_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
ResizeParameter_Interp_mode_descriptor(), enum_t_value);
}
inline bool ResizeParameter_Interp_mode_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, ResizeParameter_Interp_mode* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<ResizeParameter_Interp_mode>(
ResizeParameter_Interp_mode_descriptor(), name, value);
}
enum LossParameter_NormalizationMode : int {
LossParameter_NormalizationMode_FULL = 0,
LossParameter_NormalizationMode_VALID = 1,
LossParameter_NormalizationMode_BATCH_SIZE = 2,
LossParameter_NormalizationMode_NONE = 3
};
bool LossParameter_NormalizationMode_IsValid(int value);
constexpr LossParameter_NormalizationMode LossParameter_NormalizationMode_NormalizationMode_MIN = LossParameter_NormalizationMode_FULL;
constexpr LossParameter_NormalizationMode LossParameter_NormalizationMode_NormalizationMode_MAX = LossParameter_NormalizationMode_NONE;
constexpr int LossParameter_NormalizationMode_NormalizationMode_ARRAYSIZE = LossParameter_NormalizationMode_NormalizationMode_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* LossParameter_NormalizationMode_descriptor();
template<typename T>
inline const std::string& LossParameter_NormalizationMode_Name(T enum_t_value) {
static_assert(::std::is_same<T, LossParameter_NormalizationMode>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function LossParameter_NormalizationMode_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
LossParameter_NormalizationMode_descriptor(), enum_t_value);
}
inline bool LossParameter_NormalizationMode_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, LossParameter_NormalizationMode* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<LossParameter_NormalizationMode>(
LossParameter_NormalizationMode_descriptor(), name, value);
}
enum ConvolutionParameter_Engine : int {
ConvolutionParameter_Engine_DEFAULT = 0,
ConvolutionParameter_Engine_CAFFE = 1,
ConvolutionParameter_Engine_CUDNN = 2
};
bool ConvolutionParameter_Engine_IsValid(int value);
constexpr ConvolutionParameter_Engine ConvolutionParameter_Engine_Engine_MIN = ConvolutionParameter_Engine_DEFAULT;
constexpr ConvolutionParameter_Engine ConvolutionParameter_Engine_Engine_MAX = ConvolutionParameter_Engine_CUDNN;
constexpr int ConvolutionParameter_Engine_Engine_ARRAYSIZE = ConvolutionParameter_Engine_Engine_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* ConvolutionParameter_Engine_descriptor();
template<typename T>
inline const std::string& ConvolutionParameter_Engine_Name(T enum_t_value) {
static_assert(::std::is_same<T, ConvolutionParameter_Engine>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function ConvolutionParameter_Engine_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
ConvolutionParameter_Engine_descriptor(), enum_t_value);
}
inline bool ConvolutionParameter_Engine_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, ConvolutionParameter_Engine* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<ConvolutionParameter_Engine>(
ConvolutionParameter_Engine_descriptor(), name, value);
}
enum DataParameter_DB : int {
DataParameter_DB_LEVELDB = 0,
DataParameter_DB_LMDB = 1
};
bool DataParameter_DB_IsValid(int value);
constexpr DataParameter_DB DataParameter_DB_DB_MIN = DataParameter_DB_LEVELDB;
constexpr DataParameter_DB DataParameter_DB_DB_MAX = DataParameter_DB_LMDB;
constexpr int DataParameter_DB_DB_ARRAYSIZE = DataParameter_DB_DB_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* DataParameter_DB_descriptor();
template<typename T>
inline const std::string& DataParameter_DB_Name(T enum_t_value) {
static_assert(::std::is_same<T, DataParameter_DB>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function DataParameter_DB_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
DataParameter_DB_descriptor(), enum_t_value);
}
inline bool DataParameter_DB_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, DataParameter_DB* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<DataParameter_DB>(
DataParameter_DB_descriptor(), name, value);
}
enum EltwiseParameter_EltwiseOp : int {
EltwiseParameter_EltwiseOp_PROD = 0,
EltwiseParameter_EltwiseOp_SUM = 1,
EltwiseParameter_EltwiseOp_MAX = 2
};
bool EltwiseParameter_EltwiseOp_IsValid(int value);
constexpr EltwiseParameter_EltwiseOp EltwiseParameter_EltwiseOp_EltwiseOp_MIN = EltwiseParameter_EltwiseOp_PROD;
constexpr EltwiseParameter_EltwiseOp EltwiseParameter_EltwiseOp_EltwiseOp_MAX = EltwiseParameter_EltwiseOp_MAX;
constexpr int EltwiseParameter_EltwiseOp_EltwiseOp_ARRAYSIZE = EltwiseParameter_EltwiseOp_EltwiseOp_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* EltwiseParameter_EltwiseOp_descriptor();
template<typename T>
inline const std::string& EltwiseParameter_EltwiseOp_Name(T enum_t_value) {
static_assert(::std::is_same<T, EltwiseParameter_EltwiseOp>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function EltwiseParameter_EltwiseOp_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
EltwiseParameter_EltwiseOp_descriptor(), enum_t_value);
}
inline bool EltwiseParameter_EltwiseOp_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, EltwiseParameter_EltwiseOp* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<EltwiseParameter_EltwiseOp>(
EltwiseParameter_EltwiseOp_descriptor(), name, value);
}
enum HingeLossParameter_Norm : int {
HingeLossParameter_Norm_L1 = 1,
HingeLossParameter_Norm_L2 = 2
};
bool HingeLossParameter_Norm_IsValid(int value);
constexpr HingeLossParameter_Norm HingeLossParameter_Norm_Norm_MIN = HingeLossParameter_Norm_L1;
constexpr HingeLossParameter_Norm HingeLossParameter_Norm_Norm_MAX = HingeLossParameter_Norm_L2;
constexpr int HingeLossParameter_Norm_Norm_ARRAYSIZE = HingeLossParameter_Norm_Norm_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* HingeLossParameter_Norm_descriptor();
template<typename T>
inline const std::string& HingeLossParameter_Norm_Name(T enum_t_value) {
static_assert(::std::is_same<T, HingeLossParameter_Norm>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function HingeLossParameter_Norm_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
HingeLossParameter_Norm_descriptor(), enum_t_value);
}
inline bool HingeLossParameter_Norm_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, HingeLossParameter_Norm* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<HingeLossParameter_Norm>(
HingeLossParameter_Norm_descriptor(), name, value);
}
enum LRNParameter_NormRegion : int {
LRNParameter_NormRegion_ACROSS_CHANNELS = 0,
LRNParameter_NormRegion_WITHIN_CHANNEL = 1
};
bool LRNParameter_NormRegion_IsValid(int value);
constexpr LRNParameter_NormRegion LRNParameter_NormRegion_NormRegion_MIN = LRNParameter_NormRegion_ACROSS_CHANNELS;
constexpr LRNParameter_NormRegion LRNParameter_NormRegion_NormRegion_MAX = LRNParameter_NormRegion_WITHIN_CHANNEL;
constexpr int LRNParameter_NormRegion_NormRegion_ARRAYSIZE = LRNParameter_NormRegion_NormRegion_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* LRNParameter_NormRegion_descriptor();
template<typename T>
inline const std::string& LRNParameter_NormRegion_Name(T enum_t_value) {
static_assert(::std::is_same<T, LRNParameter_NormRegion>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function LRNParameter_NormRegion_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
LRNParameter_NormRegion_descriptor(), enum_t_value);
}
inline bool LRNParameter_NormRegion_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, LRNParameter_NormRegion* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<LRNParameter_NormRegion>(
LRNParameter_NormRegion_descriptor(), name, value);
}
enum LRNParameter_Engine : int {
LRNParameter_Engine_DEFAULT = 0,
LRNParameter_Engine_CAFFE = 1,
LRNParameter_Engine_CUDNN = 2
};
bool LRNParameter_Engine_IsValid(int value);
constexpr LRNParameter_Engine LRNParameter_Engine_Engine_MIN = LRNParameter_Engine_DEFAULT;
constexpr LRNParameter_Engine LRNParameter_Engine_Engine_MAX = LRNParameter_Engine_CUDNN;
constexpr int LRNParameter_Engine_Engine_ARRAYSIZE = LRNParameter_Engine_Engine_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* LRNParameter_Engine_descriptor();
template<typename T>
inline const std::string& LRNParameter_Engine_Name(T enum_t_value) {
static_assert(::std::is_same<T, LRNParameter_Engine>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function LRNParameter_Engine_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
LRNParameter_Engine_descriptor(), enum_t_value);
}
inline bool LRNParameter_Engine_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, LRNParameter_Engine* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<LRNParameter_Engine>(
LRNParameter_Engine_descriptor(), name, value);
}
enum MultiBoxLossParameter_LocLossType : int {
MultiBoxLossParameter_LocLossType_L2 = 0,
MultiBoxLossParameter_LocLossType_SMOOTH_L1 = 1
};
bool MultiBoxLossParameter_LocLossType_IsValid(int value);
constexpr MultiBoxLossParameter_LocLossType MultiBoxLossParameter_LocLossType_LocLossType_MIN = MultiBoxLossParameter_LocLossType_L2;
constexpr MultiBoxLossParameter_LocLossType MultiBoxLossParameter_LocLossType_LocLossType_MAX = MultiBoxLossParameter_LocLossType_SMOOTH_L1;
constexpr int MultiBoxLossParameter_LocLossType_LocLossType_ARRAYSIZE = MultiBoxLossParameter_LocLossType_LocLossType_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* MultiBoxLossParameter_LocLossType_descriptor();
template<typename T>
inline const std::string& MultiBoxLossParameter_LocLossType_Name(T enum_t_value) {
static_assert(::std::is_same<T, MultiBoxLossParameter_LocLossType>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function MultiBoxLossParameter_LocLossType_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
MultiBoxLossParameter_LocLossType_descriptor(), enum_t_value);
}
inline bool MultiBoxLossParameter_LocLossType_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, MultiBoxLossParameter_LocLossType* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<MultiBoxLossParameter_LocLossType>(
MultiBoxLossParameter_LocLossType_descriptor(), name, value);
}
enum MultiBoxLossParameter_ConfLossType : int {
MultiBoxLossParameter_ConfLossType_SOFTMAX = 0,
MultiBoxLossParameter_ConfLossType_LOGISTIC = 1
};
bool MultiBoxLossParameter_ConfLossType_IsValid(int value);
constexpr MultiBoxLossParameter_ConfLossType MultiBoxLossParameter_ConfLossType_ConfLossType_MIN = MultiBoxLossParameter_ConfLossType_SOFTMAX;
constexpr MultiBoxLossParameter_ConfLossType MultiBoxLossParameter_ConfLossType_ConfLossType_MAX = MultiBoxLossParameter_ConfLossType_LOGISTIC;
constexpr int MultiBoxLossParameter_ConfLossType_ConfLossType_ARRAYSIZE = MultiBoxLossParameter_ConfLossType_ConfLossType_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* MultiBoxLossParameter_ConfLossType_descriptor();
template<typename T>
inline const std::string& MultiBoxLossParameter_ConfLossType_Name(T enum_t_value) {
static_assert(::std::is_same<T, MultiBoxLossParameter_ConfLossType>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function MultiBoxLossParameter_ConfLossType_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
MultiBoxLossParameter_ConfLossType_descriptor(), enum_t_value);
}
inline bool MultiBoxLossParameter_ConfLossType_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, MultiBoxLossParameter_ConfLossType* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<MultiBoxLossParameter_ConfLossType>(
MultiBoxLossParameter_ConfLossType_descriptor(), name, value);
}
enum MultiBoxLossParameter_MatchType : int {
MultiBoxLossParameter_MatchType_BIPARTITE = 0,
MultiBoxLossParameter_MatchType_PER_PREDICTION = 1
};
bool MultiBoxLossParameter_MatchType_IsValid(int value);
constexpr MultiBoxLossParameter_MatchType MultiBoxLossParameter_MatchType_MatchType_MIN = MultiBoxLossParameter_MatchType_BIPARTITE;
constexpr MultiBoxLossParameter_MatchType MultiBoxLossParameter_MatchType_MatchType_MAX = MultiBoxLossParameter_MatchType_PER_PREDICTION;
constexpr int MultiBoxLossParameter_MatchType_MatchType_ARRAYSIZE = MultiBoxLossParameter_MatchType_MatchType_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* MultiBoxLossParameter_MatchType_descriptor();
template<typename T>
inline const std::string& MultiBoxLossParameter_MatchType_Name(T enum_t_value) {
static_assert(::std::is_same<T, MultiBoxLossParameter_MatchType>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function MultiBoxLossParameter_MatchType_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
MultiBoxLossParameter_MatchType_descriptor(), enum_t_value);
}
inline bool MultiBoxLossParameter_MatchType_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, MultiBoxLossParameter_MatchType* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<MultiBoxLossParameter_MatchType>(
MultiBoxLossParameter_MatchType_descriptor(), name, value);
}
enum PoolingParameter_PoolMethod : int {
PoolingParameter_PoolMethod_MAX = 0,
PoolingParameter_PoolMethod_AVE = 1,
PoolingParameter_PoolMethod_STOCHASTIC = 2
};
bool PoolingParameter_PoolMethod_IsValid(int value);
constexpr PoolingParameter_PoolMethod PoolingParameter_PoolMethod_PoolMethod_MIN = PoolingParameter_PoolMethod_MAX;
constexpr PoolingParameter_PoolMethod PoolingParameter_PoolMethod_PoolMethod_MAX = PoolingParameter_PoolMethod_STOCHASTIC;
constexpr int PoolingParameter_PoolMethod_PoolMethod_ARRAYSIZE = PoolingParameter_PoolMethod_PoolMethod_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* PoolingParameter_PoolMethod_descriptor();
template<typename T>
inline const std::string& PoolingParameter_PoolMethod_Name(T enum_t_value) {
static_assert(::std::is_same<T, PoolingParameter_PoolMethod>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function PoolingParameter_PoolMethod_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
PoolingParameter_PoolMethod_descriptor(), enum_t_value);
}
inline bool PoolingParameter_PoolMethod_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, PoolingParameter_PoolMethod* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<PoolingParameter_PoolMethod>(
PoolingParameter_PoolMethod_descriptor(), name, value);
}
enum PoolingParameter_Engine : int {
PoolingParameter_Engine_DEFAULT = 0,
PoolingParameter_Engine_CAFFE = 1,
PoolingParameter_Engine_CUDNN = 2
};
bool PoolingParameter_Engine_IsValid(int value);
constexpr PoolingParameter_Engine PoolingParameter_Engine_Engine_MIN = PoolingParameter_Engine_DEFAULT;
constexpr PoolingParameter_Engine PoolingParameter_Engine_Engine_MAX = PoolingParameter_Engine_CUDNN;
constexpr int PoolingParameter_Engine_Engine_ARRAYSIZE = PoolingParameter_Engine_Engine_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* PoolingParameter_Engine_descriptor();
template<typename T>
inline const std::string& PoolingParameter_Engine_Name(T enum_t_value) {
static_assert(::std::is_same<T, PoolingParameter_Engine>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function PoolingParameter_Engine_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
PoolingParameter_Engine_descriptor(), enum_t_value);
}
inline bool PoolingParameter_Engine_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, PoolingParameter_Engine* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<PoolingParameter_Engine>(
PoolingParameter_Engine_descriptor(), name, value);
}
enum PriorBoxParameter_CodeType : int {
PriorBoxParameter_CodeType_CORNER = 1,
PriorBoxParameter_CodeType_CENTER_SIZE = 2
};
bool PriorBoxParameter_CodeType_IsValid(int value);
constexpr PriorBoxParameter_CodeType PriorBoxParameter_CodeType_CodeType_MIN = PriorBoxParameter_CodeType_CORNER;
constexpr PriorBoxParameter_CodeType PriorBoxParameter_CodeType_CodeType_MAX = PriorBoxParameter_CodeType_CENTER_SIZE;
constexpr int PriorBoxParameter_CodeType_CodeType_ARRAYSIZE = PriorBoxParameter_CodeType_CodeType_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* PriorBoxParameter_CodeType_descriptor();
template<typename T>
inline const std::string& PriorBoxParameter_CodeType_Name(T enum_t_value) {
static_assert(::std::is_same<T, PriorBoxParameter_CodeType>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function PriorBoxParameter_CodeType_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
PriorBoxParameter_CodeType_descriptor(), enum_t_value);
}
inline bool PriorBoxParameter_CodeType_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, PriorBoxParameter_CodeType* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<PriorBoxParameter_CodeType>(
PriorBoxParameter_CodeType_descriptor(), name, value);
}
enum ReductionParameter_ReductionOp : int {
ReductionParameter_ReductionOp_SUM = 1,
ReductionParameter_ReductionOp_ASUM = 2,
ReductionParameter_ReductionOp_SUMSQ = 3,
ReductionParameter_ReductionOp_MEAN = 4
};
bool ReductionParameter_ReductionOp_IsValid(int value);
constexpr ReductionParameter_ReductionOp ReductionParameter_ReductionOp_ReductionOp_MIN = ReductionParameter_ReductionOp_SUM;
constexpr ReductionParameter_ReductionOp ReductionParameter_ReductionOp_ReductionOp_MAX = ReductionParameter_ReductionOp_MEAN;
constexpr int ReductionParameter_ReductionOp_ReductionOp_ARRAYSIZE = ReductionParameter_ReductionOp_ReductionOp_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* ReductionParameter_ReductionOp_descriptor();
template<typename T>
inline const std::string& ReductionParameter_ReductionOp_Name(T enum_t_value) {
static_assert(::std::is_same<T, ReductionParameter_ReductionOp>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function ReductionParameter_ReductionOp_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
ReductionParameter_ReductionOp_descriptor(), enum_t_value);
}
inline bool ReductionParameter_ReductionOp_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, ReductionParameter_ReductionOp* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<ReductionParameter_ReductionOp>(
ReductionParameter_ReductionOp_descriptor(), name, value);
}
enum ReLUParameter_Engine : int {
ReLUParameter_Engine_DEFAULT = 0,
ReLUParameter_Engine_CAFFE = 1,
ReLUParameter_Engine_CUDNN = 2
};
bool ReLUParameter_Engine_IsValid(int value);
constexpr ReLUParameter_Engine ReLUParameter_Engine_Engine_MIN = ReLUParameter_Engine_DEFAULT;
constexpr ReLUParameter_Engine ReLUParameter_Engine_Engine_MAX = ReLUParameter_Engine_CUDNN;
constexpr int ReLUParameter_Engine_Engine_ARRAYSIZE = ReLUParameter_Engine_Engine_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* ReLUParameter_Engine_descriptor();
template<typename T>
inline const std::string& ReLUParameter_Engine_Name(T enum_t_value) {
static_assert(::std::is_same<T, ReLUParameter_Engine>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function ReLUParameter_Engine_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
ReLUParameter_Engine_descriptor(), enum_t_value);
}
inline bool ReLUParameter_Engine_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, ReLUParameter_Engine* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<ReLUParameter_Engine>(
ReLUParameter_Engine_descriptor(), name, value);
}
enum SigmoidParameter_Engine : int {
SigmoidParameter_Engine_DEFAULT = 0,
SigmoidParameter_Engine_CAFFE = 1,
SigmoidParameter_Engine_CUDNN = 2
};
bool SigmoidParameter_Engine_IsValid(int value);
constexpr SigmoidParameter_Engine SigmoidParameter_Engine_Engine_MIN = SigmoidParameter_Engine_DEFAULT;
constexpr SigmoidParameter_Engine SigmoidParameter_Engine_Engine_MAX = SigmoidParameter_Engine_CUDNN;
constexpr int SigmoidParameter_Engine_Engine_ARRAYSIZE = SigmoidParameter_Engine_Engine_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* SigmoidParameter_Engine_descriptor();
template<typename T>
inline const std::string& SigmoidParameter_Engine_Name(T enum_t_value) {
static_assert(::std::is_same<T, SigmoidParameter_Engine>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function SigmoidParameter_Engine_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
SigmoidParameter_Engine_descriptor(), enum_t_value);
}
inline bool SigmoidParameter_Engine_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, SigmoidParameter_Engine* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<SigmoidParameter_Engine>(
SigmoidParameter_Engine_descriptor(), name, value);
}
enum SoftmaxParameter_Engine : int {
SoftmaxParameter_Engine_DEFAULT = 0,
SoftmaxParameter_Engine_CAFFE = 1,
SoftmaxParameter_Engine_CUDNN = 2
};
bool SoftmaxParameter_Engine_IsValid(int value);
constexpr SoftmaxParameter_Engine SoftmaxParameter_Engine_Engine_MIN = SoftmaxParameter_Engine_DEFAULT;
constexpr SoftmaxParameter_Engine SoftmaxParameter_Engine_Engine_MAX = SoftmaxParameter_Engine_CUDNN;
constexpr int SoftmaxParameter_Engine_Engine_ARRAYSIZE = SoftmaxParameter_Engine_Engine_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* SoftmaxParameter_Engine_descriptor();
template<typename T>
inline const std::string& SoftmaxParameter_Engine_Name(T enum_t_value) {
static_assert(::std::is_same<T, SoftmaxParameter_Engine>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function SoftmaxParameter_Engine_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
SoftmaxParameter_Engine_descriptor(), enum_t_value);
}
inline bool SoftmaxParameter_Engine_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, SoftmaxParameter_Engine* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<SoftmaxParameter_Engine>(
SoftmaxParameter_Engine_descriptor(), name, value);
}
enum TanHParameter_Engine : int {
TanHParameter_Engine_DEFAULT = 0,
TanHParameter_Engine_CAFFE = 1,
TanHParameter_Engine_CUDNN = 2
};
bool TanHParameter_Engine_IsValid(int value);
constexpr TanHParameter_Engine TanHParameter_Engine_Engine_MIN = TanHParameter_Engine_DEFAULT;
constexpr TanHParameter_Engine TanHParameter_Engine_Engine_MAX = TanHParameter_Engine_CUDNN;
constexpr int TanHParameter_Engine_Engine_ARRAYSIZE = TanHParameter_Engine_Engine_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* TanHParameter_Engine_descriptor();
template<typename T>
inline const std::string& TanHParameter_Engine_Name(T enum_t_value) {
static_assert(::std::is_same<T, TanHParameter_Engine>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function TanHParameter_Engine_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
TanHParameter_Engine_descriptor(), enum_t_value);
}
inline bool TanHParameter_Engine_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, TanHParameter_Engine* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<TanHParameter_Engine>(
TanHParameter_Engine_descriptor(), name, value);
}
enum MILParameter_MILType : int {
MILParameter_MILType_MAX = 0,
MILParameter_MILType_NOR = 1
};
bool MILParameter_MILType_IsValid(int value);
constexpr MILParameter_MILType MILParameter_MILType_MILType_MIN = MILParameter_MILType_MAX;
constexpr MILParameter_MILType MILParameter_MILType_MILType_MAX = MILParameter_MILType_NOR;
constexpr int MILParameter_MILType_MILType_ARRAYSIZE = MILParameter_MILType_MILType_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* MILParameter_MILType_descriptor();
template<typename T>
inline const std::string& MILParameter_MILType_Name(T enum_t_value) {
static_assert(::std::is_same<T, MILParameter_MILType>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function MILParameter_MILType_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
MILParameter_MILType_descriptor(), enum_t_value);
}
inline bool MILParameter_MILType_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, MILParameter_MILType* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<MILParameter_MILType>(
MILParameter_MILType_descriptor(), name, value);
}
enum VideoDataParameter_VideoType : int {
VideoDataParameter_VideoType_WEBCAM = 0,
VideoDataParameter_VideoType_VIDEO = 1
};
bool VideoDataParameter_VideoType_IsValid(int value);
constexpr VideoDataParameter_VideoType VideoDataParameter_VideoType_VideoType_MIN = VideoDataParameter_VideoType_WEBCAM;
constexpr VideoDataParameter_VideoType VideoDataParameter_VideoType_VideoType_MAX = VideoDataParameter_VideoType_VIDEO;
constexpr int VideoDataParameter_VideoType_VideoType_ARRAYSIZE = VideoDataParameter_VideoType_VideoType_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* VideoDataParameter_VideoType_descriptor();
template<typename T>
inline const std::string& VideoDataParameter_VideoType_Name(T enum_t_value) {
static_assert(::std::is_same<T, VideoDataParameter_VideoType>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function VideoDataParameter_VideoType_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
VideoDataParameter_VideoType_descriptor(), enum_t_value);
}
inline bool VideoDataParameter_VideoType_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, VideoDataParameter_VideoType* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<VideoDataParameter_VideoType>(
VideoDataParameter_VideoType_descriptor(), name, value);
}
enum SPPParameter_PoolMethod : int {
SPPParameter_PoolMethod_MAX = 0,
SPPParameter_PoolMethod_AVE = 1,
SPPParameter_PoolMethod_STOCHASTIC = 2
};
bool SPPParameter_PoolMethod_IsValid(int value);
constexpr SPPParameter_PoolMethod SPPParameter_PoolMethod_PoolMethod_MIN = SPPParameter_PoolMethod_MAX;
constexpr SPPParameter_PoolMethod SPPParameter_PoolMethod_PoolMethod_MAX = SPPParameter_PoolMethod_STOCHASTIC;
constexpr int SPPParameter_PoolMethod_PoolMethod_ARRAYSIZE = SPPParameter_PoolMethod_PoolMethod_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* SPPParameter_PoolMethod_descriptor();
template<typename T>
inline const std::string& SPPParameter_PoolMethod_Name(T enum_t_value) {
static_assert(::std::is_same<T, SPPParameter_PoolMethod>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function SPPParameter_PoolMethod_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
SPPParameter_PoolMethod_descriptor(), enum_t_value);
}
inline bool SPPParameter_PoolMethod_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, SPPParameter_PoolMethod* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<SPPParameter_PoolMethod>(
SPPParameter_PoolMethod_descriptor(), name, value);
}
enum SPPParameter_Engine : int {
SPPParameter_Engine_DEFAULT = 0,
SPPParameter_Engine_CAFFE = 1,
SPPParameter_Engine_CUDNN = 2
};
bool SPPParameter_Engine_IsValid(int value);
constexpr SPPParameter_Engine SPPParameter_Engine_Engine_MIN = SPPParameter_Engine_DEFAULT;
constexpr SPPParameter_Engine SPPParameter_Engine_Engine_MAX = SPPParameter_Engine_CUDNN;
constexpr int SPPParameter_Engine_Engine_ARRAYSIZE = SPPParameter_Engine_Engine_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* SPPParameter_Engine_descriptor();
template<typename T>
inline const std::string& SPPParameter_Engine_Name(T enum_t_value) {
static_assert(::std::is_same<T, SPPParameter_Engine>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function SPPParameter_Engine_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
SPPParameter_Engine_descriptor(), enum_t_value);
}
inline bool SPPParameter_Engine_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, SPPParameter_Engine* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<SPPParameter_Engine>(
SPPParameter_Engine_descriptor(), name, value);
}
enum V1LayerParameter_LayerType : int {
V1LayerParameter_LayerType_NONE = 0,
V1LayerParameter_LayerType_ABSVAL = 35,
V1LayerParameter_LayerType_ACCURACY = 1,
V1LayerParameter_LayerType_ARGMAX = 30,
V1LayerParameter_LayerType_BNLL = 2,
V1LayerParameter_LayerType_CONCAT = 3,
V1LayerParameter_LayerType_CONTRASTIVE_LOSS = 37,
V1LayerParameter_LayerType_CONVOLUTION = 4,
V1LayerParameter_LayerType_DATA = 5,
V1LayerParameter_LayerType_DECONVOLUTION = 39,
V1LayerParameter_LayerType_DROPOUT = 6,
V1LayerParameter_LayerType_DUMMY_DATA = 32,
V1LayerParameter_LayerType_EUCLIDEAN_LOSS = 7,
V1LayerParameter_LayerType_ELTWISE = 25,
V1LayerParameter_LayerType_EXP = 38,
V1LayerParameter_LayerType_FLATTEN = 8,
V1LayerParameter_LayerType_HDF5_DATA = 9,
V1LayerParameter_LayerType_HDF5_OUTPUT = 10,
V1LayerParameter_LayerType_HINGE_LOSS = 28,
V1LayerParameter_LayerType_IM2COL = 11,
V1LayerParameter_LayerType_IMAGE_DATA = 12,
V1LayerParameter_LayerType_INFOGAIN_LOSS = 13,
V1LayerParameter_LayerType_INNER_PRODUCT = 14,
V1LayerParameter_LayerType_LRN = 15,
V1LayerParameter_LayerType_MEMORY_DATA = 29,
V1LayerParameter_LayerType_MULTINOMIAL_LOGISTIC_LOSS = 16,
V1LayerParameter_LayerType_MVN = 34,
V1LayerParameter_LayerType_POOLING = 17,
V1LayerParameter_LayerType_POWER = 26,
V1LayerParameter_LayerType_RELU = 18,
V1LayerParameter_LayerType_SIGMOID = 19,
V1LayerParameter_LayerType_SIGMOID_CROSS_ENTROPY_LOSS = 27,
V1LayerParameter_LayerType_SILENCE = 36,
V1LayerParameter_LayerType_SOFTMAX = 20,
V1LayerParameter_LayerType_SOFTMAX_LOSS = 21,
V1LayerParameter_LayerType_SPLIT = 22,
V1LayerParameter_LayerType_SLICE = 33,
V1LayerParameter_LayerType_TANH = 23,
V1LayerParameter_LayerType_WINDOW_DATA = 24,
V1LayerParameter_LayerType_THRESHOLD = 31
};
bool V1LayerParameter_LayerType_IsValid(int value);
constexpr V1LayerParameter_LayerType V1LayerParameter_LayerType_LayerType_MIN = V1LayerParameter_LayerType_NONE;
constexpr V1LayerParameter_LayerType V1LayerParameter_LayerType_LayerType_MAX = V1LayerParameter_LayerType_DECONVOLUTION;
constexpr int V1LayerParameter_LayerType_LayerType_ARRAYSIZE = V1LayerParameter_LayerType_LayerType_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* V1LayerParameter_LayerType_descriptor();
template<typename T>
inline const std::string& V1LayerParameter_LayerType_Name(T enum_t_value) {
static_assert(::std::is_same<T, V1LayerParameter_LayerType>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function V1LayerParameter_LayerType_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
V1LayerParameter_LayerType_descriptor(), enum_t_value);
}
inline bool V1LayerParameter_LayerType_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, V1LayerParameter_LayerType* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<V1LayerParameter_LayerType>(
V1LayerParameter_LayerType_descriptor(), name, value);
}
enum V1LayerParameter_DimCheckMode : int {
V1LayerParameter_DimCheckMode_STRICT = 0,
V1LayerParameter_DimCheckMode_PERMISSIVE = 1
};
bool V1LayerParameter_DimCheckMode_IsValid(int value);
constexpr V1LayerParameter_DimCheckMode V1LayerParameter_DimCheckMode_DimCheckMode_MIN = V1LayerParameter_DimCheckMode_STRICT;
constexpr V1LayerParameter_DimCheckMode V1LayerParameter_DimCheckMode_DimCheckMode_MAX = V1LayerParameter_DimCheckMode_PERMISSIVE;
constexpr int V1LayerParameter_DimCheckMode_DimCheckMode_ARRAYSIZE = V1LayerParameter_DimCheckMode_DimCheckMode_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* V1LayerParameter_DimCheckMode_descriptor();
template<typename T>
inline const std::string& V1LayerParameter_DimCheckMode_Name(T enum_t_value) {
static_assert(::std::is_same<T, V1LayerParameter_DimCheckMode>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function V1LayerParameter_DimCheckMode_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
V1LayerParameter_DimCheckMode_descriptor(), enum_t_value);
}
inline bool V1LayerParameter_DimCheckMode_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, V1LayerParameter_DimCheckMode* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<V1LayerParameter_DimCheckMode>(
V1LayerParameter_DimCheckMode_descriptor(), name, value);
}
enum V0LayerParameter_PoolMethod : int {
V0LayerParameter_PoolMethod_MAX = 0,
V0LayerParameter_PoolMethod_AVE = 1,
V0LayerParameter_PoolMethod_STOCHASTIC = 2
};
bool V0LayerParameter_PoolMethod_IsValid(int value);
constexpr V0LayerParameter_PoolMethod V0LayerParameter_PoolMethod_PoolMethod_MIN = V0LayerParameter_PoolMethod_MAX;
constexpr V0LayerParameter_PoolMethod V0LayerParameter_PoolMethod_PoolMethod_MAX = V0LayerParameter_PoolMethod_STOCHASTIC;
constexpr int V0LayerParameter_PoolMethod_PoolMethod_ARRAYSIZE = V0LayerParameter_PoolMethod_PoolMethod_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* V0LayerParameter_PoolMethod_descriptor();
template<typename T>
inline const std::string& V0LayerParameter_PoolMethod_Name(T enum_t_value) {
static_assert(::std::is_same<T, V0LayerParameter_PoolMethod>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function V0LayerParameter_PoolMethod_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
V0LayerParameter_PoolMethod_descriptor(), enum_t_value);
}
inline bool V0LayerParameter_PoolMethod_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, V0LayerParameter_PoolMethod* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<V0LayerParameter_PoolMethod>(
V0LayerParameter_PoolMethod_descriptor(), name, value);
}
enum Phase : int {
TRAIN = 0,
TEST = 1
};
bool Phase_IsValid(int value);
constexpr Phase Phase_MIN = TRAIN;
constexpr Phase Phase_MAX = TEST;
constexpr int Phase_ARRAYSIZE = Phase_MAX + 1;
const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* Phase_descriptor();
template<typename T>
inline const std::string& Phase_Name(T enum_t_value) {
static_assert(::std::is_same<T, Phase>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function Phase_Name.");
return ::PROTOBUF_NAMESPACE_ID::internal::NameOfEnum(
Phase_descriptor(), enum_t_value);
}
inline bool Phase_Parse(
::PROTOBUF_NAMESPACE_ID::ConstStringParam name, Phase* value) {
return ::PROTOBUF_NAMESPACE_ID::internal::ParseNamedEnum<Phase>(
Phase_descriptor(), name, value);
}
// ===================================================================
class BlobShape PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.BlobShape) */ {
public:
inline BlobShape() : BlobShape(nullptr) {}
virtual ~BlobShape();
BlobShape(const BlobShape& from);
BlobShape(BlobShape&& from) noexcept
: BlobShape() {
*this = ::std::move(from);
}
inline BlobShape& operator=(const BlobShape& from) {
CopyFrom(from);
return *this;
}
inline BlobShape& operator=(BlobShape&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const BlobShape& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const BlobShape* internal_default_instance() {
return reinterpret_cast<const BlobShape*>(
&_BlobShape_default_instance_);
}
static constexpr int kIndexInFileMessages =
0;
friend void swap(BlobShape& a, BlobShape& b) {
a.Swap(&b);
}
inline void Swap(BlobShape* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(BlobShape* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline BlobShape* New() const final {
return CreateMaybeMessage<BlobShape>(nullptr);
}
BlobShape* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<BlobShape>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const BlobShape& from);
void MergeFrom(const BlobShape& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(BlobShape* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.BlobShape";
}
protected:
explicit BlobShape(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kDimFieldNumber = 1,
};
// repeated int64 dim = 1 [packed = true];
int dim_size() const;
private:
int _internal_dim_size() const;
public:
void clear_dim();
private:
::PROTOBUF_NAMESPACE_ID::int64 _internal_dim(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int64 >&
_internal_dim() const;
void _internal_add_dim(::PROTOBUF_NAMESPACE_ID::int64 value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int64 >*
_internal_mutable_dim();
public:
::PROTOBUF_NAMESPACE_ID::int64 dim(int index) const;
void set_dim(int index, ::PROTOBUF_NAMESPACE_ID::int64 value);
void add_dim(::PROTOBUF_NAMESPACE_ID::int64 value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int64 >&
dim() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int64 >*
mutable_dim();
// @@protoc_insertion_point(class_scope:caffe.BlobShape)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int64 > dim_;
mutable std::atomic<int> _dim_cached_byte_size_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class BlobProto PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.BlobProto) */ {
public:
inline BlobProto() : BlobProto(nullptr) {}
virtual ~BlobProto();
BlobProto(const BlobProto& from);
BlobProto(BlobProto&& from) noexcept
: BlobProto() {
*this = ::std::move(from);
}
inline BlobProto& operator=(const BlobProto& from) {
CopyFrom(from);
return *this;
}
inline BlobProto& operator=(BlobProto&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const BlobProto& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const BlobProto* internal_default_instance() {
return reinterpret_cast<const BlobProto*>(
&_BlobProto_default_instance_);
}
static constexpr int kIndexInFileMessages =
1;
friend void swap(BlobProto& a, BlobProto& b) {
a.Swap(&b);
}
inline void Swap(BlobProto* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(BlobProto* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline BlobProto* New() const final {
return CreateMaybeMessage<BlobProto>(nullptr);
}
BlobProto* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<BlobProto>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const BlobProto& from);
void MergeFrom(const BlobProto& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(BlobProto* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.BlobProto";
}
protected:
explicit BlobProto(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kDataFieldNumber = 5,
kDiffFieldNumber = 6,
kDoubleDataFieldNumber = 8,
kDoubleDiffFieldNumber = 9,
kShapeFieldNumber = 7,
kNumFieldNumber = 1,
kChannelsFieldNumber = 2,
kHeightFieldNumber = 3,
kWidthFieldNumber = 4,
};
// repeated float data = 5 [packed = true];
int data_size() const;
private:
int _internal_data_size() const;
public:
void clear_data();
private:
float _internal_data(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
_internal_data() const;
void _internal_add_data(float value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
_internal_mutable_data();
public:
float data(int index) const;
void set_data(int index, float value);
void add_data(float value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
data() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
mutable_data();
// repeated float diff = 6 [packed = true];
int diff_size() const;
private:
int _internal_diff_size() const;
public:
void clear_diff();
private:
float _internal_diff(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
_internal_diff() const;
void _internal_add_diff(float value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
_internal_mutable_diff();
public:
float diff(int index) const;
void set_diff(int index, float value);
void add_diff(float value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
diff() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
mutable_diff();
// repeated double double_data = 8 [packed = true];
int double_data_size() const;
private:
int _internal_double_data_size() const;
public:
void clear_double_data();
private:
double _internal_double_data(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< double >&
_internal_double_data() const;
void _internal_add_double_data(double value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< double >*
_internal_mutable_double_data();
public:
double double_data(int index) const;
void set_double_data(int index, double value);
void add_double_data(double value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< double >&
double_data() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< double >*
mutable_double_data();
// repeated double double_diff = 9 [packed = true];
int double_diff_size() const;
private:
int _internal_double_diff_size() const;
public:
void clear_double_diff();
private:
double _internal_double_diff(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< double >&
_internal_double_diff() const;
void _internal_add_double_diff(double value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< double >*
_internal_mutable_double_diff();
public:
double double_diff(int index) const;
void set_double_diff(int index, double value);
void add_double_diff(double value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< double >&
double_diff() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< double >*
mutable_double_diff();
// optional .caffe.BlobShape shape = 7;
bool has_shape() const;
private:
bool _internal_has_shape() const;
public:
void clear_shape();
const ::caffe::BlobShape& shape() const;
::caffe::BlobShape* release_shape();
::caffe::BlobShape* mutable_shape();
void set_allocated_shape(::caffe::BlobShape* shape);
private:
const ::caffe::BlobShape& _internal_shape() const;
::caffe::BlobShape* _internal_mutable_shape();
public:
void unsafe_arena_set_allocated_shape(
::caffe::BlobShape* shape);
::caffe::BlobShape* unsafe_arena_release_shape();
// optional int32 num = 1 [default = 0];
bool has_num() const;
private:
bool _internal_has_num() const;
public:
void clear_num();
::PROTOBUF_NAMESPACE_ID::int32 num() const;
void set_num(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_num() const;
void _internal_set_num(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional int32 channels = 2 [default = 0];
bool has_channels() const;
private:
bool _internal_has_channels() const;
public:
void clear_channels();
::PROTOBUF_NAMESPACE_ID::int32 channels() const;
void set_channels(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_channels() const;
void _internal_set_channels(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional int32 height = 3 [default = 0];
bool has_height() const;
private:
bool _internal_has_height() const;
public:
void clear_height();
::PROTOBUF_NAMESPACE_ID::int32 height() const;
void set_height(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_height() const;
void _internal_set_height(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional int32 width = 4 [default = 0];
bool has_width() const;
private:
bool _internal_has_width() const;
public:
void clear_width();
::PROTOBUF_NAMESPACE_ID::int32 width() const;
void set_width(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_width() const;
void _internal_set_width(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.BlobProto)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float > data_;
mutable std::atomic<int> _data_cached_byte_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float > diff_;
mutable std::atomic<int> _diff_cached_byte_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< double > double_data_;
mutable std::atomic<int> _double_data_cached_byte_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< double > double_diff_;
mutable std::atomic<int> _double_diff_cached_byte_size_;
::caffe::BlobShape* shape_;
::PROTOBUF_NAMESPACE_ID::int32 num_;
::PROTOBUF_NAMESPACE_ID::int32 channels_;
::PROTOBUF_NAMESPACE_ID::int32 height_;
::PROTOBUF_NAMESPACE_ID::int32 width_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class BlobProtoVector PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.BlobProtoVector) */ {
public:
inline BlobProtoVector() : BlobProtoVector(nullptr) {}
virtual ~BlobProtoVector();
BlobProtoVector(const BlobProtoVector& from);
BlobProtoVector(BlobProtoVector&& from) noexcept
: BlobProtoVector() {
*this = ::std::move(from);
}
inline BlobProtoVector& operator=(const BlobProtoVector& from) {
CopyFrom(from);
return *this;
}
inline BlobProtoVector& operator=(BlobProtoVector&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const BlobProtoVector& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const BlobProtoVector* internal_default_instance() {
return reinterpret_cast<const BlobProtoVector*>(
&_BlobProtoVector_default_instance_);
}
static constexpr int kIndexInFileMessages =
2;
friend void swap(BlobProtoVector& a, BlobProtoVector& b) {
a.Swap(&b);
}
inline void Swap(BlobProtoVector* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(BlobProtoVector* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline BlobProtoVector* New() const final {
return CreateMaybeMessage<BlobProtoVector>(nullptr);
}
BlobProtoVector* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<BlobProtoVector>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const BlobProtoVector& from);
void MergeFrom(const BlobProtoVector& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(BlobProtoVector* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.BlobProtoVector";
}
protected:
explicit BlobProtoVector(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kBlobsFieldNumber = 1,
};
// repeated .caffe.BlobProto blobs = 1;
int blobs_size() const;
private:
int _internal_blobs_size() const;
public:
void clear_blobs();
::caffe::BlobProto* mutable_blobs(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto >*
mutable_blobs();
private:
const ::caffe::BlobProto& _internal_blobs(int index) const;
::caffe::BlobProto* _internal_add_blobs();
public:
const ::caffe::BlobProto& blobs(int index) const;
::caffe::BlobProto* add_blobs();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto >&
blobs() const;
// @@protoc_insertion_point(class_scope:caffe.BlobProtoVector)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto > blobs_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class Datum PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.Datum) */ {
public:
inline Datum() : Datum(nullptr) {}
virtual ~Datum();
Datum(const Datum& from);
Datum(Datum&& from) noexcept
: Datum() {
*this = ::std::move(from);
}
inline Datum& operator=(const Datum& from) {
CopyFrom(from);
return *this;
}
inline Datum& operator=(Datum&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const Datum& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const Datum* internal_default_instance() {
return reinterpret_cast<const Datum*>(
&_Datum_default_instance_);
}
static constexpr int kIndexInFileMessages =
3;
friend void swap(Datum& a, Datum& b) {
a.Swap(&b);
}
inline void Swap(Datum* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(Datum* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline Datum* New() const final {
return CreateMaybeMessage<Datum>(nullptr);
}
Datum* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<Datum>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const Datum& from);
void MergeFrom(const Datum& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(Datum* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.Datum";
}
protected:
explicit Datum(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kFloatDataFieldNumber = 6,
kDataFieldNumber = 4,
kChannelsFieldNumber = 1,
kHeightFieldNumber = 2,
kWidthFieldNumber = 3,
kLabelFieldNumber = 5,
kEncodedFieldNumber = 7,
};
// repeated float float_data = 6;
int float_data_size() const;
private:
int _internal_float_data_size() const;
public:
void clear_float_data();
private:
float _internal_float_data(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
_internal_float_data() const;
void _internal_add_float_data(float value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
_internal_mutable_float_data();
public:
float float_data(int index) const;
void set_float_data(int index, float value);
void add_float_data(float value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
float_data() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
mutable_float_data();
// optional bytes data = 4;
bool has_data() const;
private:
bool _internal_has_data() const;
public:
void clear_data();
const std::string& data() const;
void set_data(const std::string& value);
void set_data(std::string&& value);
void set_data(const char* value);
void set_data(const void* value, size_t size);
std::string* mutable_data();
std::string* release_data();
void set_allocated_data(std::string* data);
private:
const std::string& _internal_data() const;
void _internal_set_data(const std::string& value);
std::string* _internal_mutable_data();
public:
// optional int32 channels = 1;
bool has_channels() const;
private:
bool _internal_has_channels() const;
public:
void clear_channels();
::PROTOBUF_NAMESPACE_ID::int32 channels() const;
void set_channels(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_channels() const;
void _internal_set_channels(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional int32 height = 2;
bool has_height() const;
private:
bool _internal_has_height() const;
public:
void clear_height();
::PROTOBUF_NAMESPACE_ID::int32 height() const;
void set_height(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_height() const;
void _internal_set_height(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional int32 width = 3;
bool has_width() const;
private:
bool _internal_has_width() const;
public:
void clear_width();
::PROTOBUF_NAMESPACE_ID::int32 width() const;
void set_width(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_width() const;
void _internal_set_width(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional int32 label = 5;
bool has_label() const;
private:
bool _internal_has_label() const;
public:
void clear_label();
::PROTOBUF_NAMESPACE_ID::int32 label() const;
void set_label(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_label() const;
void _internal_set_label(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional bool encoded = 7 [default = false];
bool has_encoded() const;
private:
bool _internal_has_encoded() const;
public:
void clear_encoded();
bool encoded() const;
void set_encoded(bool value);
private:
bool _internal_encoded() const;
void _internal_set_encoded(bool value);
public:
// @@protoc_insertion_point(class_scope:caffe.Datum)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float > float_data_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr data_;
::PROTOBUF_NAMESPACE_ID::int32 channels_;
::PROTOBUF_NAMESPACE_ID::int32 height_;
::PROTOBUF_NAMESPACE_ID::int32 width_;
::PROTOBUF_NAMESPACE_ID::int32 label_;
bool encoded_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class LabelMapItem PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.LabelMapItem) */ {
public:
inline LabelMapItem() : LabelMapItem(nullptr) {}
virtual ~LabelMapItem();
LabelMapItem(const LabelMapItem& from);
LabelMapItem(LabelMapItem&& from) noexcept
: LabelMapItem() {
*this = ::std::move(from);
}
inline LabelMapItem& operator=(const LabelMapItem& from) {
CopyFrom(from);
return *this;
}
inline LabelMapItem& operator=(LabelMapItem&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const LabelMapItem& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const LabelMapItem* internal_default_instance() {
return reinterpret_cast<const LabelMapItem*>(
&_LabelMapItem_default_instance_);
}
static constexpr int kIndexInFileMessages =
4;
friend void swap(LabelMapItem& a, LabelMapItem& b) {
a.Swap(&b);
}
inline void Swap(LabelMapItem* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(LabelMapItem* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline LabelMapItem* New() const final {
return CreateMaybeMessage<LabelMapItem>(nullptr);
}
LabelMapItem* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<LabelMapItem>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const LabelMapItem& from);
void MergeFrom(const LabelMapItem& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(LabelMapItem* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.LabelMapItem";
}
protected:
explicit LabelMapItem(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kNameFieldNumber = 1,
kDisplayNameFieldNumber = 3,
kLabelFieldNumber = 2,
};
// optional string name = 1;
bool has_name() const;
private:
bool _internal_has_name() const;
public:
void clear_name();
const std::string& name() const;
void set_name(const std::string& value);
void set_name(std::string&& value);
void set_name(const char* value);
void set_name(const char* value, size_t size);
std::string* mutable_name();
std::string* release_name();
void set_allocated_name(std::string* name);
private:
const std::string& _internal_name() const;
void _internal_set_name(const std::string& value);
std::string* _internal_mutable_name();
public:
// optional string display_name = 3;
bool has_display_name() const;
private:
bool _internal_has_display_name() const;
public:
void clear_display_name();
const std::string& display_name() const;
void set_display_name(const std::string& value);
void set_display_name(std::string&& value);
void set_display_name(const char* value);
void set_display_name(const char* value, size_t size);
std::string* mutable_display_name();
std::string* release_display_name();
void set_allocated_display_name(std::string* display_name);
private:
const std::string& _internal_display_name() const;
void _internal_set_display_name(const std::string& value);
std::string* _internal_mutable_display_name();
public:
// optional int32 label = 2;
bool has_label() const;
private:
bool _internal_has_label() const;
public:
void clear_label();
::PROTOBUF_NAMESPACE_ID::int32 label() const;
void set_label(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_label() const;
void _internal_set_label(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.LabelMapItem)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr name_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr display_name_;
::PROTOBUF_NAMESPACE_ID::int32 label_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class LabelMap PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.LabelMap) */ {
public:
inline LabelMap() : LabelMap(nullptr) {}
virtual ~LabelMap();
LabelMap(const LabelMap& from);
LabelMap(LabelMap&& from) noexcept
: LabelMap() {
*this = ::std::move(from);
}
inline LabelMap& operator=(const LabelMap& from) {
CopyFrom(from);
return *this;
}
inline LabelMap& operator=(LabelMap&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const LabelMap& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const LabelMap* internal_default_instance() {
return reinterpret_cast<const LabelMap*>(
&_LabelMap_default_instance_);
}
static constexpr int kIndexInFileMessages =
5;
friend void swap(LabelMap& a, LabelMap& b) {
a.Swap(&b);
}
inline void Swap(LabelMap* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(LabelMap* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline LabelMap* New() const final {
return CreateMaybeMessage<LabelMap>(nullptr);
}
LabelMap* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<LabelMap>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const LabelMap& from);
void MergeFrom(const LabelMap& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(LabelMap* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.LabelMap";
}
protected:
explicit LabelMap(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kItemFieldNumber = 1,
};
// repeated .caffe.LabelMapItem item = 1;
int item_size() const;
private:
int _internal_item_size() const;
public:
void clear_item();
::caffe::LabelMapItem* mutable_item(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::LabelMapItem >*
mutable_item();
private:
const ::caffe::LabelMapItem& _internal_item(int index) const;
::caffe::LabelMapItem* _internal_add_item();
public:
const ::caffe::LabelMapItem& item(int index) const;
::caffe::LabelMapItem* add_item();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::LabelMapItem >&
item() const;
// @@protoc_insertion_point(class_scope:caffe.LabelMap)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::LabelMapItem > item_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class Sampler PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.Sampler) */ {
public:
inline Sampler() : Sampler(nullptr) {}
virtual ~Sampler();
Sampler(const Sampler& from);
Sampler(Sampler&& from) noexcept
: Sampler() {
*this = ::std::move(from);
}
inline Sampler& operator=(const Sampler& from) {
CopyFrom(from);
return *this;
}
inline Sampler& operator=(Sampler&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const Sampler& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const Sampler* internal_default_instance() {
return reinterpret_cast<const Sampler*>(
&_Sampler_default_instance_);
}
static constexpr int kIndexInFileMessages =
6;
friend void swap(Sampler& a, Sampler& b) {
a.Swap(&b);
}
inline void Swap(Sampler* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(Sampler* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline Sampler* New() const final {
return CreateMaybeMessage<Sampler>(nullptr);
}
Sampler* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<Sampler>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const Sampler& from);
void MergeFrom(const Sampler& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(Sampler* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.Sampler";
}
protected:
explicit Sampler(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kMinScaleFieldNumber = 1,
kMaxScaleFieldNumber = 2,
kMinAspectRatioFieldNumber = 3,
kMaxAspectRatioFieldNumber = 4,
};
// optional float min_scale = 1 [default = 1];
bool has_min_scale() const;
private:
bool _internal_has_min_scale() const;
public:
void clear_min_scale();
float min_scale() const;
void set_min_scale(float value);
private:
float _internal_min_scale() const;
void _internal_set_min_scale(float value);
public:
// optional float max_scale = 2 [default = 1];
bool has_max_scale() const;
private:
bool _internal_has_max_scale() const;
public:
void clear_max_scale();
float max_scale() const;
void set_max_scale(float value);
private:
float _internal_max_scale() const;
void _internal_set_max_scale(float value);
public:
// optional float min_aspect_ratio = 3 [default = 1];
bool has_min_aspect_ratio() const;
private:
bool _internal_has_min_aspect_ratio() const;
public:
void clear_min_aspect_ratio();
float min_aspect_ratio() const;
void set_min_aspect_ratio(float value);
private:
float _internal_min_aspect_ratio() const;
void _internal_set_min_aspect_ratio(float value);
public:
// optional float max_aspect_ratio = 4 [default = 1];
bool has_max_aspect_ratio() const;
private:
bool _internal_has_max_aspect_ratio() const;
public:
void clear_max_aspect_ratio();
float max_aspect_ratio() const;
void set_max_aspect_ratio(float value);
private:
float _internal_max_aspect_ratio() const;
void _internal_set_max_aspect_ratio(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.Sampler)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
float min_scale_;
float max_scale_;
float min_aspect_ratio_;
float max_aspect_ratio_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class SampleConstraint PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.SampleConstraint) */ {
public:
inline SampleConstraint() : SampleConstraint(nullptr) {}
virtual ~SampleConstraint();
SampleConstraint(const SampleConstraint& from);
SampleConstraint(SampleConstraint&& from) noexcept
: SampleConstraint() {
*this = ::std::move(from);
}
inline SampleConstraint& operator=(const SampleConstraint& from) {
CopyFrom(from);
return *this;
}
inline SampleConstraint& operator=(SampleConstraint&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const SampleConstraint& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const SampleConstraint* internal_default_instance() {
return reinterpret_cast<const SampleConstraint*>(
&_SampleConstraint_default_instance_);
}
static constexpr int kIndexInFileMessages =
7;
friend void swap(SampleConstraint& a, SampleConstraint& b) {
a.Swap(&b);
}
inline void Swap(SampleConstraint* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(SampleConstraint* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline SampleConstraint* New() const final {
return CreateMaybeMessage<SampleConstraint>(nullptr);
}
SampleConstraint* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<SampleConstraint>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const SampleConstraint& from);
void MergeFrom(const SampleConstraint& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(SampleConstraint* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.SampleConstraint";
}
protected:
explicit SampleConstraint(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kMinJaccardOverlapFieldNumber = 1,
kMaxJaccardOverlapFieldNumber = 2,
kMinSampleCoverageFieldNumber = 3,
kMaxSampleCoverageFieldNumber = 4,
kMinObjectCoverageFieldNumber = 5,
kMaxObjectCoverageFieldNumber = 6,
};
// optional float min_jaccard_overlap = 1;
bool has_min_jaccard_overlap() const;
private:
bool _internal_has_min_jaccard_overlap() const;
public:
void clear_min_jaccard_overlap();
float min_jaccard_overlap() const;
void set_min_jaccard_overlap(float value);
private:
float _internal_min_jaccard_overlap() const;
void _internal_set_min_jaccard_overlap(float value);
public:
// optional float max_jaccard_overlap = 2;
bool has_max_jaccard_overlap() const;
private:
bool _internal_has_max_jaccard_overlap() const;
public:
void clear_max_jaccard_overlap();
float max_jaccard_overlap() const;
void set_max_jaccard_overlap(float value);
private:
float _internal_max_jaccard_overlap() const;
void _internal_set_max_jaccard_overlap(float value);
public:
// optional float min_sample_coverage = 3;
bool has_min_sample_coverage() const;
private:
bool _internal_has_min_sample_coverage() const;
public:
void clear_min_sample_coverage();
float min_sample_coverage() const;
void set_min_sample_coverage(float value);
private:
float _internal_min_sample_coverage() const;
void _internal_set_min_sample_coverage(float value);
public:
// optional float max_sample_coverage = 4;
bool has_max_sample_coverage() const;
private:
bool _internal_has_max_sample_coverage() const;
public:
void clear_max_sample_coverage();
float max_sample_coverage() const;
void set_max_sample_coverage(float value);
private:
float _internal_max_sample_coverage() const;
void _internal_set_max_sample_coverage(float value);
public:
// optional float min_object_coverage = 5;
bool has_min_object_coverage() const;
private:
bool _internal_has_min_object_coverage() const;
public:
void clear_min_object_coverage();
float min_object_coverage() const;
void set_min_object_coverage(float value);
private:
float _internal_min_object_coverage() const;
void _internal_set_min_object_coverage(float value);
public:
// optional float max_object_coverage = 6;
bool has_max_object_coverage() const;
private:
bool _internal_has_max_object_coverage() const;
public:
void clear_max_object_coverage();
float max_object_coverage() const;
void set_max_object_coverage(float value);
private:
float _internal_max_object_coverage() const;
void _internal_set_max_object_coverage(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.SampleConstraint)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
float min_jaccard_overlap_;
float max_jaccard_overlap_;
float min_sample_coverage_;
float max_sample_coverage_;
float min_object_coverage_;
float max_object_coverage_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class BatchSampler PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.BatchSampler) */ {
public:
inline BatchSampler() : BatchSampler(nullptr) {}
virtual ~BatchSampler();
BatchSampler(const BatchSampler& from);
BatchSampler(BatchSampler&& from) noexcept
: BatchSampler() {
*this = ::std::move(from);
}
inline BatchSampler& operator=(const BatchSampler& from) {
CopyFrom(from);
return *this;
}
inline BatchSampler& operator=(BatchSampler&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const BatchSampler& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const BatchSampler* internal_default_instance() {
return reinterpret_cast<const BatchSampler*>(
&_BatchSampler_default_instance_);
}
static constexpr int kIndexInFileMessages =
8;
friend void swap(BatchSampler& a, BatchSampler& b) {
a.Swap(&b);
}
inline void Swap(BatchSampler* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(BatchSampler* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline BatchSampler* New() const final {
return CreateMaybeMessage<BatchSampler>(nullptr);
}
BatchSampler* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<BatchSampler>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const BatchSampler& from);
void MergeFrom(const BatchSampler& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(BatchSampler* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.BatchSampler";
}
protected:
explicit BatchSampler(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kSamplerFieldNumber = 2,
kSampleConstraintFieldNumber = 3,
kMaxSampleFieldNumber = 4,
kUseOriginalImageFieldNumber = 1,
kMaxTrialsFieldNumber = 5,
};
// optional .caffe.Sampler sampler = 2;
bool has_sampler() const;
private:
bool _internal_has_sampler() const;
public:
void clear_sampler();
const ::caffe::Sampler& sampler() const;
::caffe::Sampler* release_sampler();
::caffe::Sampler* mutable_sampler();
void set_allocated_sampler(::caffe::Sampler* sampler);
private:
const ::caffe::Sampler& _internal_sampler() const;
::caffe::Sampler* _internal_mutable_sampler();
public:
void unsafe_arena_set_allocated_sampler(
::caffe::Sampler* sampler);
::caffe::Sampler* unsafe_arena_release_sampler();
// optional .caffe.SampleConstraint sample_constraint = 3;
bool has_sample_constraint() const;
private:
bool _internal_has_sample_constraint() const;
public:
void clear_sample_constraint();
const ::caffe::SampleConstraint& sample_constraint() const;
::caffe::SampleConstraint* release_sample_constraint();
::caffe::SampleConstraint* mutable_sample_constraint();
void set_allocated_sample_constraint(::caffe::SampleConstraint* sample_constraint);
private:
const ::caffe::SampleConstraint& _internal_sample_constraint() const;
::caffe::SampleConstraint* _internal_mutable_sample_constraint();
public:
void unsafe_arena_set_allocated_sample_constraint(
::caffe::SampleConstraint* sample_constraint);
::caffe::SampleConstraint* unsafe_arena_release_sample_constraint();
// optional uint32 max_sample = 4;
bool has_max_sample() const;
private:
bool _internal_has_max_sample() const;
public:
void clear_max_sample();
::PROTOBUF_NAMESPACE_ID::uint32 max_sample() const;
void set_max_sample(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_max_sample() const;
void _internal_set_max_sample(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional bool use_original_image = 1 [default = true];
bool has_use_original_image() const;
private:
bool _internal_has_use_original_image() const;
public:
void clear_use_original_image();
bool use_original_image() const;
void set_use_original_image(bool value);
private:
bool _internal_use_original_image() const;
void _internal_set_use_original_image(bool value);
public:
// optional uint32 max_trials = 5 [default = 100];
bool has_max_trials() const;
private:
bool _internal_has_max_trials() const;
public:
void clear_max_trials();
::PROTOBUF_NAMESPACE_ID::uint32 max_trials() const;
void set_max_trials(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_max_trials() const;
void _internal_set_max_trials(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.BatchSampler)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::caffe::Sampler* sampler_;
::caffe::SampleConstraint* sample_constraint_;
::PROTOBUF_NAMESPACE_ID::uint32 max_sample_;
bool use_original_image_;
::PROTOBUF_NAMESPACE_ID::uint32 max_trials_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class EmitConstraint PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.EmitConstraint) */ {
public:
inline EmitConstraint() : EmitConstraint(nullptr) {}
virtual ~EmitConstraint();
EmitConstraint(const EmitConstraint& from);
EmitConstraint(EmitConstraint&& from) noexcept
: EmitConstraint() {
*this = ::std::move(from);
}
inline EmitConstraint& operator=(const EmitConstraint& from) {
CopyFrom(from);
return *this;
}
inline EmitConstraint& operator=(EmitConstraint&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const EmitConstraint& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const EmitConstraint* internal_default_instance() {
return reinterpret_cast<const EmitConstraint*>(
&_EmitConstraint_default_instance_);
}
static constexpr int kIndexInFileMessages =
9;
friend void swap(EmitConstraint& a, EmitConstraint& b) {
a.Swap(&b);
}
inline void Swap(EmitConstraint* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(EmitConstraint* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline EmitConstraint* New() const final {
return CreateMaybeMessage<EmitConstraint>(nullptr);
}
EmitConstraint* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<EmitConstraint>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const EmitConstraint& from);
void MergeFrom(const EmitConstraint& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(EmitConstraint* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.EmitConstraint";
}
protected:
explicit EmitConstraint(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef EmitConstraint_EmitType EmitType;
static constexpr EmitType CENTER =
EmitConstraint_EmitType_CENTER;
static constexpr EmitType MIN_OVERLAP =
EmitConstraint_EmitType_MIN_OVERLAP;
static inline bool EmitType_IsValid(int value) {
return EmitConstraint_EmitType_IsValid(value);
}
static constexpr EmitType EmitType_MIN =
EmitConstraint_EmitType_EmitType_MIN;
static constexpr EmitType EmitType_MAX =
EmitConstraint_EmitType_EmitType_MAX;
static constexpr int EmitType_ARRAYSIZE =
EmitConstraint_EmitType_EmitType_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
EmitType_descriptor() {
return EmitConstraint_EmitType_descriptor();
}
template<typename T>
static inline const std::string& EmitType_Name(T enum_t_value) {
static_assert(::std::is_same<T, EmitType>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function EmitType_Name.");
return EmitConstraint_EmitType_Name(enum_t_value);
}
static inline bool EmitType_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
EmitType* value) {
return EmitConstraint_EmitType_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kEmitTypeFieldNumber = 1,
kEmitOverlapFieldNumber = 2,
};
// optional .caffe.EmitConstraint.EmitType emit_type = 1 [default = CENTER];
bool has_emit_type() const;
private:
bool _internal_has_emit_type() const;
public:
void clear_emit_type();
::caffe::EmitConstraint_EmitType emit_type() const;
void set_emit_type(::caffe::EmitConstraint_EmitType value);
private:
::caffe::EmitConstraint_EmitType _internal_emit_type() const;
void _internal_set_emit_type(::caffe::EmitConstraint_EmitType value);
public:
// optional float emit_overlap = 2;
bool has_emit_overlap() const;
private:
bool _internal_has_emit_overlap() const;
public:
void clear_emit_overlap();
float emit_overlap() const;
void set_emit_overlap(float value);
private:
float _internal_emit_overlap() const;
void _internal_set_emit_overlap(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.EmitConstraint)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
int emit_type_;
float emit_overlap_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class NormalizedBBox PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.NormalizedBBox) */ {
public:
inline NormalizedBBox() : NormalizedBBox(nullptr) {}
virtual ~NormalizedBBox();
NormalizedBBox(const NormalizedBBox& from);
NormalizedBBox(NormalizedBBox&& from) noexcept
: NormalizedBBox() {
*this = ::std::move(from);
}
inline NormalizedBBox& operator=(const NormalizedBBox& from) {
CopyFrom(from);
return *this;
}
inline NormalizedBBox& operator=(NormalizedBBox&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const NormalizedBBox& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const NormalizedBBox* internal_default_instance() {
return reinterpret_cast<const NormalizedBBox*>(
&_NormalizedBBox_default_instance_);
}
static constexpr int kIndexInFileMessages =
10;
friend void swap(NormalizedBBox& a, NormalizedBBox& b) {
a.Swap(&b);
}
inline void Swap(NormalizedBBox* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(NormalizedBBox* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline NormalizedBBox* New() const final {
return CreateMaybeMessage<NormalizedBBox>(nullptr);
}
NormalizedBBox* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<NormalizedBBox>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const NormalizedBBox& from);
void MergeFrom(const NormalizedBBox& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(NormalizedBBox* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.NormalizedBBox";
}
protected:
explicit NormalizedBBox(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kXminFieldNumber = 1,
kYminFieldNumber = 2,
kXmaxFieldNumber = 3,
kYmaxFieldNumber = 4,
kLabelFieldNumber = 5,
kDifficultFieldNumber = 6,
kScoreFieldNumber = 7,
kSizeFieldNumber = 8,
};
// optional float xmin = 1;
bool has_xmin() const;
private:
bool _internal_has_xmin() const;
public:
void clear_xmin();
float xmin() const;
void set_xmin(float value);
private:
float _internal_xmin() const;
void _internal_set_xmin(float value);
public:
// optional float ymin = 2;
bool has_ymin() const;
private:
bool _internal_has_ymin() const;
public:
void clear_ymin();
float ymin() const;
void set_ymin(float value);
private:
float _internal_ymin() const;
void _internal_set_ymin(float value);
public:
// optional float xmax = 3;
bool has_xmax() const;
private:
bool _internal_has_xmax() const;
public:
void clear_xmax();
float xmax() const;
void set_xmax(float value);
private:
float _internal_xmax() const;
void _internal_set_xmax(float value);
public:
// optional float ymax = 4;
bool has_ymax() const;
private:
bool _internal_has_ymax() const;
public:
void clear_ymax();
float ymax() const;
void set_ymax(float value);
private:
float _internal_ymax() const;
void _internal_set_ymax(float value);
public:
// optional int32 label = 5;
bool has_label() const;
private:
bool _internal_has_label() const;
public:
void clear_label();
::PROTOBUF_NAMESPACE_ID::int32 label() const;
void set_label(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_label() const;
void _internal_set_label(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional bool difficult = 6;
bool has_difficult() const;
private:
bool _internal_has_difficult() const;
public:
void clear_difficult();
bool difficult() const;
void set_difficult(bool value);
private:
bool _internal_difficult() const;
void _internal_set_difficult(bool value);
public:
// optional float score = 7;
bool has_score() const;
private:
bool _internal_has_score() const;
public:
void clear_score();
float score() const;
void set_score(float value);
private:
float _internal_score() const;
void _internal_set_score(float value);
public:
// optional float size = 8;
bool has_size() const;
private:
bool _internal_has_size() const;
public:
void clear_size();
float size() const;
void set_size(float value);
private:
float _internal_size() const;
void _internal_set_size(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.NormalizedBBox)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
float xmin_;
float ymin_;
float xmax_;
float ymax_;
::PROTOBUF_NAMESPACE_ID::int32 label_;
bool difficult_;
float score_;
float size_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class Annotation PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.Annotation) */ {
public:
inline Annotation() : Annotation(nullptr) {}
virtual ~Annotation();
Annotation(const Annotation& from);
Annotation(Annotation&& from) noexcept
: Annotation() {
*this = ::std::move(from);
}
inline Annotation& operator=(const Annotation& from) {
CopyFrom(from);
return *this;
}
inline Annotation& operator=(Annotation&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const Annotation& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const Annotation* internal_default_instance() {
return reinterpret_cast<const Annotation*>(
&_Annotation_default_instance_);
}
static constexpr int kIndexInFileMessages =
11;
friend void swap(Annotation& a, Annotation& b) {
a.Swap(&b);
}
inline void Swap(Annotation* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(Annotation* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline Annotation* New() const final {
return CreateMaybeMessage<Annotation>(nullptr);
}
Annotation* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<Annotation>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const Annotation& from);
void MergeFrom(const Annotation& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(Annotation* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.Annotation";
}
protected:
explicit Annotation(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kBboxFieldNumber = 2,
kInstanceIdFieldNumber = 1,
};
// optional .caffe.NormalizedBBox bbox = 2;
bool has_bbox() const;
private:
bool _internal_has_bbox() const;
public:
void clear_bbox();
const ::caffe::NormalizedBBox& bbox() const;
::caffe::NormalizedBBox* release_bbox();
::caffe::NormalizedBBox* mutable_bbox();
void set_allocated_bbox(::caffe::NormalizedBBox* bbox);
private:
const ::caffe::NormalizedBBox& _internal_bbox() const;
::caffe::NormalizedBBox* _internal_mutable_bbox();
public:
void unsafe_arena_set_allocated_bbox(
::caffe::NormalizedBBox* bbox);
::caffe::NormalizedBBox* unsafe_arena_release_bbox();
// optional int32 instance_id = 1 [default = 0];
bool has_instance_id() const;
private:
bool _internal_has_instance_id() const;
public:
void clear_instance_id();
::PROTOBUF_NAMESPACE_ID::int32 instance_id() const;
void set_instance_id(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_instance_id() const;
void _internal_set_instance_id(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.Annotation)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::caffe::NormalizedBBox* bbox_;
::PROTOBUF_NAMESPACE_ID::int32 instance_id_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class AnnotationGroup PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.AnnotationGroup) */ {
public:
inline AnnotationGroup() : AnnotationGroup(nullptr) {}
virtual ~AnnotationGroup();
AnnotationGroup(const AnnotationGroup& from);
AnnotationGroup(AnnotationGroup&& from) noexcept
: AnnotationGroup() {
*this = ::std::move(from);
}
inline AnnotationGroup& operator=(const AnnotationGroup& from) {
CopyFrom(from);
return *this;
}
inline AnnotationGroup& operator=(AnnotationGroup&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const AnnotationGroup& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const AnnotationGroup* internal_default_instance() {
return reinterpret_cast<const AnnotationGroup*>(
&_AnnotationGroup_default_instance_);
}
static constexpr int kIndexInFileMessages =
12;
friend void swap(AnnotationGroup& a, AnnotationGroup& b) {
a.Swap(&b);
}
inline void Swap(AnnotationGroup* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(AnnotationGroup* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline AnnotationGroup* New() const final {
return CreateMaybeMessage<AnnotationGroup>(nullptr);
}
AnnotationGroup* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<AnnotationGroup>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const AnnotationGroup& from);
void MergeFrom(const AnnotationGroup& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(AnnotationGroup* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.AnnotationGroup";
}
protected:
explicit AnnotationGroup(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kAnnotationFieldNumber = 2,
kGroupLabelFieldNumber = 1,
};
// repeated .caffe.Annotation annotation = 2;
int annotation_size() const;
private:
int _internal_annotation_size() const;
public:
void clear_annotation();
::caffe::Annotation* mutable_annotation(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::Annotation >*
mutable_annotation();
private:
const ::caffe::Annotation& _internal_annotation(int index) const;
::caffe::Annotation* _internal_add_annotation();
public:
const ::caffe::Annotation& annotation(int index) const;
::caffe::Annotation* add_annotation();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::Annotation >&
annotation() const;
// optional int32 group_label = 1;
bool has_group_label() const;
private:
bool _internal_has_group_label() const;
public:
void clear_group_label();
::PROTOBUF_NAMESPACE_ID::int32 group_label() const;
void set_group_label(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_group_label() const;
void _internal_set_group_label(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.AnnotationGroup)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::Annotation > annotation_;
::PROTOBUF_NAMESPACE_ID::int32 group_label_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class AnnotatedDatum PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.AnnotatedDatum) */ {
public:
inline AnnotatedDatum() : AnnotatedDatum(nullptr) {}
virtual ~AnnotatedDatum();
AnnotatedDatum(const AnnotatedDatum& from);
AnnotatedDatum(AnnotatedDatum&& from) noexcept
: AnnotatedDatum() {
*this = ::std::move(from);
}
inline AnnotatedDatum& operator=(const AnnotatedDatum& from) {
CopyFrom(from);
return *this;
}
inline AnnotatedDatum& operator=(AnnotatedDatum&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const AnnotatedDatum& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const AnnotatedDatum* internal_default_instance() {
return reinterpret_cast<const AnnotatedDatum*>(
&_AnnotatedDatum_default_instance_);
}
static constexpr int kIndexInFileMessages =
13;
friend void swap(AnnotatedDatum& a, AnnotatedDatum& b) {
a.Swap(&b);
}
inline void Swap(AnnotatedDatum* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(AnnotatedDatum* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline AnnotatedDatum* New() const final {
return CreateMaybeMessage<AnnotatedDatum>(nullptr);
}
AnnotatedDatum* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<AnnotatedDatum>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const AnnotatedDatum& from);
void MergeFrom(const AnnotatedDatum& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(AnnotatedDatum* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.AnnotatedDatum";
}
protected:
explicit AnnotatedDatum(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef AnnotatedDatum_AnnotationType AnnotationType;
static constexpr AnnotationType BBOX =
AnnotatedDatum_AnnotationType_BBOX;
static inline bool AnnotationType_IsValid(int value) {
return AnnotatedDatum_AnnotationType_IsValid(value);
}
static constexpr AnnotationType AnnotationType_MIN =
AnnotatedDatum_AnnotationType_AnnotationType_MIN;
static constexpr AnnotationType AnnotationType_MAX =
AnnotatedDatum_AnnotationType_AnnotationType_MAX;
static constexpr int AnnotationType_ARRAYSIZE =
AnnotatedDatum_AnnotationType_AnnotationType_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
AnnotationType_descriptor() {
return AnnotatedDatum_AnnotationType_descriptor();
}
template<typename T>
static inline const std::string& AnnotationType_Name(T enum_t_value) {
static_assert(::std::is_same<T, AnnotationType>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function AnnotationType_Name.");
return AnnotatedDatum_AnnotationType_Name(enum_t_value);
}
static inline bool AnnotationType_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
AnnotationType* value) {
return AnnotatedDatum_AnnotationType_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kAnnotationGroupFieldNumber = 3,
kDatumFieldNumber = 1,
kTypeFieldNumber = 2,
};
// repeated .caffe.AnnotationGroup annotation_group = 3;
int annotation_group_size() const;
private:
int _internal_annotation_group_size() const;
public:
void clear_annotation_group();
::caffe::AnnotationGroup* mutable_annotation_group(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::AnnotationGroup >*
mutable_annotation_group();
private:
const ::caffe::AnnotationGroup& _internal_annotation_group(int index) const;
::caffe::AnnotationGroup* _internal_add_annotation_group();
public:
const ::caffe::AnnotationGroup& annotation_group(int index) const;
::caffe::AnnotationGroup* add_annotation_group();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::AnnotationGroup >&
annotation_group() const;
// optional .caffe.Datum datum = 1;
bool has_datum() const;
private:
bool _internal_has_datum() const;
public:
void clear_datum();
const ::caffe::Datum& datum() const;
::caffe::Datum* release_datum();
::caffe::Datum* mutable_datum();
void set_allocated_datum(::caffe::Datum* datum);
private:
const ::caffe::Datum& _internal_datum() const;
::caffe::Datum* _internal_mutable_datum();
public:
void unsafe_arena_set_allocated_datum(
::caffe::Datum* datum);
::caffe::Datum* unsafe_arena_release_datum();
// optional .caffe.AnnotatedDatum.AnnotationType type = 2;
bool has_type() const;
private:
bool _internal_has_type() const;
public:
void clear_type();
::caffe::AnnotatedDatum_AnnotationType type() const;
void set_type(::caffe::AnnotatedDatum_AnnotationType value);
private:
::caffe::AnnotatedDatum_AnnotationType _internal_type() const;
void _internal_set_type(::caffe::AnnotatedDatum_AnnotationType value);
public:
// @@protoc_insertion_point(class_scope:caffe.AnnotatedDatum)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::AnnotationGroup > annotation_group_;
::caffe::Datum* datum_;
int type_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class FillerParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.FillerParameter) */ {
public:
inline FillerParameter() : FillerParameter(nullptr) {}
virtual ~FillerParameter();
FillerParameter(const FillerParameter& from);
FillerParameter(FillerParameter&& from) noexcept
: FillerParameter() {
*this = ::std::move(from);
}
inline FillerParameter& operator=(const FillerParameter& from) {
CopyFrom(from);
return *this;
}
inline FillerParameter& operator=(FillerParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const FillerParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const FillerParameter* internal_default_instance() {
return reinterpret_cast<const FillerParameter*>(
&_FillerParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
14;
friend void swap(FillerParameter& a, FillerParameter& b) {
a.Swap(&b);
}
inline void Swap(FillerParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(FillerParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline FillerParameter* New() const final {
return CreateMaybeMessage<FillerParameter>(nullptr);
}
FillerParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<FillerParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const FillerParameter& from);
void MergeFrom(const FillerParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(FillerParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.FillerParameter";
}
protected:
explicit FillerParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef FillerParameter_VarianceNorm VarianceNorm;
static constexpr VarianceNorm FAN_IN =
FillerParameter_VarianceNorm_FAN_IN;
static constexpr VarianceNorm FAN_OUT =
FillerParameter_VarianceNorm_FAN_OUT;
static constexpr VarianceNorm AVERAGE =
FillerParameter_VarianceNorm_AVERAGE;
static inline bool VarianceNorm_IsValid(int value) {
return FillerParameter_VarianceNorm_IsValid(value);
}
static constexpr VarianceNorm VarianceNorm_MIN =
FillerParameter_VarianceNorm_VarianceNorm_MIN;
static constexpr VarianceNorm VarianceNorm_MAX =
FillerParameter_VarianceNorm_VarianceNorm_MAX;
static constexpr int VarianceNorm_ARRAYSIZE =
FillerParameter_VarianceNorm_VarianceNorm_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
VarianceNorm_descriptor() {
return FillerParameter_VarianceNorm_descriptor();
}
template<typename T>
static inline const std::string& VarianceNorm_Name(T enum_t_value) {
static_assert(::std::is_same<T, VarianceNorm>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function VarianceNorm_Name.");
return FillerParameter_VarianceNorm_Name(enum_t_value);
}
static inline bool VarianceNorm_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
VarianceNorm* value) {
return FillerParameter_VarianceNorm_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kTypeFieldNumber = 1,
kValueFieldNumber = 2,
kMinFieldNumber = 3,
kMeanFieldNumber = 5,
kVarianceNormFieldNumber = 8,
kSparseFieldNumber = 7,
kMaxFieldNumber = 4,
kStdFieldNumber = 6,
};
// optional string type = 1 [default = "constant"];
bool has_type() const;
private:
bool _internal_has_type() const;
public:
void clear_type();
const std::string& type() const;
void set_type(const std::string& value);
void set_type(std::string&& value);
void set_type(const char* value);
void set_type(const char* value, size_t size);
std::string* mutable_type();
std::string* release_type();
void set_allocated_type(std::string* type);
private:
const std::string& _internal_type() const;
void _internal_set_type(const std::string& value);
std::string* _internal_mutable_type();
public:
// optional float value = 2 [default = 0];
bool has_value() const;
private:
bool _internal_has_value() const;
public:
void clear_value();
float value() const;
void set_value(float value);
private:
float _internal_value() const;
void _internal_set_value(float value);
public:
// optional float min = 3 [default = 0];
bool has_min() const;
private:
bool _internal_has_min() const;
public:
void clear_min();
float min() const;
void set_min(float value);
private:
float _internal_min() const;
void _internal_set_min(float value);
public:
// optional float mean = 5 [default = 0];
bool has_mean() const;
private:
bool _internal_has_mean() const;
public:
void clear_mean();
float mean() const;
void set_mean(float value);
private:
float _internal_mean() const;
void _internal_set_mean(float value);
public:
// optional .caffe.FillerParameter.VarianceNorm variance_norm = 8 [default = FAN_IN];
bool has_variance_norm() const;
private:
bool _internal_has_variance_norm() const;
public:
void clear_variance_norm();
::caffe::FillerParameter_VarianceNorm variance_norm() const;
void set_variance_norm(::caffe::FillerParameter_VarianceNorm value);
private:
::caffe::FillerParameter_VarianceNorm _internal_variance_norm() const;
void _internal_set_variance_norm(::caffe::FillerParameter_VarianceNorm value);
public:
// optional int32 sparse = 7 [default = -1];
bool has_sparse() const;
private:
bool _internal_has_sparse() const;
public:
void clear_sparse();
::PROTOBUF_NAMESPACE_ID::int32 sparse() const;
void set_sparse(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_sparse() const;
void _internal_set_sparse(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional float max = 4 [default = 1];
bool has_max() const;
private:
bool _internal_has_max() const;
public:
void clear_max();
float max() const;
void set_max(float value);
private:
float _internal_max() const;
void _internal_set_max(float value);
public:
// optional float std = 6 [default = 1];
bool has_std() const;
private:
bool _internal_has_std() const;
public:
void clear_std();
float std() const;
void set_std(float value);
private:
float _internal_std() const;
void _internal_set_std(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.FillerParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
public:
static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> _i_give_permission_to_break_this_code_default_type_;
private:
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr type_;
float value_;
float min_;
float mean_;
int variance_norm_;
::PROTOBUF_NAMESPACE_ID::int32 sparse_;
float max_;
float std_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class NetParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.NetParameter) */ {
public:
inline NetParameter() : NetParameter(nullptr) {}
virtual ~NetParameter();
NetParameter(const NetParameter& from);
NetParameter(NetParameter&& from) noexcept
: NetParameter() {
*this = ::std::move(from);
}
inline NetParameter& operator=(const NetParameter& from) {
CopyFrom(from);
return *this;
}
inline NetParameter& operator=(NetParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const NetParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const NetParameter* internal_default_instance() {
return reinterpret_cast<const NetParameter*>(
&_NetParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
15;
friend void swap(NetParameter& a, NetParameter& b) {
a.Swap(&b);
}
inline void Swap(NetParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(NetParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline NetParameter* New() const final {
return CreateMaybeMessage<NetParameter>(nullptr);
}
NetParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<NetParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const NetParameter& from);
void MergeFrom(const NetParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(NetParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.NetParameter";
}
protected:
explicit NetParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kLayersFieldNumber = 2,
kInputFieldNumber = 3,
kInputDimFieldNumber = 4,
kInputShapeFieldNumber = 8,
kLayerFieldNumber = 100,
kNameFieldNumber = 1,
kStateFieldNumber = 6,
kInitialSkipFieldNumber = 9,
kForceBackwardFieldNumber = 5,
kDebugInfoFieldNumber = 7,
};
// repeated .caffe.V1LayerParameter layers = 2;
int layers_size() const;
private:
int _internal_layers_size() const;
public:
void clear_layers();
::caffe::V1LayerParameter* mutable_layers(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::V1LayerParameter >*
mutable_layers();
private:
const ::caffe::V1LayerParameter& _internal_layers(int index) const;
::caffe::V1LayerParameter* _internal_add_layers();
public:
const ::caffe::V1LayerParameter& layers(int index) const;
::caffe::V1LayerParameter* add_layers();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::V1LayerParameter >&
layers() const;
// repeated string input = 3;
int input_size() const;
private:
int _internal_input_size() const;
public:
void clear_input();
const std::string& input(int index) const;
std::string* mutable_input(int index);
void set_input(int index, const std::string& value);
void set_input(int index, std::string&& value);
void set_input(int index, const char* value);
void set_input(int index, const char* value, size_t size);
std::string* add_input();
void add_input(const std::string& value);
void add_input(std::string&& value);
void add_input(const char* value);
void add_input(const char* value, size_t size);
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>& input() const;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>* mutable_input();
private:
const std::string& _internal_input(int index) const;
std::string* _internal_add_input();
public:
// repeated int32 input_dim = 4;
int input_dim_size() const;
private:
int _internal_input_dim_size() const;
public:
void clear_input_dim();
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_input_dim(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >&
_internal_input_dim() const;
void _internal_add_input_dim(::PROTOBUF_NAMESPACE_ID::int32 value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >*
_internal_mutable_input_dim();
public:
::PROTOBUF_NAMESPACE_ID::int32 input_dim(int index) const;
void set_input_dim(int index, ::PROTOBUF_NAMESPACE_ID::int32 value);
void add_input_dim(::PROTOBUF_NAMESPACE_ID::int32 value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >&
input_dim() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >*
mutable_input_dim();
// repeated .caffe.BlobShape input_shape = 8;
int input_shape_size() const;
private:
int _internal_input_shape_size() const;
public:
void clear_input_shape();
::caffe::BlobShape* mutable_input_shape(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape >*
mutable_input_shape();
private:
const ::caffe::BlobShape& _internal_input_shape(int index) const;
::caffe::BlobShape* _internal_add_input_shape();
public:
const ::caffe::BlobShape& input_shape(int index) const;
::caffe::BlobShape* add_input_shape();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape >&
input_shape() const;
// repeated .caffe.LayerParameter layer = 100;
int layer_size() const;
private:
int _internal_layer_size() const;
public:
void clear_layer();
::caffe::LayerParameter* mutable_layer(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::LayerParameter >*
mutable_layer();
private:
const ::caffe::LayerParameter& _internal_layer(int index) const;
::caffe::LayerParameter* _internal_add_layer();
public:
const ::caffe::LayerParameter& layer(int index) const;
::caffe::LayerParameter* add_layer();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::LayerParameter >&
layer() const;
// optional string name = 1;
bool has_name() const;
private:
bool _internal_has_name() const;
public:
void clear_name();
const std::string& name() const;
void set_name(const std::string& value);
void set_name(std::string&& value);
void set_name(const char* value);
void set_name(const char* value, size_t size);
std::string* mutable_name();
std::string* release_name();
void set_allocated_name(std::string* name);
private:
const std::string& _internal_name() const;
void _internal_set_name(const std::string& value);
std::string* _internal_mutable_name();
public:
// optional .caffe.NetState state = 6;
bool has_state() const;
private:
bool _internal_has_state() const;
public:
void clear_state();
const ::caffe::NetState& state() const;
::caffe::NetState* release_state();
::caffe::NetState* mutable_state();
void set_allocated_state(::caffe::NetState* state);
private:
const ::caffe::NetState& _internal_state() const;
::caffe::NetState* _internal_mutable_state();
public:
void unsafe_arena_set_allocated_state(
::caffe::NetState* state);
::caffe::NetState* unsafe_arena_release_state();
// optional bool initial_skip = 9 [default = false];
bool has_initial_skip() const;
private:
bool _internal_has_initial_skip() const;
public:
void clear_initial_skip();
bool initial_skip() const;
void set_initial_skip(bool value);
private:
bool _internal_initial_skip() const;
void _internal_set_initial_skip(bool value);
public:
// optional bool force_backward = 5 [default = false];
bool has_force_backward() const;
private:
bool _internal_has_force_backward() const;
public:
void clear_force_backward();
bool force_backward() const;
void set_force_backward(bool value);
private:
bool _internal_force_backward() const;
void _internal_set_force_backward(bool value);
public:
// optional bool debug_info = 7 [default = false];
bool has_debug_info() const;
private:
bool _internal_has_debug_info() const;
public:
void clear_debug_info();
bool debug_info() const;
void set_debug_info(bool value);
private:
bool _internal_debug_info() const;
void _internal_set_debug_info(bool value);
public:
// @@protoc_insertion_point(class_scope:caffe.NetParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::V1LayerParameter > layers_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string> input_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 > input_dim_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape > input_shape_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::LayerParameter > layer_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr name_;
::caffe::NetState* state_;
bool initial_skip_;
bool force_backward_;
bool debug_info_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class SolverParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.SolverParameter) */ {
public:
inline SolverParameter() : SolverParameter(nullptr) {}
virtual ~SolverParameter();
SolverParameter(const SolverParameter& from);
SolverParameter(SolverParameter&& from) noexcept
: SolverParameter() {
*this = ::std::move(from);
}
inline SolverParameter& operator=(const SolverParameter& from) {
CopyFrom(from);
return *this;
}
inline SolverParameter& operator=(SolverParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const SolverParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const SolverParameter* internal_default_instance() {
return reinterpret_cast<const SolverParameter*>(
&_SolverParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
16;
friend void swap(SolverParameter& a, SolverParameter& b) {
a.Swap(&b);
}
inline void Swap(SolverParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(SolverParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline SolverParameter* New() const final {
return CreateMaybeMessage<SolverParameter>(nullptr);
}
SolverParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<SolverParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const SolverParameter& from);
void MergeFrom(const SolverParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(SolverParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.SolverParameter";
}
protected:
explicit SolverParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef SolverParameter_SnapshotFormat SnapshotFormat;
static constexpr SnapshotFormat HDF5 =
SolverParameter_SnapshotFormat_HDF5;
static constexpr SnapshotFormat BINARYPROTO =
SolverParameter_SnapshotFormat_BINARYPROTO;
static inline bool SnapshotFormat_IsValid(int value) {
return SolverParameter_SnapshotFormat_IsValid(value);
}
static constexpr SnapshotFormat SnapshotFormat_MIN =
SolverParameter_SnapshotFormat_SnapshotFormat_MIN;
static constexpr SnapshotFormat SnapshotFormat_MAX =
SolverParameter_SnapshotFormat_SnapshotFormat_MAX;
static constexpr int SnapshotFormat_ARRAYSIZE =
SolverParameter_SnapshotFormat_SnapshotFormat_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
SnapshotFormat_descriptor() {
return SolverParameter_SnapshotFormat_descriptor();
}
template<typename T>
static inline const std::string& SnapshotFormat_Name(T enum_t_value) {
static_assert(::std::is_same<T, SnapshotFormat>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function SnapshotFormat_Name.");
return SolverParameter_SnapshotFormat_Name(enum_t_value);
}
static inline bool SnapshotFormat_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
SnapshotFormat* value) {
return SolverParameter_SnapshotFormat_Parse(name, value);
}
typedef SolverParameter_SolverMode SolverMode;
static constexpr SolverMode CPU =
SolverParameter_SolverMode_CPU;
static constexpr SolverMode GPU =
SolverParameter_SolverMode_GPU;
static inline bool SolverMode_IsValid(int value) {
return SolverParameter_SolverMode_IsValid(value);
}
static constexpr SolverMode SolverMode_MIN =
SolverParameter_SolverMode_SolverMode_MIN;
static constexpr SolverMode SolverMode_MAX =
SolverParameter_SolverMode_SolverMode_MAX;
static constexpr int SolverMode_ARRAYSIZE =
SolverParameter_SolverMode_SolverMode_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
SolverMode_descriptor() {
return SolverParameter_SolverMode_descriptor();
}
template<typename T>
static inline const std::string& SolverMode_Name(T enum_t_value) {
static_assert(::std::is_same<T, SolverMode>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function SolverMode_Name.");
return SolverParameter_SolverMode_Name(enum_t_value);
}
static inline bool SolverMode_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
SolverMode* value) {
return SolverParameter_SolverMode_Parse(name, value);
}
typedef SolverParameter_SolverType SolverType;
static constexpr SolverType SGD =
SolverParameter_SolverType_SGD;
static constexpr SolverType NESTEROV =
SolverParameter_SolverType_NESTEROV;
static constexpr SolverType ADAGRAD =
SolverParameter_SolverType_ADAGRAD;
static constexpr SolverType RMSPROP =
SolverParameter_SolverType_RMSPROP;
static constexpr SolverType ADADELTA =
SolverParameter_SolverType_ADADELTA;
static constexpr SolverType ADAM =
SolverParameter_SolverType_ADAM;
static inline bool SolverType_IsValid(int value) {
return SolverParameter_SolverType_IsValid(value);
}
static constexpr SolverType SolverType_MIN =
SolverParameter_SolverType_SolverType_MIN;
static constexpr SolverType SolverType_MAX =
SolverParameter_SolverType_SolverType_MAX;
static constexpr int SolverType_ARRAYSIZE =
SolverParameter_SolverType_SolverType_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
SolverType_descriptor() {
return SolverParameter_SolverType_descriptor();
}
template<typename T>
static inline const std::string& SolverType_Name(T enum_t_value) {
static_assert(::std::is_same<T, SolverType>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function SolverType_Name.");
return SolverParameter_SolverType_Name(enum_t_value);
}
static inline bool SolverType_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
SolverType* value) {
return SolverParameter_SolverType_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kTestNetFieldNumber = 2,
kTestIterFieldNumber = 3,
kTestNetParamFieldNumber = 22,
kTestStateFieldNumber = 27,
kStepvalueFieldNumber = 34,
kTrainNetFieldNumber = 1,
kLrPolicyFieldNumber = 8,
kSnapshotPrefixFieldNumber = 15,
kNetFieldNumber = 24,
kRegularizationTypeFieldNumber = 29,
kTypeFieldNumber = 40,
kEvalTypeFieldNumber = 41,
kApVersionFieldNumber = 42,
kTrainNetParamFieldNumber = 21,
kNetParamFieldNumber = 25,
kTrainStateFieldNumber = 26,
kTestIntervalFieldNumber = 4,
kBaseLrFieldNumber = 5,
kDisplayFieldNumber = 6,
kMaxIterFieldNumber = 7,
kGammaFieldNumber = 9,
kPowerFieldNumber = 10,
kMomentumFieldNumber = 11,
kWeightDecayFieldNumber = 12,
kStepsizeFieldNumber = 13,
kSnapshotFieldNumber = 14,
kDeviceIdFieldNumber = 18,
kTestComputeLossFieldNumber = 19,
kSnapshotDiffFieldNumber = 16,
kDebugInfoFieldNumber = 23,
kSolverTypeFieldNumber = 30,
kRmsDecayFieldNumber = 38,
kRandomSeedFieldNumber = 20,
kSolverModeFieldNumber = 17,
kTestInitializationFieldNumber = 32,
kSnapshotAfterTrainFieldNumber = 28,
kDeltaFieldNumber = 31,
kAverageLossFieldNumber = 33,
kClipGradientsFieldNumber = 35,
kIterSizeFieldNumber = 36,
kSnapshotFormatFieldNumber = 37,
kMomentum2FieldNumber = 39,
};
// repeated string test_net = 2;
int test_net_size() const;
private:
int _internal_test_net_size() const;
public:
void clear_test_net();
const std::string& test_net(int index) const;
std::string* mutable_test_net(int index);
void set_test_net(int index, const std::string& value);
void set_test_net(int index, std::string&& value);
void set_test_net(int index, const char* value);
void set_test_net(int index, const char* value, size_t size);
std::string* add_test_net();
void add_test_net(const std::string& value);
void add_test_net(std::string&& value);
void add_test_net(const char* value);
void add_test_net(const char* value, size_t size);
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>& test_net() const;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>* mutable_test_net();
private:
const std::string& _internal_test_net(int index) const;
std::string* _internal_add_test_net();
public:
// repeated int32 test_iter = 3;
int test_iter_size() const;
private:
int _internal_test_iter_size() const;
public:
void clear_test_iter();
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_test_iter(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >&
_internal_test_iter() const;
void _internal_add_test_iter(::PROTOBUF_NAMESPACE_ID::int32 value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >*
_internal_mutable_test_iter();
public:
::PROTOBUF_NAMESPACE_ID::int32 test_iter(int index) const;
void set_test_iter(int index, ::PROTOBUF_NAMESPACE_ID::int32 value);
void add_test_iter(::PROTOBUF_NAMESPACE_ID::int32 value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >&
test_iter() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >*
mutable_test_iter();
// repeated .caffe.NetParameter test_net_param = 22;
int test_net_param_size() const;
private:
int _internal_test_net_param_size() const;
public:
void clear_test_net_param();
::caffe::NetParameter* mutable_test_net_param(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetParameter >*
mutable_test_net_param();
private:
const ::caffe::NetParameter& _internal_test_net_param(int index) const;
::caffe::NetParameter* _internal_add_test_net_param();
public:
const ::caffe::NetParameter& test_net_param(int index) const;
::caffe::NetParameter* add_test_net_param();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetParameter >&
test_net_param() const;
// repeated .caffe.NetState test_state = 27;
int test_state_size() const;
private:
int _internal_test_state_size() const;
public:
void clear_test_state();
::caffe::NetState* mutable_test_state(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetState >*
mutable_test_state();
private:
const ::caffe::NetState& _internal_test_state(int index) const;
::caffe::NetState* _internal_add_test_state();
public:
const ::caffe::NetState& test_state(int index) const;
::caffe::NetState* add_test_state();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetState >&
test_state() const;
// repeated int32 stepvalue = 34;
int stepvalue_size() const;
private:
int _internal_stepvalue_size() const;
public:
void clear_stepvalue();
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_stepvalue(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >&
_internal_stepvalue() const;
void _internal_add_stepvalue(::PROTOBUF_NAMESPACE_ID::int32 value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >*
_internal_mutable_stepvalue();
public:
::PROTOBUF_NAMESPACE_ID::int32 stepvalue(int index) const;
void set_stepvalue(int index, ::PROTOBUF_NAMESPACE_ID::int32 value);
void add_stepvalue(::PROTOBUF_NAMESPACE_ID::int32 value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >&
stepvalue() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >*
mutable_stepvalue();
// optional string train_net = 1;
bool has_train_net() const;
private:
bool _internal_has_train_net() const;
public:
void clear_train_net();
const std::string& train_net() const;
void set_train_net(const std::string& value);
void set_train_net(std::string&& value);
void set_train_net(const char* value);
void set_train_net(const char* value, size_t size);
std::string* mutable_train_net();
std::string* release_train_net();
void set_allocated_train_net(std::string* train_net);
private:
const std::string& _internal_train_net() const;
void _internal_set_train_net(const std::string& value);
std::string* _internal_mutable_train_net();
public:
// optional string lr_policy = 8;
bool has_lr_policy() const;
private:
bool _internal_has_lr_policy() const;
public:
void clear_lr_policy();
const std::string& lr_policy() const;
void set_lr_policy(const std::string& value);
void set_lr_policy(std::string&& value);
void set_lr_policy(const char* value);
void set_lr_policy(const char* value, size_t size);
std::string* mutable_lr_policy();
std::string* release_lr_policy();
void set_allocated_lr_policy(std::string* lr_policy);
private:
const std::string& _internal_lr_policy() const;
void _internal_set_lr_policy(const std::string& value);
std::string* _internal_mutable_lr_policy();
public:
// optional string snapshot_prefix = 15;
bool has_snapshot_prefix() const;
private:
bool _internal_has_snapshot_prefix() const;
public:
void clear_snapshot_prefix();
const std::string& snapshot_prefix() const;
void set_snapshot_prefix(const std::string& value);
void set_snapshot_prefix(std::string&& value);
void set_snapshot_prefix(const char* value);
void set_snapshot_prefix(const char* value, size_t size);
std::string* mutable_snapshot_prefix();
std::string* release_snapshot_prefix();
void set_allocated_snapshot_prefix(std::string* snapshot_prefix);
private:
const std::string& _internal_snapshot_prefix() const;
void _internal_set_snapshot_prefix(const std::string& value);
std::string* _internal_mutable_snapshot_prefix();
public:
// optional string net = 24;
bool has_net() const;
private:
bool _internal_has_net() const;
public:
void clear_net();
const std::string& net() const;
void set_net(const std::string& value);
void set_net(std::string&& value);
void set_net(const char* value);
void set_net(const char* value, size_t size);
std::string* mutable_net();
std::string* release_net();
void set_allocated_net(std::string* net);
private:
const std::string& _internal_net() const;
void _internal_set_net(const std::string& value);
std::string* _internal_mutable_net();
public:
// optional string regularization_type = 29 [default = "L2"];
bool has_regularization_type() const;
private:
bool _internal_has_regularization_type() const;
public:
void clear_regularization_type();
const std::string& regularization_type() const;
void set_regularization_type(const std::string& value);
void set_regularization_type(std::string&& value);
void set_regularization_type(const char* value);
void set_regularization_type(const char* value, size_t size);
std::string* mutable_regularization_type();
std::string* release_regularization_type();
void set_allocated_regularization_type(std::string* regularization_type);
private:
const std::string& _internal_regularization_type() const;
void _internal_set_regularization_type(const std::string& value);
std::string* _internal_mutable_regularization_type();
public:
// optional string type = 40 [default = "SGD"];
bool has_type() const;
private:
bool _internal_has_type() const;
public:
void clear_type();
const std::string& type() const;
void set_type(const std::string& value);
void set_type(std::string&& value);
void set_type(const char* value);
void set_type(const char* value, size_t size);
std::string* mutable_type();
std::string* release_type();
void set_allocated_type(std::string* type);
private:
const std::string& _internal_type() const;
void _internal_set_type(const std::string& value);
std::string* _internal_mutable_type();
public:
// optional string eval_type = 41 [default = "classification"];
bool has_eval_type() const;
private:
bool _internal_has_eval_type() const;
public:
void clear_eval_type();
const std::string& eval_type() const;
void set_eval_type(const std::string& value);
void set_eval_type(std::string&& value);
void set_eval_type(const char* value);
void set_eval_type(const char* value, size_t size);
std::string* mutable_eval_type();
std::string* release_eval_type();
void set_allocated_eval_type(std::string* eval_type);
private:
const std::string& _internal_eval_type() const;
void _internal_set_eval_type(const std::string& value);
std::string* _internal_mutable_eval_type();
public:
// optional string ap_version = 42 [default = "Integral"];
bool has_ap_version() const;
private:
bool _internal_has_ap_version() const;
public:
void clear_ap_version();
const std::string& ap_version() const;
void set_ap_version(const std::string& value);
void set_ap_version(std::string&& value);
void set_ap_version(const char* value);
void set_ap_version(const char* value, size_t size);
std::string* mutable_ap_version();
std::string* release_ap_version();
void set_allocated_ap_version(std::string* ap_version);
private:
const std::string& _internal_ap_version() const;
void _internal_set_ap_version(const std::string& value);
std::string* _internal_mutable_ap_version();
public:
// optional .caffe.NetParameter train_net_param = 21;
bool has_train_net_param() const;
private:
bool _internal_has_train_net_param() const;
public:
void clear_train_net_param();
const ::caffe::NetParameter& train_net_param() const;
::caffe::NetParameter* release_train_net_param();
::caffe::NetParameter* mutable_train_net_param();
void set_allocated_train_net_param(::caffe::NetParameter* train_net_param);
private:
const ::caffe::NetParameter& _internal_train_net_param() const;
::caffe::NetParameter* _internal_mutable_train_net_param();
public:
void unsafe_arena_set_allocated_train_net_param(
::caffe::NetParameter* train_net_param);
::caffe::NetParameter* unsafe_arena_release_train_net_param();
// optional .caffe.NetParameter net_param = 25;
bool has_net_param() const;
private:
bool _internal_has_net_param() const;
public:
void clear_net_param();
const ::caffe::NetParameter& net_param() const;
::caffe::NetParameter* release_net_param();
::caffe::NetParameter* mutable_net_param();
void set_allocated_net_param(::caffe::NetParameter* net_param);
private:
const ::caffe::NetParameter& _internal_net_param() const;
::caffe::NetParameter* _internal_mutable_net_param();
public:
void unsafe_arena_set_allocated_net_param(
::caffe::NetParameter* net_param);
::caffe::NetParameter* unsafe_arena_release_net_param();
// optional .caffe.NetState train_state = 26;
bool has_train_state() const;
private:
bool _internal_has_train_state() const;
public:
void clear_train_state();
const ::caffe::NetState& train_state() const;
::caffe::NetState* release_train_state();
::caffe::NetState* mutable_train_state();
void set_allocated_train_state(::caffe::NetState* train_state);
private:
const ::caffe::NetState& _internal_train_state() const;
::caffe::NetState* _internal_mutable_train_state();
public:
void unsafe_arena_set_allocated_train_state(
::caffe::NetState* train_state);
::caffe::NetState* unsafe_arena_release_train_state();
// optional int32 test_interval = 4 [default = 0];
bool has_test_interval() const;
private:
bool _internal_has_test_interval() const;
public:
void clear_test_interval();
::PROTOBUF_NAMESPACE_ID::int32 test_interval() const;
void set_test_interval(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_test_interval() const;
void _internal_set_test_interval(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional float base_lr = 5;
bool has_base_lr() const;
private:
bool _internal_has_base_lr() const;
public:
void clear_base_lr();
float base_lr() const;
void set_base_lr(float value);
private:
float _internal_base_lr() const;
void _internal_set_base_lr(float value);
public:
// optional int32 display = 6;
bool has_display() const;
private:
bool _internal_has_display() const;
public:
void clear_display();
::PROTOBUF_NAMESPACE_ID::int32 display() const;
void set_display(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_display() const;
void _internal_set_display(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional int32 max_iter = 7;
bool has_max_iter() const;
private:
bool _internal_has_max_iter() const;
public:
void clear_max_iter();
::PROTOBUF_NAMESPACE_ID::int32 max_iter() const;
void set_max_iter(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_max_iter() const;
void _internal_set_max_iter(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional float gamma = 9;
bool has_gamma() const;
private:
bool _internal_has_gamma() const;
public:
void clear_gamma();
float gamma() const;
void set_gamma(float value);
private:
float _internal_gamma() const;
void _internal_set_gamma(float value);
public:
// optional float power = 10;
bool has_power() const;
private:
bool _internal_has_power() const;
public:
void clear_power();
float power() const;
void set_power(float value);
private:
float _internal_power() const;
void _internal_set_power(float value);
public:
// optional float momentum = 11;
bool has_momentum() const;
private:
bool _internal_has_momentum() const;
public:
void clear_momentum();
float momentum() const;
void set_momentum(float value);
private:
float _internal_momentum() const;
void _internal_set_momentum(float value);
public:
// optional float weight_decay = 12;
bool has_weight_decay() const;
private:
bool _internal_has_weight_decay() const;
public:
void clear_weight_decay();
float weight_decay() const;
void set_weight_decay(float value);
private:
float _internal_weight_decay() const;
void _internal_set_weight_decay(float value);
public:
// optional int32 stepsize = 13;
bool has_stepsize() const;
private:
bool _internal_has_stepsize() const;
public:
void clear_stepsize();
::PROTOBUF_NAMESPACE_ID::int32 stepsize() const;
void set_stepsize(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_stepsize() const;
void _internal_set_stepsize(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional int32 snapshot = 14 [default = 0];
bool has_snapshot() const;
private:
bool _internal_has_snapshot() const;
public:
void clear_snapshot();
::PROTOBUF_NAMESPACE_ID::int32 snapshot() const;
void set_snapshot(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_snapshot() const;
void _internal_set_snapshot(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional int32 device_id = 18 [default = 0];
bool has_device_id() const;
private:
bool _internal_has_device_id() const;
public:
void clear_device_id();
::PROTOBUF_NAMESPACE_ID::int32 device_id() const;
void set_device_id(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_device_id() const;
void _internal_set_device_id(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional bool test_compute_loss = 19 [default = false];
bool has_test_compute_loss() const;
private:
bool _internal_has_test_compute_loss() const;
public:
void clear_test_compute_loss();
bool test_compute_loss() const;
void set_test_compute_loss(bool value);
private:
bool _internal_test_compute_loss() const;
void _internal_set_test_compute_loss(bool value);
public:
// optional bool snapshot_diff = 16 [default = false];
bool has_snapshot_diff() const;
private:
bool _internal_has_snapshot_diff() const;
public:
void clear_snapshot_diff();
bool snapshot_diff() const;
void set_snapshot_diff(bool value);
private:
bool _internal_snapshot_diff() const;
void _internal_set_snapshot_diff(bool value);
public:
// optional bool debug_info = 23 [default = false];
bool has_debug_info() const;
private:
bool _internal_has_debug_info() const;
public:
void clear_debug_info();
bool debug_info() const;
void set_debug_info(bool value);
private:
bool _internal_debug_info() const;
void _internal_set_debug_info(bool value);
public:
// optional .caffe.SolverParameter.SolverType solver_type = 30 [default = SGD];
bool has_solver_type() const;
private:
bool _internal_has_solver_type() const;
public:
void clear_solver_type();
::caffe::SolverParameter_SolverType solver_type() const;
void set_solver_type(::caffe::SolverParameter_SolverType value);
private:
::caffe::SolverParameter_SolverType _internal_solver_type() const;
void _internal_set_solver_type(::caffe::SolverParameter_SolverType value);
public:
// optional float rms_decay = 38;
bool has_rms_decay() const;
private:
bool _internal_has_rms_decay() const;
public:
void clear_rms_decay();
float rms_decay() const;
void set_rms_decay(float value);
private:
float _internal_rms_decay() const;
void _internal_set_rms_decay(float value);
public:
// optional int64 random_seed = 20 [default = -1];
bool has_random_seed() const;
private:
bool _internal_has_random_seed() const;
public:
void clear_random_seed();
::PROTOBUF_NAMESPACE_ID::int64 random_seed() const;
void set_random_seed(::PROTOBUF_NAMESPACE_ID::int64 value);
private:
::PROTOBUF_NAMESPACE_ID::int64 _internal_random_seed() const;
void _internal_set_random_seed(::PROTOBUF_NAMESPACE_ID::int64 value);
public:
// optional .caffe.SolverParameter.SolverMode solver_mode = 17 [default = GPU];
bool has_solver_mode() const;
private:
bool _internal_has_solver_mode() const;
public:
void clear_solver_mode();
::caffe::SolverParameter_SolverMode solver_mode() const;
void set_solver_mode(::caffe::SolverParameter_SolverMode value);
private:
::caffe::SolverParameter_SolverMode _internal_solver_mode() const;
void _internal_set_solver_mode(::caffe::SolverParameter_SolverMode value);
public:
// optional bool test_initialization = 32 [default = true];
bool has_test_initialization() const;
private:
bool _internal_has_test_initialization() const;
public:
void clear_test_initialization();
bool test_initialization() const;
void set_test_initialization(bool value);
private:
bool _internal_test_initialization() const;
void _internal_set_test_initialization(bool value);
public:
// optional bool snapshot_after_train = 28 [default = true];
bool has_snapshot_after_train() const;
private:
bool _internal_has_snapshot_after_train() const;
public:
void clear_snapshot_after_train();
bool snapshot_after_train() const;
void set_snapshot_after_train(bool value);
private:
bool _internal_snapshot_after_train() const;
void _internal_set_snapshot_after_train(bool value);
public:
// optional float delta = 31 [default = 1e-08];
bool has_delta() const;
private:
bool _internal_has_delta() const;
public:
void clear_delta();
float delta() const;
void set_delta(float value);
private:
float _internal_delta() const;
void _internal_set_delta(float value);
public:
// optional int32 average_loss = 33 [default = 1];
bool has_average_loss() const;
private:
bool _internal_has_average_loss() const;
public:
void clear_average_loss();
::PROTOBUF_NAMESPACE_ID::int32 average_loss() const;
void set_average_loss(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_average_loss() const;
void _internal_set_average_loss(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional float clip_gradients = 35 [default = -1];
bool has_clip_gradients() const;
private:
bool _internal_has_clip_gradients() const;
public:
void clear_clip_gradients();
float clip_gradients() const;
void set_clip_gradients(float value);
private:
float _internal_clip_gradients() const;
void _internal_set_clip_gradients(float value);
public:
// optional int32 iter_size = 36 [default = 1];
bool has_iter_size() const;
private:
bool _internal_has_iter_size() const;
public:
void clear_iter_size();
::PROTOBUF_NAMESPACE_ID::int32 iter_size() const;
void set_iter_size(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_iter_size() const;
void _internal_set_iter_size(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional .caffe.SolverParameter.SnapshotFormat snapshot_format = 37 [default = BINARYPROTO];
bool has_snapshot_format() const;
private:
bool _internal_has_snapshot_format() const;
public:
void clear_snapshot_format();
::caffe::SolverParameter_SnapshotFormat snapshot_format() const;
void set_snapshot_format(::caffe::SolverParameter_SnapshotFormat value);
private:
::caffe::SolverParameter_SnapshotFormat _internal_snapshot_format() const;
void _internal_set_snapshot_format(::caffe::SolverParameter_SnapshotFormat value);
public:
// optional float momentum2 = 39 [default = 0.999];
bool has_momentum2() const;
private:
bool _internal_has_momentum2() const;
public:
void clear_momentum2();
float momentum2() const;
void set_momentum2(float value);
private:
float _internal_momentum2() const;
void _internal_set_momentum2(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.SolverParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<2> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string> test_net_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 > test_iter_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetParameter > test_net_param_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetState > test_state_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 > stepvalue_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr train_net_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr lr_policy_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr snapshot_prefix_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr net_;
public:
static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> _i_give_permission_to_break_this_code_default_regularization_type_;
private:
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr regularization_type_;
public:
static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> _i_give_permission_to_break_this_code_default_type_;
private:
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr type_;
public:
static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> _i_give_permission_to_break_this_code_default_eval_type_;
private:
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr eval_type_;
public:
static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> _i_give_permission_to_break_this_code_default_ap_version_;
private:
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr ap_version_;
::caffe::NetParameter* train_net_param_;
::caffe::NetParameter* net_param_;
::caffe::NetState* train_state_;
::PROTOBUF_NAMESPACE_ID::int32 test_interval_;
float base_lr_;
::PROTOBUF_NAMESPACE_ID::int32 display_;
::PROTOBUF_NAMESPACE_ID::int32 max_iter_;
float gamma_;
float power_;
float momentum_;
float weight_decay_;
::PROTOBUF_NAMESPACE_ID::int32 stepsize_;
::PROTOBUF_NAMESPACE_ID::int32 snapshot_;
::PROTOBUF_NAMESPACE_ID::int32 device_id_;
bool test_compute_loss_;
bool snapshot_diff_;
bool debug_info_;
int solver_type_;
float rms_decay_;
::PROTOBUF_NAMESPACE_ID::int64 random_seed_;
int solver_mode_;
bool test_initialization_;
bool snapshot_after_train_;
float delta_;
::PROTOBUF_NAMESPACE_ID::int32 average_loss_;
float clip_gradients_;
::PROTOBUF_NAMESPACE_ID::int32 iter_size_;
int snapshot_format_;
float momentum2_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class SolverState PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.SolverState) */ {
public:
inline SolverState() : SolverState(nullptr) {}
virtual ~SolverState();
SolverState(const SolverState& from);
SolverState(SolverState&& from) noexcept
: SolverState() {
*this = ::std::move(from);
}
inline SolverState& operator=(const SolverState& from) {
CopyFrom(from);
return *this;
}
inline SolverState& operator=(SolverState&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const SolverState& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const SolverState* internal_default_instance() {
return reinterpret_cast<const SolverState*>(
&_SolverState_default_instance_);
}
static constexpr int kIndexInFileMessages =
17;
friend void swap(SolverState& a, SolverState& b) {
a.Swap(&b);
}
inline void Swap(SolverState* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(SolverState* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline SolverState* New() const final {
return CreateMaybeMessage<SolverState>(nullptr);
}
SolverState* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<SolverState>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const SolverState& from);
void MergeFrom(const SolverState& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(SolverState* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.SolverState";
}
protected:
explicit SolverState(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kHistoryFieldNumber = 3,
kLearnedNetFieldNumber = 2,
kIterFieldNumber = 1,
kCurrentStepFieldNumber = 4,
};
// repeated .caffe.BlobProto history = 3;
int history_size() const;
private:
int _internal_history_size() const;
public:
void clear_history();
::caffe::BlobProto* mutable_history(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto >*
mutable_history();
private:
const ::caffe::BlobProto& _internal_history(int index) const;
::caffe::BlobProto* _internal_add_history();
public:
const ::caffe::BlobProto& history(int index) const;
::caffe::BlobProto* add_history();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto >&
history() const;
// optional string learned_net = 2;
bool has_learned_net() const;
private:
bool _internal_has_learned_net() const;
public:
void clear_learned_net();
const std::string& learned_net() const;
void set_learned_net(const std::string& value);
void set_learned_net(std::string&& value);
void set_learned_net(const char* value);
void set_learned_net(const char* value, size_t size);
std::string* mutable_learned_net();
std::string* release_learned_net();
void set_allocated_learned_net(std::string* learned_net);
private:
const std::string& _internal_learned_net() const;
void _internal_set_learned_net(const std::string& value);
std::string* _internal_mutable_learned_net();
public:
// optional int32 iter = 1;
bool has_iter() const;
private:
bool _internal_has_iter() const;
public:
void clear_iter();
::PROTOBUF_NAMESPACE_ID::int32 iter() const;
void set_iter(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_iter() const;
void _internal_set_iter(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional int32 current_step = 4 [default = 0];
bool has_current_step() const;
private:
bool _internal_has_current_step() const;
public:
void clear_current_step();
::PROTOBUF_NAMESPACE_ID::int32 current_step() const;
void set_current_step(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_current_step() const;
void _internal_set_current_step(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.SolverState)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto > history_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr learned_net_;
::PROTOBUF_NAMESPACE_ID::int32 iter_;
::PROTOBUF_NAMESPACE_ID::int32 current_step_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class NetState PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.NetState) */ {
public:
inline NetState() : NetState(nullptr) {}
virtual ~NetState();
NetState(const NetState& from);
NetState(NetState&& from) noexcept
: NetState() {
*this = ::std::move(from);
}
inline NetState& operator=(const NetState& from) {
CopyFrom(from);
return *this;
}
inline NetState& operator=(NetState&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const NetState& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const NetState* internal_default_instance() {
return reinterpret_cast<const NetState*>(
&_NetState_default_instance_);
}
static constexpr int kIndexInFileMessages =
18;
friend void swap(NetState& a, NetState& b) {
a.Swap(&b);
}
inline void Swap(NetState* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(NetState* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline NetState* New() const final {
return CreateMaybeMessage<NetState>(nullptr);
}
NetState* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<NetState>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const NetState& from);
void MergeFrom(const NetState& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(NetState* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.NetState";
}
protected:
explicit NetState(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kStageFieldNumber = 3,
kLevelFieldNumber = 2,
kPhaseFieldNumber = 1,
};
// repeated string stage = 3;
int stage_size() const;
private:
int _internal_stage_size() const;
public:
void clear_stage();
const std::string& stage(int index) const;
std::string* mutable_stage(int index);
void set_stage(int index, const std::string& value);
void set_stage(int index, std::string&& value);
void set_stage(int index, const char* value);
void set_stage(int index, const char* value, size_t size);
std::string* add_stage();
void add_stage(const std::string& value);
void add_stage(std::string&& value);
void add_stage(const char* value);
void add_stage(const char* value, size_t size);
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>& stage() const;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>* mutable_stage();
private:
const std::string& _internal_stage(int index) const;
std::string* _internal_add_stage();
public:
// optional int32 level = 2 [default = 0];
bool has_level() const;
private:
bool _internal_has_level() const;
public:
void clear_level();
::PROTOBUF_NAMESPACE_ID::int32 level() const;
void set_level(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_level() const;
void _internal_set_level(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional .caffe.Phase phase = 1 [default = TEST];
bool has_phase() const;
private:
bool _internal_has_phase() const;
public:
void clear_phase();
::caffe::Phase phase() const;
void set_phase(::caffe::Phase value);
private:
::caffe::Phase _internal_phase() const;
void _internal_set_phase(::caffe::Phase value);
public:
// @@protoc_insertion_point(class_scope:caffe.NetState)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string> stage_;
::PROTOBUF_NAMESPACE_ID::int32 level_;
int phase_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class NetStateRule PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.NetStateRule) */ {
public:
inline NetStateRule() : NetStateRule(nullptr) {}
virtual ~NetStateRule();
NetStateRule(const NetStateRule& from);
NetStateRule(NetStateRule&& from) noexcept
: NetStateRule() {
*this = ::std::move(from);
}
inline NetStateRule& operator=(const NetStateRule& from) {
CopyFrom(from);
return *this;
}
inline NetStateRule& operator=(NetStateRule&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const NetStateRule& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const NetStateRule* internal_default_instance() {
return reinterpret_cast<const NetStateRule*>(
&_NetStateRule_default_instance_);
}
static constexpr int kIndexInFileMessages =
19;
friend void swap(NetStateRule& a, NetStateRule& b) {
a.Swap(&b);
}
inline void Swap(NetStateRule* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(NetStateRule* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline NetStateRule* New() const final {
return CreateMaybeMessage<NetStateRule>(nullptr);
}
NetStateRule* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<NetStateRule>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const NetStateRule& from);
void MergeFrom(const NetStateRule& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(NetStateRule* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.NetStateRule";
}
protected:
explicit NetStateRule(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kStageFieldNumber = 4,
kNotStageFieldNumber = 5,
kPhaseFieldNumber = 1,
kMinLevelFieldNumber = 2,
kMaxLevelFieldNumber = 3,
};
// repeated string stage = 4;
int stage_size() const;
private:
int _internal_stage_size() const;
public:
void clear_stage();
const std::string& stage(int index) const;
std::string* mutable_stage(int index);
void set_stage(int index, const std::string& value);
void set_stage(int index, std::string&& value);
void set_stage(int index, const char* value);
void set_stage(int index, const char* value, size_t size);
std::string* add_stage();
void add_stage(const std::string& value);
void add_stage(std::string&& value);
void add_stage(const char* value);
void add_stage(const char* value, size_t size);
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>& stage() const;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>* mutable_stage();
private:
const std::string& _internal_stage(int index) const;
std::string* _internal_add_stage();
public:
// repeated string not_stage = 5;
int not_stage_size() const;
private:
int _internal_not_stage_size() const;
public:
void clear_not_stage();
const std::string& not_stage(int index) const;
std::string* mutable_not_stage(int index);
void set_not_stage(int index, const std::string& value);
void set_not_stage(int index, std::string&& value);
void set_not_stage(int index, const char* value);
void set_not_stage(int index, const char* value, size_t size);
std::string* add_not_stage();
void add_not_stage(const std::string& value);
void add_not_stage(std::string&& value);
void add_not_stage(const char* value);
void add_not_stage(const char* value, size_t size);
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>& not_stage() const;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>* mutable_not_stage();
private:
const std::string& _internal_not_stage(int index) const;
std::string* _internal_add_not_stage();
public:
// optional .caffe.Phase phase = 1;
bool has_phase() const;
private:
bool _internal_has_phase() const;
public:
void clear_phase();
::caffe::Phase phase() const;
void set_phase(::caffe::Phase value);
private:
::caffe::Phase _internal_phase() const;
void _internal_set_phase(::caffe::Phase value);
public:
// optional int32 min_level = 2;
bool has_min_level() const;
private:
bool _internal_has_min_level() const;
public:
void clear_min_level();
::PROTOBUF_NAMESPACE_ID::int32 min_level() const;
void set_min_level(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_min_level() const;
void _internal_set_min_level(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional int32 max_level = 3;
bool has_max_level() const;
private:
bool _internal_has_max_level() const;
public:
void clear_max_level();
::PROTOBUF_NAMESPACE_ID::int32 max_level() const;
void set_max_level(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_max_level() const;
void _internal_set_max_level(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.NetStateRule)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string> stage_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string> not_stage_;
int phase_;
::PROTOBUF_NAMESPACE_ID::int32 min_level_;
::PROTOBUF_NAMESPACE_ID::int32 max_level_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class ParamSpec PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.ParamSpec) */ {
public:
inline ParamSpec() : ParamSpec(nullptr) {}
virtual ~ParamSpec();
ParamSpec(const ParamSpec& from);
ParamSpec(ParamSpec&& from) noexcept
: ParamSpec() {
*this = ::std::move(from);
}
inline ParamSpec& operator=(const ParamSpec& from) {
CopyFrom(from);
return *this;
}
inline ParamSpec& operator=(ParamSpec&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const ParamSpec& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const ParamSpec* internal_default_instance() {
return reinterpret_cast<const ParamSpec*>(
&_ParamSpec_default_instance_);
}
static constexpr int kIndexInFileMessages =
20;
friend void swap(ParamSpec& a, ParamSpec& b) {
a.Swap(&b);
}
inline void Swap(ParamSpec* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(ParamSpec* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline ParamSpec* New() const final {
return CreateMaybeMessage<ParamSpec>(nullptr);
}
ParamSpec* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<ParamSpec>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const ParamSpec& from);
void MergeFrom(const ParamSpec& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(ParamSpec* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.ParamSpec";
}
protected:
explicit ParamSpec(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef ParamSpec_DimCheckMode DimCheckMode;
static constexpr DimCheckMode STRICT =
ParamSpec_DimCheckMode_STRICT;
static constexpr DimCheckMode PERMISSIVE =
ParamSpec_DimCheckMode_PERMISSIVE;
static inline bool DimCheckMode_IsValid(int value) {
return ParamSpec_DimCheckMode_IsValid(value);
}
static constexpr DimCheckMode DimCheckMode_MIN =
ParamSpec_DimCheckMode_DimCheckMode_MIN;
static constexpr DimCheckMode DimCheckMode_MAX =
ParamSpec_DimCheckMode_DimCheckMode_MAX;
static constexpr int DimCheckMode_ARRAYSIZE =
ParamSpec_DimCheckMode_DimCheckMode_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
DimCheckMode_descriptor() {
return ParamSpec_DimCheckMode_descriptor();
}
template<typename T>
static inline const std::string& DimCheckMode_Name(T enum_t_value) {
static_assert(::std::is_same<T, DimCheckMode>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function DimCheckMode_Name.");
return ParamSpec_DimCheckMode_Name(enum_t_value);
}
static inline bool DimCheckMode_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
DimCheckMode* value) {
return ParamSpec_DimCheckMode_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kNameFieldNumber = 1,
kShareModeFieldNumber = 2,
kLrMultFieldNumber = 3,
kDecayMultFieldNumber = 4,
};
// optional string name = 1;
bool has_name() const;
private:
bool _internal_has_name() const;
public:
void clear_name();
const std::string& name() const;
void set_name(const std::string& value);
void set_name(std::string&& value);
void set_name(const char* value);
void set_name(const char* value, size_t size);
std::string* mutable_name();
std::string* release_name();
void set_allocated_name(std::string* name);
private:
const std::string& _internal_name() const;
void _internal_set_name(const std::string& value);
std::string* _internal_mutable_name();
public:
// optional .caffe.ParamSpec.DimCheckMode share_mode = 2;
bool has_share_mode() const;
private:
bool _internal_has_share_mode() const;
public:
void clear_share_mode();
::caffe::ParamSpec_DimCheckMode share_mode() const;
void set_share_mode(::caffe::ParamSpec_DimCheckMode value);
private:
::caffe::ParamSpec_DimCheckMode _internal_share_mode() const;
void _internal_set_share_mode(::caffe::ParamSpec_DimCheckMode value);
public:
// optional float lr_mult = 3 [default = 1];
bool has_lr_mult() const;
private:
bool _internal_has_lr_mult() const;
public:
void clear_lr_mult();
float lr_mult() const;
void set_lr_mult(float value);
private:
float _internal_lr_mult() const;
void _internal_set_lr_mult(float value);
public:
// optional float decay_mult = 4 [default = 1];
bool has_decay_mult() const;
private:
bool _internal_has_decay_mult() const;
public:
void clear_decay_mult();
float decay_mult() const;
void set_decay_mult(float value);
private:
float _internal_decay_mult() const;
void _internal_set_decay_mult(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.ParamSpec)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr name_;
int share_mode_;
float lr_mult_;
float decay_mult_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class LayerParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.LayerParameter) */ {
public:
inline LayerParameter() : LayerParameter(nullptr) {}
virtual ~LayerParameter();
LayerParameter(const LayerParameter& from);
LayerParameter(LayerParameter&& from) noexcept
: LayerParameter() {
*this = ::std::move(from);
}
inline LayerParameter& operator=(const LayerParameter& from) {
CopyFrom(from);
return *this;
}
inline LayerParameter& operator=(LayerParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const LayerParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const LayerParameter* internal_default_instance() {
return reinterpret_cast<const LayerParameter*>(
&_LayerParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
21;
friend void swap(LayerParameter& a, LayerParameter& b) {
a.Swap(&b);
}
inline void Swap(LayerParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(LayerParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline LayerParameter* New() const final {
return CreateMaybeMessage<LayerParameter>(nullptr);
}
LayerParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<LayerParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const LayerParameter& from);
void MergeFrom(const LayerParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(LayerParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.LayerParameter";
}
protected:
explicit LayerParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kBottomFieldNumber = 3,
kTopFieldNumber = 4,
kLossWeightFieldNumber = 5,
kParamFieldNumber = 6,
kBlobsFieldNumber = 7,
kIncludeFieldNumber = 8,
kExcludeFieldNumber = 9,
kPropagateDownFieldNumber = 11,
kNameFieldNumber = 1,
kTypeFieldNumber = 2,
kTransformParamFieldNumber = 100,
kLossParamFieldNumber = 101,
kAccuracyParamFieldNumber = 102,
kArgmaxParamFieldNumber = 103,
kConcatParamFieldNumber = 104,
kContrastiveLossParamFieldNumber = 105,
kConvolutionParamFieldNumber = 106,
kDataParamFieldNumber = 107,
kDropoutParamFieldNumber = 108,
kDummyDataParamFieldNumber = 109,
kEltwiseParamFieldNumber = 110,
kExpParamFieldNumber = 111,
kHdf5DataParamFieldNumber = 112,
kHdf5OutputParamFieldNumber = 113,
kHingeLossParamFieldNumber = 114,
kImageDataParamFieldNumber = 115,
kInfogainLossParamFieldNumber = 116,
kInnerProductParamFieldNumber = 117,
kLrnParamFieldNumber = 118,
kMemoryDataParamFieldNumber = 119,
kMvnParamFieldNumber = 120,
kPoolingParamFieldNumber = 121,
kPowerParamFieldNumber = 122,
kReluParamFieldNumber = 123,
kSigmoidParamFieldNumber = 124,
kSoftmaxParamFieldNumber = 125,
kSliceParamFieldNumber = 126,
kTanhParamFieldNumber = 127,
kThresholdParamFieldNumber = 128,
kWindowDataParamFieldNumber = 129,
kPythonParamFieldNumber = 130,
kPreluParamFieldNumber = 131,
kSppParamFieldNumber = 132,
kReshapeParamFieldNumber = 133,
kLogParamFieldNumber = 134,
kFlattenParamFieldNumber = 135,
kReductionParamFieldNumber = 136,
kEmbedParamFieldNumber = 137,
kTileParamFieldNumber = 138,
kBatchNormParamFieldNumber = 139,
kEluParamFieldNumber = 140,
kBiasParamFieldNumber = 141,
kScaleParamFieldNumber = 142,
kInputParamFieldNumber = 143,
kCropParamFieldNumber = 144,
kParameterParamFieldNumber = 145,
kRecurrentParamFieldNumber = 146,
kRoiPoolingParamFieldNumber = 147,
kSmoothL1LossParamFieldNumber = 148,
kFaceDataParamFieldNumber = 150,
kUpsampleParamFieldNumber = 151,
kConnectParamFieldNumber = 152,
kAnnotatedDataParamFieldNumber = 200,
kMultiboxLossParamFieldNumber = 201,
kPermuteParamFieldNumber = 202,
kPriorBoxParamFieldNumber = 203,
kDetectionOutputParamFieldNumber = 204,
kDetectionEvaluateParamFieldNumber = 205,
kNormParamFieldNumber = 206,
kVideoDataParamFieldNumber = 207,
kMilDataParamFieldNumber = 5065028,
kMilParamFieldNumber = 5065036,
kPhaseFieldNumber = 10,
};
// repeated string bottom = 3;
int bottom_size() const;
private:
int _internal_bottom_size() const;
public:
void clear_bottom();
const std::string& bottom(int index) const;
std::string* mutable_bottom(int index);
void set_bottom(int index, const std::string& value);
void set_bottom(int index, std::string&& value);
void set_bottom(int index, const char* value);
void set_bottom(int index, const char* value, size_t size);
std::string* add_bottom();
void add_bottom(const std::string& value);
void add_bottom(std::string&& value);
void add_bottom(const char* value);
void add_bottom(const char* value, size_t size);
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>& bottom() const;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>* mutable_bottom();
private:
const std::string& _internal_bottom(int index) const;
std::string* _internal_add_bottom();
public:
// repeated string top = 4;
int top_size() const;
private:
int _internal_top_size() const;
public:
void clear_top();
const std::string& top(int index) const;
std::string* mutable_top(int index);
void set_top(int index, const std::string& value);
void set_top(int index, std::string&& value);
void set_top(int index, const char* value);
void set_top(int index, const char* value, size_t size);
std::string* add_top();
void add_top(const std::string& value);
void add_top(std::string&& value);
void add_top(const char* value);
void add_top(const char* value, size_t size);
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>& top() const;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>* mutable_top();
private:
const std::string& _internal_top(int index) const;
std::string* _internal_add_top();
public:
// repeated float loss_weight = 5;
int loss_weight_size() const;
private:
int _internal_loss_weight_size() const;
public:
void clear_loss_weight();
private:
float _internal_loss_weight(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
_internal_loss_weight() const;
void _internal_add_loss_weight(float value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
_internal_mutable_loss_weight();
public:
float loss_weight(int index) const;
void set_loss_weight(int index, float value);
void add_loss_weight(float value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
loss_weight() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
mutable_loss_weight();
// repeated .caffe.ParamSpec param = 6;
int param_size() const;
private:
int _internal_param_size() const;
public:
void clear_param();
::caffe::ParamSpec* mutable_param(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::ParamSpec >*
mutable_param();
private:
const ::caffe::ParamSpec& _internal_param(int index) const;
::caffe::ParamSpec* _internal_add_param();
public:
const ::caffe::ParamSpec& param(int index) const;
::caffe::ParamSpec* add_param();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::ParamSpec >&
param() const;
// repeated .caffe.BlobProto blobs = 7;
int blobs_size() const;
private:
int _internal_blobs_size() const;
public:
void clear_blobs();
::caffe::BlobProto* mutable_blobs(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto >*
mutable_blobs();
private:
const ::caffe::BlobProto& _internal_blobs(int index) const;
::caffe::BlobProto* _internal_add_blobs();
public:
const ::caffe::BlobProto& blobs(int index) const;
::caffe::BlobProto* add_blobs();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto >&
blobs() const;
// repeated .caffe.NetStateRule include = 8;
int include_size() const;
private:
int _internal_include_size() const;
public:
void clear_include();
::caffe::NetStateRule* mutable_include(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetStateRule >*
mutable_include();
private:
const ::caffe::NetStateRule& _internal_include(int index) const;
::caffe::NetStateRule* _internal_add_include();
public:
const ::caffe::NetStateRule& include(int index) const;
::caffe::NetStateRule* add_include();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetStateRule >&
include() const;
// repeated .caffe.NetStateRule exclude = 9;
int exclude_size() const;
private:
int _internal_exclude_size() const;
public:
void clear_exclude();
::caffe::NetStateRule* mutable_exclude(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetStateRule >*
mutable_exclude();
private:
const ::caffe::NetStateRule& _internal_exclude(int index) const;
::caffe::NetStateRule* _internal_add_exclude();
public:
const ::caffe::NetStateRule& exclude(int index) const;
::caffe::NetStateRule* add_exclude();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetStateRule >&
exclude() const;
// repeated bool propagate_down = 11;
int propagate_down_size() const;
private:
int _internal_propagate_down_size() const;
public:
void clear_propagate_down();
private:
bool _internal_propagate_down(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< bool >&
_internal_propagate_down() const;
void _internal_add_propagate_down(bool value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< bool >*
_internal_mutable_propagate_down();
public:
bool propagate_down(int index) const;
void set_propagate_down(int index, bool value);
void add_propagate_down(bool value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< bool >&
propagate_down() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< bool >*
mutable_propagate_down();
// optional string name = 1;
bool has_name() const;
private:
bool _internal_has_name() const;
public:
void clear_name();
const std::string& name() const;
void set_name(const std::string& value);
void set_name(std::string&& value);
void set_name(const char* value);
void set_name(const char* value, size_t size);
std::string* mutable_name();
std::string* release_name();
void set_allocated_name(std::string* name);
private:
const std::string& _internal_name() const;
void _internal_set_name(const std::string& value);
std::string* _internal_mutable_name();
public:
// optional string type = 2;
bool has_type() const;
private:
bool _internal_has_type() const;
public:
void clear_type();
const std::string& type() const;
void set_type(const std::string& value);
void set_type(std::string&& value);
void set_type(const char* value);
void set_type(const char* value, size_t size);
std::string* mutable_type();
std::string* release_type();
void set_allocated_type(std::string* type);
private:
const std::string& _internal_type() const;
void _internal_set_type(const std::string& value);
std::string* _internal_mutable_type();
public:
// optional .caffe.TransformationParameter transform_param = 100;
bool has_transform_param() const;
private:
bool _internal_has_transform_param() const;
public:
void clear_transform_param();
const ::caffe::TransformationParameter& transform_param() const;
::caffe::TransformationParameter* release_transform_param();
::caffe::TransformationParameter* mutable_transform_param();
void set_allocated_transform_param(::caffe::TransformationParameter* transform_param);
private:
const ::caffe::TransformationParameter& _internal_transform_param() const;
::caffe::TransformationParameter* _internal_mutable_transform_param();
public:
void unsafe_arena_set_allocated_transform_param(
::caffe::TransformationParameter* transform_param);
::caffe::TransformationParameter* unsafe_arena_release_transform_param();
// optional .caffe.LossParameter loss_param = 101;
bool has_loss_param() const;
private:
bool _internal_has_loss_param() const;
public:
void clear_loss_param();
const ::caffe::LossParameter& loss_param() const;
::caffe::LossParameter* release_loss_param();
::caffe::LossParameter* mutable_loss_param();
void set_allocated_loss_param(::caffe::LossParameter* loss_param);
private:
const ::caffe::LossParameter& _internal_loss_param() const;
::caffe::LossParameter* _internal_mutable_loss_param();
public:
void unsafe_arena_set_allocated_loss_param(
::caffe::LossParameter* loss_param);
::caffe::LossParameter* unsafe_arena_release_loss_param();
// optional .caffe.AccuracyParameter accuracy_param = 102;
bool has_accuracy_param() const;
private:
bool _internal_has_accuracy_param() const;
public:
void clear_accuracy_param();
const ::caffe::AccuracyParameter& accuracy_param() const;
::caffe::AccuracyParameter* release_accuracy_param();
::caffe::AccuracyParameter* mutable_accuracy_param();
void set_allocated_accuracy_param(::caffe::AccuracyParameter* accuracy_param);
private:
const ::caffe::AccuracyParameter& _internal_accuracy_param() const;
::caffe::AccuracyParameter* _internal_mutable_accuracy_param();
public:
void unsafe_arena_set_allocated_accuracy_param(
::caffe::AccuracyParameter* accuracy_param);
::caffe::AccuracyParameter* unsafe_arena_release_accuracy_param();
// optional .caffe.ArgMaxParameter argmax_param = 103;
bool has_argmax_param() const;
private:
bool _internal_has_argmax_param() const;
public:
void clear_argmax_param();
const ::caffe::ArgMaxParameter& argmax_param() const;
::caffe::ArgMaxParameter* release_argmax_param();
::caffe::ArgMaxParameter* mutable_argmax_param();
void set_allocated_argmax_param(::caffe::ArgMaxParameter* argmax_param);
private:
const ::caffe::ArgMaxParameter& _internal_argmax_param() const;
::caffe::ArgMaxParameter* _internal_mutable_argmax_param();
public:
void unsafe_arena_set_allocated_argmax_param(
::caffe::ArgMaxParameter* argmax_param);
::caffe::ArgMaxParameter* unsafe_arena_release_argmax_param();
// optional .caffe.ConcatParameter concat_param = 104;
bool has_concat_param() const;
private:
bool _internal_has_concat_param() const;
public:
void clear_concat_param();
const ::caffe::ConcatParameter& concat_param() const;
::caffe::ConcatParameter* release_concat_param();
::caffe::ConcatParameter* mutable_concat_param();
void set_allocated_concat_param(::caffe::ConcatParameter* concat_param);
private:
const ::caffe::ConcatParameter& _internal_concat_param() const;
::caffe::ConcatParameter* _internal_mutable_concat_param();
public:
void unsafe_arena_set_allocated_concat_param(
::caffe::ConcatParameter* concat_param);
::caffe::ConcatParameter* unsafe_arena_release_concat_param();
// optional .caffe.ContrastiveLossParameter contrastive_loss_param = 105;
bool has_contrastive_loss_param() const;
private:
bool _internal_has_contrastive_loss_param() const;
public:
void clear_contrastive_loss_param();
const ::caffe::ContrastiveLossParameter& contrastive_loss_param() const;
::caffe::ContrastiveLossParameter* release_contrastive_loss_param();
::caffe::ContrastiveLossParameter* mutable_contrastive_loss_param();
void set_allocated_contrastive_loss_param(::caffe::ContrastiveLossParameter* contrastive_loss_param);
private:
const ::caffe::ContrastiveLossParameter& _internal_contrastive_loss_param() const;
::caffe::ContrastiveLossParameter* _internal_mutable_contrastive_loss_param();
public:
void unsafe_arena_set_allocated_contrastive_loss_param(
::caffe::ContrastiveLossParameter* contrastive_loss_param);
::caffe::ContrastiveLossParameter* unsafe_arena_release_contrastive_loss_param();
// optional .caffe.ConvolutionParameter convolution_param = 106;
bool has_convolution_param() const;
private:
bool _internal_has_convolution_param() const;
public:
void clear_convolution_param();
const ::caffe::ConvolutionParameter& convolution_param() const;
::caffe::ConvolutionParameter* release_convolution_param();
::caffe::ConvolutionParameter* mutable_convolution_param();
void set_allocated_convolution_param(::caffe::ConvolutionParameter* convolution_param);
private:
const ::caffe::ConvolutionParameter& _internal_convolution_param() const;
::caffe::ConvolutionParameter* _internal_mutable_convolution_param();
public:
void unsafe_arena_set_allocated_convolution_param(
::caffe::ConvolutionParameter* convolution_param);
::caffe::ConvolutionParameter* unsafe_arena_release_convolution_param();
// optional .caffe.DataParameter data_param = 107;
bool has_data_param() const;
private:
bool _internal_has_data_param() const;
public:
void clear_data_param();
const ::caffe::DataParameter& data_param() const;
::caffe::DataParameter* release_data_param();
::caffe::DataParameter* mutable_data_param();
void set_allocated_data_param(::caffe::DataParameter* data_param);
private:
const ::caffe::DataParameter& _internal_data_param() const;
::caffe::DataParameter* _internal_mutable_data_param();
public:
void unsafe_arena_set_allocated_data_param(
::caffe::DataParameter* data_param);
::caffe::DataParameter* unsafe_arena_release_data_param();
// optional .caffe.DropoutParameter dropout_param = 108;
bool has_dropout_param() const;
private:
bool _internal_has_dropout_param() const;
public:
void clear_dropout_param();
const ::caffe::DropoutParameter& dropout_param() const;
::caffe::DropoutParameter* release_dropout_param();
::caffe::DropoutParameter* mutable_dropout_param();
void set_allocated_dropout_param(::caffe::DropoutParameter* dropout_param);
private:
const ::caffe::DropoutParameter& _internal_dropout_param() const;
::caffe::DropoutParameter* _internal_mutable_dropout_param();
public:
void unsafe_arena_set_allocated_dropout_param(
::caffe::DropoutParameter* dropout_param);
::caffe::DropoutParameter* unsafe_arena_release_dropout_param();
// optional .caffe.DummyDataParameter dummy_data_param = 109;
bool has_dummy_data_param() const;
private:
bool _internal_has_dummy_data_param() const;
public:
void clear_dummy_data_param();
const ::caffe::DummyDataParameter& dummy_data_param() const;
::caffe::DummyDataParameter* release_dummy_data_param();
::caffe::DummyDataParameter* mutable_dummy_data_param();
void set_allocated_dummy_data_param(::caffe::DummyDataParameter* dummy_data_param);
private:
const ::caffe::DummyDataParameter& _internal_dummy_data_param() const;
::caffe::DummyDataParameter* _internal_mutable_dummy_data_param();
public:
void unsafe_arena_set_allocated_dummy_data_param(
::caffe::DummyDataParameter* dummy_data_param);
::caffe::DummyDataParameter* unsafe_arena_release_dummy_data_param();
// optional .caffe.EltwiseParameter eltwise_param = 110;
bool has_eltwise_param() const;
private:
bool _internal_has_eltwise_param() const;
public:
void clear_eltwise_param();
const ::caffe::EltwiseParameter& eltwise_param() const;
::caffe::EltwiseParameter* release_eltwise_param();
::caffe::EltwiseParameter* mutable_eltwise_param();
void set_allocated_eltwise_param(::caffe::EltwiseParameter* eltwise_param);
private:
const ::caffe::EltwiseParameter& _internal_eltwise_param() const;
::caffe::EltwiseParameter* _internal_mutable_eltwise_param();
public:
void unsafe_arena_set_allocated_eltwise_param(
::caffe::EltwiseParameter* eltwise_param);
::caffe::EltwiseParameter* unsafe_arena_release_eltwise_param();
// optional .caffe.ExpParameter exp_param = 111;
bool has_exp_param() const;
private:
bool _internal_has_exp_param() const;
public:
void clear_exp_param();
const ::caffe::ExpParameter& exp_param() const;
::caffe::ExpParameter* release_exp_param();
::caffe::ExpParameter* mutable_exp_param();
void set_allocated_exp_param(::caffe::ExpParameter* exp_param);
private:
const ::caffe::ExpParameter& _internal_exp_param() const;
::caffe::ExpParameter* _internal_mutable_exp_param();
public:
void unsafe_arena_set_allocated_exp_param(
::caffe::ExpParameter* exp_param);
::caffe::ExpParameter* unsafe_arena_release_exp_param();
// optional .caffe.HDF5DataParameter hdf5_data_param = 112;
bool has_hdf5_data_param() const;
private:
bool _internal_has_hdf5_data_param() const;
public:
void clear_hdf5_data_param();
const ::caffe::HDF5DataParameter& hdf5_data_param() const;
::caffe::HDF5DataParameter* release_hdf5_data_param();
::caffe::HDF5DataParameter* mutable_hdf5_data_param();
void set_allocated_hdf5_data_param(::caffe::HDF5DataParameter* hdf5_data_param);
private:
const ::caffe::HDF5DataParameter& _internal_hdf5_data_param() const;
::caffe::HDF5DataParameter* _internal_mutable_hdf5_data_param();
public:
void unsafe_arena_set_allocated_hdf5_data_param(
::caffe::HDF5DataParameter* hdf5_data_param);
::caffe::HDF5DataParameter* unsafe_arena_release_hdf5_data_param();
// optional .caffe.HDF5OutputParameter hdf5_output_param = 113;
bool has_hdf5_output_param() const;
private:
bool _internal_has_hdf5_output_param() const;
public:
void clear_hdf5_output_param();
const ::caffe::HDF5OutputParameter& hdf5_output_param() const;
::caffe::HDF5OutputParameter* release_hdf5_output_param();
::caffe::HDF5OutputParameter* mutable_hdf5_output_param();
void set_allocated_hdf5_output_param(::caffe::HDF5OutputParameter* hdf5_output_param);
private:
const ::caffe::HDF5OutputParameter& _internal_hdf5_output_param() const;
::caffe::HDF5OutputParameter* _internal_mutable_hdf5_output_param();
public:
void unsafe_arena_set_allocated_hdf5_output_param(
::caffe::HDF5OutputParameter* hdf5_output_param);
::caffe::HDF5OutputParameter* unsafe_arena_release_hdf5_output_param();
// optional .caffe.HingeLossParameter hinge_loss_param = 114;
bool has_hinge_loss_param() const;
private:
bool _internal_has_hinge_loss_param() const;
public:
void clear_hinge_loss_param();
const ::caffe::HingeLossParameter& hinge_loss_param() const;
::caffe::HingeLossParameter* release_hinge_loss_param();
::caffe::HingeLossParameter* mutable_hinge_loss_param();
void set_allocated_hinge_loss_param(::caffe::HingeLossParameter* hinge_loss_param);
private:
const ::caffe::HingeLossParameter& _internal_hinge_loss_param() const;
::caffe::HingeLossParameter* _internal_mutable_hinge_loss_param();
public:
void unsafe_arena_set_allocated_hinge_loss_param(
::caffe::HingeLossParameter* hinge_loss_param);
::caffe::HingeLossParameter* unsafe_arena_release_hinge_loss_param();
// optional .caffe.ImageDataParameter image_data_param = 115;
bool has_image_data_param() const;
private:
bool _internal_has_image_data_param() const;
public:
void clear_image_data_param();
const ::caffe::ImageDataParameter& image_data_param() const;
::caffe::ImageDataParameter* release_image_data_param();
::caffe::ImageDataParameter* mutable_image_data_param();
void set_allocated_image_data_param(::caffe::ImageDataParameter* image_data_param);
private:
const ::caffe::ImageDataParameter& _internal_image_data_param() const;
::caffe::ImageDataParameter* _internal_mutable_image_data_param();
public:
void unsafe_arena_set_allocated_image_data_param(
::caffe::ImageDataParameter* image_data_param);
::caffe::ImageDataParameter* unsafe_arena_release_image_data_param();
// optional .caffe.InfogainLossParameter infogain_loss_param = 116;
bool has_infogain_loss_param() const;
private:
bool _internal_has_infogain_loss_param() const;
public:
void clear_infogain_loss_param();
const ::caffe::InfogainLossParameter& infogain_loss_param() const;
::caffe::InfogainLossParameter* release_infogain_loss_param();
::caffe::InfogainLossParameter* mutable_infogain_loss_param();
void set_allocated_infogain_loss_param(::caffe::InfogainLossParameter* infogain_loss_param);
private:
const ::caffe::InfogainLossParameter& _internal_infogain_loss_param() const;
::caffe::InfogainLossParameter* _internal_mutable_infogain_loss_param();
public:
void unsafe_arena_set_allocated_infogain_loss_param(
::caffe::InfogainLossParameter* infogain_loss_param);
::caffe::InfogainLossParameter* unsafe_arena_release_infogain_loss_param();
// optional .caffe.InnerProductParameter inner_product_param = 117;
bool has_inner_product_param() const;
private:
bool _internal_has_inner_product_param() const;
public:
void clear_inner_product_param();
const ::caffe::InnerProductParameter& inner_product_param() const;
::caffe::InnerProductParameter* release_inner_product_param();
::caffe::InnerProductParameter* mutable_inner_product_param();
void set_allocated_inner_product_param(::caffe::InnerProductParameter* inner_product_param);
private:
const ::caffe::InnerProductParameter& _internal_inner_product_param() const;
::caffe::InnerProductParameter* _internal_mutable_inner_product_param();
public:
void unsafe_arena_set_allocated_inner_product_param(
::caffe::InnerProductParameter* inner_product_param);
::caffe::InnerProductParameter* unsafe_arena_release_inner_product_param();
// optional .caffe.LRNParameter lrn_param = 118;
bool has_lrn_param() const;
private:
bool _internal_has_lrn_param() const;
public:
void clear_lrn_param();
const ::caffe::LRNParameter& lrn_param() const;
::caffe::LRNParameter* release_lrn_param();
::caffe::LRNParameter* mutable_lrn_param();
void set_allocated_lrn_param(::caffe::LRNParameter* lrn_param);
private:
const ::caffe::LRNParameter& _internal_lrn_param() const;
::caffe::LRNParameter* _internal_mutable_lrn_param();
public:
void unsafe_arena_set_allocated_lrn_param(
::caffe::LRNParameter* lrn_param);
::caffe::LRNParameter* unsafe_arena_release_lrn_param();
// optional .caffe.MemoryDataParameter memory_data_param = 119;
bool has_memory_data_param() const;
private:
bool _internal_has_memory_data_param() const;
public:
void clear_memory_data_param();
const ::caffe::MemoryDataParameter& memory_data_param() const;
::caffe::MemoryDataParameter* release_memory_data_param();
::caffe::MemoryDataParameter* mutable_memory_data_param();
void set_allocated_memory_data_param(::caffe::MemoryDataParameter* memory_data_param);
private:
const ::caffe::MemoryDataParameter& _internal_memory_data_param() const;
::caffe::MemoryDataParameter* _internal_mutable_memory_data_param();
public:
void unsafe_arena_set_allocated_memory_data_param(
::caffe::MemoryDataParameter* memory_data_param);
::caffe::MemoryDataParameter* unsafe_arena_release_memory_data_param();
// optional .caffe.MVNParameter mvn_param = 120;
bool has_mvn_param() const;
private:
bool _internal_has_mvn_param() const;
public:
void clear_mvn_param();
const ::caffe::MVNParameter& mvn_param() const;
::caffe::MVNParameter* release_mvn_param();
::caffe::MVNParameter* mutable_mvn_param();
void set_allocated_mvn_param(::caffe::MVNParameter* mvn_param);
private:
const ::caffe::MVNParameter& _internal_mvn_param() const;
::caffe::MVNParameter* _internal_mutable_mvn_param();
public:
void unsafe_arena_set_allocated_mvn_param(
::caffe::MVNParameter* mvn_param);
::caffe::MVNParameter* unsafe_arena_release_mvn_param();
// optional .caffe.PoolingParameter pooling_param = 121;
bool has_pooling_param() const;
private:
bool _internal_has_pooling_param() const;
public:
void clear_pooling_param();
const ::caffe::PoolingParameter& pooling_param() const;
::caffe::PoolingParameter* release_pooling_param();
::caffe::PoolingParameter* mutable_pooling_param();
void set_allocated_pooling_param(::caffe::PoolingParameter* pooling_param);
private:
const ::caffe::PoolingParameter& _internal_pooling_param() const;
::caffe::PoolingParameter* _internal_mutable_pooling_param();
public:
void unsafe_arena_set_allocated_pooling_param(
::caffe::PoolingParameter* pooling_param);
::caffe::PoolingParameter* unsafe_arena_release_pooling_param();
// optional .caffe.PowerParameter power_param = 122;
bool has_power_param() const;
private:
bool _internal_has_power_param() const;
public:
void clear_power_param();
const ::caffe::PowerParameter& power_param() const;
::caffe::PowerParameter* release_power_param();
::caffe::PowerParameter* mutable_power_param();
void set_allocated_power_param(::caffe::PowerParameter* power_param);
private:
const ::caffe::PowerParameter& _internal_power_param() const;
::caffe::PowerParameter* _internal_mutable_power_param();
public:
void unsafe_arena_set_allocated_power_param(
::caffe::PowerParameter* power_param);
::caffe::PowerParameter* unsafe_arena_release_power_param();
// optional .caffe.ReLUParameter relu_param = 123;
bool has_relu_param() const;
private:
bool _internal_has_relu_param() const;
public:
void clear_relu_param();
const ::caffe::ReLUParameter& relu_param() const;
::caffe::ReLUParameter* release_relu_param();
::caffe::ReLUParameter* mutable_relu_param();
void set_allocated_relu_param(::caffe::ReLUParameter* relu_param);
private:
const ::caffe::ReLUParameter& _internal_relu_param() const;
::caffe::ReLUParameter* _internal_mutable_relu_param();
public:
void unsafe_arena_set_allocated_relu_param(
::caffe::ReLUParameter* relu_param);
::caffe::ReLUParameter* unsafe_arena_release_relu_param();
// optional .caffe.SigmoidParameter sigmoid_param = 124;
bool has_sigmoid_param() const;
private:
bool _internal_has_sigmoid_param() const;
public:
void clear_sigmoid_param();
const ::caffe::SigmoidParameter& sigmoid_param() const;
::caffe::SigmoidParameter* release_sigmoid_param();
::caffe::SigmoidParameter* mutable_sigmoid_param();
void set_allocated_sigmoid_param(::caffe::SigmoidParameter* sigmoid_param);
private:
const ::caffe::SigmoidParameter& _internal_sigmoid_param() const;
::caffe::SigmoidParameter* _internal_mutable_sigmoid_param();
public:
void unsafe_arena_set_allocated_sigmoid_param(
::caffe::SigmoidParameter* sigmoid_param);
::caffe::SigmoidParameter* unsafe_arena_release_sigmoid_param();
// optional .caffe.SoftmaxParameter softmax_param = 125;
bool has_softmax_param() const;
private:
bool _internal_has_softmax_param() const;
public:
void clear_softmax_param();
const ::caffe::SoftmaxParameter& softmax_param() const;
::caffe::SoftmaxParameter* release_softmax_param();
::caffe::SoftmaxParameter* mutable_softmax_param();
void set_allocated_softmax_param(::caffe::SoftmaxParameter* softmax_param);
private:
const ::caffe::SoftmaxParameter& _internal_softmax_param() const;
::caffe::SoftmaxParameter* _internal_mutable_softmax_param();
public:
void unsafe_arena_set_allocated_softmax_param(
::caffe::SoftmaxParameter* softmax_param);
::caffe::SoftmaxParameter* unsafe_arena_release_softmax_param();
// optional .caffe.SliceParameter slice_param = 126;
bool has_slice_param() const;
private:
bool _internal_has_slice_param() const;
public:
void clear_slice_param();
const ::caffe::SliceParameter& slice_param() const;
::caffe::SliceParameter* release_slice_param();
::caffe::SliceParameter* mutable_slice_param();
void set_allocated_slice_param(::caffe::SliceParameter* slice_param);
private:
const ::caffe::SliceParameter& _internal_slice_param() const;
::caffe::SliceParameter* _internal_mutable_slice_param();
public:
void unsafe_arena_set_allocated_slice_param(
::caffe::SliceParameter* slice_param);
::caffe::SliceParameter* unsafe_arena_release_slice_param();
// optional .caffe.TanHParameter tanh_param = 127;
bool has_tanh_param() const;
private:
bool _internal_has_tanh_param() const;
public:
void clear_tanh_param();
const ::caffe::TanHParameter& tanh_param() const;
::caffe::TanHParameter* release_tanh_param();
::caffe::TanHParameter* mutable_tanh_param();
void set_allocated_tanh_param(::caffe::TanHParameter* tanh_param);
private:
const ::caffe::TanHParameter& _internal_tanh_param() const;
::caffe::TanHParameter* _internal_mutable_tanh_param();
public:
void unsafe_arena_set_allocated_tanh_param(
::caffe::TanHParameter* tanh_param);
::caffe::TanHParameter* unsafe_arena_release_tanh_param();
// optional .caffe.ThresholdParameter threshold_param = 128;
bool has_threshold_param() const;
private:
bool _internal_has_threshold_param() const;
public:
void clear_threshold_param();
const ::caffe::ThresholdParameter& threshold_param() const;
::caffe::ThresholdParameter* release_threshold_param();
::caffe::ThresholdParameter* mutable_threshold_param();
void set_allocated_threshold_param(::caffe::ThresholdParameter* threshold_param);
private:
const ::caffe::ThresholdParameter& _internal_threshold_param() const;
::caffe::ThresholdParameter* _internal_mutable_threshold_param();
public:
void unsafe_arena_set_allocated_threshold_param(
::caffe::ThresholdParameter* threshold_param);
::caffe::ThresholdParameter* unsafe_arena_release_threshold_param();
// optional .caffe.WindowDataParameter window_data_param = 129;
bool has_window_data_param() const;
private:
bool _internal_has_window_data_param() const;
public:
void clear_window_data_param();
const ::caffe::WindowDataParameter& window_data_param() const;
::caffe::WindowDataParameter* release_window_data_param();
::caffe::WindowDataParameter* mutable_window_data_param();
void set_allocated_window_data_param(::caffe::WindowDataParameter* window_data_param);
private:
const ::caffe::WindowDataParameter& _internal_window_data_param() const;
::caffe::WindowDataParameter* _internal_mutable_window_data_param();
public:
void unsafe_arena_set_allocated_window_data_param(
::caffe::WindowDataParameter* window_data_param);
::caffe::WindowDataParameter* unsafe_arena_release_window_data_param();
// optional .caffe.PythonParameter python_param = 130;
bool has_python_param() const;
private:
bool _internal_has_python_param() const;
public:
void clear_python_param();
const ::caffe::PythonParameter& python_param() const;
::caffe::PythonParameter* release_python_param();
::caffe::PythonParameter* mutable_python_param();
void set_allocated_python_param(::caffe::PythonParameter* python_param);
private:
const ::caffe::PythonParameter& _internal_python_param() const;
::caffe::PythonParameter* _internal_mutable_python_param();
public:
void unsafe_arena_set_allocated_python_param(
::caffe::PythonParameter* python_param);
::caffe::PythonParameter* unsafe_arena_release_python_param();
// optional .caffe.PReLUParameter prelu_param = 131;
bool has_prelu_param() const;
private:
bool _internal_has_prelu_param() const;
public:
void clear_prelu_param();
const ::caffe::PReLUParameter& prelu_param() const;
::caffe::PReLUParameter* release_prelu_param();
::caffe::PReLUParameter* mutable_prelu_param();
void set_allocated_prelu_param(::caffe::PReLUParameter* prelu_param);
private:
const ::caffe::PReLUParameter& _internal_prelu_param() const;
::caffe::PReLUParameter* _internal_mutable_prelu_param();
public:
void unsafe_arena_set_allocated_prelu_param(
::caffe::PReLUParameter* prelu_param);
::caffe::PReLUParameter* unsafe_arena_release_prelu_param();
// optional .caffe.SPPParameter spp_param = 132;
bool has_spp_param() const;
private:
bool _internal_has_spp_param() const;
public:
void clear_spp_param();
const ::caffe::SPPParameter& spp_param() const;
::caffe::SPPParameter* release_spp_param();
::caffe::SPPParameter* mutable_spp_param();
void set_allocated_spp_param(::caffe::SPPParameter* spp_param);
private:
const ::caffe::SPPParameter& _internal_spp_param() const;
::caffe::SPPParameter* _internal_mutable_spp_param();
public:
void unsafe_arena_set_allocated_spp_param(
::caffe::SPPParameter* spp_param);
::caffe::SPPParameter* unsafe_arena_release_spp_param();
// optional .caffe.ReshapeParameter reshape_param = 133;
bool has_reshape_param() const;
private:
bool _internal_has_reshape_param() const;
public:
void clear_reshape_param();
const ::caffe::ReshapeParameter& reshape_param() const;
::caffe::ReshapeParameter* release_reshape_param();
::caffe::ReshapeParameter* mutable_reshape_param();
void set_allocated_reshape_param(::caffe::ReshapeParameter* reshape_param);
private:
const ::caffe::ReshapeParameter& _internal_reshape_param() const;
::caffe::ReshapeParameter* _internal_mutable_reshape_param();
public:
void unsafe_arena_set_allocated_reshape_param(
::caffe::ReshapeParameter* reshape_param);
::caffe::ReshapeParameter* unsafe_arena_release_reshape_param();
// optional .caffe.LogParameter log_param = 134;
bool has_log_param() const;
private:
bool _internal_has_log_param() const;
public:
void clear_log_param();
const ::caffe::LogParameter& log_param() const;
::caffe::LogParameter* release_log_param();
::caffe::LogParameter* mutable_log_param();
void set_allocated_log_param(::caffe::LogParameter* log_param);
private:
const ::caffe::LogParameter& _internal_log_param() const;
::caffe::LogParameter* _internal_mutable_log_param();
public:
void unsafe_arena_set_allocated_log_param(
::caffe::LogParameter* log_param);
::caffe::LogParameter* unsafe_arena_release_log_param();
// optional .caffe.FlattenParameter flatten_param = 135;
bool has_flatten_param() const;
private:
bool _internal_has_flatten_param() const;
public:
void clear_flatten_param();
const ::caffe::FlattenParameter& flatten_param() const;
::caffe::FlattenParameter* release_flatten_param();
::caffe::FlattenParameter* mutable_flatten_param();
void set_allocated_flatten_param(::caffe::FlattenParameter* flatten_param);
private:
const ::caffe::FlattenParameter& _internal_flatten_param() const;
::caffe::FlattenParameter* _internal_mutable_flatten_param();
public:
void unsafe_arena_set_allocated_flatten_param(
::caffe::FlattenParameter* flatten_param);
::caffe::FlattenParameter* unsafe_arena_release_flatten_param();
// optional .caffe.ReductionParameter reduction_param = 136;
bool has_reduction_param() const;
private:
bool _internal_has_reduction_param() const;
public:
void clear_reduction_param();
const ::caffe::ReductionParameter& reduction_param() const;
::caffe::ReductionParameter* release_reduction_param();
::caffe::ReductionParameter* mutable_reduction_param();
void set_allocated_reduction_param(::caffe::ReductionParameter* reduction_param);
private:
const ::caffe::ReductionParameter& _internal_reduction_param() const;
::caffe::ReductionParameter* _internal_mutable_reduction_param();
public:
void unsafe_arena_set_allocated_reduction_param(
::caffe::ReductionParameter* reduction_param);
::caffe::ReductionParameter* unsafe_arena_release_reduction_param();
// optional .caffe.EmbedParameter embed_param = 137;
bool has_embed_param() const;
private:
bool _internal_has_embed_param() const;
public:
void clear_embed_param();
const ::caffe::EmbedParameter& embed_param() const;
::caffe::EmbedParameter* release_embed_param();
::caffe::EmbedParameter* mutable_embed_param();
void set_allocated_embed_param(::caffe::EmbedParameter* embed_param);
private:
const ::caffe::EmbedParameter& _internal_embed_param() const;
::caffe::EmbedParameter* _internal_mutable_embed_param();
public:
void unsafe_arena_set_allocated_embed_param(
::caffe::EmbedParameter* embed_param);
::caffe::EmbedParameter* unsafe_arena_release_embed_param();
// optional .caffe.TileParameter tile_param = 138;
bool has_tile_param() const;
private:
bool _internal_has_tile_param() const;
public:
void clear_tile_param();
const ::caffe::TileParameter& tile_param() const;
::caffe::TileParameter* release_tile_param();
::caffe::TileParameter* mutable_tile_param();
void set_allocated_tile_param(::caffe::TileParameter* tile_param);
private:
const ::caffe::TileParameter& _internal_tile_param() const;
::caffe::TileParameter* _internal_mutable_tile_param();
public:
void unsafe_arena_set_allocated_tile_param(
::caffe::TileParameter* tile_param);
::caffe::TileParameter* unsafe_arena_release_tile_param();
// optional .caffe.BatchNormParameter batch_norm_param = 139;
bool has_batch_norm_param() const;
private:
bool _internal_has_batch_norm_param() const;
public:
void clear_batch_norm_param();
const ::caffe::BatchNormParameter& batch_norm_param() const;
::caffe::BatchNormParameter* release_batch_norm_param();
::caffe::BatchNormParameter* mutable_batch_norm_param();
void set_allocated_batch_norm_param(::caffe::BatchNormParameter* batch_norm_param);
private:
const ::caffe::BatchNormParameter& _internal_batch_norm_param() const;
::caffe::BatchNormParameter* _internal_mutable_batch_norm_param();
public:
void unsafe_arena_set_allocated_batch_norm_param(
::caffe::BatchNormParameter* batch_norm_param);
::caffe::BatchNormParameter* unsafe_arena_release_batch_norm_param();
// optional .caffe.ELUParameter elu_param = 140;
bool has_elu_param() const;
private:
bool _internal_has_elu_param() const;
public:
void clear_elu_param();
const ::caffe::ELUParameter& elu_param() const;
::caffe::ELUParameter* release_elu_param();
::caffe::ELUParameter* mutable_elu_param();
void set_allocated_elu_param(::caffe::ELUParameter* elu_param);
private:
const ::caffe::ELUParameter& _internal_elu_param() const;
::caffe::ELUParameter* _internal_mutable_elu_param();
public:
void unsafe_arena_set_allocated_elu_param(
::caffe::ELUParameter* elu_param);
::caffe::ELUParameter* unsafe_arena_release_elu_param();
// optional .caffe.BiasParameter bias_param = 141;
bool has_bias_param() const;
private:
bool _internal_has_bias_param() const;
public:
void clear_bias_param();
const ::caffe::BiasParameter& bias_param() const;
::caffe::BiasParameter* release_bias_param();
::caffe::BiasParameter* mutable_bias_param();
void set_allocated_bias_param(::caffe::BiasParameter* bias_param);
private:
const ::caffe::BiasParameter& _internal_bias_param() const;
::caffe::BiasParameter* _internal_mutable_bias_param();
public:
void unsafe_arena_set_allocated_bias_param(
::caffe::BiasParameter* bias_param);
::caffe::BiasParameter* unsafe_arena_release_bias_param();
// optional .caffe.ScaleParameter scale_param = 142;
bool has_scale_param() const;
private:
bool _internal_has_scale_param() const;
public:
void clear_scale_param();
const ::caffe::ScaleParameter& scale_param() const;
::caffe::ScaleParameter* release_scale_param();
::caffe::ScaleParameter* mutable_scale_param();
void set_allocated_scale_param(::caffe::ScaleParameter* scale_param);
private:
const ::caffe::ScaleParameter& _internal_scale_param() const;
::caffe::ScaleParameter* _internal_mutable_scale_param();
public:
void unsafe_arena_set_allocated_scale_param(
::caffe::ScaleParameter* scale_param);
::caffe::ScaleParameter* unsafe_arena_release_scale_param();
// optional .caffe.InputParameter input_param = 143;
bool has_input_param() const;
private:
bool _internal_has_input_param() const;
public:
void clear_input_param();
const ::caffe::InputParameter& input_param() const;
::caffe::InputParameter* release_input_param();
::caffe::InputParameter* mutable_input_param();
void set_allocated_input_param(::caffe::InputParameter* input_param);
private:
const ::caffe::InputParameter& _internal_input_param() const;
::caffe::InputParameter* _internal_mutable_input_param();
public:
void unsafe_arena_set_allocated_input_param(
::caffe::InputParameter* input_param);
::caffe::InputParameter* unsafe_arena_release_input_param();
// optional .caffe.CropParameter crop_param = 144;
bool has_crop_param() const;
private:
bool _internal_has_crop_param() const;
public:
void clear_crop_param();
const ::caffe::CropParameter& crop_param() const;
::caffe::CropParameter* release_crop_param();
::caffe::CropParameter* mutable_crop_param();
void set_allocated_crop_param(::caffe::CropParameter* crop_param);
private:
const ::caffe::CropParameter& _internal_crop_param() const;
::caffe::CropParameter* _internal_mutable_crop_param();
public:
void unsafe_arena_set_allocated_crop_param(
::caffe::CropParameter* crop_param);
::caffe::CropParameter* unsafe_arena_release_crop_param();
// optional .caffe.ParameterParameter parameter_param = 145;
bool has_parameter_param() const;
private:
bool _internal_has_parameter_param() const;
public:
void clear_parameter_param();
const ::caffe::ParameterParameter& parameter_param() const;
::caffe::ParameterParameter* release_parameter_param();
::caffe::ParameterParameter* mutable_parameter_param();
void set_allocated_parameter_param(::caffe::ParameterParameter* parameter_param);
private:
const ::caffe::ParameterParameter& _internal_parameter_param() const;
::caffe::ParameterParameter* _internal_mutable_parameter_param();
public:
void unsafe_arena_set_allocated_parameter_param(
::caffe::ParameterParameter* parameter_param);
::caffe::ParameterParameter* unsafe_arena_release_parameter_param();
// optional .caffe.RecurrentParameter recurrent_param = 146;
bool has_recurrent_param() const;
private:
bool _internal_has_recurrent_param() const;
public:
void clear_recurrent_param();
const ::caffe::RecurrentParameter& recurrent_param() const;
::caffe::RecurrentParameter* release_recurrent_param();
::caffe::RecurrentParameter* mutable_recurrent_param();
void set_allocated_recurrent_param(::caffe::RecurrentParameter* recurrent_param);
private:
const ::caffe::RecurrentParameter& _internal_recurrent_param() const;
::caffe::RecurrentParameter* _internal_mutable_recurrent_param();
public:
void unsafe_arena_set_allocated_recurrent_param(
::caffe::RecurrentParameter* recurrent_param);
::caffe::RecurrentParameter* unsafe_arena_release_recurrent_param();
// optional .caffe.ROIPoolingParameter roi_pooling_param = 147;
bool has_roi_pooling_param() const;
private:
bool _internal_has_roi_pooling_param() const;
public:
void clear_roi_pooling_param();
const ::caffe::ROIPoolingParameter& roi_pooling_param() const;
::caffe::ROIPoolingParameter* release_roi_pooling_param();
::caffe::ROIPoolingParameter* mutable_roi_pooling_param();
void set_allocated_roi_pooling_param(::caffe::ROIPoolingParameter* roi_pooling_param);
private:
const ::caffe::ROIPoolingParameter& _internal_roi_pooling_param() const;
::caffe::ROIPoolingParameter* _internal_mutable_roi_pooling_param();
public:
void unsafe_arena_set_allocated_roi_pooling_param(
::caffe::ROIPoolingParameter* roi_pooling_param);
::caffe::ROIPoolingParameter* unsafe_arena_release_roi_pooling_param();
// optional .caffe.SmoothL1LossParameter smooth_l1_loss_param = 148;
bool has_smooth_l1_loss_param() const;
private:
bool _internal_has_smooth_l1_loss_param() const;
public:
void clear_smooth_l1_loss_param();
const ::caffe::SmoothL1LossParameter& smooth_l1_loss_param() const;
::caffe::SmoothL1LossParameter* release_smooth_l1_loss_param();
::caffe::SmoothL1LossParameter* mutable_smooth_l1_loss_param();
void set_allocated_smooth_l1_loss_param(::caffe::SmoothL1LossParameter* smooth_l1_loss_param);
private:
const ::caffe::SmoothL1LossParameter& _internal_smooth_l1_loss_param() const;
::caffe::SmoothL1LossParameter* _internal_mutable_smooth_l1_loss_param();
public:
void unsafe_arena_set_allocated_smooth_l1_loss_param(
::caffe::SmoothL1LossParameter* smooth_l1_loss_param);
::caffe::SmoothL1LossParameter* unsafe_arena_release_smooth_l1_loss_param();
// optional .caffe.FaceDataParameter face_data_param = 150;
bool has_face_data_param() const;
private:
bool _internal_has_face_data_param() const;
public:
void clear_face_data_param();
const ::caffe::FaceDataParameter& face_data_param() const;
::caffe::FaceDataParameter* release_face_data_param();
::caffe::FaceDataParameter* mutable_face_data_param();
void set_allocated_face_data_param(::caffe::FaceDataParameter* face_data_param);
private:
const ::caffe::FaceDataParameter& _internal_face_data_param() const;
::caffe::FaceDataParameter* _internal_mutable_face_data_param();
public:
void unsafe_arena_set_allocated_face_data_param(
::caffe::FaceDataParameter* face_data_param);
::caffe::FaceDataParameter* unsafe_arena_release_face_data_param();
// optional .caffe.UpsampleParameter upsample_param = 151;
bool has_upsample_param() const;
private:
bool _internal_has_upsample_param() const;
public:
void clear_upsample_param();
const ::caffe::UpsampleParameter& upsample_param() const;
::caffe::UpsampleParameter* release_upsample_param();
::caffe::UpsampleParameter* mutable_upsample_param();
void set_allocated_upsample_param(::caffe::UpsampleParameter* upsample_param);
private:
const ::caffe::UpsampleParameter& _internal_upsample_param() const;
::caffe::UpsampleParameter* _internal_mutable_upsample_param();
public:
void unsafe_arena_set_allocated_upsample_param(
::caffe::UpsampleParameter* upsample_param);
::caffe::UpsampleParameter* unsafe_arena_release_upsample_param();
// optional .caffe.ConnectParameter connect_param = 152;
bool has_connect_param() const;
private:
bool _internal_has_connect_param() const;
public:
void clear_connect_param();
const ::caffe::ConnectParameter& connect_param() const;
::caffe::ConnectParameter* release_connect_param();
::caffe::ConnectParameter* mutable_connect_param();
void set_allocated_connect_param(::caffe::ConnectParameter* connect_param);
private:
const ::caffe::ConnectParameter& _internal_connect_param() const;
::caffe::ConnectParameter* _internal_mutable_connect_param();
public:
void unsafe_arena_set_allocated_connect_param(
::caffe::ConnectParameter* connect_param);
::caffe::ConnectParameter* unsafe_arena_release_connect_param();
// optional .caffe.AnnotatedDataParameter annotated_data_param = 200;
bool has_annotated_data_param() const;
private:
bool _internal_has_annotated_data_param() const;
public:
void clear_annotated_data_param();
const ::caffe::AnnotatedDataParameter& annotated_data_param() const;
::caffe::AnnotatedDataParameter* release_annotated_data_param();
::caffe::AnnotatedDataParameter* mutable_annotated_data_param();
void set_allocated_annotated_data_param(::caffe::AnnotatedDataParameter* annotated_data_param);
private:
const ::caffe::AnnotatedDataParameter& _internal_annotated_data_param() const;
::caffe::AnnotatedDataParameter* _internal_mutable_annotated_data_param();
public:
void unsafe_arena_set_allocated_annotated_data_param(
::caffe::AnnotatedDataParameter* annotated_data_param);
::caffe::AnnotatedDataParameter* unsafe_arena_release_annotated_data_param();
// optional .caffe.MultiBoxLossParameter multibox_loss_param = 201;
bool has_multibox_loss_param() const;
private:
bool _internal_has_multibox_loss_param() const;
public:
void clear_multibox_loss_param();
const ::caffe::MultiBoxLossParameter& multibox_loss_param() const;
::caffe::MultiBoxLossParameter* release_multibox_loss_param();
::caffe::MultiBoxLossParameter* mutable_multibox_loss_param();
void set_allocated_multibox_loss_param(::caffe::MultiBoxLossParameter* multibox_loss_param);
private:
const ::caffe::MultiBoxLossParameter& _internal_multibox_loss_param() const;
::caffe::MultiBoxLossParameter* _internal_mutable_multibox_loss_param();
public:
void unsafe_arena_set_allocated_multibox_loss_param(
::caffe::MultiBoxLossParameter* multibox_loss_param);
::caffe::MultiBoxLossParameter* unsafe_arena_release_multibox_loss_param();
// optional .caffe.PermuteParameter permute_param = 202;
bool has_permute_param() const;
private:
bool _internal_has_permute_param() const;
public:
void clear_permute_param();
const ::caffe::PermuteParameter& permute_param() const;
::caffe::PermuteParameter* release_permute_param();
::caffe::PermuteParameter* mutable_permute_param();
void set_allocated_permute_param(::caffe::PermuteParameter* permute_param);
private:
const ::caffe::PermuteParameter& _internal_permute_param() const;
::caffe::PermuteParameter* _internal_mutable_permute_param();
public:
void unsafe_arena_set_allocated_permute_param(
::caffe::PermuteParameter* permute_param);
::caffe::PermuteParameter* unsafe_arena_release_permute_param();
// optional .caffe.PriorBoxParameter prior_box_param = 203;
bool has_prior_box_param() const;
private:
bool _internal_has_prior_box_param() const;
public:
void clear_prior_box_param();
const ::caffe::PriorBoxParameter& prior_box_param() const;
::caffe::PriorBoxParameter* release_prior_box_param();
::caffe::PriorBoxParameter* mutable_prior_box_param();
void set_allocated_prior_box_param(::caffe::PriorBoxParameter* prior_box_param);
private:
const ::caffe::PriorBoxParameter& _internal_prior_box_param() const;
::caffe::PriorBoxParameter* _internal_mutable_prior_box_param();
public:
void unsafe_arena_set_allocated_prior_box_param(
::caffe::PriorBoxParameter* prior_box_param);
::caffe::PriorBoxParameter* unsafe_arena_release_prior_box_param();
// optional .caffe.DetectionOutputParameter detection_output_param = 204;
bool has_detection_output_param() const;
private:
bool _internal_has_detection_output_param() const;
public:
void clear_detection_output_param();
const ::caffe::DetectionOutputParameter& detection_output_param() const;
::caffe::DetectionOutputParameter* release_detection_output_param();
::caffe::DetectionOutputParameter* mutable_detection_output_param();
void set_allocated_detection_output_param(::caffe::DetectionOutputParameter* detection_output_param);
private:
const ::caffe::DetectionOutputParameter& _internal_detection_output_param() const;
::caffe::DetectionOutputParameter* _internal_mutable_detection_output_param();
public:
void unsafe_arena_set_allocated_detection_output_param(
::caffe::DetectionOutputParameter* detection_output_param);
::caffe::DetectionOutputParameter* unsafe_arena_release_detection_output_param();
// optional .caffe.DetectionEvaluateParameter detection_evaluate_param = 205;
bool has_detection_evaluate_param() const;
private:
bool _internal_has_detection_evaluate_param() const;
public:
void clear_detection_evaluate_param();
const ::caffe::DetectionEvaluateParameter& detection_evaluate_param() const;
::caffe::DetectionEvaluateParameter* release_detection_evaluate_param();
::caffe::DetectionEvaluateParameter* mutable_detection_evaluate_param();
void set_allocated_detection_evaluate_param(::caffe::DetectionEvaluateParameter* detection_evaluate_param);
private:
const ::caffe::DetectionEvaluateParameter& _internal_detection_evaluate_param() const;
::caffe::DetectionEvaluateParameter* _internal_mutable_detection_evaluate_param();
public:
void unsafe_arena_set_allocated_detection_evaluate_param(
::caffe::DetectionEvaluateParameter* detection_evaluate_param);
::caffe::DetectionEvaluateParameter* unsafe_arena_release_detection_evaluate_param();
// optional .caffe.NormalizeParameter norm_param = 206;
bool has_norm_param() const;
private:
bool _internal_has_norm_param() const;
public:
void clear_norm_param();
const ::caffe::NormalizeParameter& norm_param() const;
::caffe::NormalizeParameter* release_norm_param();
::caffe::NormalizeParameter* mutable_norm_param();
void set_allocated_norm_param(::caffe::NormalizeParameter* norm_param);
private:
const ::caffe::NormalizeParameter& _internal_norm_param() const;
::caffe::NormalizeParameter* _internal_mutable_norm_param();
public:
void unsafe_arena_set_allocated_norm_param(
::caffe::NormalizeParameter* norm_param);
::caffe::NormalizeParameter* unsafe_arena_release_norm_param();
// optional .caffe.VideoDataParameter video_data_param = 207;
bool has_video_data_param() const;
private:
bool _internal_has_video_data_param() const;
public:
void clear_video_data_param();
const ::caffe::VideoDataParameter& video_data_param() const;
::caffe::VideoDataParameter* release_video_data_param();
::caffe::VideoDataParameter* mutable_video_data_param();
void set_allocated_video_data_param(::caffe::VideoDataParameter* video_data_param);
private:
const ::caffe::VideoDataParameter& _internal_video_data_param() const;
::caffe::VideoDataParameter* _internal_mutable_video_data_param();
public:
void unsafe_arena_set_allocated_video_data_param(
::caffe::VideoDataParameter* video_data_param);
::caffe::VideoDataParameter* unsafe_arena_release_video_data_param();
// optional .caffe.MILDataParameter mil_data_param = 5065028;
bool has_mil_data_param() const;
private:
bool _internal_has_mil_data_param() const;
public:
void clear_mil_data_param();
const ::caffe::MILDataParameter& mil_data_param() const;
::caffe::MILDataParameter* release_mil_data_param();
::caffe::MILDataParameter* mutable_mil_data_param();
void set_allocated_mil_data_param(::caffe::MILDataParameter* mil_data_param);
private:
const ::caffe::MILDataParameter& _internal_mil_data_param() const;
::caffe::MILDataParameter* _internal_mutable_mil_data_param();
public:
void unsafe_arena_set_allocated_mil_data_param(
::caffe::MILDataParameter* mil_data_param);
::caffe::MILDataParameter* unsafe_arena_release_mil_data_param();
// optional .caffe.MILParameter mil_param = 5065036;
bool has_mil_param() const;
private:
bool _internal_has_mil_param() const;
public:
void clear_mil_param();
const ::caffe::MILParameter& mil_param() const;
::caffe::MILParameter* release_mil_param();
::caffe::MILParameter* mutable_mil_param();
void set_allocated_mil_param(::caffe::MILParameter* mil_param);
private:
const ::caffe::MILParameter& _internal_mil_param() const;
::caffe::MILParameter* _internal_mutable_mil_param();
public:
void unsafe_arena_set_allocated_mil_param(
::caffe::MILParameter* mil_param);
::caffe::MILParameter* unsafe_arena_release_mil_param();
// optional .caffe.Phase phase = 10;
bool has_phase() const;
private:
bool _internal_has_phase() const;
public:
void clear_phase();
::caffe::Phase phase() const;
void set_phase(::caffe::Phase value);
private:
::caffe::Phase _internal_phase() const;
void _internal_set_phase(::caffe::Phase value);
public:
// @@protoc_insertion_point(class_scope:caffe.LayerParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<3> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string> bottom_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string> top_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float > loss_weight_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::ParamSpec > param_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto > blobs_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetStateRule > include_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetStateRule > exclude_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< bool > propagate_down_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr name_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr type_;
::caffe::TransformationParameter* transform_param_;
::caffe::LossParameter* loss_param_;
::caffe::AccuracyParameter* accuracy_param_;
::caffe::ArgMaxParameter* argmax_param_;
::caffe::ConcatParameter* concat_param_;
::caffe::ContrastiveLossParameter* contrastive_loss_param_;
::caffe::ConvolutionParameter* convolution_param_;
::caffe::DataParameter* data_param_;
::caffe::DropoutParameter* dropout_param_;
::caffe::DummyDataParameter* dummy_data_param_;
::caffe::EltwiseParameter* eltwise_param_;
::caffe::ExpParameter* exp_param_;
::caffe::HDF5DataParameter* hdf5_data_param_;
::caffe::HDF5OutputParameter* hdf5_output_param_;
::caffe::HingeLossParameter* hinge_loss_param_;
::caffe::ImageDataParameter* image_data_param_;
::caffe::InfogainLossParameter* infogain_loss_param_;
::caffe::InnerProductParameter* inner_product_param_;
::caffe::LRNParameter* lrn_param_;
::caffe::MemoryDataParameter* memory_data_param_;
::caffe::MVNParameter* mvn_param_;
::caffe::PoolingParameter* pooling_param_;
::caffe::PowerParameter* power_param_;
::caffe::ReLUParameter* relu_param_;
::caffe::SigmoidParameter* sigmoid_param_;
::caffe::SoftmaxParameter* softmax_param_;
::caffe::SliceParameter* slice_param_;
::caffe::TanHParameter* tanh_param_;
::caffe::ThresholdParameter* threshold_param_;
::caffe::WindowDataParameter* window_data_param_;
::caffe::PythonParameter* python_param_;
::caffe::PReLUParameter* prelu_param_;
::caffe::SPPParameter* spp_param_;
::caffe::ReshapeParameter* reshape_param_;
::caffe::LogParameter* log_param_;
::caffe::FlattenParameter* flatten_param_;
::caffe::ReductionParameter* reduction_param_;
::caffe::EmbedParameter* embed_param_;
::caffe::TileParameter* tile_param_;
::caffe::BatchNormParameter* batch_norm_param_;
::caffe::ELUParameter* elu_param_;
::caffe::BiasParameter* bias_param_;
::caffe::ScaleParameter* scale_param_;
::caffe::InputParameter* input_param_;
::caffe::CropParameter* crop_param_;
::caffe::ParameterParameter* parameter_param_;
::caffe::RecurrentParameter* recurrent_param_;
::caffe::ROIPoolingParameter* roi_pooling_param_;
::caffe::SmoothL1LossParameter* smooth_l1_loss_param_;
::caffe::FaceDataParameter* face_data_param_;
::caffe::UpsampleParameter* upsample_param_;
::caffe::ConnectParameter* connect_param_;
::caffe::AnnotatedDataParameter* annotated_data_param_;
::caffe::MultiBoxLossParameter* multibox_loss_param_;
::caffe::PermuteParameter* permute_param_;
::caffe::PriorBoxParameter* prior_box_param_;
::caffe::DetectionOutputParameter* detection_output_param_;
::caffe::DetectionEvaluateParameter* detection_evaluate_param_;
::caffe::NormalizeParameter* norm_param_;
::caffe::VideoDataParameter* video_data_param_;
::caffe::MILDataParameter* mil_data_param_;
::caffe::MILParameter* mil_param_;
int phase_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class TransformationParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.TransformationParameter) */ {
public:
inline TransformationParameter() : TransformationParameter(nullptr) {}
virtual ~TransformationParameter();
TransformationParameter(const TransformationParameter& from);
TransformationParameter(TransformationParameter&& from) noexcept
: TransformationParameter() {
*this = ::std::move(from);
}
inline TransformationParameter& operator=(const TransformationParameter& from) {
CopyFrom(from);
return *this;
}
inline TransformationParameter& operator=(TransformationParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const TransformationParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const TransformationParameter* internal_default_instance() {
return reinterpret_cast<const TransformationParameter*>(
&_TransformationParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
22;
friend void swap(TransformationParameter& a, TransformationParameter& b) {
a.Swap(&b);
}
inline void Swap(TransformationParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(TransformationParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline TransformationParameter* New() const final {
return CreateMaybeMessage<TransformationParameter>(nullptr);
}
TransformationParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<TransformationParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const TransformationParameter& from);
void MergeFrom(const TransformationParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(TransformationParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.TransformationParameter";
}
protected:
explicit TransformationParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kMeanValueFieldNumber = 5,
kMeanFileFieldNumber = 4,
kResizeParamFieldNumber = 8,
kNoiseParamFieldNumber = 9,
kEmitConstraintFieldNumber = 10,
kCropSizeFieldNumber = 3,
kMirrorFieldNumber = 2,
kForceColorFieldNumber = 6,
kForceGrayFieldNumber = 7,
kCropHFieldNumber = 11,
kCropWFieldNumber = 12,
kScaleFieldNumber = 1,
};
// repeated float mean_value = 5;
int mean_value_size() const;
private:
int _internal_mean_value_size() const;
public:
void clear_mean_value();
private:
float _internal_mean_value(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
_internal_mean_value() const;
void _internal_add_mean_value(float value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
_internal_mutable_mean_value();
public:
float mean_value(int index) const;
void set_mean_value(int index, float value);
void add_mean_value(float value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
mean_value() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
mutable_mean_value();
// optional string mean_file = 4;
bool has_mean_file() const;
private:
bool _internal_has_mean_file() const;
public:
void clear_mean_file();
const std::string& mean_file() const;
void set_mean_file(const std::string& value);
void set_mean_file(std::string&& value);
void set_mean_file(const char* value);
void set_mean_file(const char* value, size_t size);
std::string* mutable_mean_file();
std::string* release_mean_file();
void set_allocated_mean_file(std::string* mean_file);
private:
const std::string& _internal_mean_file() const;
void _internal_set_mean_file(const std::string& value);
std::string* _internal_mutable_mean_file();
public:
// optional .caffe.ResizeParameter resize_param = 8;
bool has_resize_param() const;
private:
bool _internal_has_resize_param() const;
public:
void clear_resize_param();
const ::caffe::ResizeParameter& resize_param() const;
::caffe::ResizeParameter* release_resize_param();
::caffe::ResizeParameter* mutable_resize_param();
void set_allocated_resize_param(::caffe::ResizeParameter* resize_param);
private:
const ::caffe::ResizeParameter& _internal_resize_param() const;
::caffe::ResizeParameter* _internal_mutable_resize_param();
public:
void unsafe_arena_set_allocated_resize_param(
::caffe::ResizeParameter* resize_param);
::caffe::ResizeParameter* unsafe_arena_release_resize_param();
// optional .caffe.NoiseParameter noise_param = 9;
bool has_noise_param() const;
private:
bool _internal_has_noise_param() const;
public:
void clear_noise_param();
const ::caffe::NoiseParameter& noise_param() const;
::caffe::NoiseParameter* release_noise_param();
::caffe::NoiseParameter* mutable_noise_param();
void set_allocated_noise_param(::caffe::NoiseParameter* noise_param);
private:
const ::caffe::NoiseParameter& _internal_noise_param() const;
::caffe::NoiseParameter* _internal_mutable_noise_param();
public:
void unsafe_arena_set_allocated_noise_param(
::caffe::NoiseParameter* noise_param);
::caffe::NoiseParameter* unsafe_arena_release_noise_param();
// optional .caffe.EmitConstraint emit_constraint = 10;
bool has_emit_constraint() const;
private:
bool _internal_has_emit_constraint() const;
public:
void clear_emit_constraint();
const ::caffe::EmitConstraint& emit_constraint() const;
::caffe::EmitConstraint* release_emit_constraint();
::caffe::EmitConstraint* mutable_emit_constraint();
void set_allocated_emit_constraint(::caffe::EmitConstraint* emit_constraint);
private:
const ::caffe::EmitConstraint& _internal_emit_constraint() const;
::caffe::EmitConstraint* _internal_mutable_emit_constraint();
public:
void unsafe_arena_set_allocated_emit_constraint(
::caffe::EmitConstraint* emit_constraint);
::caffe::EmitConstraint* unsafe_arena_release_emit_constraint();
// optional uint32 crop_size = 3 [default = 0];
bool has_crop_size() const;
private:
bool _internal_has_crop_size() const;
public:
void clear_crop_size();
::PROTOBUF_NAMESPACE_ID::uint32 crop_size() const;
void set_crop_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_crop_size() const;
void _internal_set_crop_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional bool mirror = 2 [default = false];
bool has_mirror() const;
private:
bool _internal_has_mirror() const;
public:
void clear_mirror();
bool mirror() const;
void set_mirror(bool value);
private:
bool _internal_mirror() const;
void _internal_set_mirror(bool value);
public:
// optional bool force_color = 6 [default = false];
bool has_force_color() const;
private:
bool _internal_has_force_color() const;
public:
void clear_force_color();
bool force_color() const;
void set_force_color(bool value);
private:
bool _internal_force_color() const;
void _internal_set_force_color(bool value);
public:
// optional bool force_gray = 7 [default = false];
bool has_force_gray() const;
private:
bool _internal_has_force_gray() const;
public:
void clear_force_gray();
bool force_gray() const;
void set_force_gray(bool value);
private:
bool _internal_force_gray() const;
void _internal_set_force_gray(bool value);
public:
// optional uint32 crop_h = 11 [default = 0];
bool has_crop_h() const;
private:
bool _internal_has_crop_h() const;
public:
void clear_crop_h();
::PROTOBUF_NAMESPACE_ID::uint32 crop_h() const;
void set_crop_h(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_crop_h() const;
void _internal_set_crop_h(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 crop_w = 12 [default = 0];
bool has_crop_w() const;
private:
bool _internal_has_crop_w() const;
public:
void clear_crop_w();
::PROTOBUF_NAMESPACE_ID::uint32 crop_w() const;
void set_crop_w(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_crop_w() const;
void _internal_set_crop_w(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional float scale = 1 [default = 1];
bool has_scale() const;
private:
bool _internal_has_scale() const;
public:
void clear_scale();
float scale() const;
void set_scale(float value);
private:
float _internal_scale() const;
void _internal_set_scale(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.TransformationParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float > mean_value_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr mean_file_;
::caffe::ResizeParameter* resize_param_;
::caffe::NoiseParameter* noise_param_;
::caffe::EmitConstraint* emit_constraint_;
::PROTOBUF_NAMESPACE_ID::uint32 crop_size_;
bool mirror_;
bool force_color_;
bool force_gray_;
::PROTOBUF_NAMESPACE_ID::uint32 crop_h_;
::PROTOBUF_NAMESPACE_ID::uint32 crop_w_;
float scale_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class ResizeParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.ResizeParameter) */ {
public:
inline ResizeParameter() : ResizeParameter(nullptr) {}
virtual ~ResizeParameter();
ResizeParameter(const ResizeParameter& from);
ResizeParameter(ResizeParameter&& from) noexcept
: ResizeParameter() {
*this = ::std::move(from);
}
inline ResizeParameter& operator=(const ResizeParameter& from) {
CopyFrom(from);
return *this;
}
inline ResizeParameter& operator=(ResizeParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const ResizeParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const ResizeParameter* internal_default_instance() {
return reinterpret_cast<const ResizeParameter*>(
&_ResizeParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
23;
friend void swap(ResizeParameter& a, ResizeParameter& b) {
a.Swap(&b);
}
inline void Swap(ResizeParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(ResizeParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline ResizeParameter* New() const final {
return CreateMaybeMessage<ResizeParameter>(nullptr);
}
ResizeParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<ResizeParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const ResizeParameter& from);
void MergeFrom(const ResizeParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(ResizeParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.ResizeParameter";
}
protected:
explicit ResizeParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef ResizeParameter_Resize_mode Resize_mode;
static constexpr Resize_mode WARP =
ResizeParameter_Resize_mode_WARP;
static constexpr Resize_mode FIT_SMALL_SIZE =
ResizeParameter_Resize_mode_FIT_SMALL_SIZE;
static constexpr Resize_mode FIT_LARGE_SIZE_AND_PAD =
ResizeParameter_Resize_mode_FIT_LARGE_SIZE_AND_PAD;
static inline bool Resize_mode_IsValid(int value) {
return ResizeParameter_Resize_mode_IsValid(value);
}
static constexpr Resize_mode Resize_mode_MIN =
ResizeParameter_Resize_mode_Resize_mode_MIN;
static constexpr Resize_mode Resize_mode_MAX =
ResizeParameter_Resize_mode_Resize_mode_MAX;
static constexpr int Resize_mode_ARRAYSIZE =
ResizeParameter_Resize_mode_Resize_mode_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
Resize_mode_descriptor() {
return ResizeParameter_Resize_mode_descriptor();
}
template<typename T>
static inline const std::string& Resize_mode_Name(T enum_t_value) {
static_assert(::std::is_same<T, Resize_mode>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function Resize_mode_Name.");
return ResizeParameter_Resize_mode_Name(enum_t_value);
}
static inline bool Resize_mode_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
Resize_mode* value) {
return ResizeParameter_Resize_mode_Parse(name, value);
}
typedef ResizeParameter_Pad_mode Pad_mode;
static constexpr Pad_mode CONSTANT =
ResizeParameter_Pad_mode_CONSTANT;
static constexpr Pad_mode MIRRORED =
ResizeParameter_Pad_mode_MIRRORED;
static constexpr Pad_mode REPEAT_NEAREST =
ResizeParameter_Pad_mode_REPEAT_NEAREST;
static inline bool Pad_mode_IsValid(int value) {
return ResizeParameter_Pad_mode_IsValid(value);
}
static constexpr Pad_mode Pad_mode_MIN =
ResizeParameter_Pad_mode_Pad_mode_MIN;
static constexpr Pad_mode Pad_mode_MAX =
ResizeParameter_Pad_mode_Pad_mode_MAX;
static constexpr int Pad_mode_ARRAYSIZE =
ResizeParameter_Pad_mode_Pad_mode_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
Pad_mode_descriptor() {
return ResizeParameter_Pad_mode_descriptor();
}
template<typename T>
static inline const std::string& Pad_mode_Name(T enum_t_value) {
static_assert(::std::is_same<T, Pad_mode>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function Pad_mode_Name.");
return ResizeParameter_Pad_mode_Name(enum_t_value);
}
static inline bool Pad_mode_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
Pad_mode* value) {
return ResizeParameter_Pad_mode_Parse(name, value);
}
typedef ResizeParameter_Interp_mode Interp_mode;
static constexpr Interp_mode LINEAR =
ResizeParameter_Interp_mode_LINEAR;
static constexpr Interp_mode AREA =
ResizeParameter_Interp_mode_AREA;
static constexpr Interp_mode NEAREST =
ResizeParameter_Interp_mode_NEAREST;
static constexpr Interp_mode CUBIC =
ResizeParameter_Interp_mode_CUBIC;
static constexpr Interp_mode LANCZOS4 =
ResizeParameter_Interp_mode_LANCZOS4;
static inline bool Interp_mode_IsValid(int value) {
return ResizeParameter_Interp_mode_IsValid(value);
}
static constexpr Interp_mode Interp_mode_MIN =
ResizeParameter_Interp_mode_Interp_mode_MIN;
static constexpr Interp_mode Interp_mode_MAX =
ResizeParameter_Interp_mode_Interp_mode_MAX;
static constexpr int Interp_mode_ARRAYSIZE =
ResizeParameter_Interp_mode_Interp_mode_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
Interp_mode_descriptor() {
return ResizeParameter_Interp_mode_descriptor();
}
template<typename T>
static inline const std::string& Interp_mode_Name(T enum_t_value) {
static_assert(::std::is_same<T, Interp_mode>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function Interp_mode_Name.");
return ResizeParameter_Interp_mode_Name(enum_t_value);
}
static inline bool Interp_mode_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
Interp_mode* value) {
return ResizeParameter_Interp_mode_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kPadValueFieldNumber = 6,
kInterpModeFieldNumber = 7,
kHeightFieldNumber = 3,
kWidthFieldNumber = 4,
kPadModeFieldNumber = 5,
kProbFieldNumber = 1,
kResizeModeFieldNumber = 2,
};
// repeated float pad_value = 6;
int pad_value_size() const;
private:
int _internal_pad_value_size() const;
public:
void clear_pad_value();
private:
float _internal_pad_value(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
_internal_pad_value() const;
void _internal_add_pad_value(float value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
_internal_mutable_pad_value();
public:
float pad_value(int index) const;
void set_pad_value(int index, float value);
void add_pad_value(float value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
pad_value() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
mutable_pad_value();
// repeated .caffe.ResizeParameter.Interp_mode interp_mode = 7;
int interp_mode_size() const;
private:
int _internal_interp_mode_size() const;
public:
void clear_interp_mode();
private:
::caffe::ResizeParameter_Interp_mode _internal_interp_mode(int index) const;
void _internal_add_interp_mode(::caffe::ResizeParameter_Interp_mode value);
::PROTOBUF_NAMESPACE_ID::RepeatedField<int>* _internal_mutable_interp_mode();
public:
::caffe::ResizeParameter_Interp_mode interp_mode(int index) const;
void set_interp_mode(int index, ::caffe::ResizeParameter_Interp_mode value);
void add_interp_mode(::caffe::ResizeParameter_Interp_mode value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField<int>& interp_mode() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField<int>* mutable_interp_mode();
// optional uint32 height = 3 [default = 0];
bool has_height() const;
private:
bool _internal_has_height() const;
public:
void clear_height();
::PROTOBUF_NAMESPACE_ID::uint32 height() const;
void set_height(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_height() const;
void _internal_set_height(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 width = 4 [default = 0];
bool has_width() const;
private:
bool _internal_has_width() const;
public:
void clear_width();
::PROTOBUF_NAMESPACE_ID::uint32 width() const;
void set_width(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_width() const;
void _internal_set_width(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional .caffe.ResizeParameter.Pad_mode pad_mode = 5 [default = CONSTANT];
bool has_pad_mode() const;
private:
bool _internal_has_pad_mode() const;
public:
void clear_pad_mode();
::caffe::ResizeParameter_Pad_mode pad_mode() const;
void set_pad_mode(::caffe::ResizeParameter_Pad_mode value);
private:
::caffe::ResizeParameter_Pad_mode _internal_pad_mode() const;
void _internal_set_pad_mode(::caffe::ResizeParameter_Pad_mode value);
public:
// optional float prob = 1 [default = 1];
bool has_prob() const;
private:
bool _internal_has_prob() const;
public:
void clear_prob();
float prob() const;
void set_prob(float value);
private:
float _internal_prob() const;
void _internal_set_prob(float value);
public:
// optional .caffe.ResizeParameter.Resize_mode resize_mode = 2 [default = WARP];
bool has_resize_mode() const;
private:
bool _internal_has_resize_mode() const;
public:
void clear_resize_mode();
::caffe::ResizeParameter_Resize_mode resize_mode() const;
void set_resize_mode(::caffe::ResizeParameter_Resize_mode value);
private:
::caffe::ResizeParameter_Resize_mode _internal_resize_mode() const;
void _internal_set_resize_mode(::caffe::ResizeParameter_Resize_mode value);
public:
// @@protoc_insertion_point(class_scope:caffe.ResizeParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float > pad_value_;
::PROTOBUF_NAMESPACE_ID::RepeatedField<int> interp_mode_;
::PROTOBUF_NAMESPACE_ID::uint32 height_;
::PROTOBUF_NAMESPACE_ID::uint32 width_;
int pad_mode_;
float prob_;
int resize_mode_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class SaltPepperParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.SaltPepperParameter) */ {
public:
inline SaltPepperParameter() : SaltPepperParameter(nullptr) {}
virtual ~SaltPepperParameter();
SaltPepperParameter(const SaltPepperParameter& from);
SaltPepperParameter(SaltPepperParameter&& from) noexcept
: SaltPepperParameter() {
*this = ::std::move(from);
}
inline SaltPepperParameter& operator=(const SaltPepperParameter& from) {
CopyFrom(from);
return *this;
}
inline SaltPepperParameter& operator=(SaltPepperParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const SaltPepperParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const SaltPepperParameter* internal_default_instance() {
return reinterpret_cast<const SaltPepperParameter*>(
&_SaltPepperParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
24;
friend void swap(SaltPepperParameter& a, SaltPepperParameter& b) {
a.Swap(&b);
}
inline void Swap(SaltPepperParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(SaltPepperParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline SaltPepperParameter* New() const final {
return CreateMaybeMessage<SaltPepperParameter>(nullptr);
}
SaltPepperParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<SaltPepperParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const SaltPepperParameter& from);
void MergeFrom(const SaltPepperParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(SaltPepperParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.SaltPepperParameter";
}
protected:
explicit SaltPepperParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kValueFieldNumber = 2,
kFractionFieldNumber = 1,
};
// repeated float value = 2;
int value_size() const;
private:
int _internal_value_size() const;
public:
void clear_value();
private:
float _internal_value(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
_internal_value() const;
void _internal_add_value(float value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
_internal_mutable_value();
public:
float value(int index) const;
void set_value(int index, float value);
void add_value(float value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
value() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
mutable_value();
// optional float fraction = 1 [default = 0];
bool has_fraction() const;
private:
bool _internal_has_fraction() const;
public:
void clear_fraction();
float fraction() const;
void set_fraction(float value);
private:
float _internal_fraction() const;
void _internal_set_fraction(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.SaltPepperParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float > value_;
float fraction_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class NoiseParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.NoiseParameter) */ {
public:
inline NoiseParameter() : NoiseParameter(nullptr) {}
virtual ~NoiseParameter();
NoiseParameter(const NoiseParameter& from);
NoiseParameter(NoiseParameter&& from) noexcept
: NoiseParameter() {
*this = ::std::move(from);
}
inline NoiseParameter& operator=(const NoiseParameter& from) {
CopyFrom(from);
return *this;
}
inline NoiseParameter& operator=(NoiseParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const NoiseParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const NoiseParameter* internal_default_instance() {
return reinterpret_cast<const NoiseParameter*>(
&_NoiseParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
25;
friend void swap(NoiseParameter& a, NoiseParameter& b) {
a.Swap(&b);
}
inline void Swap(NoiseParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(NoiseParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline NoiseParameter* New() const final {
return CreateMaybeMessage<NoiseParameter>(nullptr);
}
NoiseParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<NoiseParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const NoiseParameter& from);
void MergeFrom(const NoiseParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(NoiseParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.NoiseParameter";
}
protected:
explicit NoiseParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kSaltpepperParamFieldNumber = 10,
kProbFieldNumber = 1,
kHistEqFieldNumber = 2,
kInverseFieldNumber = 3,
kDecolorizeFieldNumber = 4,
kGaussBlurFieldNumber = 5,
kPosterizeFieldNumber = 7,
kErodeFieldNumber = 8,
kSaltpepperFieldNumber = 9,
kClaheFieldNumber = 11,
kConvertToHsvFieldNumber = 12,
kConvertToLabFieldNumber = 13,
kJpegFieldNumber = 6,
};
// optional .caffe.SaltPepperParameter saltpepper_param = 10;
bool has_saltpepper_param() const;
private:
bool _internal_has_saltpepper_param() const;
public:
void clear_saltpepper_param();
const ::caffe::SaltPepperParameter& saltpepper_param() const;
::caffe::SaltPepperParameter* release_saltpepper_param();
::caffe::SaltPepperParameter* mutable_saltpepper_param();
void set_allocated_saltpepper_param(::caffe::SaltPepperParameter* saltpepper_param);
private:
const ::caffe::SaltPepperParameter& _internal_saltpepper_param() const;
::caffe::SaltPepperParameter* _internal_mutable_saltpepper_param();
public:
void unsafe_arena_set_allocated_saltpepper_param(
::caffe::SaltPepperParameter* saltpepper_param);
::caffe::SaltPepperParameter* unsafe_arena_release_saltpepper_param();
// optional float prob = 1 [default = 0];
bool has_prob() const;
private:
bool _internal_has_prob() const;
public:
void clear_prob();
float prob() const;
void set_prob(float value);
private:
float _internal_prob() const;
void _internal_set_prob(float value);
public:
// optional bool hist_eq = 2 [default = false];
bool has_hist_eq() const;
private:
bool _internal_has_hist_eq() const;
public:
void clear_hist_eq();
bool hist_eq() const;
void set_hist_eq(bool value);
private:
bool _internal_hist_eq() const;
void _internal_set_hist_eq(bool value);
public:
// optional bool inverse = 3 [default = false];
bool has_inverse() const;
private:
bool _internal_has_inverse() const;
public:
void clear_inverse();
bool inverse() const;
void set_inverse(bool value);
private:
bool _internal_inverse() const;
void _internal_set_inverse(bool value);
public:
// optional bool decolorize = 4 [default = false];
bool has_decolorize() const;
private:
bool _internal_has_decolorize() const;
public:
void clear_decolorize();
bool decolorize() const;
void set_decolorize(bool value);
private:
bool _internal_decolorize() const;
void _internal_set_decolorize(bool value);
public:
// optional bool gauss_blur = 5 [default = false];
bool has_gauss_blur() const;
private:
bool _internal_has_gauss_blur() const;
public:
void clear_gauss_blur();
bool gauss_blur() const;
void set_gauss_blur(bool value);
private:
bool _internal_gauss_blur() const;
void _internal_set_gauss_blur(bool value);
public:
// optional bool posterize = 7 [default = false];
bool has_posterize() const;
private:
bool _internal_has_posterize() const;
public:
void clear_posterize();
bool posterize() const;
void set_posterize(bool value);
private:
bool _internal_posterize() const;
void _internal_set_posterize(bool value);
public:
// optional bool erode = 8 [default = false];
bool has_erode() const;
private:
bool _internal_has_erode() const;
public:
void clear_erode();
bool erode() const;
void set_erode(bool value);
private:
bool _internal_erode() const;
void _internal_set_erode(bool value);
public:
// optional bool saltpepper = 9 [default = false];
bool has_saltpepper() const;
private:
bool _internal_has_saltpepper() const;
public:
void clear_saltpepper();
bool saltpepper() const;
void set_saltpepper(bool value);
private:
bool _internal_saltpepper() const;
void _internal_set_saltpepper(bool value);
public:
// optional bool clahe = 11 [default = false];
bool has_clahe() const;
private:
bool _internal_has_clahe() const;
public:
void clear_clahe();
bool clahe() const;
void set_clahe(bool value);
private:
bool _internal_clahe() const;
void _internal_set_clahe(bool value);
public:
// optional bool convert_to_hsv = 12 [default = false];
bool has_convert_to_hsv() const;
private:
bool _internal_has_convert_to_hsv() const;
public:
void clear_convert_to_hsv();
bool convert_to_hsv() const;
void set_convert_to_hsv(bool value);
private:
bool _internal_convert_to_hsv() const;
void _internal_set_convert_to_hsv(bool value);
public:
// optional bool convert_to_lab = 13 [default = false];
bool has_convert_to_lab() const;
private:
bool _internal_has_convert_to_lab() const;
public:
void clear_convert_to_lab();
bool convert_to_lab() const;
void set_convert_to_lab(bool value);
private:
bool _internal_convert_to_lab() const;
void _internal_set_convert_to_lab(bool value);
public:
// optional float jpeg = 6 [default = -1];
bool has_jpeg() const;
private:
bool _internal_has_jpeg() const;
public:
void clear_jpeg();
float jpeg() const;
void set_jpeg(float value);
private:
float _internal_jpeg() const;
void _internal_set_jpeg(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.NoiseParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::caffe::SaltPepperParameter* saltpepper_param_;
float prob_;
bool hist_eq_;
bool inverse_;
bool decolorize_;
bool gauss_blur_;
bool posterize_;
bool erode_;
bool saltpepper_;
bool clahe_;
bool convert_to_hsv_;
bool convert_to_lab_;
float jpeg_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class LossParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.LossParameter) */ {
public:
inline LossParameter() : LossParameter(nullptr) {}
virtual ~LossParameter();
LossParameter(const LossParameter& from);
LossParameter(LossParameter&& from) noexcept
: LossParameter() {
*this = ::std::move(from);
}
inline LossParameter& operator=(const LossParameter& from) {
CopyFrom(from);
return *this;
}
inline LossParameter& operator=(LossParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const LossParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const LossParameter* internal_default_instance() {
return reinterpret_cast<const LossParameter*>(
&_LossParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
26;
friend void swap(LossParameter& a, LossParameter& b) {
a.Swap(&b);
}
inline void Swap(LossParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(LossParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline LossParameter* New() const final {
return CreateMaybeMessage<LossParameter>(nullptr);
}
LossParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<LossParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const LossParameter& from);
void MergeFrom(const LossParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(LossParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.LossParameter";
}
protected:
explicit LossParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef LossParameter_NormalizationMode NormalizationMode;
static constexpr NormalizationMode FULL =
LossParameter_NormalizationMode_FULL;
static constexpr NormalizationMode VALID =
LossParameter_NormalizationMode_VALID;
static constexpr NormalizationMode BATCH_SIZE =
LossParameter_NormalizationMode_BATCH_SIZE;
static constexpr NormalizationMode NONE =
LossParameter_NormalizationMode_NONE;
static inline bool NormalizationMode_IsValid(int value) {
return LossParameter_NormalizationMode_IsValid(value);
}
static constexpr NormalizationMode NormalizationMode_MIN =
LossParameter_NormalizationMode_NormalizationMode_MIN;
static constexpr NormalizationMode NormalizationMode_MAX =
LossParameter_NormalizationMode_NormalizationMode_MAX;
static constexpr int NormalizationMode_ARRAYSIZE =
LossParameter_NormalizationMode_NormalizationMode_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
NormalizationMode_descriptor() {
return LossParameter_NormalizationMode_descriptor();
}
template<typename T>
static inline const std::string& NormalizationMode_Name(T enum_t_value) {
static_assert(::std::is_same<T, NormalizationMode>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function NormalizationMode_Name.");
return LossParameter_NormalizationMode_Name(enum_t_value);
}
static inline bool NormalizationMode_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
NormalizationMode* value) {
return LossParameter_NormalizationMode_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kIgnoreLabelFieldNumber = 1,
kNormalizeFieldNumber = 2,
kNormalizationFieldNumber = 3,
};
// optional int32 ignore_label = 1;
bool has_ignore_label() const;
private:
bool _internal_has_ignore_label() const;
public:
void clear_ignore_label();
::PROTOBUF_NAMESPACE_ID::int32 ignore_label() const;
void set_ignore_label(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_ignore_label() const;
void _internal_set_ignore_label(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional bool normalize = 2;
bool has_normalize() const;
private:
bool _internal_has_normalize() const;
public:
void clear_normalize();
bool normalize() const;
void set_normalize(bool value);
private:
bool _internal_normalize() const;
void _internal_set_normalize(bool value);
public:
// optional .caffe.LossParameter.NormalizationMode normalization = 3 [default = VALID];
bool has_normalization() const;
private:
bool _internal_has_normalization() const;
public:
void clear_normalization();
::caffe::LossParameter_NormalizationMode normalization() const;
void set_normalization(::caffe::LossParameter_NormalizationMode value);
private:
::caffe::LossParameter_NormalizationMode _internal_normalization() const;
void _internal_set_normalization(::caffe::LossParameter_NormalizationMode value);
public:
// @@protoc_insertion_point(class_scope:caffe.LossParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::int32 ignore_label_;
bool normalize_;
int normalization_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class AccuracyParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.AccuracyParameter) */ {
public:
inline AccuracyParameter() : AccuracyParameter(nullptr) {}
virtual ~AccuracyParameter();
AccuracyParameter(const AccuracyParameter& from);
AccuracyParameter(AccuracyParameter&& from) noexcept
: AccuracyParameter() {
*this = ::std::move(from);
}
inline AccuracyParameter& operator=(const AccuracyParameter& from) {
CopyFrom(from);
return *this;
}
inline AccuracyParameter& operator=(AccuracyParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const AccuracyParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const AccuracyParameter* internal_default_instance() {
return reinterpret_cast<const AccuracyParameter*>(
&_AccuracyParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
27;
friend void swap(AccuracyParameter& a, AccuracyParameter& b) {
a.Swap(&b);
}
inline void Swap(AccuracyParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(AccuracyParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline AccuracyParameter* New() const final {
return CreateMaybeMessage<AccuracyParameter>(nullptr);
}
AccuracyParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<AccuracyParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const AccuracyParameter& from);
void MergeFrom(const AccuracyParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(AccuracyParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.AccuracyParameter";
}
protected:
explicit AccuracyParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kIgnoreLabelFieldNumber = 3,
kTopKFieldNumber = 1,
kAxisFieldNumber = 2,
};
// optional int32 ignore_label = 3;
bool has_ignore_label() const;
private:
bool _internal_has_ignore_label() const;
public:
void clear_ignore_label();
::PROTOBUF_NAMESPACE_ID::int32 ignore_label() const;
void set_ignore_label(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_ignore_label() const;
void _internal_set_ignore_label(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional uint32 top_k = 1 [default = 1];
bool has_top_k() const;
private:
bool _internal_has_top_k() const;
public:
void clear_top_k();
::PROTOBUF_NAMESPACE_ID::uint32 top_k() const;
void set_top_k(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_top_k() const;
void _internal_set_top_k(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional int32 axis = 2 [default = 1];
bool has_axis() const;
private:
bool _internal_has_axis() const;
public:
void clear_axis();
::PROTOBUF_NAMESPACE_ID::int32 axis() const;
void set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_axis() const;
void _internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.AccuracyParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::int32 ignore_label_;
::PROTOBUF_NAMESPACE_ID::uint32 top_k_;
::PROTOBUF_NAMESPACE_ID::int32 axis_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class AnnotatedDataParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.AnnotatedDataParameter) */ {
public:
inline AnnotatedDataParameter() : AnnotatedDataParameter(nullptr) {}
virtual ~AnnotatedDataParameter();
AnnotatedDataParameter(const AnnotatedDataParameter& from);
AnnotatedDataParameter(AnnotatedDataParameter&& from) noexcept
: AnnotatedDataParameter() {
*this = ::std::move(from);
}
inline AnnotatedDataParameter& operator=(const AnnotatedDataParameter& from) {
CopyFrom(from);
return *this;
}
inline AnnotatedDataParameter& operator=(AnnotatedDataParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const AnnotatedDataParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const AnnotatedDataParameter* internal_default_instance() {
return reinterpret_cast<const AnnotatedDataParameter*>(
&_AnnotatedDataParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
28;
friend void swap(AnnotatedDataParameter& a, AnnotatedDataParameter& b) {
a.Swap(&b);
}
inline void Swap(AnnotatedDataParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(AnnotatedDataParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline AnnotatedDataParameter* New() const final {
return CreateMaybeMessage<AnnotatedDataParameter>(nullptr);
}
AnnotatedDataParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<AnnotatedDataParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const AnnotatedDataParameter& from);
void MergeFrom(const AnnotatedDataParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(AnnotatedDataParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.AnnotatedDataParameter";
}
protected:
explicit AnnotatedDataParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kBatchSamplerFieldNumber = 1,
kLabelMapFileFieldNumber = 2,
};
// repeated .caffe.BatchSampler batch_sampler = 1;
int batch_sampler_size() const;
private:
int _internal_batch_sampler_size() const;
public:
void clear_batch_sampler();
::caffe::BatchSampler* mutable_batch_sampler(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BatchSampler >*
mutable_batch_sampler();
private:
const ::caffe::BatchSampler& _internal_batch_sampler(int index) const;
::caffe::BatchSampler* _internal_add_batch_sampler();
public:
const ::caffe::BatchSampler& batch_sampler(int index) const;
::caffe::BatchSampler* add_batch_sampler();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BatchSampler >&
batch_sampler() const;
// optional string label_map_file = 2;
bool has_label_map_file() const;
private:
bool _internal_has_label_map_file() const;
public:
void clear_label_map_file();
const std::string& label_map_file() const;
void set_label_map_file(const std::string& value);
void set_label_map_file(std::string&& value);
void set_label_map_file(const char* value);
void set_label_map_file(const char* value, size_t size);
std::string* mutable_label_map_file();
std::string* release_label_map_file();
void set_allocated_label_map_file(std::string* label_map_file);
private:
const std::string& _internal_label_map_file() const;
void _internal_set_label_map_file(const std::string& value);
std::string* _internal_mutable_label_map_file();
public:
// @@protoc_insertion_point(class_scope:caffe.AnnotatedDataParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BatchSampler > batch_sampler_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr label_map_file_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class ArgMaxParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.ArgMaxParameter) */ {
public:
inline ArgMaxParameter() : ArgMaxParameter(nullptr) {}
virtual ~ArgMaxParameter();
ArgMaxParameter(const ArgMaxParameter& from);
ArgMaxParameter(ArgMaxParameter&& from) noexcept
: ArgMaxParameter() {
*this = ::std::move(from);
}
inline ArgMaxParameter& operator=(const ArgMaxParameter& from) {
CopyFrom(from);
return *this;
}
inline ArgMaxParameter& operator=(ArgMaxParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const ArgMaxParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const ArgMaxParameter* internal_default_instance() {
return reinterpret_cast<const ArgMaxParameter*>(
&_ArgMaxParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
29;
friend void swap(ArgMaxParameter& a, ArgMaxParameter& b) {
a.Swap(&b);
}
inline void Swap(ArgMaxParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(ArgMaxParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline ArgMaxParameter* New() const final {
return CreateMaybeMessage<ArgMaxParameter>(nullptr);
}
ArgMaxParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<ArgMaxParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const ArgMaxParameter& from);
void MergeFrom(const ArgMaxParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(ArgMaxParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.ArgMaxParameter";
}
protected:
explicit ArgMaxParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kOutMaxValFieldNumber = 1,
kAxisFieldNumber = 3,
kTopKFieldNumber = 2,
};
// optional bool out_max_val = 1 [default = false];
bool has_out_max_val() const;
private:
bool _internal_has_out_max_val() const;
public:
void clear_out_max_val();
bool out_max_val() const;
void set_out_max_val(bool value);
private:
bool _internal_out_max_val() const;
void _internal_set_out_max_val(bool value);
public:
// optional int32 axis = 3;
bool has_axis() const;
private:
bool _internal_has_axis() const;
public:
void clear_axis();
::PROTOBUF_NAMESPACE_ID::int32 axis() const;
void set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_axis() const;
void _internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional uint32 top_k = 2 [default = 1];
bool has_top_k() const;
private:
bool _internal_has_top_k() const;
public:
void clear_top_k();
::PROTOBUF_NAMESPACE_ID::uint32 top_k() const;
void set_top_k(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_top_k() const;
void _internal_set_top_k(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.ArgMaxParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
bool out_max_val_;
::PROTOBUF_NAMESPACE_ID::int32 axis_;
::PROTOBUF_NAMESPACE_ID::uint32 top_k_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class ConcatParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.ConcatParameter) */ {
public:
inline ConcatParameter() : ConcatParameter(nullptr) {}
virtual ~ConcatParameter();
ConcatParameter(const ConcatParameter& from);
ConcatParameter(ConcatParameter&& from) noexcept
: ConcatParameter() {
*this = ::std::move(from);
}
inline ConcatParameter& operator=(const ConcatParameter& from) {
CopyFrom(from);
return *this;
}
inline ConcatParameter& operator=(ConcatParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const ConcatParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const ConcatParameter* internal_default_instance() {
return reinterpret_cast<const ConcatParameter*>(
&_ConcatParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
30;
friend void swap(ConcatParameter& a, ConcatParameter& b) {
a.Swap(&b);
}
inline void Swap(ConcatParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(ConcatParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline ConcatParameter* New() const final {
return CreateMaybeMessage<ConcatParameter>(nullptr);
}
ConcatParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<ConcatParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const ConcatParameter& from);
void MergeFrom(const ConcatParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(ConcatParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.ConcatParameter";
}
protected:
explicit ConcatParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kConcatDimFieldNumber = 1,
kAxisFieldNumber = 2,
};
// optional uint32 concat_dim = 1 [default = 1];
bool has_concat_dim() const;
private:
bool _internal_has_concat_dim() const;
public:
void clear_concat_dim();
::PROTOBUF_NAMESPACE_ID::uint32 concat_dim() const;
void set_concat_dim(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_concat_dim() const;
void _internal_set_concat_dim(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional int32 axis = 2 [default = 1];
bool has_axis() const;
private:
bool _internal_has_axis() const;
public:
void clear_axis();
::PROTOBUF_NAMESPACE_ID::int32 axis() const;
void set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_axis() const;
void _internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.ConcatParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::uint32 concat_dim_;
::PROTOBUF_NAMESPACE_ID::int32 axis_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class BatchNormParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.BatchNormParameter) */ {
public:
inline BatchNormParameter() : BatchNormParameter(nullptr) {}
virtual ~BatchNormParameter();
BatchNormParameter(const BatchNormParameter& from);
BatchNormParameter(BatchNormParameter&& from) noexcept
: BatchNormParameter() {
*this = ::std::move(from);
}
inline BatchNormParameter& operator=(const BatchNormParameter& from) {
CopyFrom(from);
return *this;
}
inline BatchNormParameter& operator=(BatchNormParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const BatchNormParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const BatchNormParameter* internal_default_instance() {
return reinterpret_cast<const BatchNormParameter*>(
&_BatchNormParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
31;
friend void swap(BatchNormParameter& a, BatchNormParameter& b) {
a.Swap(&b);
}
inline void Swap(BatchNormParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(BatchNormParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline BatchNormParameter* New() const final {
return CreateMaybeMessage<BatchNormParameter>(nullptr);
}
BatchNormParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<BatchNormParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const BatchNormParameter& from);
void MergeFrom(const BatchNormParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(BatchNormParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.BatchNormParameter";
}
protected:
explicit BatchNormParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kUseGlobalStatsFieldNumber = 1,
kMovingAverageFractionFieldNumber = 2,
kEpsFieldNumber = 3,
};
// optional bool use_global_stats = 1;
bool has_use_global_stats() const;
private:
bool _internal_has_use_global_stats() const;
public:
void clear_use_global_stats();
bool use_global_stats() const;
void set_use_global_stats(bool value);
private:
bool _internal_use_global_stats() const;
void _internal_set_use_global_stats(bool value);
public:
// optional float moving_average_fraction = 2 [default = 0.999];
bool has_moving_average_fraction() const;
private:
bool _internal_has_moving_average_fraction() const;
public:
void clear_moving_average_fraction();
float moving_average_fraction() const;
void set_moving_average_fraction(float value);
private:
float _internal_moving_average_fraction() const;
void _internal_set_moving_average_fraction(float value);
public:
// optional float eps = 3 [default = 1e-05];
bool has_eps() const;
private:
bool _internal_has_eps() const;
public:
void clear_eps();
float eps() const;
void set_eps(float value);
private:
float _internal_eps() const;
void _internal_set_eps(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.BatchNormParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
bool use_global_stats_;
float moving_average_fraction_;
float eps_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class BiasParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.BiasParameter) */ {
public:
inline BiasParameter() : BiasParameter(nullptr) {}
virtual ~BiasParameter();
BiasParameter(const BiasParameter& from);
BiasParameter(BiasParameter&& from) noexcept
: BiasParameter() {
*this = ::std::move(from);
}
inline BiasParameter& operator=(const BiasParameter& from) {
CopyFrom(from);
return *this;
}
inline BiasParameter& operator=(BiasParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const BiasParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const BiasParameter* internal_default_instance() {
return reinterpret_cast<const BiasParameter*>(
&_BiasParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
32;
friend void swap(BiasParameter& a, BiasParameter& b) {
a.Swap(&b);
}
inline void Swap(BiasParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(BiasParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline BiasParameter* New() const final {
return CreateMaybeMessage<BiasParameter>(nullptr);
}
BiasParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<BiasParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const BiasParameter& from);
void MergeFrom(const BiasParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(BiasParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.BiasParameter";
}
protected:
explicit BiasParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kFillerFieldNumber = 3,
kAxisFieldNumber = 1,
kNumAxesFieldNumber = 2,
};
// optional .caffe.FillerParameter filler = 3;
bool has_filler() const;
private:
bool _internal_has_filler() const;
public:
void clear_filler();
const ::caffe::FillerParameter& filler() const;
::caffe::FillerParameter* release_filler();
::caffe::FillerParameter* mutable_filler();
void set_allocated_filler(::caffe::FillerParameter* filler);
private:
const ::caffe::FillerParameter& _internal_filler() const;
::caffe::FillerParameter* _internal_mutable_filler();
public:
void unsafe_arena_set_allocated_filler(
::caffe::FillerParameter* filler);
::caffe::FillerParameter* unsafe_arena_release_filler();
// optional int32 axis = 1 [default = 1];
bool has_axis() const;
private:
bool _internal_has_axis() const;
public:
void clear_axis();
::PROTOBUF_NAMESPACE_ID::int32 axis() const;
void set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_axis() const;
void _internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional int32 num_axes = 2 [default = 1];
bool has_num_axes() const;
private:
bool _internal_has_num_axes() const;
public:
void clear_num_axes();
::PROTOBUF_NAMESPACE_ID::int32 num_axes() const;
void set_num_axes(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_num_axes() const;
void _internal_set_num_axes(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.BiasParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::caffe::FillerParameter* filler_;
::PROTOBUF_NAMESPACE_ID::int32 axis_;
::PROTOBUF_NAMESPACE_ID::int32 num_axes_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class ContrastiveLossParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.ContrastiveLossParameter) */ {
public:
inline ContrastiveLossParameter() : ContrastiveLossParameter(nullptr) {}
virtual ~ContrastiveLossParameter();
ContrastiveLossParameter(const ContrastiveLossParameter& from);
ContrastiveLossParameter(ContrastiveLossParameter&& from) noexcept
: ContrastiveLossParameter() {
*this = ::std::move(from);
}
inline ContrastiveLossParameter& operator=(const ContrastiveLossParameter& from) {
CopyFrom(from);
return *this;
}
inline ContrastiveLossParameter& operator=(ContrastiveLossParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const ContrastiveLossParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const ContrastiveLossParameter* internal_default_instance() {
return reinterpret_cast<const ContrastiveLossParameter*>(
&_ContrastiveLossParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
33;
friend void swap(ContrastiveLossParameter& a, ContrastiveLossParameter& b) {
a.Swap(&b);
}
inline void Swap(ContrastiveLossParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(ContrastiveLossParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline ContrastiveLossParameter* New() const final {
return CreateMaybeMessage<ContrastiveLossParameter>(nullptr);
}
ContrastiveLossParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<ContrastiveLossParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const ContrastiveLossParameter& from);
void MergeFrom(const ContrastiveLossParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(ContrastiveLossParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.ContrastiveLossParameter";
}
protected:
explicit ContrastiveLossParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kLegacyVersionFieldNumber = 2,
kMarginFieldNumber = 1,
};
// optional bool legacy_version = 2 [default = false];
bool has_legacy_version() const;
private:
bool _internal_has_legacy_version() const;
public:
void clear_legacy_version();
bool legacy_version() const;
void set_legacy_version(bool value);
private:
bool _internal_legacy_version() const;
void _internal_set_legacy_version(bool value);
public:
// optional float margin = 1 [default = 1];
bool has_margin() const;
private:
bool _internal_has_margin() const;
public:
void clear_margin();
float margin() const;
void set_margin(float value);
private:
float _internal_margin() const;
void _internal_set_margin(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.ContrastiveLossParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
bool legacy_version_;
float margin_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class ConvolutionParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.ConvolutionParameter) */ {
public:
inline ConvolutionParameter() : ConvolutionParameter(nullptr) {}
virtual ~ConvolutionParameter();
ConvolutionParameter(const ConvolutionParameter& from);
ConvolutionParameter(ConvolutionParameter&& from) noexcept
: ConvolutionParameter() {
*this = ::std::move(from);
}
inline ConvolutionParameter& operator=(const ConvolutionParameter& from) {
CopyFrom(from);
return *this;
}
inline ConvolutionParameter& operator=(ConvolutionParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const ConvolutionParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const ConvolutionParameter* internal_default_instance() {
return reinterpret_cast<const ConvolutionParameter*>(
&_ConvolutionParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
34;
friend void swap(ConvolutionParameter& a, ConvolutionParameter& b) {
a.Swap(&b);
}
inline void Swap(ConvolutionParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(ConvolutionParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline ConvolutionParameter* New() const final {
return CreateMaybeMessage<ConvolutionParameter>(nullptr);
}
ConvolutionParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<ConvolutionParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const ConvolutionParameter& from);
void MergeFrom(const ConvolutionParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(ConvolutionParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.ConvolutionParameter";
}
protected:
explicit ConvolutionParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef ConvolutionParameter_Engine Engine;
static constexpr Engine DEFAULT =
ConvolutionParameter_Engine_DEFAULT;
static constexpr Engine CAFFE =
ConvolutionParameter_Engine_CAFFE;
static constexpr Engine CUDNN =
ConvolutionParameter_Engine_CUDNN;
static inline bool Engine_IsValid(int value) {
return ConvolutionParameter_Engine_IsValid(value);
}
static constexpr Engine Engine_MIN =
ConvolutionParameter_Engine_Engine_MIN;
static constexpr Engine Engine_MAX =
ConvolutionParameter_Engine_Engine_MAX;
static constexpr int Engine_ARRAYSIZE =
ConvolutionParameter_Engine_Engine_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
Engine_descriptor() {
return ConvolutionParameter_Engine_descriptor();
}
template<typename T>
static inline const std::string& Engine_Name(T enum_t_value) {
static_assert(::std::is_same<T, Engine>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function Engine_Name.");
return ConvolutionParameter_Engine_Name(enum_t_value);
}
static inline bool Engine_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
Engine* value) {
return ConvolutionParameter_Engine_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kPadFieldNumber = 3,
kKernelSizeFieldNumber = 4,
kStrideFieldNumber = 6,
kDilationFieldNumber = 18,
kWeightFillerFieldNumber = 7,
kBiasFillerFieldNumber = 8,
kNumOutputFieldNumber = 1,
kPadHFieldNumber = 9,
kPadWFieldNumber = 10,
kKernelHFieldNumber = 11,
kKernelWFieldNumber = 12,
kStrideHFieldNumber = 13,
kStrideWFieldNumber = 14,
kEngineFieldNumber = 15,
kForceNdIm2ColFieldNumber = 17,
kAxisFieldNumber = 16,
kBiasTermFieldNumber = 2,
kGroupFieldNumber = 5,
};
// repeated uint32 pad = 3;
int pad_size() const;
private:
int _internal_pad_size() const;
public:
void clear_pad();
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_pad(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
_internal_pad() const;
void _internal_add_pad(::PROTOBUF_NAMESPACE_ID::uint32 value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
_internal_mutable_pad();
public:
::PROTOBUF_NAMESPACE_ID::uint32 pad(int index) const;
void set_pad(int index, ::PROTOBUF_NAMESPACE_ID::uint32 value);
void add_pad(::PROTOBUF_NAMESPACE_ID::uint32 value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
pad() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
mutable_pad();
// repeated uint32 kernel_size = 4;
int kernel_size_size() const;
private:
int _internal_kernel_size_size() const;
public:
void clear_kernel_size();
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_kernel_size(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
_internal_kernel_size() const;
void _internal_add_kernel_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
_internal_mutable_kernel_size();
public:
::PROTOBUF_NAMESPACE_ID::uint32 kernel_size(int index) const;
void set_kernel_size(int index, ::PROTOBUF_NAMESPACE_ID::uint32 value);
void add_kernel_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
kernel_size() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
mutable_kernel_size();
// repeated uint32 stride = 6;
int stride_size() const;
private:
int _internal_stride_size() const;
public:
void clear_stride();
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_stride(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
_internal_stride() const;
void _internal_add_stride(::PROTOBUF_NAMESPACE_ID::uint32 value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
_internal_mutable_stride();
public:
::PROTOBUF_NAMESPACE_ID::uint32 stride(int index) const;
void set_stride(int index, ::PROTOBUF_NAMESPACE_ID::uint32 value);
void add_stride(::PROTOBUF_NAMESPACE_ID::uint32 value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
stride() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
mutable_stride();
// repeated uint32 dilation = 18;
int dilation_size() const;
private:
int _internal_dilation_size() const;
public:
void clear_dilation();
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_dilation(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
_internal_dilation() const;
void _internal_add_dilation(::PROTOBUF_NAMESPACE_ID::uint32 value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
_internal_mutable_dilation();
public:
::PROTOBUF_NAMESPACE_ID::uint32 dilation(int index) const;
void set_dilation(int index, ::PROTOBUF_NAMESPACE_ID::uint32 value);
void add_dilation(::PROTOBUF_NAMESPACE_ID::uint32 value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
dilation() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
mutable_dilation();
// optional .caffe.FillerParameter weight_filler = 7;
bool has_weight_filler() const;
private:
bool _internal_has_weight_filler() const;
public:
void clear_weight_filler();
const ::caffe::FillerParameter& weight_filler() const;
::caffe::FillerParameter* release_weight_filler();
::caffe::FillerParameter* mutable_weight_filler();
void set_allocated_weight_filler(::caffe::FillerParameter* weight_filler);
private:
const ::caffe::FillerParameter& _internal_weight_filler() const;
::caffe::FillerParameter* _internal_mutable_weight_filler();
public:
void unsafe_arena_set_allocated_weight_filler(
::caffe::FillerParameter* weight_filler);
::caffe::FillerParameter* unsafe_arena_release_weight_filler();
// optional .caffe.FillerParameter bias_filler = 8;
bool has_bias_filler() const;
private:
bool _internal_has_bias_filler() const;
public:
void clear_bias_filler();
const ::caffe::FillerParameter& bias_filler() const;
::caffe::FillerParameter* release_bias_filler();
::caffe::FillerParameter* mutable_bias_filler();
void set_allocated_bias_filler(::caffe::FillerParameter* bias_filler);
private:
const ::caffe::FillerParameter& _internal_bias_filler() const;
::caffe::FillerParameter* _internal_mutable_bias_filler();
public:
void unsafe_arena_set_allocated_bias_filler(
::caffe::FillerParameter* bias_filler);
::caffe::FillerParameter* unsafe_arena_release_bias_filler();
// optional uint32 num_output = 1;
bool has_num_output() const;
private:
bool _internal_has_num_output() const;
public:
void clear_num_output();
::PROTOBUF_NAMESPACE_ID::uint32 num_output() const;
void set_num_output(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_num_output() const;
void _internal_set_num_output(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 pad_h = 9 [default = 0];
bool has_pad_h() const;
private:
bool _internal_has_pad_h() const;
public:
void clear_pad_h();
::PROTOBUF_NAMESPACE_ID::uint32 pad_h() const;
void set_pad_h(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_pad_h() const;
void _internal_set_pad_h(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 pad_w = 10 [default = 0];
bool has_pad_w() const;
private:
bool _internal_has_pad_w() const;
public:
void clear_pad_w();
::PROTOBUF_NAMESPACE_ID::uint32 pad_w() const;
void set_pad_w(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_pad_w() const;
void _internal_set_pad_w(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 kernel_h = 11;
bool has_kernel_h() const;
private:
bool _internal_has_kernel_h() const;
public:
void clear_kernel_h();
::PROTOBUF_NAMESPACE_ID::uint32 kernel_h() const;
void set_kernel_h(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_kernel_h() const;
void _internal_set_kernel_h(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 kernel_w = 12;
bool has_kernel_w() const;
private:
bool _internal_has_kernel_w() const;
public:
void clear_kernel_w();
::PROTOBUF_NAMESPACE_ID::uint32 kernel_w() const;
void set_kernel_w(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_kernel_w() const;
void _internal_set_kernel_w(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 stride_h = 13;
bool has_stride_h() const;
private:
bool _internal_has_stride_h() const;
public:
void clear_stride_h();
::PROTOBUF_NAMESPACE_ID::uint32 stride_h() const;
void set_stride_h(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_stride_h() const;
void _internal_set_stride_h(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 stride_w = 14;
bool has_stride_w() const;
private:
bool _internal_has_stride_w() const;
public:
void clear_stride_w();
::PROTOBUF_NAMESPACE_ID::uint32 stride_w() const;
void set_stride_w(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_stride_w() const;
void _internal_set_stride_w(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional .caffe.ConvolutionParameter.Engine engine = 15 [default = DEFAULT];
bool has_engine() const;
private:
bool _internal_has_engine() const;
public:
void clear_engine();
::caffe::ConvolutionParameter_Engine engine() const;
void set_engine(::caffe::ConvolutionParameter_Engine value);
private:
::caffe::ConvolutionParameter_Engine _internal_engine() const;
void _internal_set_engine(::caffe::ConvolutionParameter_Engine value);
public:
// optional bool force_nd_im2col = 17 [default = false];
bool has_force_nd_im2col() const;
private:
bool _internal_has_force_nd_im2col() const;
public:
void clear_force_nd_im2col();
bool force_nd_im2col() const;
void set_force_nd_im2col(bool value);
private:
bool _internal_force_nd_im2col() const;
void _internal_set_force_nd_im2col(bool value);
public:
// optional int32 axis = 16 [default = 1];
bool has_axis() const;
private:
bool _internal_has_axis() const;
public:
void clear_axis();
::PROTOBUF_NAMESPACE_ID::int32 axis() const;
void set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_axis() const;
void _internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional bool bias_term = 2 [default = true];
bool has_bias_term() const;
private:
bool _internal_has_bias_term() const;
public:
void clear_bias_term();
bool bias_term() const;
void set_bias_term(bool value);
private:
bool _internal_bias_term() const;
void _internal_set_bias_term(bool value);
public:
// optional uint32 group = 5 [default = 1];
bool has_group() const;
private:
bool _internal_has_group() const;
public:
void clear_group();
::PROTOBUF_NAMESPACE_ID::uint32 group() const;
void set_group(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_group() const;
void _internal_set_group(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.ConvolutionParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 > pad_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 > kernel_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 > stride_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 > dilation_;
::caffe::FillerParameter* weight_filler_;
::caffe::FillerParameter* bias_filler_;
::PROTOBUF_NAMESPACE_ID::uint32 num_output_;
::PROTOBUF_NAMESPACE_ID::uint32 pad_h_;
::PROTOBUF_NAMESPACE_ID::uint32 pad_w_;
::PROTOBUF_NAMESPACE_ID::uint32 kernel_h_;
::PROTOBUF_NAMESPACE_ID::uint32 kernel_w_;
::PROTOBUF_NAMESPACE_ID::uint32 stride_h_;
::PROTOBUF_NAMESPACE_ID::uint32 stride_w_;
int engine_;
bool force_nd_im2col_;
::PROTOBUF_NAMESPACE_ID::int32 axis_;
bool bias_term_;
::PROTOBUF_NAMESPACE_ID::uint32 group_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class CropParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.CropParameter) */ {
public:
inline CropParameter() : CropParameter(nullptr) {}
virtual ~CropParameter();
CropParameter(const CropParameter& from);
CropParameter(CropParameter&& from) noexcept
: CropParameter() {
*this = ::std::move(from);
}
inline CropParameter& operator=(const CropParameter& from) {
CopyFrom(from);
return *this;
}
inline CropParameter& operator=(CropParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const CropParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const CropParameter* internal_default_instance() {
return reinterpret_cast<const CropParameter*>(
&_CropParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
35;
friend void swap(CropParameter& a, CropParameter& b) {
a.Swap(&b);
}
inline void Swap(CropParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(CropParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline CropParameter* New() const final {
return CreateMaybeMessage<CropParameter>(nullptr);
}
CropParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<CropParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const CropParameter& from);
void MergeFrom(const CropParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(CropParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.CropParameter";
}
protected:
explicit CropParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kOffsetFieldNumber = 2,
kAxisFieldNumber = 1,
};
// repeated uint32 offset = 2;
int offset_size() const;
private:
int _internal_offset_size() const;
public:
void clear_offset();
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_offset(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
_internal_offset() const;
void _internal_add_offset(::PROTOBUF_NAMESPACE_ID::uint32 value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
_internal_mutable_offset();
public:
::PROTOBUF_NAMESPACE_ID::uint32 offset(int index) const;
void set_offset(int index, ::PROTOBUF_NAMESPACE_ID::uint32 value);
void add_offset(::PROTOBUF_NAMESPACE_ID::uint32 value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
offset() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
mutable_offset();
// optional int32 axis = 1 [default = 2];
bool has_axis() const;
private:
bool _internal_has_axis() const;
public:
void clear_axis();
::PROTOBUF_NAMESPACE_ID::int32 axis() const;
void set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_axis() const;
void _internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.CropParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 > offset_;
::PROTOBUF_NAMESPACE_ID::int32 axis_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class DataParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.DataParameter) */ {
public:
inline DataParameter() : DataParameter(nullptr) {}
virtual ~DataParameter();
DataParameter(const DataParameter& from);
DataParameter(DataParameter&& from) noexcept
: DataParameter() {
*this = ::std::move(from);
}
inline DataParameter& operator=(const DataParameter& from) {
CopyFrom(from);
return *this;
}
inline DataParameter& operator=(DataParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const DataParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const DataParameter* internal_default_instance() {
return reinterpret_cast<const DataParameter*>(
&_DataParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
36;
friend void swap(DataParameter& a, DataParameter& b) {
a.Swap(&b);
}
inline void Swap(DataParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(DataParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline DataParameter* New() const final {
return CreateMaybeMessage<DataParameter>(nullptr);
}
DataParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<DataParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const DataParameter& from);
void MergeFrom(const DataParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(DataParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.DataParameter";
}
protected:
explicit DataParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef DataParameter_DB DB;
static constexpr DB LEVELDB =
DataParameter_DB_LEVELDB;
static constexpr DB LMDB =
DataParameter_DB_LMDB;
static inline bool DB_IsValid(int value) {
return DataParameter_DB_IsValid(value);
}
static constexpr DB DB_MIN =
DataParameter_DB_DB_MIN;
static constexpr DB DB_MAX =
DataParameter_DB_DB_MAX;
static constexpr int DB_ARRAYSIZE =
DataParameter_DB_DB_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
DB_descriptor() {
return DataParameter_DB_descriptor();
}
template<typename T>
static inline const std::string& DB_Name(T enum_t_value) {
static_assert(::std::is_same<T, DB>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function DB_Name.");
return DataParameter_DB_Name(enum_t_value);
}
static inline bool DB_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
DB* value) {
return DataParameter_DB_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kSourceFieldNumber = 1,
kMeanFileFieldNumber = 3,
kBatchSizeFieldNumber = 4,
kCropSizeFieldNumber = 5,
kRandSkipFieldNumber = 7,
kMirrorFieldNumber = 6,
kForceEncodedColorFieldNumber = 9,
kBackendFieldNumber = 8,
kScaleFieldNumber = 2,
kPrefetchFieldNumber = 10,
};
// optional string source = 1;
bool has_source() const;
private:
bool _internal_has_source() const;
public:
void clear_source();
const std::string& source() const;
void set_source(const std::string& value);
void set_source(std::string&& value);
void set_source(const char* value);
void set_source(const char* value, size_t size);
std::string* mutable_source();
std::string* release_source();
void set_allocated_source(std::string* source);
private:
const std::string& _internal_source() const;
void _internal_set_source(const std::string& value);
std::string* _internal_mutable_source();
public:
// optional string mean_file = 3;
bool has_mean_file() const;
private:
bool _internal_has_mean_file() const;
public:
void clear_mean_file();
const std::string& mean_file() const;
void set_mean_file(const std::string& value);
void set_mean_file(std::string&& value);
void set_mean_file(const char* value);
void set_mean_file(const char* value, size_t size);
std::string* mutable_mean_file();
std::string* release_mean_file();
void set_allocated_mean_file(std::string* mean_file);
private:
const std::string& _internal_mean_file() const;
void _internal_set_mean_file(const std::string& value);
std::string* _internal_mutable_mean_file();
public:
// optional uint32 batch_size = 4;
bool has_batch_size() const;
private:
bool _internal_has_batch_size() const;
public:
void clear_batch_size();
::PROTOBUF_NAMESPACE_ID::uint32 batch_size() const;
void set_batch_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_batch_size() const;
void _internal_set_batch_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 crop_size = 5 [default = 0];
bool has_crop_size() const;
private:
bool _internal_has_crop_size() const;
public:
void clear_crop_size();
::PROTOBUF_NAMESPACE_ID::uint32 crop_size() const;
void set_crop_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_crop_size() const;
void _internal_set_crop_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 rand_skip = 7 [default = 0];
bool has_rand_skip() const;
private:
bool _internal_has_rand_skip() const;
public:
void clear_rand_skip();
::PROTOBUF_NAMESPACE_ID::uint32 rand_skip() const;
void set_rand_skip(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_rand_skip() const;
void _internal_set_rand_skip(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional bool mirror = 6 [default = false];
bool has_mirror() const;
private:
bool _internal_has_mirror() const;
public:
void clear_mirror();
bool mirror() const;
void set_mirror(bool value);
private:
bool _internal_mirror() const;
void _internal_set_mirror(bool value);
public:
// optional bool force_encoded_color = 9 [default = false];
bool has_force_encoded_color() const;
private:
bool _internal_has_force_encoded_color() const;
public:
void clear_force_encoded_color();
bool force_encoded_color() const;
void set_force_encoded_color(bool value);
private:
bool _internal_force_encoded_color() const;
void _internal_set_force_encoded_color(bool value);
public:
// optional .caffe.DataParameter.DB backend = 8 [default = LEVELDB];
bool has_backend() const;
private:
bool _internal_has_backend() const;
public:
void clear_backend();
::caffe::DataParameter_DB backend() const;
void set_backend(::caffe::DataParameter_DB value);
private:
::caffe::DataParameter_DB _internal_backend() const;
void _internal_set_backend(::caffe::DataParameter_DB value);
public:
// optional float scale = 2 [default = 1];
bool has_scale() const;
private:
bool _internal_has_scale() const;
public:
void clear_scale();
float scale() const;
void set_scale(float value);
private:
float _internal_scale() const;
void _internal_set_scale(float value);
public:
// optional uint32 prefetch = 10 [default = 4];
bool has_prefetch() const;
private:
bool _internal_has_prefetch() const;
public:
void clear_prefetch();
::PROTOBUF_NAMESPACE_ID::uint32 prefetch() const;
void set_prefetch(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_prefetch() const;
void _internal_set_prefetch(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.DataParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr source_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr mean_file_;
::PROTOBUF_NAMESPACE_ID::uint32 batch_size_;
::PROTOBUF_NAMESPACE_ID::uint32 crop_size_;
::PROTOBUF_NAMESPACE_ID::uint32 rand_skip_;
bool mirror_;
bool force_encoded_color_;
int backend_;
float scale_;
::PROTOBUF_NAMESPACE_ID::uint32 prefetch_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class DetectionEvaluateParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.DetectionEvaluateParameter) */ {
public:
inline DetectionEvaluateParameter() : DetectionEvaluateParameter(nullptr) {}
virtual ~DetectionEvaluateParameter();
DetectionEvaluateParameter(const DetectionEvaluateParameter& from);
DetectionEvaluateParameter(DetectionEvaluateParameter&& from) noexcept
: DetectionEvaluateParameter() {
*this = ::std::move(from);
}
inline DetectionEvaluateParameter& operator=(const DetectionEvaluateParameter& from) {
CopyFrom(from);
return *this;
}
inline DetectionEvaluateParameter& operator=(DetectionEvaluateParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const DetectionEvaluateParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const DetectionEvaluateParameter* internal_default_instance() {
return reinterpret_cast<const DetectionEvaluateParameter*>(
&_DetectionEvaluateParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
37;
friend void swap(DetectionEvaluateParameter& a, DetectionEvaluateParameter& b) {
a.Swap(&b);
}
inline void Swap(DetectionEvaluateParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(DetectionEvaluateParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline DetectionEvaluateParameter* New() const final {
return CreateMaybeMessage<DetectionEvaluateParameter>(nullptr);
}
DetectionEvaluateParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<DetectionEvaluateParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const DetectionEvaluateParameter& from);
void MergeFrom(const DetectionEvaluateParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(DetectionEvaluateParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.DetectionEvaluateParameter";
}
protected:
explicit DetectionEvaluateParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kNameSizeFileFieldNumber = 5,
kNumClassesFieldNumber = 1,
kBackgroundLabelIdFieldNumber = 2,
kOverlapThresholdFieldNumber = 3,
kEvaluateDifficultGtFieldNumber = 4,
};
// optional string name_size_file = 5;
bool has_name_size_file() const;
private:
bool _internal_has_name_size_file() const;
public:
void clear_name_size_file();
const std::string& name_size_file() const;
void set_name_size_file(const std::string& value);
void set_name_size_file(std::string&& value);
void set_name_size_file(const char* value);
void set_name_size_file(const char* value, size_t size);
std::string* mutable_name_size_file();
std::string* release_name_size_file();
void set_allocated_name_size_file(std::string* name_size_file);
private:
const std::string& _internal_name_size_file() const;
void _internal_set_name_size_file(const std::string& value);
std::string* _internal_mutable_name_size_file();
public:
// optional uint32 num_classes = 1;
bool has_num_classes() const;
private:
bool _internal_has_num_classes() const;
public:
void clear_num_classes();
::PROTOBUF_NAMESPACE_ID::uint32 num_classes() const;
void set_num_classes(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_num_classes() const;
void _internal_set_num_classes(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 background_label_id = 2 [default = 0];
bool has_background_label_id() const;
private:
bool _internal_has_background_label_id() const;
public:
void clear_background_label_id();
::PROTOBUF_NAMESPACE_ID::uint32 background_label_id() const;
void set_background_label_id(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_background_label_id() const;
void _internal_set_background_label_id(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional float overlap_threshold = 3 [default = 0.5];
bool has_overlap_threshold() const;
private:
bool _internal_has_overlap_threshold() const;
public:
void clear_overlap_threshold();
float overlap_threshold() const;
void set_overlap_threshold(float value);
private:
float _internal_overlap_threshold() const;
void _internal_set_overlap_threshold(float value);
public:
// optional bool evaluate_difficult_gt = 4 [default = true];
bool has_evaluate_difficult_gt() const;
private:
bool _internal_has_evaluate_difficult_gt() const;
public:
void clear_evaluate_difficult_gt();
bool evaluate_difficult_gt() const;
void set_evaluate_difficult_gt(bool value);
private:
bool _internal_evaluate_difficult_gt() const;
void _internal_set_evaluate_difficult_gt(bool value);
public:
// @@protoc_insertion_point(class_scope:caffe.DetectionEvaluateParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr name_size_file_;
::PROTOBUF_NAMESPACE_ID::uint32 num_classes_;
::PROTOBUF_NAMESPACE_ID::uint32 background_label_id_;
float overlap_threshold_;
bool evaluate_difficult_gt_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class NonMaximumSuppressionParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.NonMaximumSuppressionParameter) */ {
public:
inline NonMaximumSuppressionParameter() : NonMaximumSuppressionParameter(nullptr) {}
virtual ~NonMaximumSuppressionParameter();
NonMaximumSuppressionParameter(const NonMaximumSuppressionParameter& from);
NonMaximumSuppressionParameter(NonMaximumSuppressionParameter&& from) noexcept
: NonMaximumSuppressionParameter() {
*this = ::std::move(from);
}
inline NonMaximumSuppressionParameter& operator=(const NonMaximumSuppressionParameter& from) {
CopyFrom(from);
return *this;
}
inline NonMaximumSuppressionParameter& operator=(NonMaximumSuppressionParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const NonMaximumSuppressionParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const NonMaximumSuppressionParameter* internal_default_instance() {
return reinterpret_cast<const NonMaximumSuppressionParameter*>(
&_NonMaximumSuppressionParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
38;
friend void swap(NonMaximumSuppressionParameter& a, NonMaximumSuppressionParameter& b) {
a.Swap(&b);
}
inline void Swap(NonMaximumSuppressionParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(NonMaximumSuppressionParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline NonMaximumSuppressionParameter* New() const final {
return CreateMaybeMessage<NonMaximumSuppressionParameter>(nullptr);
}
NonMaximumSuppressionParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<NonMaximumSuppressionParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const NonMaximumSuppressionParameter& from);
void MergeFrom(const NonMaximumSuppressionParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(NonMaximumSuppressionParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.NonMaximumSuppressionParameter";
}
protected:
explicit NonMaximumSuppressionParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kTopKFieldNumber = 2,
kNmsThresholdFieldNumber = 1,
};
// optional int32 top_k = 2;
bool has_top_k() const;
private:
bool _internal_has_top_k() const;
public:
void clear_top_k();
::PROTOBUF_NAMESPACE_ID::int32 top_k() const;
void set_top_k(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_top_k() const;
void _internal_set_top_k(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional float nms_threshold = 1 [default = 0.3];
bool has_nms_threshold() const;
private:
bool _internal_has_nms_threshold() const;
public:
void clear_nms_threshold();
float nms_threshold() const;
void set_nms_threshold(float value);
private:
float _internal_nms_threshold() const;
void _internal_set_nms_threshold(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.NonMaximumSuppressionParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::int32 top_k_;
float nms_threshold_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class SaveOutputParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.SaveOutputParameter) */ {
public:
inline SaveOutputParameter() : SaveOutputParameter(nullptr) {}
virtual ~SaveOutputParameter();
SaveOutputParameter(const SaveOutputParameter& from);
SaveOutputParameter(SaveOutputParameter&& from) noexcept
: SaveOutputParameter() {
*this = ::std::move(from);
}
inline SaveOutputParameter& operator=(const SaveOutputParameter& from) {
CopyFrom(from);
return *this;
}
inline SaveOutputParameter& operator=(SaveOutputParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const SaveOutputParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const SaveOutputParameter* internal_default_instance() {
return reinterpret_cast<const SaveOutputParameter*>(
&_SaveOutputParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
39;
friend void swap(SaveOutputParameter& a, SaveOutputParameter& b) {
a.Swap(&b);
}
inline void Swap(SaveOutputParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(SaveOutputParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline SaveOutputParameter* New() const final {
return CreateMaybeMessage<SaveOutputParameter>(nullptr);
}
SaveOutputParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<SaveOutputParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const SaveOutputParameter& from);
void MergeFrom(const SaveOutputParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(SaveOutputParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.SaveOutputParameter";
}
protected:
explicit SaveOutputParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kOutputDirectoryFieldNumber = 1,
kOutputNamePrefixFieldNumber = 2,
kOutputFormatFieldNumber = 3,
kLabelMapFileFieldNumber = 4,
kNameSizeFileFieldNumber = 5,
kNumTestImageFieldNumber = 6,
};
// optional string output_directory = 1;
bool has_output_directory() const;
private:
bool _internal_has_output_directory() const;
public:
void clear_output_directory();
const std::string& output_directory() const;
void set_output_directory(const std::string& value);
void set_output_directory(std::string&& value);
void set_output_directory(const char* value);
void set_output_directory(const char* value, size_t size);
std::string* mutable_output_directory();
std::string* release_output_directory();
void set_allocated_output_directory(std::string* output_directory);
private:
const std::string& _internal_output_directory() const;
void _internal_set_output_directory(const std::string& value);
std::string* _internal_mutable_output_directory();
public:
// optional string output_name_prefix = 2;
bool has_output_name_prefix() const;
private:
bool _internal_has_output_name_prefix() const;
public:
void clear_output_name_prefix();
const std::string& output_name_prefix() const;
void set_output_name_prefix(const std::string& value);
void set_output_name_prefix(std::string&& value);
void set_output_name_prefix(const char* value);
void set_output_name_prefix(const char* value, size_t size);
std::string* mutable_output_name_prefix();
std::string* release_output_name_prefix();
void set_allocated_output_name_prefix(std::string* output_name_prefix);
private:
const std::string& _internal_output_name_prefix() const;
void _internal_set_output_name_prefix(const std::string& value);
std::string* _internal_mutable_output_name_prefix();
public:
// optional string output_format = 3;
bool has_output_format() const;
private:
bool _internal_has_output_format() const;
public:
void clear_output_format();
const std::string& output_format() const;
void set_output_format(const std::string& value);
void set_output_format(std::string&& value);
void set_output_format(const char* value);
void set_output_format(const char* value, size_t size);
std::string* mutable_output_format();
std::string* release_output_format();
void set_allocated_output_format(std::string* output_format);
private:
const std::string& _internal_output_format() const;
void _internal_set_output_format(const std::string& value);
std::string* _internal_mutable_output_format();
public:
// optional string label_map_file = 4;
bool has_label_map_file() const;
private:
bool _internal_has_label_map_file() const;
public:
void clear_label_map_file();
const std::string& label_map_file() const;
void set_label_map_file(const std::string& value);
void set_label_map_file(std::string&& value);
void set_label_map_file(const char* value);
void set_label_map_file(const char* value, size_t size);
std::string* mutable_label_map_file();
std::string* release_label_map_file();
void set_allocated_label_map_file(std::string* label_map_file);
private:
const std::string& _internal_label_map_file() const;
void _internal_set_label_map_file(const std::string& value);
std::string* _internal_mutable_label_map_file();
public:
// optional string name_size_file = 5;
bool has_name_size_file() const;
private:
bool _internal_has_name_size_file() const;
public:
void clear_name_size_file();
const std::string& name_size_file() const;
void set_name_size_file(const std::string& value);
void set_name_size_file(std::string&& value);
void set_name_size_file(const char* value);
void set_name_size_file(const char* value, size_t size);
std::string* mutable_name_size_file();
std::string* release_name_size_file();
void set_allocated_name_size_file(std::string* name_size_file);
private:
const std::string& _internal_name_size_file() const;
void _internal_set_name_size_file(const std::string& value);
std::string* _internal_mutable_name_size_file();
public:
// optional uint32 num_test_image = 6;
bool has_num_test_image() const;
private:
bool _internal_has_num_test_image() const;
public:
void clear_num_test_image();
::PROTOBUF_NAMESPACE_ID::uint32 num_test_image() const;
void set_num_test_image(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_num_test_image() const;
void _internal_set_num_test_image(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.SaveOutputParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr output_directory_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr output_name_prefix_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr output_format_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr label_map_file_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr name_size_file_;
::PROTOBUF_NAMESPACE_ID::uint32 num_test_image_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class DetectionOutputParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.DetectionOutputParameter) */ {
public:
inline DetectionOutputParameter() : DetectionOutputParameter(nullptr) {}
virtual ~DetectionOutputParameter();
DetectionOutputParameter(const DetectionOutputParameter& from);
DetectionOutputParameter(DetectionOutputParameter&& from) noexcept
: DetectionOutputParameter() {
*this = ::std::move(from);
}
inline DetectionOutputParameter& operator=(const DetectionOutputParameter& from) {
CopyFrom(from);
return *this;
}
inline DetectionOutputParameter& operator=(DetectionOutputParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const DetectionOutputParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const DetectionOutputParameter* internal_default_instance() {
return reinterpret_cast<const DetectionOutputParameter*>(
&_DetectionOutputParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
40;
friend void swap(DetectionOutputParameter& a, DetectionOutputParameter& b) {
a.Swap(&b);
}
inline void Swap(DetectionOutputParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(DetectionOutputParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline DetectionOutputParameter* New() const final {
return CreateMaybeMessage<DetectionOutputParameter>(nullptr);
}
DetectionOutputParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<DetectionOutputParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const DetectionOutputParameter& from);
void MergeFrom(const DetectionOutputParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(DetectionOutputParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.DetectionOutputParameter";
}
protected:
explicit DetectionOutputParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kNmsParamFieldNumber = 4,
kSaveOutputParamFieldNumber = 5,
kNumClassesFieldNumber = 1,
kBackgroundLabelIdFieldNumber = 3,
kConfidenceThresholdFieldNumber = 9,
kVarianceEncodedInTargetFieldNumber = 8,
kVisualizeFieldNumber = 10,
kVisualizeThresholdFieldNumber = 11,
kKeepTopKFieldNumber = 7,
kShareLocationFieldNumber = 2,
kCodeTypeFieldNumber = 6,
};
// optional .caffe.NonMaximumSuppressionParameter nms_param = 4;
bool has_nms_param() const;
private:
bool _internal_has_nms_param() const;
public:
void clear_nms_param();
const ::caffe::NonMaximumSuppressionParameter& nms_param() const;
::caffe::NonMaximumSuppressionParameter* release_nms_param();
::caffe::NonMaximumSuppressionParameter* mutable_nms_param();
void set_allocated_nms_param(::caffe::NonMaximumSuppressionParameter* nms_param);
private:
const ::caffe::NonMaximumSuppressionParameter& _internal_nms_param() const;
::caffe::NonMaximumSuppressionParameter* _internal_mutable_nms_param();
public:
void unsafe_arena_set_allocated_nms_param(
::caffe::NonMaximumSuppressionParameter* nms_param);
::caffe::NonMaximumSuppressionParameter* unsafe_arena_release_nms_param();
// optional .caffe.SaveOutputParameter save_output_param = 5;
bool has_save_output_param() const;
private:
bool _internal_has_save_output_param() const;
public:
void clear_save_output_param();
const ::caffe::SaveOutputParameter& save_output_param() const;
::caffe::SaveOutputParameter* release_save_output_param();
::caffe::SaveOutputParameter* mutable_save_output_param();
void set_allocated_save_output_param(::caffe::SaveOutputParameter* save_output_param);
private:
const ::caffe::SaveOutputParameter& _internal_save_output_param() const;
::caffe::SaveOutputParameter* _internal_mutable_save_output_param();
public:
void unsafe_arena_set_allocated_save_output_param(
::caffe::SaveOutputParameter* save_output_param);
::caffe::SaveOutputParameter* unsafe_arena_release_save_output_param();
// optional uint32 num_classes = 1;
bool has_num_classes() const;
private:
bool _internal_has_num_classes() const;
public:
void clear_num_classes();
::PROTOBUF_NAMESPACE_ID::uint32 num_classes() const;
void set_num_classes(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_num_classes() const;
void _internal_set_num_classes(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional int32 background_label_id = 3 [default = 0];
bool has_background_label_id() const;
private:
bool _internal_has_background_label_id() const;
public:
void clear_background_label_id();
::PROTOBUF_NAMESPACE_ID::int32 background_label_id() const;
void set_background_label_id(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_background_label_id() const;
void _internal_set_background_label_id(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional float confidence_threshold = 9;
bool has_confidence_threshold() const;
private:
bool _internal_has_confidence_threshold() const;
public:
void clear_confidence_threshold();
float confidence_threshold() const;
void set_confidence_threshold(float value);
private:
float _internal_confidence_threshold() const;
void _internal_set_confidence_threshold(float value);
public:
// optional bool variance_encoded_in_target = 8 [default = false];
bool has_variance_encoded_in_target() const;
private:
bool _internal_has_variance_encoded_in_target() const;
public:
void clear_variance_encoded_in_target();
bool variance_encoded_in_target() const;
void set_variance_encoded_in_target(bool value);
private:
bool _internal_variance_encoded_in_target() const;
void _internal_set_variance_encoded_in_target(bool value);
public:
// optional bool visualize = 10 [default = false];
bool has_visualize() const;
private:
bool _internal_has_visualize() const;
public:
void clear_visualize();
bool visualize() const;
void set_visualize(bool value);
private:
bool _internal_visualize() const;
void _internal_set_visualize(bool value);
public:
// optional float visualize_threshold = 11;
bool has_visualize_threshold() const;
private:
bool _internal_has_visualize_threshold() const;
public:
void clear_visualize_threshold();
float visualize_threshold() const;
void set_visualize_threshold(float value);
private:
float _internal_visualize_threshold() const;
void _internal_set_visualize_threshold(float value);
public:
// optional int32 keep_top_k = 7 [default = -1];
bool has_keep_top_k() const;
private:
bool _internal_has_keep_top_k() const;
public:
void clear_keep_top_k();
::PROTOBUF_NAMESPACE_ID::int32 keep_top_k() const;
void set_keep_top_k(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_keep_top_k() const;
void _internal_set_keep_top_k(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional bool share_location = 2 [default = true];
bool has_share_location() const;
private:
bool _internal_has_share_location() const;
public:
void clear_share_location();
bool share_location() const;
void set_share_location(bool value);
private:
bool _internal_share_location() const;
void _internal_set_share_location(bool value);
public:
// optional .caffe.PriorBoxParameter.CodeType code_type = 6 [default = CORNER];
bool has_code_type() const;
private:
bool _internal_has_code_type() const;
public:
void clear_code_type();
::caffe::PriorBoxParameter_CodeType code_type() const;
void set_code_type(::caffe::PriorBoxParameter_CodeType value);
private:
::caffe::PriorBoxParameter_CodeType _internal_code_type() const;
void _internal_set_code_type(::caffe::PriorBoxParameter_CodeType value);
public:
// @@protoc_insertion_point(class_scope:caffe.DetectionOutputParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::caffe::NonMaximumSuppressionParameter* nms_param_;
::caffe::SaveOutputParameter* save_output_param_;
::PROTOBUF_NAMESPACE_ID::uint32 num_classes_;
::PROTOBUF_NAMESPACE_ID::int32 background_label_id_;
float confidence_threshold_;
bool variance_encoded_in_target_;
bool visualize_;
float visualize_threshold_;
::PROTOBUF_NAMESPACE_ID::int32 keep_top_k_;
bool share_location_;
int code_type_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class DropoutParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.DropoutParameter) */ {
public:
inline DropoutParameter() : DropoutParameter(nullptr) {}
virtual ~DropoutParameter();
DropoutParameter(const DropoutParameter& from);
DropoutParameter(DropoutParameter&& from) noexcept
: DropoutParameter() {
*this = ::std::move(from);
}
inline DropoutParameter& operator=(const DropoutParameter& from) {
CopyFrom(from);
return *this;
}
inline DropoutParameter& operator=(DropoutParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const DropoutParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const DropoutParameter* internal_default_instance() {
return reinterpret_cast<const DropoutParameter*>(
&_DropoutParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
41;
friend void swap(DropoutParameter& a, DropoutParameter& b) {
a.Swap(&b);
}
inline void Swap(DropoutParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(DropoutParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline DropoutParameter* New() const final {
return CreateMaybeMessage<DropoutParameter>(nullptr);
}
DropoutParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<DropoutParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const DropoutParameter& from);
void MergeFrom(const DropoutParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(DropoutParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.DropoutParameter";
}
protected:
explicit DropoutParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kDropoutRatioFieldNumber = 1,
kScaleTrainFieldNumber = 2,
};
// optional float dropout_ratio = 1 [default = 0.5];
bool has_dropout_ratio() const;
private:
bool _internal_has_dropout_ratio() const;
public:
void clear_dropout_ratio();
float dropout_ratio() const;
void set_dropout_ratio(float value);
private:
float _internal_dropout_ratio() const;
void _internal_set_dropout_ratio(float value);
public:
// optional bool scale_train = 2 [default = true];
bool has_scale_train() const;
private:
bool _internal_has_scale_train() const;
public:
void clear_scale_train();
bool scale_train() const;
void set_scale_train(bool value);
private:
bool _internal_scale_train() const;
void _internal_set_scale_train(bool value);
public:
// @@protoc_insertion_point(class_scope:caffe.DropoutParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
float dropout_ratio_;
bool scale_train_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class DummyDataParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.DummyDataParameter) */ {
public:
inline DummyDataParameter() : DummyDataParameter(nullptr) {}
virtual ~DummyDataParameter();
DummyDataParameter(const DummyDataParameter& from);
DummyDataParameter(DummyDataParameter&& from) noexcept
: DummyDataParameter() {
*this = ::std::move(from);
}
inline DummyDataParameter& operator=(const DummyDataParameter& from) {
CopyFrom(from);
return *this;
}
inline DummyDataParameter& operator=(DummyDataParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const DummyDataParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const DummyDataParameter* internal_default_instance() {
return reinterpret_cast<const DummyDataParameter*>(
&_DummyDataParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
42;
friend void swap(DummyDataParameter& a, DummyDataParameter& b) {
a.Swap(&b);
}
inline void Swap(DummyDataParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(DummyDataParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline DummyDataParameter* New() const final {
return CreateMaybeMessage<DummyDataParameter>(nullptr);
}
DummyDataParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<DummyDataParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const DummyDataParameter& from);
void MergeFrom(const DummyDataParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(DummyDataParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.DummyDataParameter";
}
protected:
explicit DummyDataParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kDataFillerFieldNumber = 1,
kNumFieldNumber = 2,
kChannelsFieldNumber = 3,
kHeightFieldNumber = 4,
kWidthFieldNumber = 5,
kShapeFieldNumber = 6,
};
// repeated .caffe.FillerParameter data_filler = 1;
int data_filler_size() const;
private:
int _internal_data_filler_size() const;
public:
void clear_data_filler();
::caffe::FillerParameter* mutable_data_filler(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::FillerParameter >*
mutable_data_filler();
private:
const ::caffe::FillerParameter& _internal_data_filler(int index) const;
::caffe::FillerParameter* _internal_add_data_filler();
public:
const ::caffe::FillerParameter& data_filler(int index) const;
::caffe::FillerParameter* add_data_filler();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::FillerParameter >&
data_filler() const;
// repeated uint32 num = 2;
int num_size() const;
private:
int _internal_num_size() const;
public:
void clear_num();
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_num(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
_internal_num() const;
void _internal_add_num(::PROTOBUF_NAMESPACE_ID::uint32 value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
_internal_mutable_num();
public:
::PROTOBUF_NAMESPACE_ID::uint32 num(int index) const;
void set_num(int index, ::PROTOBUF_NAMESPACE_ID::uint32 value);
void add_num(::PROTOBUF_NAMESPACE_ID::uint32 value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
num() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
mutable_num();
// repeated uint32 channels = 3;
int channels_size() const;
private:
int _internal_channels_size() const;
public:
void clear_channels();
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_channels(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
_internal_channels() const;
void _internal_add_channels(::PROTOBUF_NAMESPACE_ID::uint32 value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
_internal_mutable_channels();
public:
::PROTOBUF_NAMESPACE_ID::uint32 channels(int index) const;
void set_channels(int index, ::PROTOBUF_NAMESPACE_ID::uint32 value);
void add_channels(::PROTOBUF_NAMESPACE_ID::uint32 value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
channels() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
mutable_channels();
// repeated uint32 height = 4;
int height_size() const;
private:
int _internal_height_size() const;
public:
void clear_height();
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_height(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
_internal_height() const;
void _internal_add_height(::PROTOBUF_NAMESPACE_ID::uint32 value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
_internal_mutable_height();
public:
::PROTOBUF_NAMESPACE_ID::uint32 height(int index) const;
void set_height(int index, ::PROTOBUF_NAMESPACE_ID::uint32 value);
void add_height(::PROTOBUF_NAMESPACE_ID::uint32 value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
height() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
mutable_height();
// repeated uint32 width = 5;
int width_size() const;
private:
int _internal_width_size() const;
public:
void clear_width();
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_width(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
_internal_width() const;
void _internal_add_width(::PROTOBUF_NAMESPACE_ID::uint32 value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
_internal_mutable_width();
public:
::PROTOBUF_NAMESPACE_ID::uint32 width(int index) const;
void set_width(int index, ::PROTOBUF_NAMESPACE_ID::uint32 value);
void add_width(::PROTOBUF_NAMESPACE_ID::uint32 value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
width() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
mutable_width();
// repeated .caffe.BlobShape shape = 6;
int shape_size() const;
private:
int _internal_shape_size() const;
public:
void clear_shape();
::caffe::BlobShape* mutable_shape(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape >*
mutable_shape();
private:
const ::caffe::BlobShape& _internal_shape(int index) const;
::caffe::BlobShape* _internal_add_shape();
public:
const ::caffe::BlobShape& shape(int index) const;
::caffe::BlobShape* add_shape();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape >&
shape() const;
// @@protoc_insertion_point(class_scope:caffe.DummyDataParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::FillerParameter > data_filler_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 > num_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 > channels_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 > height_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 > width_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape > shape_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class EltwiseParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.EltwiseParameter) */ {
public:
inline EltwiseParameter() : EltwiseParameter(nullptr) {}
virtual ~EltwiseParameter();
EltwiseParameter(const EltwiseParameter& from);
EltwiseParameter(EltwiseParameter&& from) noexcept
: EltwiseParameter() {
*this = ::std::move(from);
}
inline EltwiseParameter& operator=(const EltwiseParameter& from) {
CopyFrom(from);
return *this;
}
inline EltwiseParameter& operator=(EltwiseParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const EltwiseParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const EltwiseParameter* internal_default_instance() {
return reinterpret_cast<const EltwiseParameter*>(
&_EltwiseParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
43;
friend void swap(EltwiseParameter& a, EltwiseParameter& b) {
a.Swap(&b);
}
inline void Swap(EltwiseParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(EltwiseParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline EltwiseParameter* New() const final {
return CreateMaybeMessage<EltwiseParameter>(nullptr);
}
EltwiseParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<EltwiseParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const EltwiseParameter& from);
void MergeFrom(const EltwiseParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(EltwiseParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.EltwiseParameter";
}
protected:
explicit EltwiseParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef EltwiseParameter_EltwiseOp EltwiseOp;
static constexpr EltwiseOp PROD =
EltwiseParameter_EltwiseOp_PROD;
static constexpr EltwiseOp SUM =
EltwiseParameter_EltwiseOp_SUM;
static constexpr EltwiseOp MAX =
EltwiseParameter_EltwiseOp_MAX;
static inline bool EltwiseOp_IsValid(int value) {
return EltwiseParameter_EltwiseOp_IsValid(value);
}
static constexpr EltwiseOp EltwiseOp_MIN =
EltwiseParameter_EltwiseOp_EltwiseOp_MIN;
static constexpr EltwiseOp EltwiseOp_MAX =
EltwiseParameter_EltwiseOp_EltwiseOp_MAX;
static constexpr int EltwiseOp_ARRAYSIZE =
EltwiseParameter_EltwiseOp_EltwiseOp_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
EltwiseOp_descriptor() {
return EltwiseParameter_EltwiseOp_descriptor();
}
template<typename T>
static inline const std::string& EltwiseOp_Name(T enum_t_value) {
static_assert(::std::is_same<T, EltwiseOp>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function EltwiseOp_Name.");
return EltwiseParameter_EltwiseOp_Name(enum_t_value);
}
static inline bool EltwiseOp_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
EltwiseOp* value) {
return EltwiseParameter_EltwiseOp_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kCoeffFieldNumber = 2,
kOperationFieldNumber = 1,
kStableProdGradFieldNumber = 3,
};
// repeated float coeff = 2;
int coeff_size() const;
private:
int _internal_coeff_size() const;
public:
void clear_coeff();
private:
float _internal_coeff(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
_internal_coeff() const;
void _internal_add_coeff(float value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
_internal_mutable_coeff();
public:
float coeff(int index) const;
void set_coeff(int index, float value);
void add_coeff(float value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
coeff() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
mutable_coeff();
// optional .caffe.EltwiseParameter.EltwiseOp operation = 1 [default = SUM];
bool has_operation() const;
private:
bool _internal_has_operation() const;
public:
void clear_operation();
::caffe::EltwiseParameter_EltwiseOp operation() const;
void set_operation(::caffe::EltwiseParameter_EltwiseOp value);
private:
::caffe::EltwiseParameter_EltwiseOp _internal_operation() const;
void _internal_set_operation(::caffe::EltwiseParameter_EltwiseOp value);
public:
// optional bool stable_prod_grad = 3 [default = true];
bool has_stable_prod_grad() const;
private:
bool _internal_has_stable_prod_grad() const;
public:
void clear_stable_prod_grad();
bool stable_prod_grad() const;
void set_stable_prod_grad(bool value);
private:
bool _internal_stable_prod_grad() const;
void _internal_set_stable_prod_grad(bool value);
public:
// @@protoc_insertion_point(class_scope:caffe.EltwiseParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float > coeff_;
int operation_;
bool stable_prod_grad_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class ELUParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.ELUParameter) */ {
public:
inline ELUParameter() : ELUParameter(nullptr) {}
virtual ~ELUParameter();
ELUParameter(const ELUParameter& from);
ELUParameter(ELUParameter&& from) noexcept
: ELUParameter() {
*this = ::std::move(from);
}
inline ELUParameter& operator=(const ELUParameter& from) {
CopyFrom(from);
return *this;
}
inline ELUParameter& operator=(ELUParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const ELUParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const ELUParameter* internal_default_instance() {
return reinterpret_cast<const ELUParameter*>(
&_ELUParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
44;
friend void swap(ELUParameter& a, ELUParameter& b) {
a.Swap(&b);
}
inline void Swap(ELUParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(ELUParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline ELUParameter* New() const final {
return CreateMaybeMessage<ELUParameter>(nullptr);
}
ELUParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<ELUParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const ELUParameter& from);
void MergeFrom(const ELUParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(ELUParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.ELUParameter";
}
protected:
explicit ELUParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kAlphaFieldNumber = 1,
};
// optional float alpha = 1 [default = 1];
bool has_alpha() const;
private:
bool _internal_has_alpha() const;
public:
void clear_alpha();
float alpha() const;
void set_alpha(float value);
private:
float _internal_alpha() const;
void _internal_set_alpha(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.ELUParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
float alpha_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class EmbedParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.EmbedParameter) */ {
public:
inline EmbedParameter() : EmbedParameter(nullptr) {}
virtual ~EmbedParameter();
EmbedParameter(const EmbedParameter& from);
EmbedParameter(EmbedParameter&& from) noexcept
: EmbedParameter() {
*this = ::std::move(from);
}
inline EmbedParameter& operator=(const EmbedParameter& from) {
CopyFrom(from);
return *this;
}
inline EmbedParameter& operator=(EmbedParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const EmbedParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const EmbedParameter* internal_default_instance() {
return reinterpret_cast<const EmbedParameter*>(
&_EmbedParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
45;
friend void swap(EmbedParameter& a, EmbedParameter& b) {
a.Swap(&b);
}
inline void Swap(EmbedParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(EmbedParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline EmbedParameter* New() const final {
return CreateMaybeMessage<EmbedParameter>(nullptr);
}
EmbedParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<EmbedParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const EmbedParameter& from);
void MergeFrom(const EmbedParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(EmbedParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.EmbedParameter";
}
protected:
explicit EmbedParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kWeightFillerFieldNumber = 4,
kBiasFillerFieldNumber = 5,
kNumOutputFieldNumber = 1,
kInputDimFieldNumber = 2,
kBiasTermFieldNumber = 3,
};
// optional .caffe.FillerParameter weight_filler = 4;
bool has_weight_filler() const;
private:
bool _internal_has_weight_filler() const;
public:
void clear_weight_filler();
const ::caffe::FillerParameter& weight_filler() const;
::caffe::FillerParameter* release_weight_filler();
::caffe::FillerParameter* mutable_weight_filler();
void set_allocated_weight_filler(::caffe::FillerParameter* weight_filler);
private:
const ::caffe::FillerParameter& _internal_weight_filler() const;
::caffe::FillerParameter* _internal_mutable_weight_filler();
public:
void unsafe_arena_set_allocated_weight_filler(
::caffe::FillerParameter* weight_filler);
::caffe::FillerParameter* unsafe_arena_release_weight_filler();
// optional .caffe.FillerParameter bias_filler = 5;
bool has_bias_filler() const;
private:
bool _internal_has_bias_filler() const;
public:
void clear_bias_filler();
const ::caffe::FillerParameter& bias_filler() const;
::caffe::FillerParameter* release_bias_filler();
::caffe::FillerParameter* mutable_bias_filler();
void set_allocated_bias_filler(::caffe::FillerParameter* bias_filler);
private:
const ::caffe::FillerParameter& _internal_bias_filler() const;
::caffe::FillerParameter* _internal_mutable_bias_filler();
public:
void unsafe_arena_set_allocated_bias_filler(
::caffe::FillerParameter* bias_filler);
::caffe::FillerParameter* unsafe_arena_release_bias_filler();
// optional uint32 num_output = 1;
bool has_num_output() const;
private:
bool _internal_has_num_output() const;
public:
void clear_num_output();
::PROTOBUF_NAMESPACE_ID::uint32 num_output() const;
void set_num_output(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_num_output() const;
void _internal_set_num_output(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 input_dim = 2;
bool has_input_dim() const;
private:
bool _internal_has_input_dim() const;
public:
void clear_input_dim();
::PROTOBUF_NAMESPACE_ID::uint32 input_dim() const;
void set_input_dim(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_input_dim() const;
void _internal_set_input_dim(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional bool bias_term = 3 [default = true];
bool has_bias_term() const;
private:
bool _internal_has_bias_term() const;
public:
void clear_bias_term();
bool bias_term() const;
void set_bias_term(bool value);
private:
bool _internal_bias_term() const;
void _internal_set_bias_term(bool value);
public:
// @@protoc_insertion_point(class_scope:caffe.EmbedParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::caffe::FillerParameter* weight_filler_;
::caffe::FillerParameter* bias_filler_;
::PROTOBUF_NAMESPACE_ID::uint32 num_output_;
::PROTOBUF_NAMESPACE_ID::uint32 input_dim_;
bool bias_term_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class ExpParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.ExpParameter) */ {
public:
inline ExpParameter() : ExpParameter(nullptr) {}
virtual ~ExpParameter();
ExpParameter(const ExpParameter& from);
ExpParameter(ExpParameter&& from) noexcept
: ExpParameter() {
*this = ::std::move(from);
}
inline ExpParameter& operator=(const ExpParameter& from) {
CopyFrom(from);
return *this;
}
inline ExpParameter& operator=(ExpParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const ExpParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const ExpParameter* internal_default_instance() {
return reinterpret_cast<const ExpParameter*>(
&_ExpParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
46;
friend void swap(ExpParameter& a, ExpParameter& b) {
a.Swap(&b);
}
inline void Swap(ExpParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(ExpParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline ExpParameter* New() const final {
return CreateMaybeMessage<ExpParameter>(nullptr);
}
ExpParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<ExpParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const ExpParameter& from);
void MergeFrom(const ExpParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(ExpParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.ExpParameter";
}
protected:
explicit ExpParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kShiftFieldNumber = 3,
kBaseFieldNumber = 1,
kScaleFieldNumber = 2,
};
// optional float shift = 3 [default = 0];
bool has_shift() const;
private:
bool _internal_has_shift() const;
public:
void clear_shift();
float shift() const;
void set_shift(float value);
private:
float _internal_shift() const;
void _internal_set_shift(float value);
public:
// optional float base = 1 [default = -1];
bool has_base() const;
private:
bool _internal_has_base() const;
public:
void clear_base();
float base() const;
void set_base(float value);
private:
float _internal_base() const;
void _internal_set_base(float value);
public:
// optional float scale = 2 [default = 1];
bool has_scale() const;
private:
bool _internal_has_scale() const;
public:
void clear_scale();
float scale() const;
void set_scale(float value);
private:
float _internal_scale() const;
void _internal_set_scale(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.ExpParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
float shift_;
float base_;
float scale_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class FlattenParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.FlattenParameter) */ {
public:
inline FlattenParameter() : FlattenParameter(nullptr) {}
virtual ~FlattenParameter();
FlattenParameter(const FlattenParameter& from);
FlattenParameter(FlattenParameter&& from) noexcept
: FlattenParameter() {
*this = ::std::move(from);
}
inline FlattenParameter& operator=(const FlattenParameter& from) {
CopyFrom(from);
return *this;
}
inline FlattenParameter& operator=(FlattenParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const FlattenParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const FlattenParameter* internal_default_instance() {
return reinterpret_cast<const FlattenParameter*>(
&_FlattenParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
47;
friend void swap(FlattenParameter& a, FlattenParameter& b) {
a.Swap(&b);
}
inline void Swap(FlattenParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(FlattenParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline FlattenParameter* New() const final {
return CreateMaybeMessage<FlattenParameter>(nullptr);
}
FlattenParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<FlattenParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const FlattenParameter& from);
void MergeFrom(const FlattenParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(FlattenParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.FlattenParameter";
}
protected:
explicit FlattenParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kAxisFieldNumber = 1,
kEndAxisFieldNumber = 2,
};
// optional int32 axis = 1 [default = 1];
bool has_axis() const;
private:
bool _internal_has_axis() const;
public:
void clear_axis();
::PROTOBUF_NAMESPACE_ID::int32 axis() const;
void set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_axis() const;
void _internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional int32 end_axis = 2 [default = -1];
bool has_end_axis() const;
private:
bool _internal_has_end_axis() const;
public:
void clear_end_axis();
::PROTOBUF_NAMESPACE_ID::int32 end_axis() const;
void set_end_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_end_axis() const;
void _internal_set_end_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.FlattenParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::int32 axis_;
::PROTOBUF_NAMESPACE_ID::int32 end_axis_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class HDF5DataParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.HDF5DataParameter) */ {
public:
inline HDF5DataParameter() : HDF5DataParameter(nullptr) {}
virtual ~HDF5DataParameter();
HDF5DataParameter(const HDF5DataParameter& from);
HDF5DataParameter(HDF5DataParameter&& from) noexcept
: HDF5DataParameter() {
*this = ::std::move(from);
}
inline HDF5DataParameter& operator=(const HDF5DataParameter& from) {
CopyFrom(from);
return *this;
}
inline HDF5DataParameter& operator=(HDF5DataParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const HDF5DataParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const HDF5DataParameter* internal_default_instance() {
return reinterpret_cast<const HDF5DataParameter*>(
&_HDF5DataParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
48;
friend void swap(HDF5DataParameter& a, HDF5DataParameter& b) {
a.Swap(&b);
}
inline void Swap(HDF5DataParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(HDF5DataParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline HDF5DataParameter* New() const final {
return CreateMaybeMessage<HDF5DataParameter>(nullptr);
}
HDF5DataParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<HDF5DataParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const HDF5DataParameter& from);
void MergeFrom(const HDF5DataParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(HDF5DataParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.HDF5DataParameter";
}
protected:
explicit HDF5DataParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kSourceFieldNumber = 1,
kBatchSizeFieldNumber = 2,
kShuffleFieldNumber = 3,
};
// optional string source = 1;
bool has_source() const;
private:
bool _internal_has_source() const;
public:
void clear_source();
const std::string& source() const;
void set_source(const std::string& value);
void set_source(std::string&& value);
void set_source(const char* value);
void set_source(const char* value, size_t size);
std::string* mutable_source();
std::string* release_source();
void set_allocated_source(std::string* source);
private:
const std::string& _internal_source() const;
void _internal_set_source(const std::string& value);
std::string* _internal_mutable_source();
public:
// optional uint32 batch_size = 2;
bool has_batch_size() const;
private:
bool _internal_has_batch_size() const;
public:
void clear_batch_size();
::PROTOBUF_NAMESPACE_ID::uint32 batch_size() const;
void set_batch_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_batch_size() const;
void _internal_set_batch_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional bool shuffle = 3 [default = false];
bool has_shuffle() const;
private:
bool _internal_has_shuffle() const;
public:
void clear_shuffle();
bool shuffle() const;
void set_shuffle(bool value);
private:
bool _internal_shuffle() const;
void _internal_set_shuffle(bool value);
public:
// @@protoc_insertion_point(class_scope:caffe.HDF5DataParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr source_;
::PROTOBUF_NAMESPACE_ID::uint32 batch_size_;
bool shuffle_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class HDF5OutputParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.HDF5OutputParameter) */ {
public:
inline HDF5OutputParameter() : HDF5OutputParameter(nullptr) {}
virtual ~HDF5OutputParameter();
HDF5OutputParameter(const HDF5OutputParameter& from);
HDF5OutputParameter(HDF5OutputParameter&& from) noexcept
: HDF5OutputParameter() {
*this = ::std::move(from);
}
inline HDF5OutputParameter& operator=(const HDF5OutputParameter& from) {
CopyFrom(from);
return *this;
}
inline HDF5OutputParameter& operator=(HDF5OutputParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const HDF5OutputParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const HDF5OutputParameter* internal_default_instance() {
return reinterpret_cast<const HDF5OutputParameter*>(
&_HDF5OutputParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
49;
friend void swap(HDF5OutputParameter& a, HDF5OutputParameter& b) {
a.Swap(&b);
}
inline void Swap(HDF5OutputParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(HDF5OutputParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline HDF5OutputParameter* New() const final {
return CreateMaybeMessage<HDF5OutputParameter>(nullptr);
}
HDF5OutputParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<HDF5OutputParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const HDF5OutputParameter& from);
void MergeFrom(const HDF5OutputParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(HDF5OutputParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.HDF5OutputParameter";
}
protected:
explicit HDF5OutputParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kFileNameFieldNumber = 1,
};
// optional string file_name = 1;
bool has_file_name() const;
private:
bool _internal_has_file_name() const;
public:
void clear_file_name();
const std::string& file_name() const;
void set_file_name(const std::string& value);
void set_file_name(std::string&& value);
void set_file_name(const char* value);
void set_file_name(const char* value, size_t size);
std::string* mutable_file_name();
std::string* release_file_name();
void set_allocated_file_name(std::string* file_name);
private:
const std::string& _internal_file_name() const;
void _internal_set_file_name(const std::string& value);
std::string* _internal_mutable_file_name();
public:
// @@protoc_insertion_point(class_scope:caffe.HDF5OutputParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr file_name_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class HingeLossParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.HingeLossParameter) */ {
public:
inline HingeLossParameter() : HingeLossParameter(nullptr) {}
virtual ~HingeLossParameter();
HingeLossParameter(const HingeLossParameter& from);
HingeLossParameter(HingeLossParameter&& from) noexcept
: HingeLossParameter() {
*this = ::std::move(from);
}
inline HingeLossParameter& operator=(const HingeLossParameter& from) {
CopyFrom(from);
return *this;
}
inline HingeLossParameter& operator=(HingeLossParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const HingeLossParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const HingeLossParameter* internal_default_instance() {
return reinterpret_cast<const HingeLossParameter*>(
&_HingeLossParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
50;
friend void swap(HingeLossParameter& a, HingeLossParameter& b) {
a.Swap(&b);
}
inline void Swap(HingeLossParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(HingeLossParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline HingeLossParameter* New() const final {
return CreateMaybeMessage<HingeLossParameter>(nullptr);
}
HingeLossParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<HingeLossParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const HingeLossParameter& from);
void MergeFrom(const HingeLossParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(HingeLossParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.HingeLossParameter";
}
protected:
explicit HingeLossParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef HingeLossParameter_Norm Norm;
static constexpr Norm L1 =
HingeLossParameter_Norm_L1;
static constexpr Norm L2 =
HingeLossParameter_Norm_L2;
static inline bool Norm_IsValid(int value) {
return HingeLossParameter_Norm_IsValid(value);
}
static constexpr Norm Norm_MIN =
HingeLossParameter_Norm_Norm_MIN;
static constexpr Norm Norm_MAX =
HingeLossParameter_Norm_Norm_MAX;
static constexpr int Norm_ARRAYSIZE =
HingeLossParameter_Norm_Norm_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
Norm_descriptor() {
return HingeLossParameter_Norm_descriptor();
}
template<typename T>
static inline const std::string& Norm_Name(T enum_t_value) {
static_assert(::std::is_same<T, Norm>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function Norm_Name.");
return HingeLossParameter_Norm_Name(enum_t_value);
}
static inline bool Norm_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
Norm* value) {
return HingeLossParameter_Norm_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kNormFieldNumber = 1,
};
// optional .caffe.HingeLossParameter.Norm norm = 1 [default = L1];
bool has_norm() const;
private:
bool _internal_has_norm() const;
public:
void clear_norm();
::caffe::HingeLossParameter_Norm norm() const;
void set_norm(::caffe::HingeLossParameter_Norm value);
private:
::caffe::HingeLossParameter_Norm _internal_norm() const;
void _internal_set_norm(::caffe::HingeLossParameter_Norm value);
public:
// @@protoc_insertion_point(class_scope:caffe.HingeLossParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
int norm_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class ImageDataParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.ImageDataParameter) */ {
public:
inline ImageDataParameter() : ImageDataParameter(nullptr) {}
virtual ~ImageDataParameter();
ImageDataParameter(const ImageDataParameter& from);
ImageDataParameter(ImageDataParameter&& from) noexcept
: ImageDataParameter() {
*this = ::std::move(from);
}
inline ImageDataParameter& operator=(const ImageDataParameter& from) {
CopyFrom(from);
return *this;
}
inline ImageDataParameter& operator=(ImageDataParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const ImageDataParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const ImageDataParameter* internal_default_instance() {
return reinterpret_cast<const ImageDataParameter*>(
&_ImageDataParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
51;
friend void swap(ImageDataParameter& a, ImageDataParameter& b) {
a.Swap(&b);
}
inline void Swap(ImageDataParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(ImageDataParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline ImageDataParameter* New() const final {
return CreateMaybeMessage<ImageDataParameter>(nullptr);
}
ImageDataParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<ImageDataParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const ImageDataParameter& from);
void MergeFrom(const ImageDataParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(ImageDataParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.ImageDataParameter";
}
protected:
explicit ImageDataParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kSourceFieldNumber = 1,
kMeanFileFieldNumber = 3,
kRootFolderFieldNumber = 12,
kCropSizeFieldNumber = 5,
kRandSkipFieldNumber = 7,
kShuffleFieldNumber = 8,
kMirrorFieldNumber = 6,
kNewHeightFieldNumber = 9,
kNewWidthFieldNumber = 10,
kIsColorFieldNumber = 11,
kScaleFieldNumber = 2,
kBatchSizeFieldNumber = 4,
};
// optional string source = 1;
bool has_source() const;
private:
bool _internal_has_source() const;
public:
void clear_source();
const std::string& source() const;
void set_source(const std::string& value);
void set_source(std::string&& value);
void set_source(const char* value);
void set_source(const char* value, size_t size);
std::string* mutable_source();
std::string* release_source();
void set_allocated_source(std::string* source);
private:
const std::string& _internal_source() const;
void _internal_set_source(const std::string& value);
std::string* _internal_mutable_source();
public:
// optional string mean_file = 3;
bool has_mean_file() const;
private:
bool _internal_has_mean_file() const;
public:
void clear_mean_file();
const std::string& mean_file() const;
void set_mean_file(const std::string& value);
void set_mean_file(std::string&& value);
void set_mean_file(const char* value);
void set_mean_file(const char* value, size_t size);
std::string* mutable_mean_file();
std::string* release_mean_file();
void set_allocated_mean_file(std::string* mean_file);
private:
const std::string& _internal_mean_file() const;
void _internal_set_mean_file(const std::string& value);
std::string* _internal_mutable_mean_file();
public:
// optional string root_folder = 12 [default = ""];
bool has_root_folder() const;
private:
bool _internal_has_root_folder() const;
public:
void clear_root_folder();
const std::string& root_folder() const;
void set_root_folder(const std::string& value);
void set_root_folder(std::string&& value);
void set_root_folder(const char* value);
void set_root_folder(const char* value, size_t size);
std::string* mutable_root_folder();
std::string* release_root_folder();
void set_allocated_root_folder(std::string* root_folder);
private:
const std::string& _internal_root_folder() const;
void _internal_set_root_folder(const std::string& value);
std::string* _internal_mutable_root_folder();
public:
// optional uint32 crop_size = 5 [default = 0];
bool has_crop_size() const;
private:
bool _internal_has_crop_size() const;
public:
void clear_crop_size();
::PROTOBUF_NAMESPACE_ID::uint32 crop_size() const;
void set_crop_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_crop_size() const;
void _internal_set_crop_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 rand_skip = 7 [default = 0];
bool has_rand_skip() const;
private:
bool _internal_has_rand_skip() const;
public:
void clear_rand_skip();
::PROTOBUF_NAMESPACE_ID::uint32 rand_skip() const;
void set_rand_skip(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_rand_skip() const;
void _internal_set_rand_skip(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional bool shuffle = 8 [default = false];
bool has_shuffle() const;
private:
bool _internal_has_shuffle() const;
public:
void clear_shuffle();
bool shuffle() const;
void set_shuffle(bool value);
private:
bool _internal_shuffle() const;
void _internal_set_shuffle(bool value);
public:
// optional bool mirror = 6 [default = false];
bool has_mirror() const;
private:
bool _internal_has_mirror() const;
public:
void clear_mirror();
bool mirror() const;
void set_mirror(bool value);
private:
bool _internal_mirror() const;
void _internal_set_mirror(bool value);
public:
// optional uint32 new_height = 9 [default = 0];
bool has_new_height() const;
private:
bool _internal_has_new_height() const;
public:
void clear_new_height();
::PROTOBUF_NAMESPACE_ID::uint32 new_height() const;
void set_new_height(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_new_height() const;
void _internal_set_new_height(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 new_width = 10 [default = 0];
bool has_new_width() const;
private:
bool _internal_has_new_width() const;
public:
void clear_new_width();
::PROTOBUF_NAMESPACE_ID::uint32 new_width() const;
void set_new_width(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_new_width() const;
void _internal_set_new_width(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional bool is_color = 11 [default = true];
bool has_is_color() const;
private:
bool _internal_has_is_color() const;
public:
void clear_is_color();
bool is_color() const;
void set_is_color(bool value);
private:
bool _internal_is_color() const;
void _internal_set_is_color(bool value);
public:
// optional float scale = 2 [default = 1];
bool has_scale() const;
private:
bool _internal_has_scale() const;
public:
void clear_scale();
float scale() const;
void set_scale(float value);
private:
float _internal_scale() const;
void _internal_set_scale(float value);
public:
// optional uint32 batch_size = 4 [default = 1];
bool has_batch_size() const;
private:
bool _internal_has_batch_size() const;
public:
void clear_batch_size();
::PROTOBUF_NAMESPACE_ID::uint32 batch_size() const;
void set_batch_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_batch_size() const;
void _internal_set_batch_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.ImageDataParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr source_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr mean_file_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr root_folder_;
::PROTOBUF_NAMESPACE_ID::uint32 crop_size_;
::PROTOBUF_NAMESPACE_ID::uint32 rand_skip_;
bool shuffle_;
bool mirror_;
::PROTOBUF_NAMESPACE_ID::uint32 new_height_;
::PROTOBUF_NAMESPACE_ID::uint32 new_width_;
bool is_color_;
float scale_;
::PROTOBUF_NAMESPACE_ID::uint32 batch_size_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class InfogainLossParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.InfogainLossParameter) */ {
public:
inline InfogainLossParameter() : InfogainLossParameter(nullptr) {}
virtual ~InfogainLossParameter();
InfogainLossParameter(const InfogainLossParameter& from);
InfogainLossParameter(InfogainLossParameter&& from) noexcept
: InfogainLossParameter() {
*this = ::std::move(from);
}
inline InfogainLossParameter& operator=(const InfogainLossParameter& from) {
CopyFrom(from);
return *this;
}
inline InfogainLossParameter& operator=(InfogainLossParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const InfogainLossParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const InfogainLossParameter* internal_default_instance() {
return reinterpret_cast<const InfogainLossParameter*>(
&_InfogainLossParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
52;
friend void swap(InfogainLossParameter& a, InfogainLossParameter& b) {
a.Swap(&b);
}
inline void Swap(InfogainLossParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(InfogainLossParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline InfogainLossParameter* New() const final {
return CreateMaybeMessage<InfogainLossParameter>(nullptr);
}
InfogainLossParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<InfogainLossParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const InfogainLossParameter& from);
void MergeFrom(const InfogainLossParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(InfogainLossParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.InfogainLossParameter";
}
protected:
explicit InfogainLossParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kSourceFieldNumber = 1,
};
// optional string source = 1;
bool has_source() const;
private:
bool _internal_has_source() const;
public:
void clear_source();
const std::string& source() const;
void set_source(const std::string& value);
void set_source(std::string&& value);
void set_source(const char* value);
void set_source(const char* value, size_t size);
std::string* mutable_source();
std::string* release_source();
void set_allocated_source(std::string* source);
private:
const std::string& _internal_source() const;
void _internal_set_source(const std::string& value);
std::string* _internal_mutable_source();
public:
// @@protoc_insertion_point(class_scope:caffe.InfogainLossParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr source_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class InnerProductParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.InnerProductParameter) */ {
public:
inline InnerProductParameter() : InnerProductParameter(nullptr) {}
virtual ~InnerProductParameter();
InnerProductParameter(const InnerProductParameter& from);
InnerProductParameter(InnerProductParameter&& from) noexcept
: InnerProductParameter() {
*this = ::std::move(from);
}
inline InnerProductParameter& operator=(const InnerProductParameter& from) {
CopyFrom(from);
return *this;
}
inline InnerProductParameter& operator=(InnerProductParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const InnerProductParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const InnerProductParameter* internal_default_instance() {
return reinterpret_cast<const InnerProductParameter*>(
&_InnerProductParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
53;
friend void swap(InnerProductParameter& a, InnerProductParameter& b) {
a.Swap(&b);
}
inline void Swap(InnerProductParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(InnerProductParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline InnerProductParameter* New() const final {
return CreateMaybeMessage<InnerProductParameter>(nullptr);
}
InnerProductParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<InnerProductParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const InnerProductParameter& from);
void MergeFrom(const InnerProductParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(InnerProductParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.InnerProductParameter";
}
protected:
explicit InnerProductParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kWeightFillerFieldNumber = 3,
kBiasFillerFieldNumber = 4,
kNumOutputFieldNumber = 1,
kTransposeFieldNumber = 6,
kBiasTermFieldNumber = 2,
kAxisFieldNumber = 5,
};
// optional .caffe.FillerParameter weight_filler = 3;
bool has_weight_filler() const;
private:
bool _internal_has_weight_filler() const;
public:
void clear_weight_filler();
const ::caffe::FillerParameter& weight_filler() const;
::caffe::FillerParameter* release_weight_filler();
::caffe::FillerParameter* mutable_weight_filler();
void set_allocated_weight_filler(::caffe::FillerParameter* weight_filler);
private:
const ::caffe::FillerParameter& _internal_weight_filler() const;
::caffe::FillerParameter* _internal_mutable_weight_filler();
public:
void unsafe_arena_set_allocated_weight_filler(
::caffe::FillerParameter* weight_filler);
::caffe::FillerParameter* unsafe_arena_release_weight_filler();
// optional .caffe.FillerParameter bias_filler = 4;
bool has_bias_filler() const;
private:
bool _internal_has_bias_filler() const;
public:
void clear_bias_filler();
const ::caffe::FillerParameter& bias_filler() const;
::caffe::FillerParameter* release_bias_filler();
::caffe::FillerParameter* mutable_bias_filler();
void set_allocated_bias_filler(::caffe::FillerParameter* bias_filler);
private:
const ::caffe::FillerParameter& _internal_bias_filler() const;
::caffe::FillerParameter* _internal_mutable_bias_filler();
public:
void unsafe_arena_set_allocated_bias_filler(
::caffe::FillerParameter* bias_filler);
::caffe::FillerParameter* unsafe_arena_release_bias_filler();
// optional uint32 num_output = 1;
bool has_num_output() const;
private:
bool _internal_has_num_output() const;
public:
void clear_num_output();
::PROTOBUF_NAMESPACE_ID::uint32 num_output() const;
void set_num_output(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_num_output() const;
void _internal_set_num_output(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional bool transpose = 6 [default = false];
bool has_transpose() const;
private:
bool _internal_has_transpose() const;
public:
void clear_transpose();
bool transpose() const;
void set_transpose(bool value);
private:
bool _internal_transpose() const;
void _internal_set_transpose(bool value);
public:
// optional bool bias_term = 2 [default = true];
bool has_bias_term() const;
private:
bool _internal_has_bias_term() const;
public:
void clear_bias_term();
bool bias_term() const;
void set_bias_term(bool value);
private:
bool _internal_bias_term() const;
void _internal_set_bias_term(bool value);
public:
// optional int32 axis = 5 [default = 1];
bool has_axis() const;
private:
bool _internal_has_axis() const;
public:
void clear_axis();
::PROTOBUF_NAMESPACE_ID::int32 axis() const;
void set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_axis() const;
void _internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.InnerProductParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::caffe::FillerParameter* weight_filler_;
::caffe::FillerParameter* bias_filler_;
::PROTOBUF_NAMESPACE_ID::uint32 num_output_;
bool transpose_;
bool bias_term_;
::PROTOBUF_NAMESPACE_ID::int32 axis_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class InputParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.InputParameter) */ {
public:
inline InputParameter() : InputParameter(nullptr) {}
virtual ~InputParameter();
InputParameter(const InputParameter& from);
InputParameter(InputParameter&& from) noexcept
: InputParameter() {
*this = ::std::move(from);
}
inline InputParameter& operator=(const InputParameter& from) {
CopyFrom(from);
return *this;
}
inline InputParameter& operator=(InputParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const InputParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const InputParameter* internal_default_instance() {
return reinterpret_cast<const InputParameter*>(
&_InputParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
54;
friend void swap(InputParameter& a, InputParameter& b) {
a.Swap(&b);
}
inline void Swap(InputParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(InputParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline InputParameter* New() const final {
return CreateMaybeMessage<InputParameter>(nullptr);
}
InputParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<InputParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const InputParameter& from);
void MergeFrom(const InputParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(InputParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.InputParameter";
}
protected:
explicit InputParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kShapeFieldNumber = 1,
};
// repeated .caffe.BlobShape shape = 1;
int shape_size() const;
private:
int _internal_shape_size() const;
public:
void clear_shape();
::caffe::BlobShape* mutable_shape(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape >*
mutable_shape();
private:
const ::caffe::BlobShape& _internal_shape(int index) const;
::caffe::BlobShape* _internal_add_shape();
public:
const ::caffe::BlobShape& shape(int index) const;
::caffe::BlobShape* add_shape();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape >&
shape() const;
// @@protoc_insertion_point(class_scope:caffe.InputParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape > shape_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class LogParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.LogParameter) */ {
public:
inline LogParameter() : LogParameter(nullptr) {}
virtual ~LogParameter();
LogParameter(const LogParameter& from);
LogParameter(LogParameter&& from) noexcept
: LogParameter() {
*this = ::std::move(from);
}
inline LogParameter& operator=(const LogParameter& from) {
CopyFrom(from);
return *this;
}
inline LogParameter& operator=(LogParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const LogParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const LogParameter* internal_default_instance() {
return reinterpret_cast<const LogParameter*>(
&_LogParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
55;
friend void swap(LogParameter& a, LogParameter& b) {
a.Swap(&b);
}
inline void Swap(LogParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(LogParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline LogParameter* New() const final {
return CreateMaybeMessage<LogParameter>(nullptr);
}
LogParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<LogParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const LogParameter& from);
void MergeFrom(const LogParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(LogParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.LogParameter";
}
protected:
explicit LogParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kShiftFieldNumber = 3,
kBaseFieldNumber = 1,
kScaleFieldNumber = 2,
};
// optional float shift = 3 [default = 0];
bool has_shift() const;
private:
bool _internal_has_shift() const;
public:
void clear_shift();
float shift() const;
void set_shift(float value);
private:
float _internal_shift() const;
void _internal_set_shift(float value);
public:
// optional float base = 1 [default = -1];
bool has_base() const;
private:
bool _internal_has_base() const;
public:
void clear_base();
float base() const;
void set_base(float value);
private:
float _internal_base() const;
void _internal_set_base(float value);
public:
// optional float scale = 2 [default = 1];
bool has_scale() const;
private:
bool _internal_has_scale() const;
public:
void clear_scale();
float scale() const;
void set_scale(float value);
private:
float _internal_scale() const;
void _internal_set_scale(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.LogParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
float shift_;
float base_;
float scale_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class LRNParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.LRNParameter) */ {
public:
inline LRNParameter() : LRNParameter(nullptr) {}
virtual ~LRNParameter();
LRNParameter(const LRNParameter& from);
LRNParameter(LRNParameter&& from) noexcept
: LRNParameter() {
*this = ::std::move(from);
}
inline LRNParameter& operator=(const LRNParameter& from) {
CopyFrom(from);
return *this;
}
inline LRNParameter& operator=(LRNParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const LRNParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const LRNParameter* internal_default_instance() {
return reinterpret_cast<const LRNParameter*>(
&_LRNParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
56;
friend void swap(LRNParameter& a, LRNParameter& b) {
a.Swap(&b);
}
inline void Swap(LRNParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(LRNParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline LRNParameter* New() const final {
return CreateMaybeMessage<LRNParameter>(nullptr);
}
LRNParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<LRNParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const LRNParameter& from);
void MergeFrom(const LRNParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(LRNParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.LRNParameter";
}
protected:
explicit LRNParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef LRNParameter_NormRegion NormRegion;
static constexpr NormRegion ACROSS_CHANNELS =
LRNParameter_NormRegion_ACROSS_CHANNELS;
static constexpr NormRegion WITHIN_CHANNEL =
LRNParameter_NormRegion_WITHIN_CHANNEL;
static inline bool NormRegion_IsValid(int value) {
return LRNParameter_NormRegion_IsValid(value);
}
static constexpr NormRegion NormRegion_MIN =
LRNParameter_NormRegion_NormRegion_MIN;
static constexpr NormRegion NormRegion_MAX =
LRNParameter_NormRegion_NormRegion_MAX;
static constexpr int NormRegion_ARRAYSIZE =
LRNParameter_NormRegion_NormRegion_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
NormRegion_descriptor() {
return LRNParameter_NormRegion_descriptor();
}
template<typename T>
static inline const std::string& NormRegion_Name(T enum_t_value) {
static_assert(::std::is_same<T, NormRegion>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function NormRegion_Name.");
return LRNParameter_NormRegion_Name(enum_t_value);
}
static inline bool NormRegion_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
NormRegion* value) {
return LRNParameter_NormRegion_Parse(name, value);
}
typedef LRNParameter_Engine Engine;
static constexpr Engine DEFAULT =
LRNParameter_Engine_DEFAULT;
static constexpr Engine CAFFE =
LRNParameter_Engine_CAFFE;
static constexpr Engine CUDNN =
LRNParameter_Engine_CUDNN;
static inline bool Engine_IsValid(int value) {
return LRNParameter_Engine_IsValid(value);
}
static constexpr Engine Engine_MIN =
LRNParameter_Engine_Engine_MIN;
static constexpr Engine Engine_MAX =
LRNParameter_Engine_Engine_MAX;
static constexpr int Engine_ARRAYSIZE =
LRNParameter_Engine_Engine_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
Engine_descriptor() {
return LRNParameter_Engine_descriptor();
}
template<typename T>
static inline const std::string& Engine_Name(T enum_t_value) {
static_assert(::std::is_same<T, Engine>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function Engine_Name.");
return LRNParameter_Engine_Name(enum_t_value);
}
static inline bool Engine_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
Engine* value) {
return LRNParameter_Engine_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kNormRegionFieldNumber = 4,
kEngineFieldNumber = 6,
kLocalSizeFieldNumber = 1,
kAlphaFieldNumber = 2,
kBetaFieldNumber = 3,
kKFieldNumber = 5,
};
// optional .caffe.LRNParameter.NormRegion norm_region = 4 [default = ACROSS_CHANNELS];
bool has_norm_region() const;
private:
bool _internal_has_norm_region() const;
public:
void clear_norm_region();
::caffe::LRNParameter_NormRegion norm_region() const;
void set_norm_region(::caffe::LRNParameter_NormRegion value);
private:
::caffe::LRNParameter_NormRegion _internal_norm_region() const;
void _internal_set_norm_region(::caffe::LRNParameter_NormRegion value);
public:
// optional .caffe.LRNParameter.Engine engine = 6 [default = DEFAULT];
bool has_engine() const;
private:
bool _internal_has_engine() const;
public:
void clear_engine();
::caffe::LRNParameter_Engine engine() const;
void set_engine(::caffe::LRNParameter_Engine value);
private:
::caffe::LRNParameter_Engine _internal_engine() const;
void _internal_set_engine(::caffe::LRNParameter_Engine value);
public:
// optional uint32 local_size = 1 [default = 5];
bool has_local_size() const;
private:
bool _internal_has_local_size() const;
public:
void clear_local_size();
::PROTOBUF_NAMESPACE_ID::uint32 local_size() const;
void set_local_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_local_size() const;
void _internal_set_local_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional float alpha = 2 [default = 1];
bool has_alpha() const;
private:
bool _internal_has_alpha() const;
public:
void clear_alpha();
float alpha() const;
void set_alpha(float value);
private:
float _internal_alpha() const;
void _internal_set_alpha(float value);
public:
// optional float beta = 3 [default = 0.75];
bool has_beta() const;
private:
bool _internal_has_beta() const;
public:
void clear_beta();
float beta() const;
void set_beta(float value);
private:
float _internal_beta() const;
void _internal_set_beta(float value);
public:
// optional float k = 5 [default = 1];
bool has_k() const;
private:
bool _internal_has_k() const;
public:
void clear_k();
float k() const;
void set_k(float value);
private:
float _internal_k() const;
void _internal_set_k(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.LRNParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
int norm_region_;
int engine_;
::PROTOBUF_NAMESPACE_ID::uint32 local_size_;
float alpha_;
float beta_;
float k_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class MemoryDataParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.MemoryDataParameter) */ {
public:
inline MemoryDataParameter() : MemoryDataParameter(nullptr) {}
virtual ~MemoryDataParameter();
MemoryDataParameter(const MemoryDataParameter& from);
MemoryDataParameter(MemoryDataParameter&& from) noexcept
: MemoryDataParameter() {
*this = ::std::move(from);
}
inline MemoryDataParameter& operator=(const MemoryDataParameter& from) {
CopyFrom(from);
return *this;
}
inline MemoryDataParameter& operator=(MemoryDataParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const MemoryDataParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const MemoryDataParameter* internal_default_instance() {
return reinterpret_cast<const MemoryDataParameter*>(
&_MemoryDataParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
57;
friend void swap(MemoryDataParameter& a, MemoryDataParameter& b) {
a.Swap(&b);
}
inline void Swap(MemoryDataParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(MemoryDataParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline MemoryDataParameter* New() const final {
return CreateMaybeMessage<MemoryDataParameter>(nullptr);
}
MemoryDataParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<MemoryDataParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const MemoryDataParameter& from);
void MergeFrom(const MemoryDataParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(MemoryDataParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.MemoryDataParameter";
}
protected:
explicit MemoryDataParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kBatchSizeFieldNumber = 1,
kChannelsFieldNumber = 2,
kHeightFieldNumber = 3,
kWidthFieldNumber = 4,
};
// optional uint32 batch_size = 1;
bool has_batch_size() const;
private:
bool _internal_has_batch_size() const;
public:
void clear_batch_size();
::PROTOBUF_NAMESPACE_ID::uint32 batch_size() const;
void set_batch_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_batch_size() const;
void _internal_set_batch_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 channels = 2;
bool has_channels() const;
private:
bool _internal_has_channels() const;
public:
void clear_channels();
::PROTOBUF_NAMESPACE_ID::uint32 channels() const;
void set_channels(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_channels() const;
void _internal_set_channels(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 height = 3;
bool has_height() const;
private:
bool _internal_has_height() const;
public:
void clear_height();
::PROTOBUF_NAMESPACE_ID::uint32 height() const;
void set_height(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_height() const;
void _internal_set_height(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 width = 4;
bool has_width() const;
private:
bool _internal_has_width() const;
public:
void clear_width();
::PROTOBUF_NAMESPACE_ID::uint32 width() const;
void set_width(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_width() const;
void _internal_set_width(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.MemoryDataParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::uint32 batch_size_;
::PROTOBUF_NAMESPACE_ID::uint32 channels_;
::PROTOBUF_NAMESPACE_ID::uint32 height_;
::PROTOBUF_NAMESPACE_ID::uint32 width_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class MultiBoxLossParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.MultiBoxLossParameter) */ {
public:
inline MultiBoxLossParameter() : MultiBoxLossParameter(nullptr) {}
virtual ~MultiBoxLossParameter();
MultiBoxLossParameter(const MultiBoxLossParameter& from);
MultiBoxLossParameter(MultiBoxLossParameter&& from) noexcept
: MultiBoxLossParameter() {
*this = ::std::move(from);
}
inline MultiBoxLossParameter& operator=(const MultiBoxLossParameter& from) {
CopyFrom(from);
return *this;
}
inline MultiBoxLossParameter& operator=(MultiBoxLossParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const MultiBoxLossParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const MultiBoxLossParameter* internal_default_instance() {
return reinterpret_cast<const MultiBoxLossParameter*>(
&_MultiBoxLossParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
58;
friend void swap(MultiBoxLossParameter& a, MultiBoxLossParameter& b) {
a.Swap(&b);
}
inline void Swap(MultiBoxLossParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(MultiBoxLossParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline MultiBoxLossParameter* New() const final {
return CreateMaybeMessage<MultiBoxLossParameter>(nullptr);
}
MultiBoxLossParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<MultiBoxLossParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const MultiBoxLossParameter& from);
void MergeFrom(const MultiBoxLossParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(MultiBoxLossParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.MultiBoxLossParameter";
}
protected:
explicit MultiBoxLossParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef MultiBoxLossParameter_LocLossType LocLossType;
static constexpr LocLossType L2 =
MultiBoxLossParameter_LocLossType_L2;
static constexpr LocLossType SMOOTH_L1 =
MultiBoxLossParameter_LocLossType_SMOOTH_L1;
static inline bool LocLossType_IsValid(int value) {
return MultiBoxLossParameter_LocLossType_IsValid(value);
}
static constexpr LocLossType LocLossType_MIN =
MultiBoxLossParameter_LocLossType_LocLossType_MIN;
static constexpr LocLossType LocLossType_MAX =
MultiBoxLossParameter_LocLossType_LocLossType_MAX;
static constexpr int LocLossType_ARRAYSIZE =
MultiBoxLossParameter_LocLossType_LocLossType_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
LocLossType_descriptor() {
return MultiBoxLossParameter_LocLossType_descriptor();
}
template<typename T>
static inline const std::string& LocLossType_Name(T enum_t_value) {
static_assert(::std::is_same<T, LocLossType>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function LocLossType_Name.");
return MultiBoxLossParameter_LocLossType_Name(enum_t_value);
}
static inline bool LocLossType_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
LocLossType* value) {
return MultiBoxLossParameter_LocLossType_Parse(name, value);
}
typedef MultiBoxLossParameter_ConfLossType ConfLossType;
static constexpr ConfLossType SOFTMAX =
MultiBoxLossParameter_ConfLossType_SOFTMAX;
static constexpr ConfLossType LOGISTIC =
MultiBoxLossParameter_ConfLossType_LOGISTIC;
static inline bool ConfLossType_IsValid(int value) {
return MultiBoxLossParameter_ConfLossType_IsValid(value);
}
static constexpr ConfLossType ConfLossType_MIN =
MultiBoxLossParameter_ConfLossType_ConfLossType_MIN;
static constexpr ConfLossType ConfLossType_MAX =
MultiBoxLossParameter_ConfLossType_ConfLossType_MAX;
static constexpr int ConfLossType_ARRAYSIZE =
MultiBoxLossParameter_ConfLossType_ConfLossType_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
ConfLossType_descriptor() {
return MultiBoxLossParameter_ConfLossType_descriptor();
}
template<typename T>
static inline const std::string& ConfLossType_Name(T enum_t_value) {
static_assert(::std::is_same<T, ConfLossType>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function ConfLossType_Name.");
return MultiBoxLossParameter_ConfLossType_Name(enum_t_value);
}
static inline bool ConfLossType_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
ConfLossType* value) {
return MultiBoxLossParameter_ConfLossType_Parse(name, value);
}
typedef MultiBoxLossParameter_MatchType MatchType;
static constexpr MatchType BIPARTITE =
MultiBoxLossParameter_MatchType_BIPARTITE;
static constexpr MatchType PER_PREDICTION =
MultiBoxLossParameter_MatchType_PER_PREDICTION;
static inline bool MatchType_IsValid(int value) {
return MultiBoxLossParameter_MatchType_IsValid(value);
}
static constexpr MatchType MatchType_MIN =
MultiBoxLossParameter_MatchType_MatchType_MIN;
static constexpr MatchType MatchType_MAX =
MultiBoxLossParameter_MatchType_MatchType_MAX;
static constexpr int MatchType_ARRAYSIZE =
MultiBoxLossParameter_MatchType_MatchType_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
MatchType_descriptor() {
return MultiBoxLossParameter_MatchType_descriptor();
}
template<typename T>
static inline const std::string& MatchType_Name(T enum_t_value) {
static_assert(::std::is_same<T, MatchType>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function MatchType_Name.");
return MultiBoxLossParameter_MatchType_Name(enum_t_value);
}
static inline bool MatchType_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
MatchType* value) {
return MultiBoxLossParameter_MatchType_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kConfLossTypeFieldNumber = 2,
kNumClassesFieldNumber = 4,
kBackgroundLabelIdFieldNumber = 9,
kEncodeVarianceInTargetFieldNumber = 16,
kMapObjectToAgnosticFieldNumber = 17,
kLocLossTypeFieldNumber = 1,
kLocWeightFieldNumber = 3,
kMatchTypeFieldNumber = 6,
kOverlapThresholdFieldNumber = 7,
kShareLocationFieldNumber = 5,
kUsePriorForMatchingFieldNumber = 8,
kUseDifficultGtFieldNumber = 10,
kDoNegMiningFieldNumber = 11,
kNegPosRatioFieldNumber = 12,
kNegOverlapFieldNumber = 13,
kCodeTypeFieldNumber = 14,
};
// optional .caffe.MultiBoxLossParameter.ConfLossType conf_loss_type = 2 [default = SOFTMAX];
bool has_conf_loss_type() const;
private:
bool _internal_has_conf_loss_type() const;
public:
void clear_conf_loss_type();
::caffe::MultiBoxLossParameter_ConfLossType conf_loss_type() const;
void set_conf_loss_type(::caffe::MultiBoxLossParameter_ConfLossType value);
private:
::caffe::MultiBoxLossParameter_ConfLossType _internal_conf_loss_type() const;
void _internal_set_conf_loss_type(::caffe::MultiBoxLossParameter_ConfLossType value);
public:
// optional uint32 num_classes = 4;
bool has_num_classes() const;
private:
bool _internal_has_num_classes() const;
public:
void clear_num_classes();
::PROTOBUF_NAMESPACE_ID::uint32 num_classes() const;
void set_num_classes(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_num_classes() const;
void _internal_set_num_classes(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 background_label_id = 9 [default = 0];
bool has_background_label_id() const;
private:
bool _internal_has_background_label_id() const;
public:
void clear_background_label_id();
::PROTOBUF_NAMESPACE_ID::uint32 background_label_id() const;
void set_background_label_id(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_background_label_id() const;
void _internal_set_background_label_id(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional bool encode_variance_in_target = 16 [default = false];
bool has_encode_variance_in_target() const;
private:
bool _internal_has_encode_variance_in_target() const;
public:
void clear_encode_variance_in_target();
bool encode_variance_in_target() const;
void set_encode_variance_in_target(bool value);
private:
bool _internal_encode_variance_in_target() const;
void _internal_set_encode_variance_in_target(bool value);
public:
// optional bool map_object_to_agnostic = 17 [default = false];
bool has_map_object_to_agnostic() const;
private:
bool _internal_has_map_object_to_agnostic() const;
public:
void clear_map_object_to_agnostic();
bool map_object_to_agnostic() const;
void set_map_object_to_agnostic(bool value);
private:
bool _internal_map_object_to_agnostic() const;
void _internal_set_map_object_to_agnostic(bool value);
public:
// optional .caffe.MultiBoxLossParameter.LocLossType loc_loss_type = 1 [default = SMOOTH_L1];
bool has_loc_loss_type() const;
private:
bool _internal_has_loc_loss_type() const;
public:
void clear_loc_loss_type();
::caffe::MultiBoxLossParameter_LocLossType loc_loss_type() const;
void set_loc_loss_type(::caffe::MultiBoxLossParameter_LocLossType value);
private:
::caffe::MultiBoxLossParameter_LocLossType _internal_loc_loss_type() const;
void _internal_set_loc_loss_type(::caffe::MultiBoxLossParameter_LocLossType value);
public:
// optional float loc_weight = 3 [default = 1];
bool has_loc_weight() const;
private:
bool _internal_has_loc_weight() const;
public:
void clear_loc_weight();
float loc_weight() const;
void set_loc_weight(float value);
private:
float _internal_loc_weight() const;
void _internal_set_loc_weight(float value);
public:
// optional .caffe.MultiBoxLossParameter.MatchType match_type = 6 [default = PER_PREDICTION];
bool has_match_type() const;
private:
bool _internal_has_match_type() const;
public:
void clear_match_type();
::caffe::MultiBoxLossParameter_MatchType match_type() const;
void set_match_type(::caffe::MultiBoxLossParameter_MatchType value);
private:
::caffe::MultiBoxLossParameter_MatchType _internal_match_type() const;
void _internal_set_match_type(::caffe::MultiBoxLossParameter_MatchType value);
public:
// optional float overlap_threshold = 7 [default = 0.5];
bool has_overlap_threshold() const;
private:
bool _internal_has_overlap_threshold() const;
public:
void clear_overlap_threshold();
float overlap_threshold() const;
void set_overlap_threshold(float value);
private:
float _internal_overlap_threshold() const;
void _internal_set_overlap_threshold(float value);
public:
// optional bool share_location = 5 [default = true];
bool has_share_location() const;
private:
bool _internal_has_share_location() const;
public:
void clear_share_location();
bool share_location() const;
void set_share_location(bool value);
private:
bool _internal_share_location() const;
void _internal_set_share_location(bool value);
public:
// optional bool use_prior_for_matching = 8 [default = true];
bool has_use_prior_for_matching() const;
private:
bool _internal_has_use_prior_for_matching() const;
public:
void clear_use_prior_for_matching();
bool use_prior_for_matching() const;
void set_use_prior_for_matching(bool value);
private:
bool _internal_use_prior_for_matching() const;
void _internal_set_use_prior_for_matching(bool value);
public:
// optional bool use_difficult_gt = 10 [default = true];
bool has_use_difficult_gt() const;
private:
bool _internal_has_use_difficult_gt() const;
public:
void clear_use_difficult_gt();
bool use_difficult_gt() const;
void set_use_difficult_gt(bool value);
private:
bool _internal_use_difficult_gt() const;
void _internal_set_use_difficult_gt(bool value);
public:
// optional bool do_neg_mining = 11 [default = true];
bool has_do_neg_mining() const;
private:
bool _internal_has_do_neg_mining() const;
public:
void clear_do_neg_mining();
bool do_neg_mining() const;
void set_do_neg_mining(bool value);
private:
bool _internal_do_neg_mining() const;
void _internal_set_do_neg_mining(bool value);
public:
// optional float neg_pos_ratio = 12 [default = 3];
bool has_neg_pos_ratio() const;
private:
bool _internal_has_neg_pos_ratio() const;
public:
void clear_neg_pos_ratio();
float neg_pos_ratio() const;
void set_neg_pos_ratio(float value);
private:
float _internal_neg_pos_ratio() const;
void _internal_set_neg_pos_ratio(float value);
public:
// optional float neg_overlap = 13 [default = 0.5];
bool has_neg_overlap() const;
private:
bool _internal_has_neg_overlap() const;
public:
void clear_neg_overlap();
float neg_overlap() const;
void set_neg_overlap(float value);
private:
float _internal_neg_overlap() const;
void _internal_set_neg_overlap(float value);
public:
// optional .caffe.PriorBoxParameter.CodeType code_type = 14 [default = CORNER];
bool has_code_type() const;
private:
bool _internal_has_code_type() const;
public:
void clear_code_type();
::caffe::PriorBoxParameter_CodeType code_type() const;
void set_code_type(::caffe::PriorBoxParameter_CodeType value);
private:
::caffe::PriorBoxParameter_CodeType _internal_code_type() const;
void _internal_set_code_type(::caffe::PriorBoxParameter_CodeType value);
public:
// @@protoc_insertion_point(class_scope:caffe.MultiBoxLossParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
int conf_loss_type_;
::PROTOBUF_NAMESPACE_ID::uint32 num_classes_;
::PROTOBUF_NAMESPACE_ID::uint32 background_label_id_;
bool encode_variance_in_target_;
bool map_object_to_agnostic_;
int loc_loss_type_;
float loc_weight_;
int match_type_;
float overlap_threshold_;
bool share_location_;
bool use_prior_for_matching_;
bool use_difficult_gt_;
bool do_neg_mining_;
float neg_pos_ratio_;
float neg_overlap_;
int code_type_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class MVNParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.MVNParameter) */ {
public:
inline MVNParameter() : MVNParameter(nullptr) {}
virtual ~MVNParameter();
MVNParameter(const MVNParameter& from);
MVNParameter(MVNParameter&& from) noexcept
: MVNParameter() {
*this = ::std::move(from);
}
inline MVNParameter& operator=(const MVNParameter& from) {
CopyFrom(from);
return *this;
}
inline MVNParameter& operator=(MVNParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const MVNParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const MVNParameter* internal_default_instance() {
return reinterpret_cast<const MVNParameter*>(
&_MVNParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
59;
friend void swap(MVNParameter& a, MVNParameter& b) {
a.Swap(&b);
}
inline void Swap(MVNParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(MVNParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline MVNParameter* New() const final {
return CreateMaybeMessage<MVNParameter>(nullptr);
}
MVNParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<MVNParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const MVNParameter& from);
void MergeFrom(const MVNParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(MVNParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.MVNParameter";
}
protected:
explicit MVNParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kAcrossChannelsFieldNumber = 2,
kNormalizeVarianceFieldNumber = 1,
kEpsFieldNumber = 3,
};
// optional bool across_channels = 2 [default = false];
bool has_across_channels() const;
private:
bool _internal_has_across_channels() const;
public:
void clear_across_channels();
bool across_channels() const;
void set_across_channels(bool value);
private:
bool _internal_across_channels() const;
void _internal_set_across_channels(bool value);
public:
// optional bool normalize_variance = 1 [default = true];
bool has_normalize_variance() const;
private:
bool _internal_has_normalize_variance() const;
public:
void clear_normalize_variance();
bool normalize_variance() const;
void set_normalize_variance(bool value);
private:
bool _internal_normalize_variance() const;
void _internal_set_normalize_variance(bool value);
public:
// optional float eps = 3 [default = 1e-09];
bool has_eps() const;
private:
bool _internal_has_eps() const;
public:
void clear_eps();
float eps() const;
void set_eps(float value);
private:
float _internal_eps() const;
void _internal_set_eps(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.MVNParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
bool across_channels_;
bool normalize_variance_;
float eps_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class NormalizeParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.NormalizeParameter) */ {
public:
inline NormalizeParameter() : NormalizeParameter(nullptr) {}
virtual ~NormalizeParameter();
NormalizeParameter(const NormalizeParameter& from);
NormalizeParameter(NormalizeParameter&& from) noexcept
: NormalizeParameter() {
*this = ::std::move(from);
}
inline NormalizeParameter& operator=(const NormalizeParameter& from) {
CopyFrom(from);
return *this;
}
inline NormalizeParameter& operator=(NormalizeParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const NormalizeParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const NormalizeParameter* internal_default_instance() {
return reinterpret_cast<const NormalizeParameter*>(
&_NormalizeParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
60;
friend void swap(NormalizeParameter& a, NormalizeParameter& b) {
a.Swap(&b);
}
inline void Swap(NormalizeParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(NormalizeParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline NormalizeParameter* New() const final {
return CreateMaybeMessage<NormalizeParameter>(nullptr);
}
NormalizeParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<NormalizeParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const NormalizeParameter& from);
void MergeFrom(const NormalizeParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(NormalizeParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.NormalizeParameter";
}
protected:
explicit NormalizeParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kScaleFillerFieldNumber = 2,
kAcrossSpatialFieldNumber = 1,
kChannelSharedFieldNumber = 3,
kEpsFieldNumber = 4,
};
// optional .caffe.FillerParameter scale_filler = 2;
bool has_scale_filler() const;
private:
bool _internal_has_scale_filler() const;
public:
void clear_scale_filler();
const ::caffe::FillerParameter& scale_filler() const;
::caffe::FillerParameter* release_scale_filler();
::caffe::FillerParameter* mutable_scale_filler();
void set_allocated_scale_filler(::caffe::FillerParameter* scale_filler);
private:
const ::caffe::FillerParameter& _internal_scale_filler() const;
::caffe::FillerParameter* _internal_mutable_scale_filler();
public:
void unsafe_arena_set_allocated_scale_filler(
::caffe::FillerParameter* scale_filler);
::caffe::FillerParameter* unsafe_arena_release_scale_filler();
// optional bool across_spatial = 1 [default = true];
bool has_across_spatial() const;
private:
bool _internal_has_across_spatial() const;
public:
void clear_across_spatial();
bool across_spatial() const;
void set_across_spatial(bool value);
private:
bool _internal_across_spatial() const;
void _internal_set_across_spatial(bool value);
public:
// optional bool channel_shared = 3 [default = true];
bool has_channel_shared() const;
private:
bool _internal_has_channel_shared() const;
public:
void clear_channel_shared();
bool channel_shared() const;
void set_channel_shared(bool value);
private:
bool _internal_channel_shared() const;
void _internal_set_channel_shared(bool value);
public:
// optional float eps = 4 [default = 1e-10];
bool has_eps() const;
private:
bool _internal_has_eps() const;
public:
void clear_eps();
float eps() const;
void set_eps(float value);
private:
float _internal_eps() const;
void _internal_set_eps(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.NormalizeParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::caffe::FillerParameter* scale_filler_;
bool across_spatial_;
bool channel_shared_;
float eps_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class ParameterParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.ParameterParameter) */ {
public:
inline ParameterParameter() : ParameterParameter(nullptr) {}
virtual ~ParameterParameter();
ParameterParameter(const ParameterParameter& from);
ParameterParameter(ParameterParameter&& from) noexcept
: ParameterParameter() {
*this = ::std::move(from);
}
inline ParameterParameter& operator=(const ParameterParameter& from) {
CopyFrom(from);
return *this;
}
inline ParameterParameter& operator=(ParameterParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const ParameterParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const ParameterParameter* internal_default_instance() {
return reinterpret_cast<const ParameterParameter*>(
&_ParameterParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
61;
friend void swap(ParameterParameter& a, ParameterParameter& b) {
a.Swap(&b);
}
inline void Swap(ParameterParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(ParameterParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline ParameterParameter* New() const final {
return CreateMaybeMessage<ParameterParameter>(nullptr);
}
ParameterParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<ParameterParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const ParameterParameter& from);
void MergeFrom(const ParameterParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(ParameterParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.ParameterParameter";
}
protected:
explicit ParameterParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kShapeFieldNumber = 1,
};
// optional .caffe.BlobShape shape = 1;
bool has_shape() const;
private:
bool _internal_has_shape() const;
public:
void clear_shape();
const ::caffe::BlobShape& shape() const;
::caffe::BlobShape* release_shape();
::caffe::BlobShape* mutable_shape();
void set_allocated_shape(::caffe::BlobShape* shape);
private:
const ::caffe::BlobShape& _internal_shape() const;
::caffe::BlobShape* _internal_mutable_shape();
public:
void unsafe_arena_set_allocated_shape(
::caffe::BlobShape* shape);
::caffe::BlobShape* unsafe_arena_release_shape();
// @@protoc_insertion_point(class_scope:caffe.ParameterParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::caffe::BlobShape* shape_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class PermuteParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.PermuteParameter) */ {
public:
inline PermuteParameter() : PermuteParameter(nullptr) {}
virtual ~PermuteParameter();
PermuteParameter(const PermuteParameter& from);
PermuteParameter(PermuteParameter&& from) noexcept
: PermuteParameter() {
*this = ::std::move(from);
}
inline PermuteParameter& operator=(const PermuteParameter& from) {
CopyFrom(from);
return *this;
}
inline PermuteParameter& operator=(PermuteParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const PermuteParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const PermuteParameter* internal_default_instance() {
return reinterpret_cast<const PermuteParameter*>(
&_PermuteParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
62;
friend void swap(PermuteParameter& a, PermuteParameter& b) {
a.Swap(&b);
}
inline void Swap(PermuteParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(PermuteParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline PermuteParameter* New() const final {
return CreateMaybeMessage<PermuteParameter>(nullptr);
}
PermuteParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<PermuteParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const PermuteParameter& from);
void MergeFrom(const PermuteParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(PermuteParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.PermuteParameter";
}
protected:
explicit PermuteParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kOrderFieldNumber = 1,
};
// repeated uint32 order = 1;
int order_size() const;
private:
int _internal_order_size() const;
public:
void clear_order();
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_order(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
_internal_order() const;
void _internal_add_order(::PROTOBUF_NAMESPACE_ID::uint32 value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
_internal_mutable_order();
public:
::PROTOBUF_NAMESPACE_ID::uint32 order(int index) const;
void set_order(int index, ::PROTOBUF_NAMESPACE_ID::uint32 value);
void add_order(::PROTOBUF_NAMESPACE_ID::uint32 value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
order() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
mutable_order();
// @@protoc_insertion_point(class_scope:caffe.PermuteParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 > order_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class PoolingParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.PoolingParameter) */ {
public:
inline PoolingParameter() : PoolingParameter(nullptr) {}
virtual ~PoolingParameter();
PoolingParameter(const PoolingParameter& from);
PoolingParameter(PoolingParameter&& from) noexcept
: PoolingParameter() {
*this = ::std::move(from);
}
inline PoolingParameter& operator=(const PoolingParameter& from) {
CopyFrom(from);
return *this;
}
inline PoolingParameter& operator=(PoolingParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const PoolingParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const PoolingParameter* internal_default_instance() {
return reinterpret_cast<const PoolingParameter*>(
&_PoolingParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
63;
friend void swap(PoolingParameter& a, PoolingParameter& b) {
a.Swap(&b);
}
inline void Swap(PoolingParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(PoolingParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline PoolingParameter* New() const final {
return CreateMaybeMessage<PoolingParameter>(nullptr);
}
PoolingParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<PoolingParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const PoolingParameter& from);
void MergeFrom(const PoolingParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(PoolingParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.PoolingParameter";
}
protected:
explicit PoolingParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef PoolingParameter_PoolMethod PoolMethod;
static constexpr PoolMethod MAX =
PoolingParameter_PoolMethod_MAX;
static constexpr PoolMethod AVE =
PoolingParameter_PoolMethod_AVE;
static constexpr PoolMethod STOCHASTIC =
PoolingParameter_PoolMethod_STOCHASTIC;
static inline bool PoolMethod_IsValid(int value) {
return PoolingParameter_PoolMethod_IsValid(value);
}
static constexpr PoolMethod PoolMethod_MIN =
PoolingParameter_PoolMethod_PoolMethod_MIN;
static constexpr PoolMethod PoolMethod_MAX =
PoolingParameter_PoolMethod_PoolMethod_MAX;
static constexpr int PoolMethod_ARRAYSIZE =
PoolingParameter_PoolMethod_PoolMethod_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
PoolMethod_descriptor() {
return PoolingParameter_PoolMethod_descriptor();
}
template<typename T>
static inline const std::string& PoolMethod_Name(T enum_t_value) {
static_assert(::std::is_same<T, PoolMethod>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function PoolMethod_Name.");
return PoolingParameter_PoolMethod_Name(enum_t_value);
}
static inline bool PoolMethod_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
PoolMethod* value) {
return PoolingParameter_PoolMethod_Parse(name, value);
}
typedef PoolingParameter_Engine Engine;
static constexpr Engine DEFAULT =
PoolingParameter_Engine_DEFAULT;
static constexpr Engine CAFFE =
PoolingParameter_Engine_CAFFE;
static constexpr Engine CUDNN =
PoolingParameter_Engine_CUDNN;
static inline bool Engine_IsValid(int value) {
return PoolingParameter_Engine_IsValid(value);
}
static constexpr Engine Engine_MIN =
PoolingParameter_Engine_Engine_MIN;
static constexpr Engine Engine_MAX =
PoolingParameter_Engine_Engine_MAX;
static constexpr int Engine_ARRAYSIZE =
PoolingParameter_Engine_Engine_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
Engine_descriptor() {
return PoolingParameter_Engine_descriptor();
}
template<typename T>
static inline const std::string& Engine_Name(T enum_t_value) {
static_assert(::std::is_same<T, Engine>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function Engine_Name.");
return PoolingParameter_Engine_Name(enum_t_value);
}
static inline bool Engine_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
Engine* value) {
return PoolingParameter_Engine_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kPoolFieldNumber = 1,
kKernelSizeFieldNumber = 2,
kPadFieldNumber = 4,
kKernelHFieldNumber = 5,
kKernelWFieldNumber = 6,
kStrideHFieldNumber = 7,
kStrideWFieldNumber = 8,
kPadHFieldNumber = 9,
kPadWFieldNumber = 10,
kEngineFieldNumber = 11,
kGlobalPoolingFieldNumber = 12,
kStrideFieldNumber = 3,
};
// optional .caffe.PoolingParameter.PoolMethod pool = 1 [default = MAX];
bool has_pool() const;
private:
bool _internal_has_pool() const;
public:
void clear_pool();
::caffe::PoolingParameter_PoolMethod pool() const;
void set_pool(::caffe::PoolingParameter_PoolMethod value);
private:
::caffe::PoolingParameter_PoolMethod _internal_pool() const;
void _internal_set_pool(::caffe::PoolingParameter_PoolMethod value);
public:
// optional uint32 kernel_size = 2;
bool has_kernel_size() const;
private:
bool _internal_has_kernel_size() const;
public:
void clear_kernel_size();
::PROTOBUF_NAMESPACE_ID::uint32 kernel_size() const;
void set_kernel_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_kernel_size() const;
void _internal_set_kernel_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 pad = 4 [default = 0];
bool has_pad() const;
private:
bool _internal_has_pad() const;
public:
void clear_pad();
::PROTOBUF_NAMESPACE_ID::uint32 pad() const;
void set_pad(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_pad() const;
void _internal_set_pad(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 kernel_h = 5;
bool has_kernel_h() const;
private:
bool _internal_has_kernel_h() const;
public:
void clear_kernel_h();
::PROTOBUF_NAMESPACE_ID::uint32 kernel_h() const;
void set_kernel_h(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_kernel_h() const;
void _internal_set_kernel_h(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 kernel_w = 6;
bool has_kernel_w() const;
private:
bool _internal_has_kernel_w() const;
public:
void clear_kernel_w();
::PROTOBUF_NAMESPACE_ID::uint32 kernel_w() const;
void set_kernel_w(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_kernel_w() const;
void _internal_set_kernel_w(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 stride_h = 7;
bool has_stride_h() const;
private:
bool _internal_has_stride_h() const;
public:
void clear_stride_h();
::PROTOBUF_NAMESPACE_ID::uint32 stride_h() const;
void set_stride_h(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_stride_h() const;
void _internal_set_stride_h(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 stride_w = 8;
bool has_stride_w() const;
private:
bool _internal_has_stride_w() const;
public:
void clear_stride_w();
::PROTOBUF_NAMESPACE_ID::uint32 stride_w() const;
void set_stride_w(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_stride_w() const;
void _internal_set_stride_w(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 pad_h = 9 [default = 0];
bool has_pad_h() const;
private:
bool _internal_has_pad_h() const;
public:
void clear_pad_h();
::PROTOBUF_NAMESPACE_ID::uint32 pad_h() const;
void set_pad_h(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_pad_h() const;
void _internal_set_pad_h(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 pad_w = 10 [default = 0];
bool has_pad_w() const;
private:
bool _internal_has_pad_w() const;
public:
void clear_pad_w();
::PROTOBUF_NAMESPACE_ID::uint32 pad_w() const;
void set_pad_w(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_pad_w() const;
void _internal_set_pad_w(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional .caffe.PoolingParameter.Engine engine = 11 [default = DEFAULT];
bool has_engine() const;
private:
bool _internal_has_engine() const;
public:
void clear_engine();
::caffe::PoolingParameter_Engine engine() const;
void set_engine(::caffe::PoolingParameter_Engine value);
private:
::caffe::PoolingParameter_Engine _internal_engine() const;
void _internal_set_engine(::caffe::PoolingParameter_Engine value);
public:
// optional bool global_pooling = 12 [default = false];
bool has_global_pooling() const;
private:
bool _internal_has_global_pooling() const;
public:
void clear_global_pooling();
bool global_pooling() const;
void set_global_pooling(bool value);
private:
bool _internal_global_pooling() const;
void _internal_set_global_pooling(bool value);
public:
// optional uint32 stride = 3 [default = 1];
bool has_stride() const;
private:
bool _internal_has_stride() const;
public:
void clear_stride();
::PROTOBUF_NAMESPACE_ID::uint32 stride() const;
void set_stride(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_stride() const;
void _internal_set_stride(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.PoolingParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
int pool_;
::PROTOBUF_NAMESPACE_ID::uint32 kernel_size_;
::PROTOBUF_NAMESPACE_ID::uint32 pad_;
::PROTOBUF_NAMESPACE_ID::uint32 kernel_h_;
::PROTOBUF_NAMESPACE_ID::uint32 kernel_w_;
::PROTOBUF_NAMESPACE_ID::uint32 stride_h_;
::PROTOBUF_NAMESPACE_ID::uint32 stride_w_;
::PROTOBUF_NAMESPACE_ID::uint32 pad_h_;
::PROTOBUF_NAMESPACE_ID::uint32 pad_w_;
int engine_;
bool global_pooling_;
::PROTOBUF_NAMESPACE_ID::uint32 stride_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class PowerParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.PowerParameter) */ {
public:
inline PowerParameter() : PowerParameter(nullptr) {}
virtual ~PowerParameter();
PowerParameter(const PowerParameter& from);
PowerParameter(PowerParameter&& from) noexcept
: PowerParameter() {
*this = ::std::move(from);
}
inline PowerParameter& operator=(const PowerParameter& from) {
CopyFrom(from);
return *this;
}
inline PowerParameter& operator=(PowerParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const PowerParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const PowerParameter* internal_default_instance() {
return reinterpret_cast<const PowerParameter*>(
&_PowerParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
64;
friend void swap(PowerParameter& a, PowerParameter& b) {
a.Swap(&b);
}
inline void Swap(PowerParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(PowerParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline PowerParameter* New() const final {
return CreateMaybeMessage<PowerParameter>(nullptr);
}
PowerParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<PowerParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const PowerParameter& from);
void MergeFrom(const PowerParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(PowerParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.PowerParameter";
}
protected:
explicit PowerParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kShiftFieldNumber = 3,
kPowerFieldNumber = 1,
kScaleFieldNumber = 2,
};
// optional float shift = 3 [default = 0];
bool has_shift() const;
private:
bool _internal_has_shift() const;
public:
void clear_shift();
float shift() const;
void set_shift(float value);
private:
float _internal_shift() const;
void _internal_set_shift(float value);
public:
// optional float power = 1 [default = 1];
bool has_power() const;
private:
bool _internal_has_power() const;
public:
void clear_power();
float power() const;
void set_power(float value);
private:
float _internal_power() const;
void _internal_set_power(float value);
public:
// optional float scale = 2 [default = 1];
bool has_scale() const;
private:
bool _internal_has_scale() const;
public:
void clear_scale();
float scale() const;
void set_scale(float value);
private:
float _internal_scale() const;
void _internal_set_scale(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.PowerParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
float shift_;
float power_;
float scale_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class PriorBoxParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.PriorBoxParameter) */ {
public:
inline PriorBoxParameter() : PriorBoxParameter(nullptr) {}
virtual ~PriorBoxParameter();
PriorBoxParameter(const PriorBoxParameter& from);
PriorBoxParameter(PriorBoxParameter&& from) noexcept
: PriorBoxParameter() {
*this = ::std::move(from);
}
inline PriorBoxParameter& operator=(const PriorBoxParameter& from) {
CopyFrom(from);
return *this;
}
inline PriorBoxParameter& operator=(PriorBoxParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const PriorBoxParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const PriorBoxParameter* internal_default_instance() {
return reinterpret_cast<const PriorBoxParameter*>(
&_PriorBoxParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
65;
friend void swap(PriorBoxParameter& a, PriorBoxParameter& b) {
a.Swap(&b);
}
inline void Swap(PriorBoxParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(PriorBoxParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline PriorBoxParameter* New() const final {
return CreateMaybeMessage<PriorBoxParameter>(nullptr);
}
PriorBoxParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<PriorBoxParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const PriorBoxParameter& from);
void MergeFrom(const PriorBoxParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(PriorBoxParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.PriorBoxParameter";
}
protected:
explicit PriorBoxParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef PriorBoxParameter_CodeType CodeType;
static constexpr CodeType CORNER =
PriorBoxParameter_CodeType_CORNER;
static constexpr CodeType CENTER_SIZE =
PriorBoxParameter_CodeType_CENTER_SIZE;
static inline bool CodeType_IsValid(int value) {
return PriorBoxParameter_CodeType_IsValid(value);
}
static constexpr CodeType CodeType_MIN =
PriorBoxParameter_CodeType_CodeType_MIN;
static constexpr CodeType CodeType_MAX =
PriorBoxParameter_CodeType_CodeType_MAX;
static constexpr int CodeType_ARRAYSIZE =
PriorBoxParameter_CodeType_CodeType_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
CodeType_descriptor() {
return PriorBoxParameter_CodeType_descriptor();
}
template<typename T>
static inline const std::string& CodeType_Name(T enum_t_value) {
static_assert(::std::is_same<T, CodeType>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function CodeType_Name.");
return PriorBoxParameter_CodeType_Name(enum_t_value);
}
static inline bool CodeType_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
CodeType* value) {
return PriorBoxParameter_CodeType_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kAspectRatioFieldNumber = 3,
kVarianceFieldNumber = 6,
kMinSizeFieldNumber = 1,
kMaxSizeFieldNumber = 2,
kFlipFieldNumber = 4,
kClipFieldNumber = 5,
};
// repeated float aspect_ratio = 3;
int aspect_ratio_size() const;
private:
int _internal_aspect_ratio_size() const;
public:
void clear_aspect_ratio();
private:
float _internal_aspect_ratio(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
_internal_aspect_ratio() const;
void _internal_add_aspect_ratio(float value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
_internal_mutable_aspect_ratio();
public:
float aspect_ratio(int index) const;
void set_aspect_ratio(int index, float value);
void add_aspect_ratio(float value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
aspect_ratio() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
mutable_aspect_ratio();
// repeated float variance = 6;
int variance_size() const;
private:
int _internal_variance_size() const;
public:
void clear_variance();
private:
float _internal_variance(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
_internal_variance() const;
void _internal_add_variance(float value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
_internal_mutable_variance();
public:
float variance(int index) const;
void set_variance(int index, float value);
void add_variance(float value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
variance() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
mutable_variance();
// optional float min_size = 1;
bool has_min_size() const;
private:
bool _internal_has_min_size() const;
public:
void clear_min_size();
float min_size() const;
void set_min_size(float value);
private:
float _internal_min_size() const;
void _internal_set_min_size(float value);
public:
// optional float max_size = 2;
bool has_max_size() const;
private:
bool _internal_has_max_size() const;
public:
void clear_max_size();
float max_size() const;
void set_max_size(float value);
private:
float _internal_max_size() const;
void _internal_set_max_size(float value);
public:
// optional bool flip = 4 [default = true];
bool has_flip() const;
private:
bool _internal_has_flip() const;
public:
void clear_flip();
bool flip() const;
void set_flip(bool value);
private:
bool _internal_flip() const;
void _internal_set_flip(bool value);
public:
// optional bool clip = 5 [default = true];
bool has_clip() const;
private:
bool _internal_has_clip() const;
public:
void clear_clip();
bool clip() const;
void set_clip(bool value);
private:
bool _internal_clip() const;
void _internal_set_clip(bool value);
public:
// @@protoc_insertion_point(class_scope:caffe.PriorBoxParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float > aspect_ratio_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float > variance_;
float min_size_;
float max_size_;
bool flip_;
bool clip_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class PythonParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.PythonParameter) */ {
public:
inline PythonParameter() : PythonParameter(nullptr) {}
virtual ~PythonParameter();
PythonParameter(const PythonParameter& from);
PythonParameter(PythonParameter&& from) noexcept
: PythonParameter() {
*this = ::std::move(from);
}
inline PythonParameter& operator=(const PythonParameter& from) {
CopyFrom(from);
return *this;
}
inline PythonParameter& operator=(PythonParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const PythonParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const PythonParameter* internal_default_instance() {
return reinterpret_cast<const PythonParameter*>(
&_PythonParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
66;
friend void swap(PythonParameter& a, PythonParameter& b) {
a.Swap(&b);
}
inline void Swap(PythonParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(PythonParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline PythonParameter* New() const final {
return CreateMaybeMessage<PythonParameter>(nullptr);
}
PythonParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<PythonParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const PythonParameter& from);
void MergeFrom(const PythonParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(PythonParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.PythonParameter";
}
protected:
explicit PythonParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kModuleFieldNumber = 1,
kLayerFieldNumber = 2,
kParamStrFieldNumber = 3,
kShareInParallelFieldNumber = 4,
};
// optional string module = 1;
bool has_module() const;
private:
bool _internal_has_module() const;
public:
void clear_module();
const std::string& module() const;
void set_module(const std::string& value);
void set_module(std::string&& value);
void set_module(const char* value);
void set_module(const char* value, size_t size);
std::string* mutable_module();
std::string* release_module();
void set_allocated_module(std::string* module);
private:
const std::string& _internal_module() const;
void _internal_set_module(const std::string& value);
std::string* _internal_mutable_module();
public:
// optional string layer = 2;
bool has_layer() const;
private:
bool _internal_has_layer() const;
public:
void clear_layer();
const std::string& layer() const;
void set_layer(const std::string& value);
void set_layer(std::string&& value);
void set_layer(const char* value);
void set_layer(const char* value, size_t size);
std::string* mutable_layer();
std::string* release_layer();
void set_allocated_layer(std::string* layer);
private:
const std::string& _internal_layer() const;
void _internal_set_layer(const std::string& value);
std::string* _internal_mutable_layer();
public:
// optional string param_str = 3 [default = ""];
bool has_param_str() const;
private:
bool _internal_has_param_str() const;
public:
void clear_param_str();
const std::string& param_str() const;
void set_param_str(const std::string& value);
void set_param_str(std::string&& value);
void set_param_str(const char* value);
void set_param_str(const char* value, size_t size);
std::string* mutable_param_str();
std::string* release_param_str();
void set_allocated_param_str(std::string* param_str);
private:
const std::string& _internal_param_str() const;
void _internal_set_param_str(const std::string& value);
std::string* _internal_mutable_param_str();
public:
// optional bool share_in_parallel = 4 [default = false];
bool has_share_in_parallel() const;
private:
bool _internal_has_share_in_parallel() const;
public:
void clear_share_in_parallel();
bool share_in_parallel() const;
void set_share_in_parallel(bool value);
private:
bool _internal_share_in_parallel() const;
void _internal_set_share_in_parallel(bool value);
public:
// @@protoc_insertion_point(class_scope:caffe.PythonParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr module_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr layer_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr param_str_;
bool share_in_parallel_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class RecurrentParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.RecurrentParameter) */ {
public:
inline RecurrentParameter() : RecurrentParameter(nullptr) {}
virtual ~RecurrentParameter();
RecurrentParameter(const RecurrentParameter& from);
RecurrentParameter(RecurrentParameter&& from) noexcept
: RecurrentParameter() {
*this = ::std::move(from);
}
inline RecurrentParameter& operator=(const RecurrentParameter& from) {
CopyFrom(from);
return *this;
}
inline RecurrentParameter& operator=(RecurrentParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const RecurrentParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const RecurrentParameter* internal_default_instance() {
return reinterpret_cast<const RecurrentParameter*>(
&_RecurrentParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
67;
friend void swap(RecurrentParameter& a, RecurrentParameter& b) {
a.Swap(&b);
}
inline void Swap(RecurrentParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(RecurrentParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline RecurrentParameter* New() const final {
return CreateMaybeMessage<RecurrentParameter>(nullptr);
}
RecurrentParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<RecurrentParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const RecurrentParameter& from);
void MergeFrom(const RecurrentParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(RecurrentParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.RecurrentParameter";
}
protected:
explicit RecurrentParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kWeightFillerFieldNumber = 2,
kBiasFillerFieldNumber = 3,
kNumOutputFieldNumber = 1,
kDebugInfoFieldNumber = 4,
kExposeHiddenFieldNumber = 5,
};
// optional .caffe.FillerParameter weight_filler = 2;
bool has_weight_filler() const;
private:
bool _internal_has_weight_filler() const;
public:
void clear_weight_filler();
const ::caffe::FillerParameter& weight_filler() const;
::caffe::FillerParameter* release_weight_filler();
::caffe::FillerParameter* mutable_weight_filler();
void set_allocated_weight_filler(::caffe::FillerParameter* weight_filler);
private:
const ::caffe::FillerParameter& _internal_weight_filler() const;
::caffe::FillerParameter* _internal_mutable_weight_filler();
public:
void unsafe_arena_set_allocated_weight_filler(
::caffe::FillerParameter* weight_filler);
::caffe::FillerParameter* unsafe_arena_release_weight_filler();
// optional .caffe.FillerParameter bias_filler = 3;
bool has_bias_filler() const;
private:
bool _internal_has_bias_filler() const;
public:
void clear_bias_filler();
const ::caffe::FillerParameter& bias_filler() const;
::caffe::FillerParameter* release_bias_filler();
::caffe::FillerParameter* mutable_bias_filler();
void set_allocated_bias_filler(::caffe::FillerParameter* bias_filler);
private:
const ::caffe::FillerParameter& _internal_bias_filler() const;
::caffe::FillerParameter* _internal_mutable_bias_filler();
public:
void unsafe_arena_set_allocated_bias_filler(
::caffe::FillerParameter* bias_filler);
::caffe::FillerParameter* unsafe_arena_release_bias_filler();
// optional uint32 num_output = 1 [default = 0];
bool has_num_output() const;
private:
bool _internal_has_num_output() const;
public:
void clear_num_output();
::PROTOBUF_NAMESPACE_ID::uint32 num_output() const;
void set_num_output(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_num_output() const;
void _internal_set_num_output(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional bool debug_info = 4 [default = false];
bool has_debug_info() const;
private:
bool _internal_has_debug_info() const;
public:
void clear_debug_info();
bool debug_info() const;
void set_debug_info(bool value);
private:
bool _internal_debug_info() const;
void _internal_set_debug_info(bool value);
public:
// optional bool expose_hidden = 5 [default = false];
bool has_expose_hidden() const;
private:
bool _internal_has_expose_hidden() const;
public:
void clear_expose_hidden();
bool expose_hidden() const;
void set_expose_hidden(bool value);
private:
bool _internal_expose_hidden() const;
void _internal_set_expose_hidden(bool value);
public:
// @@protoc_insertion_point(class_scope:caffe.RecurrentParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::caffe::FillerParameter* weight_filler_;
::caffe::FillerParameter* bias_filler_;
::PROTOBUF_NAMESPACE_ID::uint32 num_output_;
bool debug_info_;
bool expose_hidden_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class ReductionParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.ReductionParameter) */ {
public:
inline ReductionParameter() : ReductionParameter(nullptr) {}
virtual ~ReductionParameter();
ReductionParameter(const ReductionParameter& from);
ReductionParameter(ReductionParameter&& from) noexcept
: ReductionParameter() {
*this = ::std::move(from);
}
inline ReductionParameter& operator=(const ReductionParameter& from) {
CopyFrom(from);
return *this;
}
inline ReductionParameter& operator=(ReductionParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const ReductionParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const ReductionParameter* internal_default_instance() {
return reinterpret_cast<const ReductionParameter*>(
&_ReductionParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
68;
friend void swap(ReductionParameter& a, ReductionParameter& b) {
a.Swap(&b);
}
inline void Swap(ReductionParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(ReductionParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline ReductionParameter* New() const final {
return CreateMaybeMessage<ReductionParameter>(nullptr);
}
ReductionParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<ReductionParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const ReductionParameter& from);
void MergeFrom(const ReductionParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(ReductionParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.ReductionParameter";
}
protected:
explicit ReductionParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef ReductionParameter_ReductionOp ReductionOp;
static constexpr ReductionOp SUM =
ReductionParameter_ReductionOp_SUM;
static constexpr ReductionOp ASUM =
ReductionParameter_ReductionOp_ASUM;
static constexpr ReductionOp SUMSQ =
ReductionParameter_ReductionOp_SUMSQ;
static constexpr ReductionOp MEAN =
ReductionParameter_ReductionOp_MEAN;
static inline bool ReductionOp_IsValid(int value) {
return ReductionParameter_ReductionOp_IsValid(value);
}
static constexpr ReductionOp ReductionOp_MIN =
ReductionParameter_ReductionOp_ReductionOp_MIN;
static constexpr ReductionOp ReductionOp_MAX =
ReductionParameter_ReductionOp_ReductionOp_MAX;
static constexpr int ReductionOp_ARRAYSIZE =
ReductionParameter_ReductionOp_ReductionOp_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
ReductionOp_descriptor() {
return ReductionParameter_ReductionOp_descriptor();
}
template<typename T>
static inline const std::string& ReductionOp_Name(T enum_t_value) {
static_assert(::std::is_same<T, ReductionOp>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function ReductionOp_Name.");
return ReductionParameter_ReductionOp_Name(enum_t_value);
}
static inline bool ReductionOp_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
ReductionOp* value) {
return ReductionParameter_ReductionOp_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kAxisFieldNumber = 2,
kOperationFieldNumber = 1,
kCoeffFieldNumber = 3,
};
// optional int32 axis = 2 [default = 0];
bool has_axis() const;
private:
bool _internal_has_axis() const;
public:
void clear_axis();
::PROTOBUF_NAMESPACE_ID::int32 axis() const;
void set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_axis() const;
void _internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional .caffe.ReductionParameter.ReductionOp operation = 1 [default = SUM];
bool has_operation() const;
private:
bool _internal_has_operation() const;
public:
void clear_operation();
::caffe::ReductionParameter_ReductionOp operation() const;
void set_operation(::caffe::ReductionParameter_ReductionOp value);
private:
::caffe::ReductionParameter_ReductionOp _internal_operation() const;
void _internal_set_operation(::caffe::ReductionParameter_ReductionOp value);
public:
// optional float coeff = 3 [default = 1];
bool has_coeff() const;
private:
bool _internal_has_coeff() const;
public:
void clear_coeff();
float coeff() const;
void set_coeff(float value);
private:
float _internal_coeff() const;
void _internal_set_coeff(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.ReductionParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::int32 axis_;
int operation_;
float coeff_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class ReLUParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.ReLUParameter) */ {
public:
inline ReLUParameter() : ReLUParameter(nullptr) {}
virtual ~ReLUParameter();
ReLUParameter(const ReLUParameter& from);
ReLUParameter(ReLUParameter&& from) noexcept
: ReLUParameter() {
*this = ::std::move(from);
}
inline ReLUParameter& operator=(const ReLUParameter& from) {
CopyFrom(from);
return *this;
}
inline ReLUParameter& operator=(ReLUParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const ReLUParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const ReLUParameter* internal_default_instance() {
return reinterpret_cast<const ReLUParameter*>(
&_ReLUParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
69;
friend void swap(ReLUParameter& a, ReLUParameter& b) {
a.Swap(&b);
}
inline void Swap(ReLUParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(ReLUParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline ReLUParameter* New() const final {
return CreateMaybeMessage<ReLUParameter>(nullptr);
}
ReLUParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<ReLUParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const ReLUParameter& from);
void MergeFrom(const ReLUParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(ReLUParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.ReLUParameter";
}
protected:
explicit ReLUParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef ReLUParameter_Engine Engine;
static constexpr Engine DEFAULT =
ReLUParameter_Engine_DEFAULT;
static constexpr Engine CAFFE =
ReLUParameter_Engine_CAFFE;
static constexpr Engine CUDNN =
ReLUParameter_Engine_CUDNN;
static inline bool Engine_IsValid(int value) {
return ReLUParameter_Engine_IsValid(value);
}
static constexpr Engine Engine_MIN =
ReLUParameter_Engine_Engine_MIN;
static constexpr Engine Engine_MAX =
ReLUParameter_Engine_Engine_MAX;
static constexpr int Engine_ARRAYSIZE =
ReLUParameter_Engine_Engine_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
Engine_descriptor() {
return ReLUParameter_Engine_descriptor();
}
template<typename T>
static inline const std::string& Engine_Name(T enum_t_value) {
static_assert(::std::is_same<T, Engine>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function Engine_Name.");
return ReLUParameter_Engine_Name(enum_t_value);
}
static inline bool Engine_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
Engine* value) {
return ReLUParameter_Engine_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kNegativeSlopeFieldNumber = 1,
kEngineFieldNumber = 2,
};
// optional float negative_slope = 1 [default = 0];
bool has_negative_slope() const;
private:
bool _internal_has_negative_slope() const;
public:
void clear_negative_slope();
float negative_slope() const;
void set_negative_slope(float value);
private:
float _internal_negative_slope() const;
void _internal_set_negative_slope(float value);
public:
// optional .caffe.ReLUParameter.Engine engine = 2 [default = DEFAULT];
bool has_engine() const;
private:
bool _internal_has_engine() const;
public:
void clear_engine();
::caffe::ReLUParameter_Engine engine() const;
void set_engine(::caffe::ReLUParameter_Engine value);
private:
::caffe::ReLUParameter_Engine _internal_engine() const;
void _internal_set_engine(::caffe::ReLUParameter_Engine value);
public:
// @@protoc_insertion_point(class_scope:caffe.ReLUParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
float negative_slope_;
int engine_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class ReshapeParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.ReshapeParameter) */ {
public:
inline ReshapeParameter() : ReshapeParameter(nullptr) {}
virtual ~ReshapeParameter();
ReshapeParameter(const ReshapeParameter& from);
ReshapeParameter(ReshapeParameter&& from) noexcept
: ReshapeParameter() {
*this = ::std::move(from);
}
inline ReshapeParameter& operator=(const ReshapeParameter& from) {
CopyFrom(from);
return *this;
}
inline ReshapeParameter& operator=(ReshapeParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const ReshapeParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const ReshapeParameter* internal_default_instance() {
return reinterpret_cast<const ReshapeParameter*>(
&_ReshapeParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
70;
friend void swap(ReshapeParameter& a, ReshapeParameter& b) {
a.Swap(&b);
}
inline void Swap(ReshapeParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(ReshapeParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline ReshapeParameter* New() const final {
return CreateMaybeMessage<ReshapeParameter>(nullptr);
}
ReshapeParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<ReshapeParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const ReshapeParameter& from);
void MergeFrom(const ReshapeParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(ReshapeParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.ReshapeParameter";
}
protected:
explicit ReshapeParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kShapeFieldNumber = 1,
kAxisFieldNumber = 2,
kNumAxesFieldNumber = 3,
};
// optional .caffe.BlobShape shape = 1;
bool has_shape() const;
private:
bool _internal_has_shape() const;
public:
void clear_shape();
const ::caffe::BlobShape& shape() const;
::caffe::BlobShape* release_shape();
::caffe::BlobShape* mutable_shape();
void set_allocated_shape(::caffe::BlobShape* shape);
private:
const ::caffe::BlobShape& _internal_shape() const;
::caffe::BlobShape* _internal_mutable_shape();
public:
void unsafe_arena_set_allocated_shape(
::caffe::BlobShape* shape);
::caffe::BlobShape* unsafe_arena_release_shape();
// optional int32 axis = 2 [default = 0];
bool has_axis() const;
private:
bool _internal_has_axis() const;
public:
void clear_axis();
::PROTOBUF_NAMESPACE_ID::int32 axis() const;
void set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_axis() const;
void _internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional int32 num_axes = 3 [default = -1];
bool has_num_axes() const;
private:
bool _internal_has_num_axes() const;
public:
void clear_num_axes();
::PROTOBUF_NAMESPACE_ID::int32 num_axes() const;
void set_num_axes(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_num_axes() const;
void _internal_set_num_axes(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.ReshapeParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::caffe::BlobShape* shape_;
::PROTOBUF_NAMESPACE_ID::int32 axis_;
::PROTOBUF_NAMESPACE_ID::int32 num_axes_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class ROIPoolingParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.ROIPoolingParameter) */ {
public:
inline ROIPoolingParameter() : ROIPoolingParameter(nullptr) {}
virtual ~ROIPoolingParameter();
ROIPoolingParameter(const ROIPoolingParameter& from);
ROIPoolingParameter(ROIPoolingParameter&& from) noexcept
: ROIPoolingParameter() {
*this = ::std::move(from);
}
inline ROIPoolingParameter& operator=(const ROIPoolingParameter& from) {
CopyFrom(from);
return *this;
}
inline ROIPoolingParameter& operator=(ROIPoolingParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const ROIPoolingParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const ROIPoolingParameter* internal_default_instance() {
return reinterpret_cast<const ROIPoolingParameter*>(
&_ROIPoolingParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
71;
friend void swap(ROIPoolingParameter& a, ROIPoolingParameter& b) {
a.Swap(&b);
}
inline void Swap(ROIPoolingParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(ROIPoolingParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline ROIPoolingParameter* New() const final {
return CreateMaybeMessage<ROIPoolingParameter>(nullptr);
}
ROIPoolingParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<ROIPoolingParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const ROIPoolingParameter& from);
void MergeFrom(const ROIPoolingParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(ROIPoolingParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.ROIPoolingParameter";
}
protected:
explicit ROIPoolingParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kPooledHFieldNumber = 1,
kPooledWFieldNumber = 2,
kSpatialScaleFieldNumber = 3,
};
// optional uint32 pooled_h = 1 [default = 0];
bool has_pooled_h() const;
private:
bool _internal_has_pooled_h() const;
public:
void clear_pooled_h();
::PROTOBUF_NAMESPACE_ID::uint32 pooled_h() const;
void set_pooled_h(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_pooled_h() const;
void _internal_set_pooled_h(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 pooled_w = 2 [default = 0];
bool has_pooled_w() const;
private:
bool _internal_has_pooled_w() const;
public:
void clear_pooled_w();
::PROTOBUF_NAMESPACE_ID::uint32 pooled_w() const;
void set_pooled_w(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_pooled_w() const;
void _internal_set_pooled_w(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional float spatial_scale = 3 [default = 1];
bool has_spatial_scale() const;
private:
bool _internal_has_spatial_scale() const;
public:
void clear_spatial_scale();
float spatial_scale() const;
void set_spatial_scale(float value);
private:
float _internal_spatial_scale() const;
void _internal_set_spatial_scale(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.ROIPoolingParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::uint32 pooled_h_;
::PROTOBUF_NAMESPACE_ID::uint32 pooled_w_;
float spatial_scale_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class ScaleParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.ScaleParameter) */ {
public:
inline ScaleParameter() : ScaleParameter(nullptr) {}
virtual ~ScaleParameter();
ScaleParameter(const ScaleParameter& from);
ScaleParameter(ScaleParameter&& from) noexcept
: ScaleParameter() {
*this = ::std::move(from);
}
inline ScaleParameter& operator=(const ScaleParameter& from) {
CopyFrom(from);
return *this;
}
inline ScaleParameter& operator=(ScaleParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const ScaleParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const ScaleParameter* internal_default_instance() {
return reinterpret_cast<const ScaleParameter*>(
&_ScaleParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
72;
friend void swap(ScaleParameter& a, ScaleParameter& b) {
a.Swap(&b);
}
inline void Swap(ScaleParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(ScaleParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline ScaleParameter* New() const final {
return CreateMaybeMessage<ScaleParameter>(nullptr);
}
ScaleParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<ScaleParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const ScaleParameter& from);
void MergeFrom(const ScaleParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(ScaleParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.ScaleParameter";
}
protected:
explicit ScaleParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kFillerFieldNumber = 3,
kBiasFillerFieldNumber = 5,
kBiasTermFieldNumber = 4,
kAxisFieldNumber = 1,
kNumAxesFieldNumber = 2,
};
// optional .caffe.FillerParameter filler = 3;
bool has_filler() const;
private:
bool _internal_has_filler() const;
public:
void clear_filler();
const ::caffe::FillerParameter& filler() const;
::caffe::FillerParameter* release_filler();
::caffe::FillerParameter* mutable_filler();
void set_allocated_filler(::caffe::FillerParameter* filler);
private:
const ::caffe::FillerParameter& _internal_filler() const;
::caffe::FillerParameter* _internal_mutable_filler();
public:
void unsafe_arena_set_allocated_filler(
::caffe::FillerParameter* filler);
::caffe::FillerParameter* unsafe_arena_release_filler();
// optional .caffe.FillerParameter bias_filler = 5;
bool has_bias_filler() const;
private:
bool _internal_has_bias_filler() const;
public:
void clear_bias_filler();
const ::caffe::FillerParameter& bias_filler() const;
::caffe::FillerParameter* release_bias_filler();
::caffe::FillerParameter* mutable_bias_filler();
void set_allocated_bias_filler(::caffe::FillerParameter* bias_filler);
private:
const ::caffe::FillerParameter& _internal_bias_filler() const;
::caffe::FillerParameter* _internal_mutable_bias_filler();
public:
void unsafe_arena_set_allocated_bias_filler(
::caffe::FillerParameter* bias_filler);
::caffe::FillerParameter* unsafe_arena_release_bias_filler();
// optional bool bias_term = 4 [default = false];
bool has_bias_term() const;
private:
bool _internal_has_bias_term() const;
public:
void clear_bias_term();
bool bias_term() const;
void set_bias_term(bool value);
private:
bool _internal_bias_term() const;
void _internal_set_bias_term(bool value);
public:
// optional int32 axis = 1 [default = 1];
bool has_axis() const;
private:
bool _internal_has_axis() const;
public:
void clear_axis();
::PROTOBUF_NAMESPACE_ID::int32 axis() const;
void set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_axis() const;
void _internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional int32 num_axes = 2 [default = 1];
bool has_num_axes() const;
private:
bool _internal_has_num_axes() const;
public:
void clear_num_axes();
::PROTOBUF_NAMESPACE_ID::int32 num_axes() const;
void set_num_axes(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_num_axes() const;
void _internal_set_num_axes(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.ScaleParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::caffe::FillerParameter* filler_;
::caffe::FillerParameter* bias_filler_;
bool bias_term_;
::PROTOBUF_NAMESPACE_ID::int32 axis_;
::PROTOBUF_NAMESPACE_ID::int32 num_axes_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class SigmoidParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.SigmoidParameter) */ {
public:
inline SigmoidParameter() : SigmoidParameter(nullptr) {}
virtual ~SigmoidParameter();
SigmoidParameter(const SigmoidParameter& from);
SigmoidParameter(SigmoidParameter&& from) noexcept
: SigmoidParameter() {
*this = ::std::move(from);
}
inline SigmoidParameter& operator=(const SigmoidParameter& from) {
CopyFrom(from);
return *this;
}
inline SigmoidParameter& operator=(SigmoidParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const SigmoidParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const SigmoidParameter* internal_default_instance() {
return reinterpret_cast<const SigmoidParameter*>(
&_SigmoidParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
73;
friend void swap(SigmoidParameter& a, SigmoidParameter& b) {
a.Swap(&b);
}
inline void Swap(SigmoidParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(SigmoidParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline SigmoidParameter* New() const final {
return CreateMaybeMessage<SigmoidParameter>(nullptr);
}
SigmoidParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<SigmoidParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const SigmoidParameter& from);
void MergeFrom(const SigmoidParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(SigmoidParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.SigmoidParameter";
}
protected:
explicit SigmoidParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef SigmoidParameter_Engine Engine;
static constexpr Engine DEFAULT =
SigmoidParameter_Engine_DEFAULT;
static constexpr Engine CAFFE =
SigmoidParameter_Engine_CAFFE;
static constexpr Engine CUDNN =
SigmoidParameter_Engine_CUDNN;
static inline bool Engine_IsValid(int value) {
return SigmoidParameter_Engine_IsValid(value);
}
static constexpr Engine Engine_MIN =
SigmoidParameter_Engine_Engine_MIN;
static constexpr Engine Engine_MAX =
SigmoidParameter_Engine_Engine_MAX;
static constexpr int Engine_ARRAYSIZE =
SigmoidParameter_Engine_Engine_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
Engine_descriptor() {
return SigmoidParameter_Engine_descriptor();
}
template<typename T>
static inline const std::string& Engine_Name(T enum_t_value) {
static_assert(::std::is_same<T, Engine>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function Engine_Name.");
return SigmoidParameter_Engine_Name(enum_t_value);
}
static inline bool Engine_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
Engine* value) {
return SigmoidParameter_Engine_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kEngineFieldNumber = 1,
};
// optional .caffe.SigmoidParameter.Engine engine = 1 [default = DEFAULT];
bool has_engine() const;
private:
bool _internal_has_engine() const;
public:
void clear_engine();
::caffe::SigmoidParameter_Engine engine() const;
void set_engine(::caffe::SigmoidParameter_Engine value);
private:
::caffe::SigmoidParameter_Engine _internal_engine() const;
void _internal_set_engine(::caffe::SigmoidParameter_Engine value);
public:
// @@protoc_insertion_point(class_scope:caffe.SigmoidParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
int engine_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class SliceParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.SliceParameter) */ {
public:
inline SliceParameter() : SliceParameter(nullptr) {}
virtual ~SliceParameter();
SliceParameter(const SliceParameter& from);
SliceParameter(SliceParameter&& from) noexcept
: SliceParameter() {
*this = ::std::move(from);
}
inline SliceParameter& operator=(const SliceParameter& from) {
CopyFrom(from);
return *this;
}
inline SliceParameter& operator=(SliceParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const SliceParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const SliceParameter* internal_default_instance() {
return reinterpret_cast<const SliceParameter*>(
&_SliceParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
74;
friend void swap(SliceParameter& a, SliceParameter& b) {
a.Swap(&b);
}
inline void Swap(SliceParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(SliceParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline SliceParameter* New() const final {
return CreateMaybeMessage<SliceParameter>(nullptr);
}
SliceParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<SliceParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const SliceParameter& from);
void MergeFrom(const SliceParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(SliceParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.SliceParameter";
}
protected:
explicit SliceParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kSlicePointFieldNumber = 2,
kSliceDimFieldNumber = 1,
kAxisFieldNumber = 3,
};
// repeated uint32 slice_point = 2;
int slice_point_size() const;
private:
int _internal_slice_point_size() const;
public:
void clear_slice_point();
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_slice_point(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
_internal_slice_point() const;
void _internal_add_slice_point(::PROTOBUF_NAMESPACE_ID::uint32 value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
_internal_mutable_slice_point();
public:
::PROTOBUF_NAMESPACE_ID::uint32 slice_point(int index) const;
void set_slice_point(int index, ::PROTOBUF_NAMESPACE_ID::uint32 value);
void add_slice_point(::PROTOBUF_NAMESPACE_ID::uint32 value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
slice_point() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
mutable_slice_point();
// optional uint32 slice_dim = 1 [default = 1];
bool has_slice_dim() const;
private:
bool _internal_has_slice_dim() const;
public:
void clear_slice_dim();
::PROTOBUF_NAMESPACE_ID::uint32 slice_dim() const;
void set_slice_dim(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_slice_dim() const;
void _internal_set_slice_dim(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional int32 axis = 3 [default = 1];
bool has_axis() const;
private:
bool _internal_has_axis() const;
public:
void clear_axis();
::PROTOBUF_NAMESPACE_ID::int32 axis() const;
void set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_axis() const;
void _internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.SliceParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 > slice_point_;
::PROTOBUF_NAMESPACE_ID::uint32 slice_dim_;
::PROTOBUF_NAMESPACE_ID::int32 axis_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class SmoothL1LossParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.SmoothL1LossParameter) */ {
public:
inline SmoothL1LossParameter() : SmoothL1LossParameter(nullptr) {}
virtual ~SmoothL1LossParameter();
SmoothL1LossParameter(const SmoothL1LossParameter& from);
SmoothL1LossParameter(SmoothL1LossParameter&& from) noexcept
: SmoothL1LossParameter() {
*this = ::std::move(from);
}
inline SmoothL1LossParameter& operator=(const SmoothL1LossParameter& from) {
CopyFrom(from);
return *this;
}
inline SmoothL1LossParameter& operator=(SmoothL1LossParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const SmoothL1LossParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const SmoothL1LossParameter* internal_default_instance() {
return reinterpret_cast<const SmoothL1LossParameter*>(
&_SmoothL1LossParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
75;
friend void swap(SmoothL1LossParameter& a, SmoothL1LossParameter& b) {
a.Swap(&b);
}
inline void Swap(SmoothL1LossParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(SmoothL1LossParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline SmoothL1LossParameter* New() const final {
return CreateMaybeMessage<SmoothL1LossParameter>(nullptr);
}
SmoothL1LossParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<SmoothL1LossParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const SmoothL1LossParameter& from);
void MergeFrom(const SmoothL1LossParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(SmoothL1LossParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.SmoothL1LossParameter";
}
protected:
explicit SmoothL1LossParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kSigmaFieldNumber = 1,
};
// optional float sigma = 1 [default = 1];
bool has_sigma() const;
private:
bool _internal_has_sigma() const;
public:
void clear_sigma();
float sigma() const;
void set_sigma(float value);
private:
float _internal_sigma() const;
void _internal_set_sigma(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.SmoothL1LossParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
float sigma_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class SoftmaxParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.SoftmaxParameter) */ {
public:
inline SoftmaxParameter() : SoftmaxParameter(nullptr) {}
virtual ~SoftmaxParameter();
SoftmaxParameter(const SoftmaxParameter& from);
SoftmaxParameter(SoftmaxParameter&& from) noexcept
: SoftmaxParameter() {
*this = ::std::move(from);
}
inline SoftmaxParameter& operator=(const SoftmaxParameter& from) {
CopyFrom(from);
return *this;
}
inline SoftmaxParameter& operator=(SoftmaxParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const SoftmaxParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const SoftmaxParameter* internal_default_instance() {
return reinterpret_cast<const SoftmaxParameter*>(
&_SoftmaxParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
76;
friend void swap(SoftmaxParameter& a, SoftmaxParameter& b) {
a.Swap(&b);
}
inline void Swap(SoftmaxParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(SoftmaxParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline SoftmaxParameter* New() const final {
return CreateMaybeMessage<SoftmaxParameter>(nullptr);
}
SoftmaxParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<SoftmaxParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const SoftmaxParameter& from);
void MergeFrom(const SoftmaxParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(SoftmaxParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.SoftmaxParameter";
}
protected:
explicit SoftmaxParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef SoftmaxParameter_Engine Engine;
static constexpr Engine DEFAULT =
SoftmaxParameter_Engine_DEFAULT;
static constexpr Engine CAFFE =
SoftmaxParameter_Engine_CAFFE;
static constexpr Engine CUDNN =
SoftmaxParameter_Engine_CUDNN;
static inline bool Engine_IsValid(int value) {
return SoftmaxParameter_Engine_IsValid(value);
}
static constexpr Engine Engine_MIN =
SoftmaxParameter_Engine_Engine_MIN;
static constexpr Engine Engine_MAX =
SoftmaxParameter_Engine_Engine_MAX;
static constexpr int Engine_ARRAYSIZE =
SoftmaxParameter_Engine_Engine_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
Engine_descriptor() {
return SoftmaxParameter_Engine_descriptor();
}
template<typename T>
static inline const std::string& Engine_Name(T enum_t_value) {
static_assert(::std::is_same<T, Engine>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function Engine_Name.");
return SoftmaxParameter_Engine_Name(enum_t_value);
}
static inline bool Engine_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
Engine* value) {
return SoftmaxParameter_Engine_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kEngineFieldNumber = 1,
kAxisFieldNumber = 2,
};
// optional .caffe.SoftmaxParameter.Engine engine = 1 [default = DEFAULT];
bool has_engine() const;
private:
bool _internal_has_engine() const;
public:
void clear_engine();
::caffe::SoftmaxParameter_Engine engine() const;
void set_engine(::caffe::SoftmaxParameter_Engine value);
private:
::caffe::SoftmaxParameter_Engine _internal_engine() const;
void _internal_set_engine(::caffe::SoftmaxParameter_Engine value);
public:
// optional int32 axis = 2 [default = 1];
bool has_axis() const;
private:
bool _internal_has_axis() const;
public:
void clear_axis();
::PROTOBUF_NAMESPACE_ID::int32 axis() const;
void set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_axis() const;
void _internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.SoftmaxParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
int engine_;
::PROTOBUF_NAMESPACE_ID::int32 axis_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class TanHParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.TanHParameter) */ {
public:
inline TanHParameter() : TanHParameter(nullptr) {}
virtual ~TanHParameter();
TanHParameter(const TanHParameter& from);
TanHParameter(TanHParameter&& from) noexcept
: TanHParameter() {
*this = ::std::move(from);
}
inline TanHParameter& operator=(const TanHParameter& from) {
CopyFrom(from);
return *this;
}
inline TanHParameter& operator=(TanHParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const TanHParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const TanHParameter* internal_default_instance() {
return reinterpret_cast<const TanHParameter*>(
&_TanHParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
77;
friend void swap(TanHParameter& a, TanHParameter& b) {
a.Swap(&b);
}
inline void Swap(TanHParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(TanHParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline TanHParameter* New() const final {
return CreateMaybeMessage<TanHParameter>(nullptr);
}
TanHParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<TanHParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const TanHParameter& from);
void MergeFrom(const TanHParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(TanHParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.TanHParameter";
}
protected:
explicit TanHParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef TanHParameter_Engine Engine;
static constexpr Engine DEFAULT =
TanHParameter_Engine_DEFAULT;
static constexpr Engine CAFFE =
TanHParameter_Engine_CAFFE;
static constexpr Engine CUDNN =
TanHParameter_Engine_CUDNN;
static inline bool Engine_IsValid(int value) {
return TanHParameter_Engine_IsValid(value);
}
static constexpr Engine Engine_MIN =
TanHParameter_Engine_Engine_MIN;
static constexpr Engine Engine_MAX =
TanHParameter_Engine_Engine_MAX;
static constexpr int Engine_ARRAYSIZE =
TanHParameter_Engine_Engine_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
Engine_descriptor() {
return TanHParameter_Engine_descriptor();
}
template<typename T>
static inline const std::string& Engine_Name(T enum_t_value) {
static_assert(::std::is_same<T, Engine>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function Engine_Name.");
return TanHParameter_Engine_Name(enum_t_value);
}
static inline bool Engine_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
Engine* value) {
return TanHParameter_Engine_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kEngineFieldNumber = 1,
};
// optional .caffe.TanHParameter.Engine engine = 1 [default = DEFAULT];
bool has_engine() const;
private:
bool _internal_has_engine() const;
public:
void clear_engine();
::caffe::TanHParameter_Engine engine() const;
void set_engine(::caffe::TanHParameter_Engine value);
private:
::caffe::TanHParameter_Engine _internal_engine() const;
void _internal_set_engine(::caffe::TanHParameter_Engine value);
public:
// @@protoc_insertion_point(class_scope:caffe.TanHParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
int engine_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class TileParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.TileParameter) */ {
public:
inline TileParameter() : TileParameter(nullptr) {}
virtual ~TileParameter();
TileParameter(const TileParameter& from);
TileParameter(TileParameter&& from) noexcept
: TileParameter() {
*this = ::std::move(from);
}
inline TileParameter& operator=(const TileParameter& from) {
CopyFrom(from);
return *this;
}
inline TileParameter& operator=(TileParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const TileParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const TileParameter* internal_default_instance() {
return reinterpret_cast<const TileParameter*>(
&_TileParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
78;
friend void swap(TileParameter& a, TileParameter& b) {
a.Swap(&b);
}
inline void Swap(TileParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(TileParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline TileParameter* New() const final {
return CreateMaybeMessage<TileParameter>(nullptr);
}
TileParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<TileParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const TileParameter& from);
void MergeFrom(const TileParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(TileParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.TileParameter";
}
protected:
explicit TileParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kTilesFieldNumber = 2,
kAxisFieldNumber = 1,
};
// optional int32 tiles = 2;
bool has_tiles() const;
private:
bool _internal_has_tiles() const;
public:
void clear_tiles();
::PROTOBUF_NAMESPACE_ID::int32 tiles() const;
void set_tiles(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_tiles() const;
void _internal_set_tiles(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional int32 axis = 1 [default = 1];
bool has_axis() const;
private:
bool _internal_has_axis() const;
public:
void clear_axis();
::PROTOBUF_NAMESPACE_ID::int32 axis() const;
void set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_axis() const;
void _internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.TileParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::int32 tiles_;
::PROTOBUF_NAMESPACE_ID::int32 axis_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class ThresholdParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.ThresholdParameter) */ {
public:
inline ThresholdParameter() : ThresholdParameter(nullptr) {}
virtual ~ThresholdParameter();
ThresholdParameter(const ThresholdParameter& from);
ThresholdParameter(ThresholdParameter&& from) noexcept
: ThresholdParameter() {
*this = ::std::move(from);
}
inline ThresholdParameter& operator=(const ThresholdParameter& from) {
CopyFrom(from);
return *this;
}
inline ThresholdParameter& operator=(ThresholdParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const ThresholdParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const ThresholdParameter* internal_default_instance() {
return reinterpret_cast<const ThresholdParameter*>(
&_ThresholdParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
79;
friend void swap(ThresholdParameter& a, ThresholdParameter& b) {
a.Swap(&b);
}
inline void Swap(ThresholdParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(ThresholdParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline ThresholdParameter* New() const final {
return CreateMaybeMessage<ThresholdParameter>(nullptr);
}
ThresholdParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<ThresholdParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const ThresholdParameter& from);
void MergeFrom(const ThresholdParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(ThresholdParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.ThresholdParameter";
}
protected:
explicit ThresholdParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kThresholdFieldNumber = 1,
};
// optional float threshold = 1 [default = 0];
bool has_threshold() const;
private:
bool _internal_has_threshold() const;
public:
void clear_threshold();
float threshold() const;
void set_threshold(float value);
private:
float _internal_threshold() const;
void _internal_set_threshold(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.ThresholdParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
float threshold_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class MILParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.MILParameter) */ {
public:
inline MILParameter() : MILParameter(nullptr) {}
virtual ~MILParameter();
MILParameter(const MILParameter& from);
MILParameter(MILParameter&& from) noexcept
: MILParameter() {
*this = ::std::move(from);
}
inline MILParameter& operator=(const MILParameter& from) {
CopyFrom(from);
return *this;
}
inline MILParameter& operator=(MILParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const MILParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const MILParameter* internal_default_instance() {
return reinterpret_cast<const MILParameter*>(
&_MILParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
80;
friend void swap(MILParameter& a, MILParameter& b) {
a.Swap(&b);
}
inline void Swap(MILParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(MILParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline MILParameter* New() const final {
return CreateMaybeMessage<MILParameter>(nullptr);
}
MILParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<MILParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const MILParameter& from);
void MergeFrom(const MILParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(MILParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.MILParameter";
}
protected:
explicit MILParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef MILParameter_MILType MILType;
static constexpr MILType MAX =
MILParameter_MILType_MAX;
static constexpr MILType NOR =
MILParameter_MILType_NOR;
static inline bool MILType_IsValid(int value) {
return MILParameter_MILType_IsValid(value);
}
static constexpr MILType MILType_MIN =
MILParameter_MILType_MILType_MIN;
static constexpr MILType MILType_MAX =
MILParameter_MILType_MILType_MAX;
static constexpr int MILType_ARRAYSIZE =
MILParameter_MILType_MILType_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
MILType_descriptor() {
return MILParameter_MILType_descriptor();
}
template<typename T>
static inline const std::string& MILType_Name(T enum_t_value) {
static_assert(::std::is_same<T, MILType>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function MILType_Name.");
return MILParameter_MILType_Name(enum_t_value);
}
static inline bool MILType_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
MILType* value) {
return MILParameter_MILType_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kTypeFieldNumber = 1,
};
// optional .caffe.MILParameter.MILType type = 1 [default = MAX];
bool has_type() const;
private:
bool _internal_has_type() const;
public:
void clear_type();
::caffe::MILParameter_MILType type() const;
void set_type(::caffe::MILParameter_MILType value);
private:
::caffe::MILParameter_MILType _internal_type() const;
void _internal_set_type(::caffe::MILParameter_MILType value);
public:
// @@protoc_insertion_point(class_scope:caffe.MILParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
int type_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class VideoDataParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.VideoDataParameter) */ {
public:
inline VideoDataParameter() : VideoDataParameter(nullptr) {}
virtual ~VideoDataParameter();
VideoDataParameter(const VideoDataParameter& from);
VideoDataParameter(VideoDataParameter&& from) noexcept
: VideoDataParameter() {
*this = ::std::move(from);
}
inline VideoDataParameter& operator=(const VideoDataParameter& from) {
CopyFrom(from);
return *this;
}
inline VideoDataParameter& operator=(VideoDataParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const VideoDataParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const VideoDataParameter* internal_default_instance() {
return reinterpret_cast<const VideoDataParameter*>(
&_VideoDataParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
81;
friend void swap(VideoDataParameter& a, VideoDataParameter& b) {
a.Swap(&b);
}
inline void Swap(VideoDataParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(VideoDataParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline VideoDataParameter* New() const final {
return CreateMaybeMessage<VideoDataParameter>(nullptr);
}
VideoDataParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<VideoDataParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const VideoDataParameter& from);
void MergeFrom(const VideoDataParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(VideoDataParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.VideoDataParameter";
}
protected:
explicit VideoDataParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef VideoDataParameter_VideoType VideoType;
static constexpr VideoType WEBCAM =
VideoDataParameter_VideoType_WEBCAM;
static constexpr VideoType VIDEO =
VideoDataParameter_VideoType_VIDEO;
static inline bool VideoType_IsValid(int value) {
return VideoDataParameter_VideoType_IsValid(value);
}
static constexpr VideoType VideoType_MIN =
VideoDataParameter_VideoType_VideoType_MIN;
static constexpr VideoType VideoType_MAX =
VideoDataParameter_VideoType_VideoType_MAX;
static constexpr int VideoType_ARRAYSIZE =
VideoDataParameter_VideoType_VideoType_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
VideoType_descriptor() {
return VideoDataParameter_VideoType_descriptor();
}
template<typename T>
static inline const std::string& VideoType_Name(T enum_t_value) {
static_assert(::std::is_same<T, VideoType>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function VideoType_Name.");
return VideoDataParameter_VideoType_Name(enum_t_value);
}
static inline bool VideoType_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
VideoType* value) {
return VideoDataParameter_VideoType_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kVideoFileFieldNumber = 3,
kVideoTypeFieldNumber = 1,
kDeviceIdFieldNumber = 2,
};
// optional string video_file = 3;
bool has_video_file() const;
private:
bool _internal_has_video_file() const;
public:
void clear_video_file();
const std::string& video_file() const;
void set_video_file(const std::string& value);
void set_video_file(std::string&& value);
void set_video_file(const char* value);
void set_video_file(const char* value, size_t size);
std::string* mutable_video_file();
std::string* release_video_file();
void set_allocated_video_file(std::string* video_file);
private:
const std::string& _internal_video_file() const;
void _internal_set_video_file(const std::string& value);
std::string* _internal_mutable_video_file();
public:
// optional .caffe.VideoDataParameter.VideoType video_type = 1 [default = WEBCAM];
bool has_video_type() const;
private:
bool _internal_has_video_type() const;
public:
void clear_video_type();
::caffe::VideoDataParameter_VideoType video_type() const;
void set_video_type(::caffe::VideoDataParameter_VideoType value);
private:
::caffe::VideoDataParameter_VideoType _internal_video_type() const;
void _internal_set_video_type(::caffe::VideoDataParameter_VideoType value);
public:
// optional int32 device_id = 2 [default = 0];
bool has_device_id() const;
private:
bool _internal_has_device_id() const;
public:
void clear_device_id();
::PROTOBUF_NAMESPACE_ID::int32 device_id() const;
void set_device_id(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_device_id() const;
void _internal_set_device_id(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.VideoDataParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr video_file_;
int video_type_;
::PROTOBUF_NAMESPACE_ID::int32 device_id_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class WindowDataParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.WindowDataParameter) */ {
public:
inline WindowDataParameter() : WindowDataParameter(nullptr) {}
virtual ~WindowDataParameter();
WindowDataParameter(const WindowDataParameter& from);
WindowDataParameter(WindowDataParameter&& from) noexcept
: WindowDataParameter() {
*this = ::std::move(from);
}
inline WindowDataParameter& operator=(const WindowDataParameter& from) {
CopyFrom(from);
return *this;
}
inline WindowDataParameter& operator=(WindowDataParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const WindowDataParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const WindowDataParameter* internal_default_instance() {
return reinterpret_cast<const WindowDataParameter*>(
&_WindowDataParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
82;
friend void swap(WindowDataParameter& a, WindowDataParameter& b) {
a.Swap(&b);
}
inline void Swap(WindowDataParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(WindowDataParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline WindowDataParameter* New() const final {
return CreateMaybeMessage<WindowDataParameter>(nullptr);
}
WindowDataParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<WindowDataParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const WindowDataParameter& from);
void MergeFrom(const WindowDataParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(WindowDataParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.WindowDataParameter";
}
protected:
explicit WindowDataParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kSourceFieldNumber = 1,
kMeanFileFieldNumber = 3,
kCropModeFieldNumber = 11,
kRootFolderFieldNumber = 13,
kBatchSizeFieldNumber = 4,
kCropSizeFieldNumber = 5,
kMirrorFieldNumber = 6,
kCacheImagesFieldNumber = 12,
kContextPadFieldNumber = 10,
kScaleFieldNumber = 2,
kFgThresholdFieldNumber = 7,
kBgThresholdFieldNumber = 8,
kFgFractionFieldNumber = 9,
};
// optional string source = 1;
bool has_source() const;
private:
bool _internal_has_source() const;
public:
void clear_source();
const std::string& source() const;
void set_source(const std::string& value);
void set_source(std::string&& value);
void set_source(const char* value);
void set_source(const char* value, size_t size);
std::string* mutable_source();
std::string* release_source();
void set_allocated_source(std::string* source);
private:
const std::string& _internal_source() const;
void _internal_set_source(const std::string& value);
std::string* _internal_mutable_source();
public:
// optional string mean_file = 3;
bool has_mean_file() const;
private:
bool _internal_has_mean_file() const;
public:
void clear_mean_file();
const std::string& mean_file() const;
void set_mean_file(const std::string& value);
void set_mean_file(std::string&& value);
void set_mean_file(const char* value);
void set_mean_file(const char* value, size_t size);
std::string* mutable_mean_file();
std::string* release_mean_file();
void set_allocated_mean_file(std::string* mean_file);
private:
const std::string& _internal_mean_file() const;
void _internal_set_mean_file(const std::string& value);
std::string* _internal_mutable_mean_file();
public:
// optional string crop_mode = 11 [default = "warp"];
bool has_crop_mode() const;
private:
bool _internal_has_crop_mode() const;
public:
void clear_crop_mode();
const std::string& crop_mode() const;
void set_crop_mode(const std::string& value);
void set_crop_mode(std::string&& value);
void set_crop_mode(const char* value);
void set_crop_mode(const char* value, size_t size);
std::string* mutable_crop_mode();
std::string* release_crop_mode();
void set_allocated_crop_mode(std::string* crop_mode);
private:
const std::string& _internal_crop_mode() const;
void _internal_set_crop_mode(const std::string& value);
std::string* _internal_mutable_crop_mode();
public:
// optional string root_folder = 13 [default = ""];
bool has_root_folder() const;
private:
bool _internal_has_root_folder() const;
public:
void clear_root_folder();
const std::string& root_folder() const;
void set_root_folder(const std::string& value);
void set_root_folder(std::string&& value);
void set_root_folder(const char* value);
void set_root_folder(const char* value, size_t size);
std::string* mutable_root_folder();
std::string* release_root_folder();
void set_allocated_root_folder(std::string* root_folder);
private:
const std::string& _internal_root_folder() const;
void _internal_set_root_folder(const std::string& value);
std::string* _internal_mutable_root_folder();
public:
// optional uint32 batch_size = 4;
bool has_batch_size() const;
private:
bool _internal_has_batch_size() const;
public:
void clear_batch_size();
::PROTOBUF_NAMESPACE_ID::uint32 batch_size() const;
void set_batch_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_batch_size() const;
void _internal_set_batch_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 crop_size = 5 [default = 0];
bool has_crop_size() const;
private:
bool _internal_has_crop_size() const;
public:
void clear_crop_size();
::PROTOBUF_NAMESPACE_ID::uint32 crop_size() const;
void set_crop_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_crop_size() const;
void _internal_set_crop_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional bool mirror = 6 [default = false];
bool has_mirror() const;
private:
bool _internal_has_mirror() const;
public:
void clear_mirror();
bool mirror() const;
void set_mirror(bool value);
private:
bool _internal_mirror() const;
void _internal_set_mirror(bool value);
public:
// optional bool cache_images = 12 [default = false];
bool has_cache_images() const;
private:
bool _internal_has_cache_images() const;
public:
void clear_cache_images();
bool cache_images() const;
void set_cache_images(bool value);
private:
bool _internal_cache_images() const;
void _internal_set_cache_images(bool value);
public:
// optional uint32 context_pad = 10 [default = 0];
bool has_context_pad() const;
private:
bool _internal_has_context_pad() const;
public:
void clear_context_pad();
::PROTOBUF_NAMESPACE_ID::uint32 context_pad() const;
void set_context_pad(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_context_pad() const;
void _internal_set_context_pad(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional float scale = 2 [default = 1];
bool has_scale() const;
private:
bool _internal_has_scale() const;
public:
void clear_scale();
float scale() const;
void set_scale(float value);
private:
float _internal_scale() const;
void _internal_set_scale(float value);
public:
// optional float fg_threshold = 7 [default = 0.5];
bool has_fg_threshold() const;
private:
bool _internal_has_fg_threshold() const;
public:
void clear_fg_threshold();
float fg_threshold() const;
void set_fg_threshold(float value);
private:
float _internal_fg_threshold() const;
void _internal_set_fg_threshold(float value);
public:
// optional float bg_threshold = 8 [default = 0.5];
bool has_bg_threshold() const;
private:
bool _internal_has_bg_threshold() const;
public:
void clear_bg_threshold();
float bg_threshold() const;
void set_bg_threshold(float value);
private:
float _internal_bg_threshold() const;
void _internal_set_bg_threshold(float value);
public:
// optional float fg_fraction = 9 [default = 0.25];
bool has_fg_fraction() const;
private:
bool _internal_has_fg_fraction() const;
public:
void clear_fg_fraction();
float fg_fraction() const;
void set_fg_fraction(float value);
private:
float _internal_fg_fraction() const;
void _internal_set_fg_fraction(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.WindowDataParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr source_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr mean_file_;
public:
static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> _i_give_permission_to_break_this_code_default_crop_mode_;
private:
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr crop_mode_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr root_folder_;
::PROTOBUF_NAMESPACE_ID::uint32 batch_size_;
::PROTOBUF_NAMESPACE_ID::uint32 crop_size_;
bool mirror_;
bool cache_images_;
::PROTOBUF_NAMESPACE_ID::uint32 context_pad_;
float scale_;
float fg_threshold_;
float bg_threshold_;
float fg_fraction_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class MILDataParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.MILDataParameter) */ {
public:
inline MILDataParameter() : MILDataParameter(nullptr) {}
virtual ~MILDataParameter();
MILDataParameter(const MILDataParameter& from);
MILDataParameter(MILDataParameter&& from) noexcept
: MILDataParameter() {
*this = ::std::move(from);
}
inline MILDataParameter& operator=(const MILDataParameter& from) {
CopyFrom(from);
return *this;
}
inline MILDataParameter& operator=(MILDataParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const MILDataParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const MILDataParameter* internal_default_instance() {
return reinterpret_cast<const MILDataParameter*>(
&_MILDataParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
83;
friend void swap(MILDataParameter& a, MILDataParameter& b) {
a.Swap(&b);
}
inline void Swap(MILDataParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(MILDataParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline MILDataParameter* New() const final {
return CreateMaybeMessage<MILDataParameter>(nullptr);
}
MILDataParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<MILDataParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const MILDataParameter& from);
void MergeFrom(const MILDataParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(MILDataParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.MILDataParameter";
}
protected:
explicit MILDataParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kSourceFieldNumber = 1,
kLabelFileFieldNumber = 7,
kRootDirFieldNumber = 11,
kExtFieldNumber = 12,
kImagesPerBatchFieldNumber = 3,
kNClassesFieldNumber = 5,
kNumScalesFieldNumber = 2,
kChannelsFieldNumber = 4,
kScaleFactorFieldNumber = 6,
kRandomizeFieldNumber = 13,
};
// optional string source = 1;
bool has_source() const;
private:
bool _internal_has_source() const;
public:
void clear_source();
const std::string& source() const;
void set_source(const std::string& value);
void set_source(std::string&& value);
void set_source(const char* value);
void set_source(const char* value, size_t size);
std::string* mutable_source();
std::string* release_source();
void set_allocated_source(std::string* source);
private:
const std::string& _internal_source() const;
void _internal_set_source(const std::string& value);
std::string* _internal_mutable_source();
public:
// optional string label_file = 7;
bool has_label_file() const;
private:
bool _internal_has_label_file() const;
public:
void clear_label_file();
const std::string& label_file() const;
void set_label_file(const std::string& value);
void set_label_file(std::string&& value);
void set_label_file(const char* value);
void set_label_file(const char* value, size_t size);
std::string* mutable_label_file();
std::string* release_label_file();
void set_allocated_label_file(std::string* label_file);
private:
const std::string& _internal_label_file() const;
void _internal_set_label_file(const std::string& value);
std::string* _internal_mutable_label_file();
public:
// optional string root_dir = 11;
bool has_root_dir() const;
private:
bool _internal_has_root_dir() const;
public:
void clear_root_dir();
const std::string& root_dir() const;
void set_root_dir(const std::string& value);
void set_root_dir(std::string&& value);
void set_root_dir(const char* value);
void set_root_dir(const char* value, size_t size);
std::string* mutable_root_dir();
std::string* release_root_dir();
void set_allocated_root_dir(std::string* root_dir);
private:
const std::string& _internal_root_dir() const;
void _internal_set_root_dir(const std::string& value);
std::string* _internal_mutable_root_dir();
public:
// optional string ext = 12;
bool has_ext() const;
private:
bool _internal_has_ext() const;
public:
void clear_ext();
const std::string& ext() const;
void set_ext(const std::string& value);
void set_ext(std::string&& value);
void set_ext(const char* value);
void set_ext(const char* value, size_t size);
std::string* mutable_ext();
std::string* release_ext();
void set_allocated_ext(std::string* ext);
private:
const std::string& _internal_ext() const;
void _internal_set_ext(const std::string& value);
std::string* _internal_mutable_ext();
public:
// optional uint32 images_per_batch = 3;
bool has_images_per_batch() const;
private:
bool _internal_has_images_per_batch() const;
public:
void clear_images_per_batch();
::PROTOBUF_NAMESPACE_ID::uint32 images_per_batch() const;
void set_images_per_batch(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_images_per_batch() const;
void _internal_set_images_per_batch(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 n_classes = 5;
bool has_n_classes() const;
private:
bool _internal_has_n_classes() const;
public:
void clear_n_classes();
::PROTOBUF_NAMESPACE_ID::uint32 n_classes() const;
void set_n_classes(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_n_classes() const;
void _internal_set_n_classes(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 num_scales = 2 [default = 1];
bool has_num_scales() const;
private:
bool _internal_has_num_scales() const;
public:
void clear_num_scales();
::PROTOBUF_NAMESPACE_ID::uint32 num_scales() const;
void set_num_scales(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_num_scales() const;
void _internal_set_num_scales(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 channels = 4 [default = 3];
bool has_channels() const;
private:
bool _internal_has_channels() const;
public:
void clear_channels();
::PROTOBUF_NAMESPACE_ID::uint32 channels() const;
void set_channels(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_channels() const;
void _internal_set_channels(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional float scale_factor = 6 [default = 1];
bool has_scale_factor() const;
private:
bool _internal_has_scale_factor() const;
public:
void clear_scale_factor();
float scale_factor() const;
void set_scale_factor(float value);
private:
float _internal_scale_factor() const;
void _internal_set_scale_factor(float value);
public:
// optional bool randomize = 13 [default = true];
bool has_randomize() const;
private:
bool _internal_has_randomize() const;
public:
void clear_randomize();
bool randomize() const;
void set_randomize(bool value);
private:
bool _internal_randomize() const;
void _internal_set_randomize(bool value);
public:
// @@protoc_insertion_point(class_scope:caffe.MILDataParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr source_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr label_file_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr root_dir_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr ext_;
::PROTOBUF_NAMESPACE_ID::uint32 images_per_batch_;
::PROTOBUF_NAMESPACE_ID::uint32 n_classes_;
::PROTOBUF_NAMESPACE_ID::uint32 num_scales_;
::PROTOBUF_NAMESPACE_ID::uint32 channels_;
float scale_factor_;
bool randomize_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class SPPParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.SPPParameter) */ {
public:
inline SPPParameter() : SPPParameter(nullptr) {}
virtual ~SPPParameter();
SPPParameter(const SPPParameter& from);
SPPParameter(SPPParameter&& from) noexcept
: SPPParameter() {
*this = ::std::move(from);
}
inline SPPParameter& operator=(const SPPParameter& from) {
CopyFrom(from);
return *this;
}
inline SPPParameter& operator=(SPPParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const SPPParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const SPPParameter* internal_default_instance() {
return reinterpret_cast<const SPPParameter*>(
&_SPPParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
84;
friend void swap(SPPParameter& a, SPPParameter& b) {
a.Swap(&b);
}
inline void Swap(SPPParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(SPPParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline SPPParameter* New() const final {
return CreateMaybeMessage<SPPParameter>(nullptr);
}
SPPParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<SPPParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const SPPParameter& from);
void MergeFrom(const SPPParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(SPPParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.SPPParameter";
}
protected:
explicit SPPParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef SPPParameter_PoolMethod PoolMethod;
static constexpr PoolMethod MAX =
SPPParameter_PoolMethod_MAX;
static constexpr PoolMethod AVE =
SPPParameter_PoolMethod_AVE;
static constexpr PoolMethod STOCHASTIC =
SPPParameter_PoolMethod_STOCHASTIC;
static inline bool PoolMethod_IsValid(int value) {
return SPPParameter_PoolMethod_IsValid(value);
}
static constexpr PoolMethod PoolMethod_MIN =
SPPParameter_PoolMethod_PoolMethod_MIN;
static constexpr PoolMethod PoolMethod_MAX =
SPPParameter_PoolMethod_PoolMethod_MAX;
static constexpr int PoolMethod_ARRAYSIZE =
SPPParameter_PoolMethod_PoolMethod_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
PoolMethod_descriptor() {
return SPPParameter_PoolMethod_descriptor();
}
template<typename T>
static inline const std::string& PoolMethod_Name(T enum_t_value) {
static_assert(::std::is_same<T, PoolMethod>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function PoolMethod_Name.");
return SPPParameter_PoolMethod_Name(enum_t_value);
}
static inline bool PoolMethod_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
PoolMethod* value) {
return SPPParameter_PoolMethod_Parse(name, value);
}
typedef SPPParameter_Engine Engine;
static constexpr Engine DEFAULT =
SPPParameter_Engine_DEFAULT;
static constexpr Engine CAFFE =
SPPParameter_Engine_CAFFE;
static constexpr Engine CUDNN =
SPPParameter_Engine_CUDNN;
static inline bool Engine_IsValid(int value) {
return SPPParameter_Engine_IsValid(value);
}
static constexpr Engine Engine_MIN =
SPPParameter_Engine_Engine_MIN;
static constexpr Engine Engine_MAX =
SPPParameter_Engine_Engine_MAX;
static constexpr int Engine_ARRAYSIZE =
SPPParameter_Engine_Engine_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
Engine_descriptor() {
return SPPParameter_Engine_descriptor();
}
template<typename T>
static inline const std::string& Engine_Name(T enum_t_value) {
static_assert(::std::is_same<T, Engine>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function Engine_Name.");
return SPPParameter_Engine_Name(enum_t_value);
}
static inline bool Engine_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
Engine* value) {
return SPPParameter_Engine_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kPyramidHeightFieldNumber = 1,
kPoolFieldNumber = 2,
kEngineFieldNumber = 6,
};
// optional uint32 pyramid_height = 1;
bool has_pyramid_height() const;
private:
bool _internal_has_pyramid_height() const;
public:
void clear_pyramid_height();
::PROTOBUF_NAMESPACE_ID::uint32 pyramid_height() const;
void set_pyramid_height(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_pyramid_height() const;
void _internal_set_pyramid_height(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional .caffe.SPPParameter.PoolMethod pool = 2 [default = MAX];
bool has_pool() const;
private:
bool _internal_has_pool() const;
public:
void clear_pool();
::caffe::SPPParameter_PoolMethod pool() const;
void set_pool(::caffe::SPPParameter_PoolMethod value);
private:
::caffe::SPPParameter_PoolMethod _internal_pool() const;
void _internal_set_pool(::caffe::SPPParameter_PoolMethod value);
public:
// optional .caffe.SPPParameter.Engine engine = 6 [default = DEFAULT];
bool has_engine() const;
private:
bool _internal_has_engine() const;
public:
void clear_engine();
::caffe::SPPParameter_Engine engine() const;
void set_engine(::caffe::SPPParameter_Engine value);
private:
::caffe::SPPParameter_Engine _internal_engine() const;
void _internal_set_engine(::caffe::SPPParameter_Engine value);
public:
// @@protoc_insertion_point(class_scope:caffe.SPPParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::uint32 pyramid_height_;
int pool_;
int engine_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class V1LayerParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.V1LayerParameter) */ {
public:
inline V1LayerParameter() : V1LayerParameter(nullptr) {}
virtual ~V1LayerParameter();
V1LayerParameter(const V1LayerParameter& from);
V1LayerParameter(V1LayerParameter&& from) noexcept
: V1LayerParameter() {
*this = ::std::move(from);
}
inline V1LayerParameter& operator=(const V1LayerParameter& from) {
CopyFrom(from);
return *this;
}
inline V1LayerParameter& operator=(V1LayerParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const V1LayerParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const V1LayerParameter* internal_default_instance() {
return reinterpret_cast<const V1LayerParameter*>(
&_V1LayerParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
85;
friend void swap(V1LayerParameter& a, V1LayerParameter& b) {
a.Swap(&b);
}
inline void Swap(V1LayerParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(V1LayerParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline V1LayerParameter* New() const final {
return CreateMaybeMessage<V1LayerParameter>(nullptr);
}
V1LayerParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<V1LayerParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const V1LayerParameter& from);
void MergeFrom(const V1LayerParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(V1LayerParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.V1LayerParameter";
}
protected:
explicit V1LayerParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef V1LayerParameter_LayerType LayerType;
static constexpr LayerType NONE =
V1LayerParameter_LayerType_NONE;
static constexpr LayerType ABSVAL =
V1LayerParameter_LayerType_ABSVAL;
static constexpr LayerType ACCURACY =
V1LayerParameter_LayerType_ACCURACY;
static constexpr LayerType ARGMAX =
V1LayerParameter_LayerType_ARGMAX;
static constexpr LayerType BNLL =
V1LayerParameter_LayerType_BNLL;
static constexpr LayerType CONCAT =
V1LayerParameter_LayerType_CONCAT;
static constexpr LayerType CONTRASTIVE_LOSS =
V1LayerParameter_LayerType_CONTRASTIVE_LOSS;
static constexpr LayerType CONVOLUTION =
V1LayerParameter_LayerType_CONVOLUTION;
static constexpr LayerType DATA =
V1LayerParameter_LayerType_DATA;
static constexpr LayerType DECONVOLUTION =
V1LayerParameter_LayerType_DECONVOLUTION;
static constexpr LayerType DROPOUT =
V1LayerParameter_LayerType_DROPOUT;
static constexpr LayerType DUMMY_DATA =
V1LayerParameter_LayerType_DUMMY_DATA;
static constexpr LayerType EUCLIDEAN_LOSS =
V1LayerParameter_LayerType_EUCLIDEAN_LOSS;
static constexpr LayerType ELTWISE =
V1LayerParameter_LayerType_ELTWISE;
static constexpr LayerType EXP =
V1LayerParameter_LayerType_EXP;
static constexpr LayerType FLATTEN =
V1LayerParameter_LayerType_FLATTEN;
static constexpr LayerType HDF5_DATA =
V1LayerParameter_LayerType_HDF5_DATA;
static constexpr LayerType HDF5_OUTPUT =
V1LayerParameter_LayerType_HDF5_OUTPUT;
static constexpr LayerType HINGE_LOSS =
V1LayerParameter_LayerType_HINGE_LOSS;
static constexpr LayerType IM2COL =
V1LayerParameter_LayerType_IM2COL;
static constexpr LayerType IMAGE_DATA =
V1LayerParameter_LayerType_IMAGE_DATA;
static constexpr LayerType INFOGAIN_LOSS =
V1LayerParameter_LayerType_INFOGAIN_LOSS;
static constexpr LayerType INNER_PRODUCT =
V1LayerParameter_LayerType_INNER_PRODUCT;
static constexpr LayerType LRN =
V1LayerParameter_LayerType_LRN;
static constexpr LayerType MEMORY_DATA =
V1LayerParameter_LayerType_MEMORY_DATA;
static constexpr LayerType MULTINOMIAL_LOGISTIC_LOSS =
V1LayerParameter_LayerType_MULTINOMIAL_LOGISTIC_LOSS;
static constexpr LayerType MVN =
V1LayerParameter_LayerType_MVN;
static constexpr LayerType POOLING =
V1LayerParameter_LayerType_POOLING;
static constexpr LayerType POWER =
V1LayerParameter_LayerType_POWER;
static constexpr LayerType RELU =
V1LayerParameter_LayerType_RELU;
static constexpr LayerType SIGMOID =
V1LayerParameter_LayerType_SIGMOID;
static constexpr LayerType SIGMOID_CROSS_ENTROPY_LOSS =
V1LayerParameter_LayerType_SIGMOID_CROSS_ENTROPY_LOSS;
static constexpr LayerType SILENCE =
V1LayerParameter_LayerType_SILENCE;
static constexpr LayerType SOFTMAX =
V1LayerParameter_LayerType_SOFTMAX;
static constexpr LayerType SOFTMAX_LOSS =
V1LayerParameter_LayerType_SOFTMAX_LOSS;
static constexpr LayerType SPLIT =
V1LayerParameter_LayerType_SPLIT;
static constexpr LayerType SLICE =
V1LayerParameter_LayerType_SLICE;
static constexpr LayerType TANH =
V1LayerParameter_LayerType_TANH;
static constexpr LayerType WINDOW_DATA =
V1LayerParameter_LayerType_WINDOW_DATA;
static constexpr LayerType THRESHOLD =
V1LayerParameter_LayerType_THRESHOLD;
static inline bool LayerType_IsValid(int value) {
return V1LayerParameter_LayerType_IsValid(value);
}
static constexpr LayerType LayerType_MIN =
V1LayerParameter_LayerType_LayerType_MIN;
static constexpr LayerType LayerType_MAX =
V1LayerParameter_LayerType_LayerType_MAX;
static constexpr int LayerType_ARRAYSIZE =
V1LayerParameter_LayerType_LayerType_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
LayerType_descriptor() {
return V1LayerParameter_LayerType_descriptor();
}
template<typename T>
static inline const std::string& LayerType_Name(T enum_t_value) {
static_assert(::std::is_same<T, LayerType>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function LayerType_Name.");
return V1LayerParameter_LayerType_Name(enum_t_value);
}
static inline bool LayerType_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
LayerType* value) {
return V1LayerParameter_LayerType_Parse(name, value);
}
typedef V1LayerParameter_DimCheckMode DimCheckMode;
static constexpr DimCheckMode STRICT =
V1LayerParameter_DimCheckMode_STRICT;
static constexpr DimCheckMode PERMISSIVE =
V1LayerParameter_DimCheckMode_PERMISSIVE;
static inline bool DimCheckMode_IsValid(int value) {
return V1LayerParameter_DimCheckMode_IsValid(value);
}
static constexpr DimCheckMode DimCheckMode_MIN =
V1LayerParameter_DimCheckMode_DimCheckMode_MIN;
static constexpr DimCheckMode DimCheckMode_MAX =
V1LayerParameter_DimCheckMode_DimCheckMode_MAX;
static constexpr int DimCheckMode_ARRAYSIZE =
V1LayerParameter_DimCheckMode_DimCheckMode_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
DimCheckMode_descriptor() {
return V1LayerParameter_DimCheckMode_descriptor();
}
template<typename T>
static inline const std::string& DimCheckMode_Name(T enum_t_value) {
static_assert(::std::is_same<T, DimCheckMode>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function DimCheckMode_Name.");
return V1LayerParameter_DimCheckMode_Name(enum_t_value);
}
static inline bool DimCheckMode_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
DimCheckMode* value) {
return V1LayerParameter_DimCheckMode_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kBottomFieldNumber = 2,
kTopFieldNumber = 3,
kBlobsFieldNumber = 6,
kBlobsLrFieldNumber = 7,
kWeightDecayFieldNumber = 8,
kIncludeFieldNumber = 32,
kExcludeFieldNumber = 33,
kLossWeightFieldNumber = 35,
kParamFieldNumber = 1001,
kBlobShareModeFieldNumber = 1002,
kNameFieldNumber = 4,
kLayerFieldNumber = 1,
kConcatParamFieldNumber = 9,
kConvolutionParamFieldNumber = 10,
kDataParamFieldNumber = 11,
kDropoutParamFieldNumber = 12,
kHdf5DataParamFieldNumber = 13,
kHdf5OutputParamFieldNumber = 14,
kImageDataParamFieldNumber = 15,
kInfogainLossParamFieldNumber = 16,
kInnerProductParamFieldNumber = 17,
kLrnParamFieldNumber = 18,
kPoolingParamFieldNumber = 19,
kWindowDataParamFieldNumber = 20,
kPowerParamFieldNumber = 21,
kMemoryDataParamFieldNumber = 22,
kArgmaxParamFieldNumber = 23,
kEltwiseParamFieldNumber = 24,
kThresholdParamFieldNumber = 25,
kDummyDataParamFieldNumber = 26,
kAccuracyParamFieldNumber = 27,
kHingeLossParamFieldNumber = 29,
kReluParamFieldNumber = 30,
kSliceParamFieldNumber = 31,
kMvnParamFieldNumber = 34,
kTransformParamFieldNumber = 36,
kTanhParamFieldNumber = 37,
kSigmoidParamFieldNumber = 38,
kSoftmaxParamFieldNumber = 39,
kContrastiveLossParamFieldNumber = 40,
kExpParamFieldNumber = 41,
kLossParamFieldNumber = 42,
kTypeFieldNumber = 5,
};
// repeated string bottom = 2;
int bottom_size() const;
private:
int _internal_bottom_size() const;
public:
void clear_bottom();
const std::string& bottom(int index) const;
std::string* mutable_bottom(int index);
void set_bottom(int index, const std::string& value);
void set_bottom(int index, std::string&& value);
void set_bottom(int index, const char* value);
void set_bottom(int index, const char* value, size_t size);
std::string* add_bottom();
void add_bottom(const std::string& value);
void add_bottom(std::string&& value);
void add_bottom(const char* value);
void add_bottom(const char* value, size_t size);
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>& bottom() const;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>* mutable_bottom();
private:
const std::string& _internal_bottom(int index) const;
std::string* _internal_add_bottom();
public:
// repeated string top = 3;
int top_size() const;
private:
int _internal_top_size() const;
public:
void clear_top();
const std::string& top(int index) const;
std::string* mutable_top(int index);
void set_top(int index, const std::string& value);
void set_top(int index, std::string&& value);
void set_top(int index, const char* value);
void set_top(int index, const char* value, size_t size);
std::string* add_top();
void add_top(const std::string& value);
void add_top(std::string&& value);
void add_top(const char* value);
void add_top(const char* value, size_t size);
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>& top() const;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>* mutable_top();
private:
const std::string& _internal_top(int index) const;
std::string* _internal_add_top();
public:
// repeated .caffe.BlobProto blobs = 6;
int blobs_size() const;
private:
int _internal_blobs_size() const;
public:
void clear_blobs();
::caffe::BlobProto* mutable_blobs(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto >*
mutable_blobs();
private:
const ::caffe::BlobProto& _internal_blobs(int index) const;
::caffe::BlobProto* _internal_add_blobs();
public:
const ::caffe::BlobProto& blobs(int index) const;
::caffe::BlobProto* add_blobs();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto >&
blobs() const;
// repeated float blobs_lr = 7;
int blobs_lr_size() const;
private:
int _internal_blobs_lr_size() const;
public:
void clear_blobs_lr();
private:
float _internal_blobs_lr(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
_internal_blobs_lr() const;
void _internal_add_blobs_lr(float value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
_internal_mutable_blobs_lr();
public:
float blobs_lr(int index) const;
void set_blobs_lr(int index, float value);
void add_blobs_lr(float value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
blobs_lr() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
mutable_blobs_lr();
// repeated float weight_decay = 8;
int weight_decay_size() const;
private:
int _internal_weight_decay_size() const;
public:
void clear_weight_decay();
private:
float _internal_weight_decay(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
_internal_weight_decay() const;
void _internal_add_weight_decay(float value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
_internal_mutable_weight_decay();
public:
float weight_decay(int index) const;
void set_weight_decay(int index, float value);
void add_weight_decay(float value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
weight_decay() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
mutable_weight_decay();
// repeated .caffe.NetStateRule include = 32;
int include_size() const;
private:
int _internal_include_size() const;
public:
void clear_include();
::caffe::NetStateRule* mutable_include(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetStateRule >*
mutable_include();
private:
const ::caffe::NetStateRule& _internal_include(int index) const;
::caffe::NetStateRule* _internal_add_include();
public:
const ::caffe::NetStateRule& include(int index) const;
::caffe::NetStateRule* add_include();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetStateRule >&
include() const;
// repeated .caffe.NetStateRule exclude = 33;
int exclude_size() const;
private:
int _internal_exclude_size() const;
public:
void clear_exclude();
::caffe::NetStateRule* mutable_exclude(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetStateRule >*
mutable_exclude();
private:
const ::caffe::NetStateRule& _internal_exclude(int index) const;
::caffe::NetStateRule* _internal_add_exclude();
public:
const ::caffe::NetStateRule& exclude(int index) const;
::caffe::NetStateRule* add_exclude();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetStateRule >&
exclude() const;
// repeated float loss_weight = 35;
int loss_weight_size() const;
private:
int _internal_loss_weight_size() const;
public:
void clear_loss_weight();
private:
float _internal_loss_weight(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
_internal_loss_weight() const;
void _internal_add_loss_weight(float value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
_internal_mutable_loss_weight();
public:
float loss_weight(int index) const;
void set_loss_weight(int index, float value);
void add_loss_weight(float value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
loss_weight() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
mutable_loss_weight();
// repeated string param = 1001;
int param_size() const;
private:
int _internal_param_size() const;
public:
void clear_param();
const std::string& param(int index) const;
std::string* mutable_param(int index);
void set_param(int index, const std::string& value);
void set_param(int index, std::string&& value);
void set_param(int index, const char* value);
void set_param(int index, const char* value, size_t size);
std::string* add_param();
void add_param(const std::string& value);
void add_param(std::string&& value);
void add_param(const char* value);
void add_param(const char* value, size_t size);
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>& param() const;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>* mutable_param();
private:
const std::string& _internal_param(int index) const;
std::string* _internal_add_param();
public:
// repeated .caffe.V1LayerParameter.DimCheckMode blob_share_mode = 1002;
int blob_share_mode_size() const;
private:
int _internal_blob_share_mode_size() const;
public:
void clear_blob_share_mode();
private:
::caffe::V1LayerParameter_DimCheckMode _internal_blob_share_mode(int index) const;
void _internal_add_blob_share_mode(::caffe::V1LayerParameter_DimCheckMode value);
::PROTOBUF_NAMESPACE_ID::RepeatedField<int>* _internal_mutable_blob_share_mode();
public:
::caffe::V1LayerParameter_DimCheckMode blob_share_mode(int index) const;
void set_blob_share_mode(int index, ::caffe::V1LayerParameter_DimCheckMode value);
void add_blob_share_mode(::caffe::V1LayerParameter_DimCheckMode value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField<int>& blob_share_mode() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField<int>* mutable_blob_share_mode();
// optional string name = 4;
bool has_name() const;
private:
bool _internal_has_name() const;
public:
void clear_name();
const std::string& name() const;
void set_name(const std::string& value);
void set_name(std::string&& value);
void set_name(const char* value);
void set_name(const char* value, size_t size);
std::string* mutable_name();
std::string* release_name();
void set_allocated_name(std::string* name);
private:
const std::string& _internal_name() const;
void _internal_set_name(const std::string& value);
std::string* _internal_mutable_name();
public:
// optional .caffe.V0LayerParameter layer = 1;
bool has_layer() const;
private:
bool _internal_has_layer() const;
public:
void clear_layer();
const ::caffe::V0LayerParameter& layer() const;
::caffe::V0LayerParameter* release_layer();
::caffe::V0LayerParameter* mutable_layer();
void set_allocated_layer(::caffe::V0LayerParameter* layer);
private:
const ::caffe::V0LayerParameter& _internal_layer() const;
::caffe::V0LayerParameter* _internal_mutable_layer();
public:
void unsafe_arena_set_allocated_layer(
::caffe::V0LayerParameter* layer);
::caffe::V0LayerParameter* unsafe_arena_release_layer();
// optional .caffe.ConcatParameter concat_param = 9;
bool has_concat_param() const;
private:
bool _internal_has_concat_param() const;
public:
void clear_concat_param();
const ::caffe::ConcatParameter& concat_param() const;
::caffe::ConcatParameter* release_concat_param();
::caffe::ConcatParameter* mutable_concat_param();
void set_allocated_concat_param(::caffe::ConcatParameter* concat_param);
private:
const ::caffe::ConcatParameter& _internal_concat_param() const;
::caffe::ConcatParameter* _internal_mutable_concat_param();
public:
void unsafe_arena_set_allocated_concat_param(
::caffe::ConcatParameter* concat_param);
::caffe::ConcatParameter* unsafe_arena_release_concat_param();
// optional .caffe.ConvolutionParameter convolution_param = 10;
bool has_convolution_param() const;
private:
bool _internal_has_convolution_param() const;
public:
void clear_convolution_param();
const ::caffe::ConvolutionParameter& convolution_param() const;
::caffe::ConvolutionParameter* release_convolution_param();
::caffe::ConvolutionParameter* mutable_convolution_param();
void set_allocated_convolution_param(::caffe::ConvolutionParameter* convolution_param);
private:
const ::caffe::ConvolutionParameter& _internal_convolution_param() const;
::caffe::ConvolutionParameter* _internal_mutable_convolution_param();
public:
void unsafe_arena_set_allocated_convolution_param(
::caffe::ConvolutionParameter* convolution_param);
::caffe::ConvolutionParameter* unsafe_arena_release_convolution_param();
// optional .caffe.DataParameter data_param = 11;
bool has_data_param() const;
private:
bool _internal_has_data_param() const;
public:
void clear_data_param();
const ::caffe::DataParameter& data_param() const;
::caffe::DataParameter* release_data_param();
::caffe::DataParameter* mutable_data_param();
void set_allocated_data_param(::caffe::DataParameter* data_param);
private:
const ::caffe::DataParameter& _internal_data_param() const;
::caffe::DataParameter* _internal_mutable_data_param();
public:
void unsafe_arena_set_allocated_data_param(
::caffe::DataParameter* data_param);
::caffe::DataParameter* unsafe_arena_release_data_param();
// optional .caffe.DropoutParameter dropout_param = 12;
bool has_dropout_param() const;
private:
bool _internal_has_dropout_param() const;
public:
void clear_dropout_param();
const ::caffe::DropoutParameter& dropout_param() const;
::caffe::DropoutParameter* release_dropout_param();
::caffe::DropoutParameter* mutable_dropout_param();
void set_allocated_dropout_param(::caffe::DropoutParameter* dropout_param);
private:
const ::caffe::DropoutParameter& _internal_dropout_param() const;
::caffe::DropoutParameter* _internal_mutable_dropout_param();
public:
void unsafe_arena_set_allocated_dropout_param(
::caffe::DropoutParameter* dropout_param);
::caffe::DropoutParameter* unsafe_arena_release_dropout_param();
// optional .caffe.HDF5DataParameter hdf5_data_param = 13;
bool has_hdf5_data_param() const;
private:
bool _internal_has_hdf5_data_param() const;
public:
void clear_hdf5_data_param();
const ::caffe::HDF5DataParameter& hdf5_data_param() const;
::caffe::HDF5DataParameter* release_hdf5_data_param();
::caffe::HDF5DataParameter* mutable_hdf5_data_param();
void set_allocated_hdf5_data_param(::caffe::HDF5DataParameter* hdf5_data_param);
private:
const ::caffe::HDF5DataParameter& _internal_hdf5_data_param() const;
::caffe::HDF5DataParameter* _internal_mutable_hdf5_data_param();
public:
void unsafe_arena_set_allocated_hdf5_data_param(
::caffe::HDF5DataParameter* hdf5_data_param);
::caffe::HDF5DataParameter* unsafe_arena_release_hdf5_data_param();
// optional .caffe.HDF5OutputParameter hdf5_output_param = 14;
bool has_hdf5_output_param() const;
private:
bool _internal_has_hdf5_output_param() const;
public:
void clear_hdf5_output_param();
const ::caffe::HDF5OutputParameter& hdf5_output_param() const;
::caffe::HDF5OutputParameter* release_hdf5_output_param();
::caffe::HDF5OutputParameter* mutable_hdf5_output_param();
void set_allocated_hdf5_output_param(::caffe::HDF5OutputParameter* hdf5_output_param);
private:
const ::caffe::HDF5OutputParameter& _internal_hdf5_output_param() const;
::caffe::HDF5OutputParameter* _internal_mutable_hdf5_output_param();
public:
void unsafe_arena_set_allocated_hdf5_output_param(
::caffe::HDF5OutputParameter* hdf5_output_param);
::caffe::HDF5OutputParameter* unsafe_arena_release_hdf5_output_param();
// optional .caffe.ImageDataParameter image_data_param = 15;
bool has_image_data_param() const;
private:
bool _internal_has_image_data_param() const;
public:
void clear_image_data_param();
const ::caffe::ImageDataParameter& image_data_param() const;
::caffe::ImageDataParameter* release_image_data_param();
::caffe::ImageDataParameter* mutable_image_data_param();
void set_allocated_image_data_param(::caffe::ImageDataParameter* image_data_param);
private:
const ::caffe::ImageDataParameter& _internal_image_data_param() const;
::caffe::ImageDataParameter* _internal_mutable_image_data_param();
public:
void unsafe_arena_set_allocated_image_data_param(
::caffe::ImageDataParameter* image_data_param);
::caffe::ImageDataParameter* unsafe_arena_release_image_data_param();
// optional .caffe.InfogainLossParameter infogain_loss_param = 16;
bool has_infogain_loss_param() const;
private:
bool _internal_has_infogain_loss_param() const;
public:
void clear_infogain_loss_param();
const ::caffe::InfogainLossParameter& infogain_loss_param() const;
::caffe::InfogainLossParameter* release_infogain_loss_param();
::caffe::InfogainLossParameter* mutable_infogain_loss_param();
void set_allocated_infogain_loss_param(::caffe::InfogainLossParameter* infogain_loss_param);
private:
const ::caffe::InfogainLossParameter& _internal_infogain_loss_param() const;
::caffe::InfogainLossParameter* _internal_mutable_infogain_loss_param();
public:
void unsafe_arena_set_allocated_infogain_loss_param(
::caffe::InfogainLossParameter* infogain_loss_param);
::caffe::InfogainLossParameter* unsafe_arena_release_infogain_loss_param();
// optional .caffe.InnerProductParameter inner_product_param = 17;
bool has_inner_product_param() const;
private:
bool _internal_has_inner_product_param() const;
public:
void clear_inner_product_param();
const ::caffe::InnerProductParameter& inner_product_param() const;
::caffe::InnerProductParameter* release_inner_product_param();
::caffe::InnerProductParameter* mutable_inner_product_param();
void set_allocated_inner_product_param(::caffe::InnerProductParameter* inner_product_param);
private:
const ::caffe::InnerProductParameter& _internal_inner_product_param() const;
::caffe::InnerProductParameter* _internal_mutable_inner_product_param();
public:
void unsafe_arena_set_allocated_inner_product_param(
::caffe::InnerProductParameter* inner_product_param);
::caffe::InnerProductParameter* unsafe_arena_release_inner_product_param();
// optional .caffe.LRNParameter lrn_param = 18;
bool has_lrn_param() const;
private:
bool _internal_has_lrn_param() const;
public:
void clear_lrn_param();
const ::caffe::LRNParameter& lrn_param() const;
::caffe::LRNParameter* release_lrn_param();
::caffe::LRNParameter* mutable_lrn_param();
void set_allocated_lrn_param(::caffe::LRNParameter* lrn_param);
private:
const ::caffe::LRNParameter& _internal_lrn_param() const;
::caffe::LRNParameter* _internal_mutable_lrn_param();
public:
void unsafe_arena_set_allocated_lrn_param(
::caffe::LRNParameter* lrn_param);
::caffe::LRNParameter* unsafe_arena_release_lrn_param();
// optional .caffe.PoolingParameter pooling_param = 19;
bool has_pooling_param() const;
private:
bool _internal_has_pooling_param() const;
public:
void clear_pooling_param();
const ::caffe::PoolingParameter& pooling_param() const;
::caffe::PoolingParameter* release_pooling_param();
::caffe::PoolingParameter* mutable_pooling_param();
void set_allocated_pooling_param(::caffe::PoolingParameter* pooling_param);
private:
const ::caffe::PoolingParameter& _internal_pooling_param() const;
::caffe::PoolingParameter* _internal_mutable_pooling_param();
public:
void unsafe_arena_set_allocated_pooling_param(
::caffe::PoolingParameter* pooling_param);
::caffe::PoolingParameter* unsafe_arena_release_pooling_param();
// optional .caffe.WindowDataParameter window_data_param = 20;
bool has_window_data_param() const;
private:
bool _internal_has_window_data_param() const;
public:
void clear_window_data_param();
const ::caffe::WindowDataParameter& window_data_param() const;
::caffe::WindowDataParameter* release_window_data_param();
::caffe::WindowDataParameter* mutable_window_data_param();
void set_allocated_window_data_param(::caffe::WindowDataParameter* window_data_param);
private:
const ::caffe::WindowDataParameter& _internal_window_data_param() const;
::caffe::WindowDataParameter* _internal_mutable_window_data_param();
public:
void unsafe_arena_set_allocated_window_data_param(
::caffe::WindowDataParameter* window_data_param);
::caffe::WindowDataParameter* unsafe_arena_release_window_data_param();
// optional .caffe.PowerParameter power_param = 21;
bool has_power_param() const;
private:
bool _internal_has_power_param() const;
public:
void clear_power_param();
const ::caffe::PowerParameter& power_param() const;
::caffe::PowerParameter* release_power_param();
::caffe::PowerParameter* mutable_power_param();
void set_allocated_power_param(::caffe::PowerParameter* power_param);
private:
const ::caffe::PowerParameter& _internal_power_param() const;
::caffe::PowerParameter* _internal_mutable_power_param();
public:
void unsafe_arena_set_allocated_power_param(
::caffe::PowerParameter* power_param);
::caffe::PowerParameter* unsafe_arena_release_power_param();
// optional .caffe.MemoryDataParameter memory_data_param = 22;
bool has_memory_data_param() const;
private:
bool _internal_has_memory_data_param() const;
public:
void clear_memory_data_param();
const ::caffe::MemoryDataParameter& memory_data_param() const;
::caffe::MemoryDataParameter* release_memory_data_param();
::caffe::MemoryDataParameter* mutable_memory_data_param();
void set_allocated_memory_data_param(::caffe::MemoryDataParameter* memory_data_param);
private:
const ::caffe::MemoryDataParameter& _internal_memory_data_param() const;
::caffe::MemoryDataParameter* _internal_mutable_memory_data_param();
public:
void unsafe_arena_set_allocated_memory_data_param(
::caffe::MemoryDataParameter* memory_data_param);
::caffe::MemoryDataParameter* unsafe_arena_release_memory_data_param();
// optional .caffe.ArgMaxParameter argmax_param = 23;
bool has_argmax_param() const;
private:
bool _internal_has_argmax_param() const;
public:
void clear_argmax_param();
const ::caffe::ArgMaxParameter& argmax_param() const;
::caffe::ArgMaxParameter* release_argmax_param();
::caffe::ArgMaxParameter* mutable_argmax_param();
void set_allocated_argmax_param(::caffe::ArgMaxParameter* argmax_param);
private:
const ::caffe::ArgMaxParameter& _internal_argmax_param() const;
::caffe::ArgMaxParameter* _internal_mutable_argmax_param();
public:
void unsafe_arena_set_allocated_argmax_param(
::caffe::ArgMaxParameter* argmax_param);
::caffe::ArgMaxParameter* unsafe_arena_release_argmax_param();
// optional .caffe.EltwiseParameter eltwise_param = 24;
bool has_eltwise_param() const;
private:
bool _internal_has_eltwise_param() const;
public:
void clear_eltwise_param();
const ::caffe::EltwiseParameter& eltwise_param() const;
::caffe::EltwiseParameter* release_eltwise_param();
::caffe::EltwiseParameter* mutable_eltwise_param();
void set_allocated_eltwise_param(::caffe::EltwiseParameter* eltwise_param);
private:
const ::caffe::EltwiseParameter& _internal_eltwise_param() const;
::caffe::EltwiseParameter* _internal_mutable_eltwise_param();
public:
void unsafe_arena_set_allocated_eltwise_param(
::caffe::EltwiseParameter* eltwise_param);
::caffe::EltwiseParameter* unsafe_arena_release_eltwise_param();
// optional .caffe.ThresholdParameter threshold_param = 25;
bool has_threshold_param() const;
private:
bool _internal_has_threshold_param() const;
public:
void clear_threshold_param();
const ::caffe::ThresholdParameter& threshold_param() const;
::caffe::ThresholdParameter* release_threshold_param();
::caffe::ThresholdParameter* mutable_threshold_param();
void set_allocated_threshold_param(::caffe::ThresholdParameter* threshold_param);
private:
const ::caffe::ThresholdParameter& _internal_threshold_param() const;
::caffe::ThresholdParameter* _internal_mutable_threshold_param();
public:
void unsafe_arena_set_allocated_threshold_param(
::caffe::ThresholdParameter* threshold_param);
::caffe::ThresholdParameter* unsafe_arena_release_threshold_param();
// optional .caffe.DummyDataParameter dummy_data_param = 26;
bool has_dummy_data_param() const;
private:
bool _internal_has_dummy_data_param() const;
public:
void clear_dummy_data_param();
const ::caffe::DummyDataParameter& dummy_data_param() const;
::caffe::DummyDataParameter* release_dummy_data_param();
::caffe::DummyDataParameter* mutable_dummy_data_param();
void set_allocated_dummy_data_param(::caffe::DummyDataParameter* dummy_data_param);
private:
const ::caffe::DummyDataParameter& _internal_dummy_data_param() const;
::caffe::DummyDataParameter* _internal_mutable_dummy_data_param();
public:
void unsafe_arena_set_allocated_dummy_data_param(
::caffe::DummyDataParameter* dummy_data_param);
::caffe::DummyDataParameter* unsafe_arena_release_dummy_data_param();
// optional .caffe.AccuracyParameter accuracy_param = 27;
bool has_accuracy_param() const;
private:
bool _internal_has_accuracy_param() const;
public:
void clear_accuracy_param();
const ::caffe::AccuracyParameter& accuracy_param() const;
::caffe::AccuracyParameter* release_accuracy_param();
::caffe::AccuracyParameter* mutable_accuracy_param();
void set_allocated_accuracy_param(::caffe::AccuracyParameter* accuracy_param);
private:
const ::caffe::AccuracyParameter& _internal_accuracy_param() const;
::caffe::AccuracyParameter* _internal_mutable_accuracy_param();
public:
void unsafe_arena_set_allocated_accuracy_param(
::caffe::AccuracyParameter* accuracy_param);
::caffe::AccuracyParameter* unsafe_arena_release_accuracy_param();
// optional .caffe.HingeLossParameter hinge_loss_param = 29;
bool has_hinge_loss_param() const;
private:
bool _internal_has_hinge_loss_param() const;
public:
void clear_hinge_loss_param();
const ::caffe::HingeLossParameter& hinge_loss_param() const;
::caffe::HingeLossParameter* release_hinge_loss_param();
::caffe::HingeLossParameter* mutable_hinge_loss_param();
void set_allocated_hinge_loss_param(::caffe::HingeLossParameter* hinge_loss_param);
private:
const ::caffe::HingeLossParameter& _internal_hinge_loss_param() const;
::caffe::HingeLossParameter* _internal_mutable_hinge_loss_param();
public:
void unsafe_arena_set_allocated_hinge_loss_param(
::caffe::HingeLossParameter* hinge_loss_param);
::caffe::HingeLossParameter* unsafe_arena_release_hinge_loss_param();
// optional .caffe.ReLUParameter relu_param = 30;
bool has_relu_param() const;
private:
bool _internal_has_relu_param() const;
public:
void clear_relu_param();
const ::caffe::ReLUParameter& relu_param() const;
::caffe::ReLUParameter* release_relu_param();
::caffe::ReLUParameter* mutable_relu_param();
void set_allocated_relu_param(::caffe::ReLUParameter* relu_param);
private:
const ::caffe::ReLUParameter& _internal_relu_param() const;
::caffe::ReLUParameter* _internal_mutable_relu_param();
public:
void unsafe_arena_set_allocated_relu_param(
::caffe::ReLUParameter* relu_param);
::caffe::ReLUParameter* unsafe_arena_release_relu_param();
// optional .caffe.SliceParameter slice_param = 31;
bool has_slice_param() const;
private:
bool _internal_has_slice_param() const;
public:
void clear_slice_param();
const ::caffe::SliceParameter& slice_param() const;
::caffe::SliceParameter* release_slice_param();
::caffe::SliceParameter* mutable_slice_param();
void set_allocated_slice_param(::caffe::SliceParameter* slice_param);
private:
const ::caffe::SliceParameter& _internal_slice_param() const;
::caffe::SliceParameter* _internal_mutable_slice_param();
public:
void unsafe_arena_set_allocated_slice_param(
::caffe::SliceParameter* slice_param);
::caffe::SliceParameter* unsafe_arena_release_slice_param();
// optional .caffe.MVNParameter mvn_param = 34;
bool has_mvn_param() const;
private:
bool _internal_has_mvn_param() const;
public:
void clear_mvn_param();
const ::caffe::MVNParameter& mvn_param() const;
::caffe::MVNParameter* release_mvn_param();
::caffe::MVNParameter* mutable_mvn_param();
void set_allocated_mvn_param(::caffe::MVNParameter* mvn_param);
private:
const ::caffe::MVNParameter& _internal_mvn_param() const;
::caffe::MVNParameter* _internal_mutable_mvn_param();
public:
void unsafe_arena_set_allocated_mvn_param(
::caffe::MVNParameter* mvn_param);
::caffe::MVNParameter* unsafe_arena_release_mvn_param();
// optional .caffe.TransformationParameter transform_param = 36;
bool has_transform_param() const;
private:
bool _internal_has_transform_param() const;
public:
void clear_transform_param();
const ::caffe::TransformationParameter& transform_param() const;
::caffe::TransformationParameter* release_transform_param();
::caffe::TransformationParameter* mutable_transform_param();
void set_allocated_transform_param(::caffe::TransformationParameter* transform_param);
private:
const ::caffe::TransformationParameter& _internal_transform_param() const;
::caffe::TransformationParameter* _internal_mutable_transform_param();
public:
void unsafe_arena_set_allocated_transform_param(
::caffe::TransformationParameter* transform_param);
::caffe::TransformationParameter* unsafe_arena_release_transform_param();
// optional .caffe.TanHParameter tanh_param = 37;
bool has_tanh_param() const;
private:
bool _internal_has_tanh_param() const;
public:
void clear_tanh_param();
const ::caffe::TanHParameter& tanh_param() const;
::caffe::TanHParameter* release_tanh_param();
::caffe::TanHParameter* mutable_tanh_param();
void set_allocated_tanh_param(::caffe::TanHParameter* tanh_param);
private:
const ::caffe::TanHParameter& _internal_tanh_param() const;
::caffe::TanHParameter* _internal_mutable_tanh_param();
public:
void unsafe_arena_set_allocated_tanh_param(
::caffe::TanHParameter* tanh_param);
::caffe::TanHParameter* unsafe_arena_release_tanh_param();
// optional .caffe.SigmoidParameter sigmoid_param = 38;
bool has_sigmoid_param() const;
private:
bool _internal_has_sigmoid_param() const;
public:
void clear_sigmoid_param();
const ::caffe::SigmoidParameter& sigmoid_param() const;
::caffe::SigmoidParameter* release_sigmoid_param();
::caffe::SigmoidParameter* mutable_sigmoid_param();
void set_allocated_sigmoid_param(::caffe::SigmoidParameter* sigmoid_param);
private:
const ::caffe::SigmoidParameter& _internal_sigmoid_param() const;
::caffe::SigmoidParameter* _internal_mutable_sigmoid_param();
public:
void unsafe_arena_set_allocated_sigmoid_param(
::caffe::SigmoidParameter* sigmoid_param);
::caffe::SigmoidParameter* unsafe_arena_release_sigmoid_param();
// optional .caffe.SoftmaxParameter softmax_param = 39;
bool has_softmax_param() const;
private:
bool _internal_has_softmax_param() const;
public:
void clear_softmax_param();
const ::caffe::SoftmaxParameter& softmax_param() const;
::caffe::SoftmaxParameter* release_softmax_param();
::caffe::SoftmaxParameter* mutable_softmax_param();
void set_allocated_softmax_param(::caffe::SoftmaxParameter* softmax_param);
private:
const ::caffe::SoftmaxParameter& _internal_softmax_param() const;
::caffe::SoftmaxParameter* _internal_mutable_softmax_param();
public:
void unsafe_arena_set_allocated_softmax_param(
::caffe::SoftmaxParameter* softmax_param);
::caffe::SoftmaxParameter* unsafe_arena_release_softmax_param();
// optional .caffe.ContrastiveLossParameter contrastive_loss_param = 40;
bool has_contrastive_loss_param() const;
private:
bool _internal_has_contrastive_loss_param() const;
public:
void clear_contrastive_loss_param();
const ::caffe::ContrastiveLossParameter& contrastive_loss_param() const;
::caffe::ContrastiveLossParameter* release_contrastive_loss_param();
::caffe::ContrastiveLossParameter* mutable_contrastive_loss_param();
void set_allocated_contrastive_loss_param(::caffe::ContrastiveLossParameter* contrastive_loss_param);
private:
const ::caffe::ContrastiveLossParameter& _internal_contrastive_loss_param() const;
::caffe::ContrastiveLossParameter* _internal_mutable_contrastive_loss_param();
public:
void unsafe_arena_set_allocated_contrastive_loss_param(
::caffe::ContrastiveLossParameter* contrastive_loss_param);
::caffe::ContrastiveLossParameter* unsafe_arena_release_contrastive_loss_param();
// optional .caffe.ExpParameter exp_param = 41;
bool has_exp_param() const;
private:
bool _internal_has_exp_param() const;
public:
void clear_exp_param();
const ::caffe::ExpParameter& exp_param() const;
::caffe::ExpParameter* release_exp_param();
::caffe::ExpParameter* mutable_exp_param();
void set_allocated_exp_param(::caffe::ExpParameter* exp_param);
private:
const ::caffe::ExpParameter& _internal_exp_param() const;
::caffe::ExpParameter* _internal_mutable_exp_param();
public:
void unsafe_arena_set_allocated_exp_param(
::caffe::ExpParameter* exp_param);
::caffe::ExpParameter* unsafe_arena_release_exp_param();
// optional .caffe.LossParameter loss_param = 42;
bool has_loss_param() const;
private:
bool _internal_has_loss_param() const;
public:
void clear_loss_param();
const ::caffe::LossParameter& loss_param() const;
::caffe::LossParameter* release_loss_param();
::caffe::LossParameter* mutable_loss_param();
void set_allocated_loss_param(::caffe::LossParameter* loss_param);
private:
const ::caffe::LossParameter& _internal_loss_param() const;
::caffe::LossParameter* _internal_mutable_loss_param();
public:
void unsafe_arena_set_allocated_loss_param(
::caffe::LossParameter* loss_param);
::caffe::LossParameter* unsafe_arena_release_loss_param();
// optional .caffe.V1LayerParameter.LayerType type = 5;
bool has_type() const;
private:
bool _internal_has_type() const;
public:
void clear_type();
::caffe::V1LayerParameter_LayerType type() const;
void set_type(::caffe::V1LayerParameter_LayerType value);
private:
::caffe::V1LayerParameter_LayerType _internal_type() const;
void _internal_set_type(::caffe::V1LayerParameter_LayerType value);
public:
// @@protoc_insertion_point(class_scope:caffe.V1LayerParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<2> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string> bottom_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string> top_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto > blobs_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float > blobs_lr_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float > weight_decay_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetStateRule > include_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetStateRule > exclude_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float > loss_weight_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string> param_;
::PROTOBUF_NAMESPACE_ID::RepeatedField<int> blob_share_mode_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr name_;
::caffe::V0LayerParameter* layer_;
::caffe::ConcatParameter* concat_param_;
::caffe::ConvolutionParameter* convolution_param_;
::caffe::DataParameter* data_param_;
::caffe::DropoutParameter* dropout_param_;
::caffe::HDF5DataParameter* hdf5_data_param_;
::caffe::HDF5OutputParameter* hdf5_output_param_;
::caffe::ImageDataParameter* image_data_param_;
::caffe::InfogainLossParameter* infogain_loss_param_;
::caffe::InnerProductParameter* inner_product_param_;
::caffe::LRNParameter* lrn_param_;
::caffe::PoolingParameter* pooling_param_;
::caffe::WindowDataParameter* window_data_param_;
::caffe::PowerParameter* power_param_;
::caffe::MemoryDataParameter* memory_data_param_;
::caffe::ArgMaxParameter* argmax_param_;
::caffe::EltwiseParameter* eltwise_param_;
::caffe::ThresholdParameter* threshold_param_;
::caffe::DummyDataParameter* dummy_data_param_;
::caffe::AccuracyParameter* accuracy_param_;
::caffe::HingeLossParameter* hinge_loss_param_;
::caffe::ReLUParameter* relu_param_;
::caffe::SliceParameter* slice_param_;
::caffe::MVNParameter* mvn_param_;
::caffe::TransformationParameter* transform_param_;
::caffe::TanHParameter* tanh_param_;
::caffe::SigmoidParameter* sigmoid_param_;
::caffe::SoftmaxParameter* softmax_param_;
::caffe::ContrastiveLossParameter* contrastive_loss_param_;
::caffe::ExpParameter* exp_param_;
::caffe::LossParameter* loss_param_;
int type_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class V0LayerParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.V0LayerParameter) */ {
public:
inline V0LayerParameter() : V0LayerParameter(nullptr) {}
virtual ~V0LayerParameter();
V0LayerParameter(const V0LayerParameter& from);
V0LayerParameter(V0LayerParameter&& from) noexcept
: V0LayerParameter() {
*this = ::std::move(from);
}
inline V0LayerParameter& operator=(const V0LayerParameter& from) {
CopyFrom(from);
return *this;
}
inline V0LayerParameter& operator=(V0LayerParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const V0LayerParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const V0LayerParameter* internal_default_instance() {
return reinterpret_cast<const V0LayerParameter*>(
&_V0LayerParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
86;
friend void swap(V0LayerParameter& a, V0LayerParameter& b) {
a.Swap(&b);
}
inline void Swap(V0LayerParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(V0LayerParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline V0LayerParameter* New() const final {
return CreateMaybeMessage<V0LayerParameter>(nullptr);
}
V0LayerParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<V0LayerParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const V0LayerParameter& from);
void MergeFrom(const V0LayerParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(V0LayerParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.V0LayerParameter";
}
protected:
explicit V0LayerParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
typedef V0LayerParameter_PoolMethod PoolMethod;
static constexpr PoolMethod MAX =
V0LayerParameter_PoolMethod_MAX;
static constexpr PoolMethod AVE =
V0LayerParameter_PoolMethod_AVE;
static constexpr PoolMethod STOCHASTIC =
V0LayerParameter_PoolMethod_STOCHASTIC;
static inline bool PoolMethod_IsValid(int value) {
return V0LayerParameter_PoolMethod_IsValid(value);
}
static constexpr PoolMethod PoolMethod_MIN =
V0LayerParameter_PoolMethod_PoolMethod_MIN;
static constexpr PoolMethod PoolMethod_MAX =
V0LayerParameter_PoolMethod_PoolMethod_MAX;
static constexpr int PoolMethod_ARRAYSIZE =
V0LayerParameter_PoolMethod_PoolMethod_ARRAYSIZE;
static inline const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor*
PoolMethod_descriptor() {
return V0LayerParameter_PoolMethod_descriptor();
}
template<typename T>
static inline const std::string& PoolMethod_Name(T enum_t_value) {
static_assert(::std::is_same<T, PoolMethod>::value ||
::std::is_integral<T>::value,
"Incorrect type passed to function PoolMethod_Name.");
return V0LayerParameter_PoolMethod_Name(enum_t_value);
}
static inline bool PoolMethod_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,
PoolMethod* value) {
return V0LayerParameter_PoolMethod_Parse(name, value);
}
// accessors -------------------------------------------------------
enum : int {
kBlobsFieldNumber = 50,
kBlobsLrFieldNumber = 51,
kWeightDecayFieldNumber = 52,
kNameFieldNumber = 1,
kTypeFieldNumber = 2,
kSourceFieldNumber = 16,
kMeanfileFieldNumber = 18,
kDetCropModeFieldNumber = 59,
kWeightFillerFieldNumber = 5,
kBiasFillerFieldNumber = 6,
kHdf5OutputParamFieldNumber = 1001,
kNumOutputFieldNumber = 3,
kPadFieldNumber = 7,
kKernelsizeFieldNumber = 8,
kPoolFieldNumber = 11,
kBatchsizeFieldNumber = 19,
kCropsizeFieldNumber = 20,
kNewWidthFieldNumber = 63,
kMirrorFieldNumber = 21,
kShuffleImagesFieldNumber = 64,
kRandSkipFieldNumber = 53,
kDetContextPadFieldNumber = 58,
kNewNumFieldNumber = 60,
kNewChannelsFieldNumber = 61,
kNewHeightFieldNumber = 62,
kConcatDimFieldNumber = 65,
kBiastermFieldNumber = 4,
kGroupFieldNumber = 9,
kStrideFieldNumber = 10,
kDropoutRatioFieldNumber = 12,
kLocalSizeFieldNumber = 13,
kAlphaFieldNumber = 14,
kBetaFieldNumber = 15,
kScaleFieldNumber = 17,
kKFieldNumber = 22,
kDetFgThresholdFieldNumber = 54,
kDetBgThresholdFieldNumber = 55,
kDetFgFractionFieldNumber = 56,
};
// repeated .caffe.BlobProto blobs = 50;
int blobs_size() const;
private:
int _internal_blobs_size() const;
public:
void clear_blobs();
::caffe::BlobProto* mutable_blobs(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto >*
mutable_blobs();
private:
const ::caffe::BlobProto& _internal_blobs(int index) const;
::caffe::BlobProto* _internal_add_blobs();
public:
const ::caffe::BlobProto& blobs(int index) const;
::caffe::BlobProto* add_blobs();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto >&
blobs() const;
// repeated float blobs_lr = 51;
int blobs_lr_size() const;
private:
int _internal_blobs_lr_size() const;
public:
void clear_blobs_lr();
private:
float _internal_blobs_lr(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
_internal_blobs_lr() const;
void _internal_add_blobs_lr(float value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
_internal_mutable_blobs_lr();
public:
float blobs_lr(int index) const;
void set_blobs_lr(int index, float value);
void add_blobs_lr(float value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
blobs_lr() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
mutable_blobs_lr();
// repeated float weight_decay = 52;
int weight_decay_size() const;
private:
int _internal_weight_decay_size() const;
public:
void clear_weight_decay();
private:
float _internal_weight_decay(int index) const;
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
_internal_weight_decay() const;
void _internal_add_weight_decay(float value);
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
_internal_mutable_weight_decay();
public:
float weight_decay(int index) const;
void set_weight_decay(int index, float value);
void add_weight_decay(float value);
const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
weight_decay() const;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
mutable_weight_decay();
// optional string name = 1;
bool has_name() const;
private:
bool _internal_has_name() const;
public:
void clear_name();
const std::string& name() const;
void set_name(const std::string& value);
void set_name(std::string&& value);
void set_name(const char* value);
void set_name(const char* value, size_t size);
std::string* mutable_name();
std::string* release_name();
void set_allocated_name(std::string* name);
private:
const std::string& _internal_name() const;
void _internal_set_name(const std::string& value);
std::string* _internal_mutable_name();
public:
// optional string type = 2;
bool has_type() const;
private:
bool _internal_has_type() const;
public:
void clear_type();
const std::string& type() const;
void set_type(const std::string& value);
void set_type(std::string&& value);
void set_type(const char* value);
void set_type(const char* value, size_t size);
std::string* mutable_type();
std::string* release_type();
void set_allocated_type(std::string* type);
private:
const std::string& _internal_type() const;
void _internal_set_type(const std::string& value);
std::string* _internal_mutable_type();
public:
// optional string source = 16;
bool has_source() const;
private:
bool _internal_has_source() const;
public:
void clear_source();
const std::string& source() const;
void set_source(const std::string& value);
void set_source(std::string&& value);
void set_source(const char* value);
void set_source(const char* value, size_t size);
std::string* mutable_source();
std::string* release_source();
void set_allocated_source(std::string* source);
private:
const std::string& _internal_source() const;
void _internal_set_source(const std::string& value);
std::string* _internal_mutable_source();
public:
// optional string meanfile = 18;
bool has_meanfile() const;
private:
bool _internal_has_meanfile() const;
public:
void clear_meanfile();
const std::string& meanfile() const;
void set_meanfile(const std::string& value);
void set_meanfile(std::string&& value);
void set_meanfile(const char* value);
void set_meanfile(const char* value, size_t size);
std::string* mutable_meanfile();
std::string* release_meanfile();
void set_allocated_meanfile(std::string* meanfile);
private:
const std::string& _internal_meanfile() const;
void _internal_set_meanfile(const std::string& value);
std::string* _internal_mutable_meanfile();
public:
// optional string det_crop_mode = 59 [default = "warp"];
bool has_det_crop_mode() const;
private:
bool _internal_has_det_crop_mode() const;
public:
void clear_det_crop_mode();
const std::string& det_crop_mode() const;
void set_det_crop_mode(const std::string& value);
void set_det_crop_mode(std::string&& value);
void set_det_crop_mode(const char* value);
void set_det_crop_mode(const char* value, size_t size);
std::string* mutable_det_crop_mode();
std::string* release_det_crop_mode();
void set_allocated_det_crop_mode(std::string* det_crop_mode);
private:
const std::string& _internal_det_crop_mode() const;
void _internal_set_det_crop_mode(const std::string& value);
std::string* _internal_mutable_det_crop_mode();
public:
// optional .caffe.FillerParameter weight_filler = 5;
bool has_weight_filler() const;
private:
bool _internal_has_weight_filler() const;
public:
void clear_weight_filler();
const ::caffe::FillerParameter& weight_filler() const;
::caffe::FillerParameter* release_weight_filler();
::caffe::FillerParameter* mutable_weight_filler();
void set_allocated_weight_filler(::caffe::FillerParameter* weight_filler);
private:
const ::caffe::FillerParameter& _internal_weight_filler() const;
::caffe::FillerParameter* _internal_mutable_weight_filler();
public:
void unsafe_arena_set_allocated_weight_filler(
::caffe::FillerParameter* weight_filler);
::caffe::FillerParameter* unsafe_arena_release_weight_filler();
// optional .caffe.FillerParameter bias_filler = 6;
bool has_bias_filler() const;
private:
bool _internal_has_bias_filler() const;
public:
void clear_bias_filler();
const ::caffe::FillerParameter& bias_filler() const;
::caffe::FillerParameter* release_bias_filler();
::caffe::FillerParameter* mutable_bias_filler();
void set_allocated_bias_filler(::caffe::FillerParameter* bias_filler);
private:
const ::caffe::FillerParameter& _internal_bias_filler() const;
::caffe::FillerParameter* _internal_mutable_bias_filler();
public:
void unsafe_arena_set_allocated_bias_filler(
::caffe::FillerParameter* bias_filler);
::caffe::FillerParameter* unsafe_arena_release_bias_filler();
// optional .caffe.HDF5OutputParameter hdf5_output_param = 1001;
bool has_hdf5_output_param() const;
private:
bool _internal_has_hdf5_output_param() const;
public:
void clear_hdf5_output_param();
const ::caffe::HDF5OutputParameter& hdf5_output_param() const;
::caffe::HDF5OutputParameter* release_hdf5_output_param();
::caffe::HDF5OutputParameter* mutable_hdf5_output_param();
void set_allocated_hdf5_output_param(::caffe::HDF5OutputParameter* hdf5_output_param);
private:
const ::caffe::HDF5OutputParameter& _internal_hdf5_output_param() const;
::caffe::HDF5OutputParameter* _internal_mutable_hdf5_output_param();
public:
void unsafe_arena_set_allocated_hdf5_output_param(
::caffe::HDF5OutputParameter* hdf5_output_param);
::caffe::HDF5OutputParameter* unsafe_arena_release_hdf5_output_param();
// optional uint32 num_output = 3;
bool has_num_output() const;
private:
bool _internal_has_num_output() const;
public:
void clear_num_output();
::PROTOBUF_NAMESPACE_ID::uint32 num_output() const;
void set_num_output(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_num_output() const;
void _internal_set_num_output(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 pad = 7 [default = 0];
bool has_pad() const;
private:
bool _internal_has_pad() const;
public:
void clear_pad();
::PROTOBUF_NAMESPACE_ID::uint32 pad() const;
void set_pad(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_pad() const;
void _internal_set_pad(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 kernelsize = 8;
bool has_kernelsize() const;
private:
bool _internal_has_kernelsize() const;
public:
void clear_kernelsize();
::PROTOBUF_NAMESPACE_ID::uint32 kernelsize() const;
void set_kernelsize(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_kernelsize() const;
void _internal_set_kernelsize(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional .caffe.V0LayerParameter.PoolMethod pool = 11 [default = MAX];
bool has_pool() const;
private:
bool _internal_has_pool() const;
public:
void clear_pool();
::caffe::V0LayerParameter_PoolMethod pool() const;
void set_pool(::caffe::V0LayerParameter_PoolMethod value);
private:
::caffe::V0LayerParameter_PoolMethod _internal_pool() const;
void _internal_set_pool(::caffe::V0LayerParameter_PoolMethod value);
public:
// optional uint32 batchsize = 19;
bool has_batchsize() const;
private:
bool _internal_has_batchsize() const;
public:
void clear_batchsize();
::PROTOBUF_NAMESPACE_ID::uint32 batchsize() const;
void set_batchsize(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_batchsize() const;
void _internal_set_batchsize(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 cropsize = 20 [default = 0];
bool has_cropsize() const;
private:
bool _internal_has_cropsize() const;
public:
void clear_cropsize();
::PROTOBUF_NAMESPACE_ID::uint32 cropsize() const;
void set_cropsize(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_cropsize() const;
void _internal_set_cropsize(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional int32 new_width = 63 [default = 0];
bool has_new_width() const;
private:
bool _internal_has_new_width() const;
public:
void clear_new_width();
::PROTOBUF_NAMESPACE_ID::int32 new_width() const;
void set_new_width(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_new_width() const;
void _internal_set_new_width(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional bool mirror = 21 [default = false];
bool has_mirror() const;
private:
bool _internal_has_mirror() const;
public:
void clear_mirror();
bool mirror() const;
void set_mirror(bool value);
private:
bool _internal_mirror() const;
void _internal_set_mirror(bool value);
public:
// optional bool shuffle_images = 64 [default = false];
bool has_shuffle_images() const;
private:
bool _internal_has_shuffle_images() const;
public:
void clear_shuffle_images();
bool shuffle_images() const;
void set_shuffle_images(bool value);
private:
bool _internal_shuffle_images() const;
void _internal_set_shuffle_images(bool value);
public:
// optional uint32 rand_skip = 53 [default = 0];
bool has_rand_skip() const;
private:
bool _internal_has_rand_skip() const;
public:
void clear_rand_skip();
::PROTOBUF_NAMESPACE_ID::uint32 rand_skip() const;
void set_rand_skip(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_rand_skip() const;
void _internal_set_rand_skip(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 det_context_pad = 58 [default = 0];
bool has_det_context_pad() const;
private:
bool _internal_has_det_context_pad() const;
public:
void clear_det_context_pad();
::PROTOBUF_NAMESPACE_ID::uint32 det_context_pad() const;
void set_det_context_pad(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_det_context_pad() const;
void _internal_set_det_context_pad(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional int32 new_num = 60 [default = 0];
bool has_new_num() const;
private:
bool _internal_has_new_num() const;
public:
void clear_new_num();
::PROTOBUF_NAMESPACE_ID::int32 new_num() const;
void set_new_num(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_new_num() const;
void _internal_set_new_num(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional int32 new_channels = 61 [default = 0];
bool has_new_channels() const;
private:
bool _internal_has_new_channels() const;
public:
void clear_new_channels();
::PROTOBUF_NAMESPACE_ID::int32 new_channels() const;
void set_new_channels(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_new_channels() const;
void _internal_set_new_channels(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional int32 new_height = 62 [default = 0];
bool has_new_height() const;
private:
bool _internal_has_new_height() const;
public:
void clear_new_height();
::PROTOBUF_NAMESPACE_ID::int32 new_height() const;
void set_new_height(::PROTOBUF_NAMESPACE_ID::int32 value);
private:
::PROTOBUF_NAMESPACE_ID::int32 _internal_new_height() const;
void _internal_set_new_height(::PROTOBUF_NAMESPACE_ID::int32 value);
public:
// optional uint32 concat_dim = 65 [default = 1];
bool has_concat_dim() const;
private:
bool _internal_has_concat_dim() const;
public:
void clear_concat_dim();
::PROTOBUF_NAMESPACE_ID::uint32 concat_dim() const;
void set_concat_dim(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_concat_dim() const;
void _internal_set_concat_dim(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional bool biasterm = 4 [default = true];
bool has_biasterm() const;
private:
bool _internal_has_biasterm() const;
public:
void clear_biasterm();
bool biasterm() const;
void set_biasterm(bool value);
private:
bool _internal_biasterm() const;
void _internal_set_biasterm(bool value);
public:
// optional uint32 group = 9 [default = 1];
bool has_group() const;
private:
bool _internal_has_group() const;
public:
void clear_group();
::PROTOBUF_NAMESPACE_ID::uint32 group() const;
void set_group(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_group() const;
void _internal_set_group(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 stride = 10 [default = 1];
bool has_stride() const;
private:
bool _internal_has_stride() const;
public:
void clear_stride();
::PROTOBUF_NAMESPACE_ID::uint32 stride() const;
void set_stride(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_stride() const;
void _internal_set_stride(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional float dropout_ratio = 12 [default = 0.5];
bool has_dropout_ratio() const;
private:
bool _internal_has_dropout_ratio() const;
public:
void clear_dropout_ratio();
float dropout_ratio() const;
void set_dropout_ratio(float value);
private:
float _internal_dropout_ratio() const;
void _internal_set_dropout_ratio(float value);
public:
// optional uint32 local_size = 13 [default = 5];
bool has_local_size() const;
private:
bool _internal_has_local_size() const;
public:
void clear_local_size();
::PROTOBUF_NAMESPACE_ID::uint32 local_size() const;
void set_local_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_local_size() const;
void _internal_set_local_size(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional float alpha = 14 [default = 1];
bool has_alpha() const;
private:
bool _internal_has_alpha() const;
public:
void clear_alpha();
float alpha() const;
void set_alpha(float value);
private:
float _internal_alpha() const;
void _internal_set_alpha(float value);
public:
// optional float beta = 15 [default = 0.75];
bool has_beta() const;
private:
bool _internal_has_beta() const;
public:
void clear_beta();
float beta() const;
void set_beta(float value);
private:
float _internal_beta() const;
void _internal_set_beta(float value);
public:
// optional float scale = 17 [default = 1];
bool has_scale() const;
private:
bool _internal_has_scale() const;
public:
void clear_scale();
float scale() const;
void set_scale(float value);
private:
float _internal_scale() const;
void _internal_set_scale(float value);
public:
// optional float k = 22 [default = 1];
bool has_k() const;
private:
bool _internal_has_k() const;
public:
void clear_k();
float k() const;
void set_k(float value);
private:
float _internal_k() const;
void _internal_set_k(float value);
public:
// optional float det_fg_threshold = 54 [default = 0.5];
bool has_det_fg_threshold() const;
private:
bool _internal_has_det_fg_threshold() const;
public:
void clear_det_fg_threshold();
float det_fg_threshold() const;
void set_det_fg_threshold(float value);
private:
float _internal_det_fg_threshold() const;
void _internal_set_det_fg_threshold(float value);
public:
// optional float det_bg_threshold = 55 [default = 0.5];
bool has_det_bg_threshold() const;
private:
bool _internal_has_det_bg_threshold() const;
public:
void clear_det_bg_threshold();
float det_bg_threshold() const;
void set_det_bg_threshold(float value);
private:
float _internal_det_bg_threshold() const;
void _internal_set_det_bg_threshold(float value);
public:
// optional float det_fg_fraction = 56 [default = 0.25];
bool has_det_fg_fraction() const;
private:
bool _internal_has_det_fg_fraction() const;
public:
void clear_det_fg_fraction();
float det_fg_fraction() const;
void set_det_fg_fraction(float value);
private:
float _internal_det_fg_fraction() const;
void _internal_set_det_fg_fraction(float value);
public:
// @@protoc_insertion_point(class_scope:caffe.V0LayerParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<2> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto > blobs_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float > blobs_lr_;
::PROTOBUF_NAMESPACE_ID::RepeatedField< float > weight_decay_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr name_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr type_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr source_;
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr meanfile_;
public:
static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> _i_give_permission_to_break_this_code_default_det_crop_mode_;
private:
::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr det_crop_mode_;
::caffe::FillerParameter* weight_filler_;
::caffe::FillerParameter* bias_filler_;
::caffe::HDF5OutputParameter* hdf5_output_param_;
::PROTOBUF_NAMESPACE_ID::uint32 num_output_;
::PROTOBUF_NAMESPACE_ID::uint32 pad_;
::PROTOBUF_NAMESPACE_ID::uint32 kernelsize_;
int pool_;
::PROTOBUF_NAMESPACE_ID::uint32 batchsize_;
::PROTOBUF_NAMESPACE_ID::uint32 cropsize_;
::PROTOBUF_NAMESPACE_ID::int32 new_width_;
bool mirror_;
bool shuffle_images_;
::PROTOBUF_NAMESPACE_ID::uint32 rand_skip_;
::PROTOBUF_NAMESPACE_ID::uint32 det_context_pad_;
::PROTOBUF_NAMESPACE_ID::int32 new_num_;
::PROTOBUF_NAMESPACE_ID::int32 new_channels_;
::PROTOBUF_NAMESPACE_ID::int32 new_height_;
::PROTOBUF_NAMESPACE_ID::uint32 concat_dim_;
bool biasterm_;
::PROTOBUF_NAMESPACE_ID::uint32 group_;
::PROTOBUF_NAMESPACE_ID::uint32 stride_;
float dropout_ratio_;
::PROTOBUF_NAMESPACE_ID::uint32 local_size_;
float alpha_;
float beta_;
float scale_;
float k_;
float det_fg_threshold_;
float det_bg_threshold_;
float det_fg_fraction_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class PReLUParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.PReLUParameter) */ {
public:
inline PReLUParameter() : PReLUParameter(nullptr) {}
virtual ~PReLUParameter();
PReLUParameter(const PReLUParameter& from);
PReLUParameter(PReLUParameter&& from) noexcept
: PReLUParameter() {
*this = ::std::move(from);
}
inline PReLUParameter& operator=(const PReLUParameter& from) {
CopyFrom(from);
return *this;
}
inline PReLUParameter& operator=(PReLUParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const PReLUParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const PReLUParameter* internal_default_instance() {
return reinterpret_cast<const PReLUParameter*>(
&_PReLUParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
87;
friend void swap(PReLUParameter& a, PReLUParameter& b) {
a.Swap(&b);
}
inline void Swap(PReLUParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(PReLUParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline PReLUParameter* New() const final {
return CreateMaybeMessage<PReLUParameter>(nullptr);
}
PReLUParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<PReLUParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const PReLUParameter& from);
void MergeFrom(const PReLUParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(PReLUParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.PReLUParameter";
}
protected:
explicit PReLUParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kFillerFieldNumber = 1,
kChannelSharedFieldNumber = 2,
};
// optional .caffe.FillerParameter filler = 1;
bool has_filler() const;
private:
bool _internal_has_filler() const;
public:
void clear_filler();
const ::caffe::FillerParameter& filler() const;
::caffe::FillerParameter* release_filler();
::caffe::FillerParameter* mutable_filler();
void set_allocated_filler(::caffe::FillerParameter* filler);
private:
const ::caffe::FillerParameter& _internal_filler() const;
::caffe::FillerParameter* _internal_mutable_filler();
public:
void unsafe_arena_set_allocated_filler(
::caffe::FillerParameter* filler);
::caffe::FillerParameter* unsafe_arena_release_filler();
// optional bool channel_shared = 2 [default = false];
bool has_channel_shared() const;
private:
bool _internal_has_channel_shared() const;
public:
void clear_channel_shared();
bool channel_shared() const;
void set_channel_shared(bool value);
private:
bool _internal_channel_shared() const;
void _internal_set_channel_shared(bool value);
public:
// @@protoc_insertion_point(class_scope:caffe.PReLUParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::caffe::FillerParameter* filler_;
bool channel_shared_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class FaceDataParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.FaceDataParameter) */ {
public:
inline FaceDataParameter() : FaceDataParameter(nullptr) {}
virtual ~FaceDataParameter();
FaceDataParameter(const FaceDataParameter& from);
FaceDataParameter(FaceDataParameter&& from) noexcept
: FaceDataParameter() {
*this = ::std::move(from);
}
inline FaceDataParameter& operator=(const FaceDataParameter& from) {
CopyFrom(from);
return *this;
}
inline FaceDataParameter& operator=(FaceDataParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const FaceDataParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const FaceDataParameter* internal_default_instance() {
return reinterpret_cast<const FaceDataParameter*>(
&_FaceDataParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
88;
friend void swap(FaceDataParameter& a, FaceDataParameter& b) {
a.Swap(&b);
}
inline void Swap(FaceDataParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(FaceDataParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline FaceDataParameter* New() const final {
return CreateMaybeMessage<FaceDataParameter>(nullptr);
}
FaceDataParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<FaceDataParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const FaceDataParameter& from);
void MergeFrom(const FaceDataParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(FaceDataParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.FaceDataParameter";
}
protected:
explicit FaceDataParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kShapeFieldNumber = 6,
kFullfaceFieldNumber = 1,
kEyeFieldNumber = 3,
kNoseFieldNumber = 4,
kMouthFieldNumber = 5,
kCroppedfaceFieldNumber = 2,
};
// repeated .caffe.BlobShape shape = 6;
int shape_size() const;
private:
int _internal_shape_size() const;
public:
void clear_shape();
::caffe::BlobShape* mutable_shape(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape >*
mutable_shape();
private:
const ::caffe::BlobShape& _internal_shape(int index) const;
::caffe::BlobShape* _internal_add_shape();
public:
const ::caffe::BlobShape& shape(int index) const;
::caffe::BlobShape* add_shape();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape >&
shape() const;
// optional bool fullface = 1 [default = false];
bool has_fullface() const;
private:
bool _internal_has_fullface() const;
public:
void clear_fullface();
bool fullface() const;
void set_fullface(bool value);
private:
bool _internal_fullface() const;
void _internal_set_fullface(bool value);
public:
// optional bool eye = 3 [default = false];
bool has_eye() const;
private:
bool _internal_has_eye() const;
public:
void clear_eye();
bool eye() const;
void set_eye(bool value);
private:
bool _internal_eye() const;
void _internal_set_eye(bool value);
public:
// optional bool nose = 4 [default = false];
bool has_nose() const;
private:
bool _internal_has_nose() const;
public:
void clear_nose();
bool nose() const;
void set_nose(bool value);
private:
bool _internal_nose() const;
void _internal_set_nose(bool value);
public:
// optional bool mouth = 5 [default = false];
bool has_mouth() const;
private:
bool _internal_has_mouth() const;
public:
void clear_mouth();
bool mouth() const;
void set_mouth(bool value);
private:
bool _internal_mouth() const;
void _internal_set_mouth(bool value);
public:
// optional bool croppedface = 2 [default = true];
bool has_croppedface() const;
private:
bool _internal_has_croppedface() const;
public:
void clear_croppedface();
bool croppedface() const;
void set_croppedface(bool value);
private:
bool _internal_croppedface() const;
void _internal_set_croppedface(bool value);
public:
// @@protoc_insertion_point(class_scope:caffe.FaceDataParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape > shape_;
bool fullface_;
bool eye_;
bool nose_;
bool mouth_;
bool croppedface_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class UpsampleParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.UpsampleParameter) */ {
public:
inline UpsampleParameter() : UpsampleParameter(nullptr) {}
virtual ~UpsampleParameter();
UpsampleParameter(const UpsampleParameter& from);
UpsampleParameter(UpsampleParameter&& from) noexcept
: UpsampleParameter() {
*this = ::std::move(from);
}
inline UpsampleParameter& operator=(const UpsampleParameter& from) {
CopyFrom(from);
return *this;
}
inline UpsampleParameter& operator=(UpsampleParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const UpsampleParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const UpsampleParameter* internal_default_instance() {
return reinterpret_cast<const UpsampleParameter*>(
&_UpsampleParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
89;
friend void swap(UpsampleParameter& a, UpsampleParameter& b) {
a.Swap(&b);
}
inline void Swap(UpsampleParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(UpsampleParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline UpsampleParameter* New() const final {
return CreateMaybeMessage<UpsampleParameter>(nullptr);
}
UpsampleParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<UpsampleParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const UpsampleParameter& from);
void MergeFrom(const UpsampleParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(UpsampleParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.UpsampleParameter";
}
protected:
explicit UpsampleParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kScaleHFieldNumber = 2,
kScaleWFieldNumber = 3,
kPadOutHFieldNumber = 4,
kPadOutWFieldNumber = 5,
kUpsampleHFieldNumber = 6,
kUpsampleWFieldNumber = 7,
kScaleFieldNumber = 1,
};
// optional uint32 scale_h = 2;
bool has_scale_h() const;
private:
bool _internal_has_scale_h() const;
public:
void clear_scale_h();
::PROTOBUF_NAMESPACE_ID::uint32 scale_h() const;
void set_scale_h(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_scale_h() const;
void _internal_set_scale_h(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 scale_w = 3;
bool has_scale_w() const;
private:
bool _internal_has_scale_w() const;
public:
void clear_scale_w();
::PROTOBUF_NAMESPACE_ID::uint32 scale_w() const;
void set_scale_w(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_scale_w() const;
void _internal_set_scale_w(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional bool pad_out_h = 4 [default = false];
bool has_pad_out_h() const;
private:
bool _internal_has_pad_out_h() const;
public:
void clear_pad_out_h();
bool pad_out_h() const;
void set_pad_out_h(bool value);
private:
bool _internal_pad_out_h() const;
void _internal_set_pad_out_h(bool value);
public:
// optional bool pad_out_w = 5 [default = false];
bool has_pad_out_w() const;
private:
bool _internal_has_pad_out_w() const;
public:
void clear_pad_out_w();
bool pad_out_w() const;
void set_pad_out_w(bool value);
private:
bool _internal_pad_out_w() const;
void _internal_set_pad_out_w(bool value);
public:
// optional uint32 upsample_h = 6;
bool has_upsample_h() const;
private:
bool _internal_has_upsample_h() const;
public:
void clear_upsample_h();
::PROTOBUF_NAMESPACE_ID::uint32 upsample_h() const;
void set_upsample_h(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_upsample_h() const;
void _internal_set_upsample_h(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 upsample_w = 7;
bool has_upsample_w() const;
private:
bool _internal_has_upsample_w() const;
public:
void clear_upsample_w();
::PROTOBUF_NAMESPACE_ID::uint32 upsample_w() const;
void set_upsample_w(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_upsample_w() const;
void _internal_set_upsample_w(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// optional uint32 scale = 1 [default = 2];
bool has_scale() const;
private:
bool _internal_has_scale() const;
public:
void clear_scale();
::PROTOBUF_NAMESPACE_ID::uint32 scale() const;
void set_scale(::PROTOBUF_NAMESPACE_ID::uint32 value);
private:
::PROTOBUF_NAMESPACE_ID::uint32 _internal_scale() const;
void _internal_set_scale(::PROTOBUF_NAMESPACE_ID::uint32 value);
public:
// @@protoc_insertion_point(class_scope:caffe.UpsampleParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
::PROTOBUF_NAMESPACE_ID::uint32 scale_h_;
::PROTOBUF_NAMESPACE_ID::uint32 scale_w_;
bool pad_out_h_;
bool pad_out_w_;
::PROTOBUF_NAMESPACE_ID::uint32 upsample_h_;
::PROTOBUF_NAMESPACE_ID::uint32 upsample_w_;
::PROTOBUF_NAMESPACE_ID::uint32 scale_;
friend struct ::TableStruct_caffe_2eproto;
};
// -------------------------------------------------------------------
class ConnectParameter PROTOBUF_FINAL :
public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:caffe.ConnectParameter) */ {
public:
inline ConnectParameter() : ConnectParameter(nullptr) {}
virtual ~ConnectParameter();
ConnectParameter(const ConnectParameter& from);
ConnectParameter(ConnectParameter&& from) noexcept
: ConnectParameter() {
*this = ::std::move(from);
}
inline ConnectParameter& operator=(const ConnectParameter& from) {
CopyFrom(from);
return *this;
}
inline ConnectParameter& operator=(ConnectParameter&& from) noexcept {
if (GetArena() == from.GetArena()) {
if (this != &from) InternalSwap(&from);
} else {
CopyFrom(from);
}
return *this;
}
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const {
return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance);
}
inline ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet* mutable_unknown_fields() {
return _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
return GetDescriptor();
}
static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
return GetMetadataStatic().descriptor;
}
static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
return GetMetadataStatic().reflection;
}
static const ConnectParameter& default_instance();
static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY
static inline const ConnectParameter* internal_default_instance() {
return reinterpret_cast<const ConnectParameter*>(
&_ConnectParameter_default_instance_);
}
static constexpr int kIndexInFileMessages =
90;
friend void swap(ConnectParameter& a, ConnectParameter& b) {
a.Swap(&b);
}
inline void Swap(ConnectParameter* other) {
if (other == this) return;
if (GetArena() == other->GetArena()) {
InternalSwap(other);
} else {
::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other);
}
}
void UnsafeArenaSwap(ConnectParameter* other) {
if (other == this) return;
GOOGLE_DCHECK(GetArena() == other->GetArena());
InternalSwap(other);
}
// implements Message ----------------------------------------------
inline ConnectParameter* New() const final {
return CreateMaybeMessage<ConnectParameter>(nullptr);
}
ConnectParameter* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
return CreateMaybeMessage<ConnectParameter>(arena);
}
void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
void CopyFrom(const ConnectParameter& from);
void MergeFrom(const ConnectParameter& from);
PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
bool IsInitialized() const final;
size_t ByteSizeLong() const final;
const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
::PROTOBUF_NAMESPACE_ID::uint8* _InternalSerialize(
::PROTOBUF_NAMESPACE_ID::uint8* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final;
int GetCachedSize() const final { return _cached_size_.Get(); }
private:
inline void SharedCtor();
inline void SharedDtor();
void SetCachedSize(int size) const final;
void InternalSwap(ConnectParameter* other);
friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
return "caffe.ConnectParameter";
}
protected:
explicit ConnectParameter(::PROTOBUF_NAMESPACE_ID::Arena* arena);
private:
static void ArenaDtor(void* object);
inline void RegisterArenaDtor(::PROTOBUF_NAMESPACE_ID::Arena* arena);
public:
::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
private:
static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_caffe_2eproto);
return ::descriptor_table_caffe_2eproto.file_level_metadata[kIndexInFileMessages];
}
public:
// nested types ----------------------------------------------------
// accessors -------------------------------------------------------
enum : int {
kShapeFieldNumber = 1,
};
// repeated .caffe.BlobShape shape = 1;
int shape_size() const;
private:
int _internal_shape_size() const;
public:
void clear_shape();
::caffe::BlobShape* mutable_shape(int index);
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape >*
mutable_shape();
private:
const ::caffe::BlobShape& _internal_shape(int index) const;
::caffe::BlobShape* _internal_add_shape();
public:
const ::caffe::BlobShape& shape(int index) const;
::caffe::BlobShape* add_shape();
const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape >&
shape() const;
// @@protoc_insertion_point(class_scope:caffe.ConnectParameter)
private:
class _Internal;
template <typename T> friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper;
typedef void InternalArenaConstructable_;
typedef void DestructorSkippable_;
::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape > shape_;
mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
friend struct ::TableStruct_caffe_2eproto;
};
// ===================================================================
// ===================================================================
#ifdef __GNUC__
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wstrict-aliasing"
#endif // __GNUC__
// BlobShape
// repeated int64 dim = 1 [packed = true];
inline int BlobShape::_internal_dim_size() const {
return dim_.size();
}
inline int BlobShape::dim_size() const {
return _internal_dim_size();
}
inline void BlobShape::clear_dim() {
dim_.Clear();
}
inline ::PROTOBUF_NAMESPACE_ID::int64 BlobShape::_internal_dim(int index) const {
return dim_.Get(index);
}
inline ::PROTOBUF_NAMESPACE_ID::int64 BlobShape::dim(int index) const {
// @@protoc_insertion_point(field_get:caffe.BlobShape.dim)
return _internal_dim(index);
}
inline void BlobShape::set_dim(int index, ::PROTOBUF_NAMESPACE_ID::int64 value) {
dim_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.BlobShape.dim)
}
inline void BlobShape::_internal_add_dim(::PROTOBUF_NAMESPACE_ID::int64 value) {
dim_.Add(value);
}
inline void BlobShape::add_dim(::PROTOBUF_NAMESPACE_ID::int64 value) {
_internal_add_dim(value);
// @@protoc_insertion_point(field_add:caffe.BlobShape.dim)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int64 >&
BlobShape::_internal_dim() const {
return dim_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int64 >&
BlobShape::dim() const {
// @@protoc_insertion_point(field_list:caffe.BlobShape.dim)
return _internal_dim();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int64 >*
BlobShape::_internal_mutable_dim() {
return &dim_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int64 >*
BlobShape::mutable_dim() {
// @@protoc_insertion_point(field_mutable_list:caffe.BlobShape.dim)
return _internal_mutable_dim();
}
// -------------------------------------------------------------------
// BlobProto
// optional .caffe.BlobShape shape = 7;
inline bool BlobProto::_internal_has_shape() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
PROTOBUF_ASSUME(!value || shape_ != nullptr);
return value;
}
inline bool BlobProto::has_shape() const {
return _internal_has_shape();
}
inline void BlobProto::clear_shape() {
if (shape_ != nullptr) shape_->Clear();
_has_bits_[0] &= ~0x00000001u;
}
inline const ::caffe::BlobShape& BlobProto::_internal_shape() const {
const ::caffe::BlobShape* p = shape_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::BlobShape*>(
&::caffe::_BlobShape_default_instance_);
}
inline const ::caffe::BlobShape& BlobProto::shape() const {
// @@protoc_insertion_point(field_get:caffe.BlobProto.shape)
return _internal_shape();
}
inline void BlobProto::unsafe_arena_set_allocated_shape(
::caffe::BlobShape* shape) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(shape_);
}
shape_ = shape;
if (shape) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.BlobProto.shape)
}
inline ::caffe::BlobShape* BlobProto::release_shape() {
_has_bits_[0] &= ~0x00000001u;
::caffe::BlobShape* temp = shape_;
shape_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::BlobShape* BlobProto::unsafe_arena_release_shape() {
// @@protoc_insertion_point(field_release:caffe.BlobProto.shape)
_has_bits_[0] &= ~0x00000001u;
::caffe::BlobShape* temp = shape_;
shape_ = nullptr;
return temp;
}
inline ::caffe::BlobShape* BlobProto::_internal_mutable_shape() {
_has_bits_[0] |= 0x00000001u;
if (shape_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::BlobShape>(GetArena());
shape_ = p;
}
return shape_;
}
inline ::caffe::BlobShape* BlobProto::mutable_shape() {
// @@protoc_insertion_point(field_mutable:caffe.BlobProto.shape)
return _internal_mutable_shape();
}
inline void BlobProto::set_allocated_shape(::caffe::BlobShape* shape) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete shape_;
}
if (shape) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(shape);
if (message_arena != submessage_arena) {
shape = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, shape, submessage_arena);
}
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
shape_ = shape;
// @@protoc_insertion_point(field_set_allocated:caffe.BlobProto.shape)
}
// repeated float data = 5 [packed = true];
inline int BlobProto::_internal_data_size() const {
return data_.size();
}
inline int BlobProto::data_size() const {
return _internal_data_size();
}
inline void BlobProto::clear_data() {
data_.Clear();
}
inline float BlobProto::_internal_data(int index) const {
return data_.Get(index);
}
inline float BlobProto::data(int index) const {
// @@protoc_insertion_point(field_get:caffe.BlobProto.data)
return _internal_data(index);
}
inline void BlobProto::set_data(int index, float value) {
data_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.BlobProto.data)
}
inline void BlobProto::_internal_add_data(float value) {
data_.Add(value);
}
inline void BlobProto::add_data(float value) {
_internal_add_data(value);
// @@protoc_insertion_point(field_add:caffe.BlobProto.data)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
BlobProto::_internal_data() const {
return data_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
BlobProto::data() const {
// @@protoc_insertion_point(field_list:caffe.BlobProto.data)
return _internal_data();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
BlobProto::_internal_mutable_data() {
return &data_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
BlobProto::mutable_data() {
// @@protoc_insertion_point(field_mutable_list:caffe.BlobProto.data)
return _internal_mutable_data();
}
// repeated float diff = 6 [packed = true];
inline int BlobProto::_internal_diff_size() const {
return diff_.size();
}
inline int BlobProto::diff_size() const {
return _internal_diff_size();
}
inline void BlobProto::clear_diff() {
diff_.Clear();
}
inline float BlobProto::_internal_diff(int index) const {
return diff_.Get(index);
}
inline float BlobProto::diff(int index) const {
// @@protoc_insertion_point(field_get:caffe.BlobProto.diff)
return _internal_diff(index);
}
inline void BlobProto::set_diff(int index, float value) {
diff_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.BlobProto.diff)
}
inline void BlobProto::_internal_add_diff(float value) {
diff_.Add(value);
}
inline void BlobProto::add_diff(float value) {
_internal_add_diff(value);
// @@protoc_insertion_point(field_add:caffe.BlobProto.diff)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
BlobProto::_internal_diff() const {
return diff_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
BlobProto::diff() const {
// @@protoc_insertion_point(field_list:caffe.BlobProto.diff)
return _internal_diff();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
BlobProto::_internal_mutable_diff() {
return &diff_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
BlobProto::mutable_diff() {
// @@protoc_insertion_point(field_mutable_list:caffe.BlobProto.diff)
return _internal_mutable_diff();
}
// repeated double double_data = 8 [packed = true];
inline int BlobProto::_internal_double_data_size() const {
return double_data_.size();
}
inline int BlobProto::double_data_size() const {
return _internal_double_data_size();
}
inline void BlobProto::clear_double_data() {
double_data_.Clear();
}
inline double BlobProto::_internal_double_data(int index) const {
return double_data_.Get(index);
}
inline double BlobProto::double_data(int index) const {
// @@protoc_insertion_point(field_get:caffe.BlobProto.double_data)
return _internal_double_data(index);
}
inline void BlobProto::set_double_data(int index, double value) {
double_data_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.BlobProto.double_data)
}
inline void BlobProto::_internal_add_double_data(double value) {
double_data_.Add(value);
}
inline void BlobProto::add_double_data(double value) {
_internal_add_double_data(value);
// @@protoc_insertion_point(field_add:caffe.BlobProto.double_data)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< double >&
BlobProto::_internal_double_data() const {
return double_data_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< double >&
BlobProto::double_data() const {
// @@protoc_insertion_point(field_list:caffe.BlobProto.double_data)
return _internal_double_data();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< double >*
BlobProto::_internal_mutable_double_data() {
return &double_data_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< double >*
BlobProto::mutable_double_data() {
// @@protoc_insertion_point(field_mutable_list:caffe.BlobProto.double_data)
return _internal_mutable_double_data();
}
// repeated double double_diff = 9 [packed = true];
inline int BlobProto::_internal_double_diff_size() const {
return double_diff_.size();
}
inline int BlobProto::double_diff_size() const {
return _internal_double_diff_size();
}
inline void BlobProto::clear_double_diff() {
double_diff_.Clear();
}
inline double BlobProto::_internal_double_diff(int index) const {
return double_diff_.Get(index);
}
inline double BlobProto::double_diff(int index) const {
// @@protoc_insertion_point(field_get:caffe.BlobProto.double_diff)
return _internal_double_diff(index);
}
inline void BlobProto::set_double_diff(int index, double value) {
double_diff_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.BlobProto.double_diff)
}
inline void BlobProto::_internal_add_double_diff(double value) {
double_diff_.Add(value);
}
inline void BlobProto::add_double_diff(double value) {
_internal_add_double_diff(value);
// @@protoc_insertion_point(field_add:caffe.BlobProto.double_diff)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< double >&
BlobProto::_internal_double_diff() const {
return double_diff_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< double >&
BlobProto::double_diff() const {
// @@protoc_insertion_point(field_list:caffe.BlobProto.double_diff)
return _internal_double_diff();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< double >*
BlobProto::_internal_mutable_double_diff() {
return &double_diff_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< double >*
BlobProto::mutable_double_diff() {
// @@protoc_insertion_point(field_mutable_list:caffe.BlobProto.double_diff)
return _internal_mutable_double_diff();
}
// optional int32 num = 1 [default = 0];
inline bool BlobProto::_internal_has_num() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool BlobProto::has_num() const {
return _internal_has_num();
}
inline void BlobProto::clear_num() {
num_ = 0;
_has_bits_[0] &= ~0x00000002u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 BlobProto::_internal_num() const {
return num_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 BlobProto::num() const {
// @@protoc_insertion_point(field_get:caffe.BlobProto.num)
return _internal_num();
}
inline void BlobProto::_internal_set_num(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000002u;
num_ = value;
}
inline void BlobProto::set_num(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_num(value);
// @@protoc_insertion_point(field_set:caffe.BlobProto.num)
}
// optional int32 channels = 2 [default = 0];
inline bool BlobProto::_internal_has_channels() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool BlobProto::has_channels() const {
return _internal_has_channels();
}
inline void BlobProto::clear_channels() {
channels_ = 0;
_has_bits_[0] &= ~0x00000004u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 BlobProto::_internal_channels() const {
return channels_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 BlobProto::channels() const {
// @@protoc_insertion_point(field_get:caffe.BlobProto.channels)
return _internal_channels();
}
inline void BlobProto::_internal_set_channels(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000004u;
channels_ = value;
}
inline void BlobProto::set_channels(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_channels(value);
// @@protoc_insertion_point(field_set:caffe.BlobProto.channels)
}
// optional int32 height = 3 [default = 0];
inline bool BlobProto::_internal_has_height() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool BlobProto::has_height() const {
return _internal_has_height();
}
inline void BlobProto::clear_height() {
height_ = 0;
_has_bits_[0] &= ~0x00000008u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 BlobProto::_internal_height() const {
return height_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 BlobProto::height() const {
// @@protoc_insertion_point(field_get:caffe.BlobProto.height)
return _internal_height();
}
inline void BlobProto::_internal_set_height(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000008u;
height_ = value;
}
inline void BlobProto::set_height(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_height(value);
// @@protoc_insertion_point(field_set:caffe.BlobProto.height)
}
// optional int32 width = 4 [default = 0];
inline bool BlobProto::_internal_has_width() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool BlobProto::has_width() const {
return _internal_has_width();
}
inline void BlobProto::clear_width() {
width_ = 0;
_has_bits_[0] &= ~0x00000010u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 BlobProto::_internal_width() const {
return width_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 BlobProto::width() const {
// @@protoc_insertion_point(field_get:caffe.BlobProto.width)
return _internal_width();
}
inline void BlobProto::_internal_set_width(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000010u;
width_ = value;
}
inline void BlobProto::set_width(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_width(value);
// @@protoc_insertion_point(field_set:caffe.BlobProto.width)
}
// -------------------------------------------------------------------
// BlobProtoVector
// repeated .caffe.BlobProto blobs = 1;
inline int BlobProtoVector::_internal_blobs_size() const {
return blobs_.size();
}
inline int BlobProtoVector::blobs_size() const {
return _internal_blobs_size();
}
inline void BlobProtoVector::clear_blobs() {
blobs_.Clear();
}
inline ::caffe::BlobProto* BlobProtoVector::mutable_blobs(int index) {
// @@protoc_insertion_point(field_mutable:caffe.BlobProtoVector.blobs)
return blobs_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto >*
BlobProtoVector::mutable_blobs() {
// @@protoc_insertion_point(field_mutable_list:caffe.BlobProtoVector.blobs)
return &blobs_;
}
inline const ::caffe::BlobProto& BlobProtoVector::_internal_blobs(int index) const {
return blobs_.Get(index);
}
inline const ::caffe::BlobProto& BlobProtoVector::blobs(int index) const {
// @@protoc_insertion_point(field_get:caffe.BlobProtoVector.blobs)
return _internal_blobs(index);
}
inline ::caffe::BlobProto* BlobProtoVector::_internal_add_blobs() {
return blobs_.Add();
}
inline ::caffe::BlobProto* BlobProtoVector::add_blobs() {
// @@protoc_insertion_point(field_add:caffe.BlobProtoVector.blobs)
return _internal_add_blobs();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto >&
BlobProtoVector::blobs() const {
// @@protoc_insertion_point(field_list:caffe.BlobProtoVector.blobs)
return blobs_;
}
// -------------------------------------------------------------------
// Datum
// optional int32 channels = 1;
inline bool Datum::_internal_has_channels() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool Datum::has_channels() const {
return _internal_has_channels();
}
inline void Datum::clear_channels() {
channels_ = 0;
_has_bits_[0] &= ~0x00000002u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 Datum::_internal_channels() const {
return channels_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 Datum::channels() const {
// @@protoc_insertion_point(field_get:caffe.Datum.channels)
return _internal_channels();
}
inline void Datum::_internal_set_channels(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000002u;
channels_ = value;
}
inline void Datum::set_channels(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_channels(value);
// @@protoc_insertion_point(field_set:caffe.Datum.channels)
}
// optional int32 height = 2;
inline bool Datum::_internal_has_height() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool Datum::has_height() const {
return _internal_has_height();
}
inline void Datum::clear_height() {
height_ = 0;
_has_bits_[0] &= ~0x00000004u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 Datum::_internal_height() const {
return height_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 Datum::height() const {
// @@protoc_insertion_point(field_get:caffe.Datum.height)
return _internal_height();
}
inline void Datum::_internal_set_height(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000004u;
height_ = value;
}
inline void Datum::set_height(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_height(value);
// @@protoc_insertion_point(field_set:caffe.Datum.height)
}
// optional int32 width = 3;
inline bool Datum::_internal_has_width() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool Datum::has_width() const {
return _internal_has_width();
}
inline void Datum::clear_width() {
width_ = 0;
_has_bits_[0] &= ~0x00000008u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 Datum::_internal_width() const {
return width_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 Datum::width() const {
// @@protoc_insertion_point(field_get:caffe.Datum.width)
return _internal_width();
}
inline void Datum::_internal_set_width(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000008u;
width_ = value;
}
inline void Datum::set_width(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_width(value);
// @@protoc_insertion_point(field_set:caffe.Datum.width)
}
// optional bytes data = 4;
inline bool Datum::_internal_has_data() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool Datum::has_data() const {
return _internal_has_data();
}
inline void Datum::clear_data() {
data_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000001u;
}
inline const std::string& Datum::data() const {
// @@protoc_insertion_point(field_get:caffe.Datum.data)
return _internal_data();
}
inline void Datum::set_data(const std::string& value) {
_internal_set_data(value);
// @@protoc_insertion_point(field_set:caffe.Datum.data)
}
inline std::string* Datum::mutable_data() {
// @@protoc_insertion_point(field_mutable:caffe.Datum.data)
return _internal_mutable_data();
}
inline const std::string& Datum::_internal_data() const {
return data_.Get();
}
inline void Datum::_internal_set_data(const std::string& value) {
_has_bits_[0] |= 0x00000001u;
data_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void Datum::set_data(std::string&& value) {
_has_bits_[0] |= 0x00000001u;
data_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.Datum.data)
}
inline void Datum::set_data(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000001u;
data_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.Datum.data)
}
inline void Datum::set_data(const void* value,
size_t size) {
_has_bits_[0] |= 0x00000001u;
data_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.Datum.data)
}
inline std::string* Datum::_internal_mutable_data() {
_has_bits_[0] |= 0x00000001u;
return data_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* Datum::release_data() {
// @@protoc_insertion_point(field_release:caffe.Datum.data)
if (!_internal_has_data()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000001u;
return data_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void Datum::set_allocated_data(std::string* data) {
if (data != nullptr) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
data_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), data,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.Datum.data)
}
// optional int32 label = 5;
inline bool Datum::_internal_has_label() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool Datum::has_label() const {
return _internal_has_label();
}
inline void Datum::clear_label() {
label_ = 0;
_has_bits_[0] &= ~0x00000010u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 Datum::_internal_label() const {
return label_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 Datum::label() const {
// @@protoc_insertion_point(field_get:caffe.Datum.label)
return _internal_label();
}
inline void Datum::_internal_set_label(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000010u;
label_ = value;
}
inline void Datum::set_label(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_label(value);
// @@protoc_insertion_point(field_set:caffe.Datum.label)
}
// repeated float float_data = 6;
inline int Datum::_internal_float_data_size() const {
return float_data_.size();
}
inline int Datum::float_data_size() const {
return _internal_float_data_size();
}
inline void Datum::clear_float_data() {
float_data_.Clear();
}
inline float Datum::_internal_float_data(int index) const {
return float_data_.Get(index);
}
inline float Datum::float_data(int index) const {
// @@protoc_insertion_point(field_get:caffe.Datum.float_data)
return _internal_float_data(index);
}
inline void Datum::set_float_data(int index, float value) {
float_data_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.Datum.float_data)
}
inline void Datum::_internal_add_float_data(float value) {
float_data_.Add(value);
}
inline void Datum::add_float_data(float value) {
_internal_add_float_data(value);
// @@protoc_insertion_point(field_add:caffe.Datum.float_data)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
Datum::_internal_float_data() const {
return float_data_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
Datum::float_data() const {
// @@protoc_insertion_point(field_list:caffe.Datum.float_data)
return _internal_float_data();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
Datum::_internal_mutable_float_data() {
return &float_data_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
Datum::mutable_float_data() {
// @@protoc_insertion_point(field_mutable_list:caffe.Datum.float_data)
return _internal_mutable_float_data();
}
// optional bool encoded = 7 [default = false];
inline bool Datum::_internal_has_encoded() const {
bool value = (_has_bits_[0] & 0x00000020u) != 0;
return value;
}
inline bool Datum::has_encoded() const {
return _internal_has_encoded();
}
inline void Datum::clear_encoded() {
encoded_ = false;
_has_bits_[0] &= ~0x00000020u;
}
inline bool Datum::_internal_encoded() const {
return encoded_;
}
inline bool Datum::encoded() const {
// @@protoc_insertion_point(field_get:caffe.Datum.encoded)
return _internal_encoded();
}
inline void Datum::_internal_set_encoded(bool value) {
_has_bits_[0] |= 0x00000020u;
encoded_ = value;
}
inline void Datum::set_encoded(bool value) {
_internal_set_encoded(value);
// @@protoc_insertion_point(field_set:caffe.Datum.encoded)
}
// -------------------------------------------------------------------
// LabelMapItem
// optional string name = 1;
inline bool LabelMapItem::_internal_has_name() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool LabelMapItem::has_name() const {
return _internal_has_name();
}
inline void LabelMapItem::clear_name() {
name_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000001u;
}
inline const std::string& LabelMapItem::name() const {
// @@protoc_insertion_point(field_get:caffe.LabelMapItem.name)
return _internal_name();
}
inline void LabelMapItem::set_name(const std::string& value) {
_internal_set_name(value);
// @@protoc_insertion_point(field_set:caffe.LabelMapItem.name)
}
inline std::string* LabelMapItem::mutable_name() {
// @@protoc_insertion_point(field_mutable:caffe.LabelMapItem.name)
return _internal_mutable_name();
}
inline const std::string& LabelMapItem::_internal_name() const {
return name_.Get();
}
inline void LabelMapItem::_internal_set_name(const std::string& value) {
_has_bits_[0] |= 0x00000001u;
name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void LabelMapItem::set_name(std::string&& value) {
_has_bits_[0] |= 0x00000001u;
name_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.LabelMapItem.name)
}
inline void LabelMapItem::set_name(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000001u;
name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.LabelMapItem.name)
}
inline void LabelMapItem::set_name(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000001u;
name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.LabelMapItem.name)
}
inline std::string* LabelMapItem::_internal_mutable_name() {
_has_bits_[0] |= 0x00000001u;
return name_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* LabelMapItem::release_name() {
// @@protoc_insertion_point(field_release:caffe.LabelMapItem.name)
if (!_internal_has_name()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000001u;
return name_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void LabelMapItem::set_allocated_name(std::string* name) {
if (name != nullptr) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
name_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), name,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.LabelMapItem.name)
}
// optional int32 label = 2;
inline bool LabelMapItem::_internal_has_label() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool LabelMapItem::has_label() const {
return _internal_has_label();
}
inline void LabelMapItem::clear_label() {
label_ = 0;
_has_bits_[0] &= ~0x00000004u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 LabelMapItem::_internal_label() const {
return label_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 LabelMapItem::label() const {
// @@protoc_insertion_point(field_get:caffe.LabelMapItem.label)
return _internal_label();
}
inline void LabelMapItem::_internal_set_label(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000004u;
label_ = value;
}
inline void LabelMapItem::set_label(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_label(value);
// @@protoc_insertion_point(field_set:caffe.LabelMapItem.label)
}
// optional string display_name = 3;
inline bool LabelMapItem::_internal_has_display_name() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool LabelMapItem::has_display_name() const {
return _internal_has_display_name();
}
inline void LabelMapItem::clear_display_name() {
display_name_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000002u;
}
inline const std::string& LabelMapItem::display_name() const {
// @@protoc_insertion_point(field_get:caffe.LabelMapItem.display_name)
return _internal_display_name();
}
inline void LabelMapItem::set_display_name(const std::string& value) {
_internal_set_display_name(value);
// @@protoc_insertion_point(field_set:caffe.LabelMapItem.display_name)
}
inline std::string* LabelMapItem::mutable_display_name() {
// @@protoc_insertion_point(field_mutable:caffe.LabelMapItem.display_name)
return _internal_mutable_display_name();
}
inline const std::string& LabelMapItem::_internal_display_name() const {
return display_name_.Get();
}
inline void LabelMapItem::_internal_set_display_name(const std::string& value) {
_has_bits_[0] |= 0x00000002u;
display_name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void LabelMapItem::set_display_name(std::string&& value) {
_has_bits_[0] |= 0x00000002u;
display_name_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.LabelMapItem.display_name)
}
inline void LabelMapItem::set_display_name(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000002u;
display_name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.LabelMapItem.display_name)
}
inline void LabelMapItem::set_display_name(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000002u;
display_name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.LabelMapItem.display_name)
}
inline std::string* LabelMapItem::_internal_mutable_display_name() {
_has_bits_[0] |= 0x00000002u;
return display_name_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* LabelMapItem::release_display_name() {
// @@protoc_insertion_point(field_release:caffe.LabelMapItem.display_name)
if (!_internal_has_display_name()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000002u;
return display_name_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void LabelMapItem::set_allocated_display_name(std::string* display_name) {
if (display_name != nullptr) {
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
display_name_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), display_name,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.LabelMapItem.display_name)
}
// -------------------------------------------------------------------
// LabelMap
// repeated .caffe.LabelMapItem item = 1;
inline int LabelMap::_internal_item_size() const {
return item_.size();
}
inline int LabelMap::item_size() const {
return _internal_item_size();
}
inline void LabelMap::clear_item() {
item_.Clear();
}
inline ::caffe::LabelMapItem* LabelMap::mutable_item(int index) {
// @@protoc_insertion_point(field_mutable:caffe.LabelMap.item)
return item_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::LabelMapItem >*
LabelMap::mutable_item() {
// @@protoc_insertion_point(field_mutable_list:caffe.LabelMap.item)
return &item_;
}
inline const ::caffe::LabelMapItem& LabelMap::_internal_item(int index) const {
return item_.Get(index);
}
inline const ::caffe::LabelMapItem& LabelMap::item(int index) const {
// @@protoc_insertion_point(field_get:caffe.LabelMap.item)
return _internal_item(index);
}
inline ::caffe::LabelMapItem* LabelMap::_internal_add_item() {
return item_.Add();
}
inline ::caffe::LabelMapItem* LabelMap::add_item() {
// @@protoc_insertion_point(field_add:caffe.LabelMap.item)
return _internal_add_item();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::LabelMapItem >&
LabelMap::item() const {
// @@protoc_insertion_point(field_list:caffe.LabelMap.item)
return item_;
}
// -------------------------------------------------------------------
// Sampler
// optional float min_scale = 1 [default = 1];
inline bool Sampler::_internal_has_min_scale() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool Sampler::has_min_scale() const {
return _internal_has_min_scale();
}
inline void Sampler::clear_min_scale() {
min_scale_ = 1;
_has_bits_[0] &= ~0x00000001u;
}
inline float Sampler::_internal_min_scale() const {
return min_scale_;
}
inline float Sampler::min_scale() const {
// @@protoc_insertion_point(field_get:caffe.Sampler.min_scale)
return _internal_min_scale();
}
inline void Sampler::_internal_set_min_scale(float value) {
_has_bits_[0] |= 0x00000001u;
min_scale_ = value;
}
inline void Sampler::set_min_scale(float value) {
_internal_set_min_scale(value);
// @@protoc_insertion_point(field_set:caffe.Sampler.min_scale)
}
// optional float max_scale = 2 [default = 1];
inline bool Sampler::_internal_has_max_scale() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool Sampler::has_max_scale() const {
return _internal_has_max_scale();
}
inline void Sampler::clear_max_scale() {
max_scale_ = 1;
_has_bits_[0] &= ~0x00000002u;
}
inline float Sampler::_internal_max_scale() const {
return max_scale_;
}
inline float Sampler::max_scale() const {
// @@protoc_insertion_point(field_get:caffe.Sampler.max_scale)
return _internal_max_scale();
}
inline void Sampler::_internal_set_max_scale(float value) {
_has_bits_[0] |= 0x00000002u;
max_scale_ = value;
}
inline void Sampler::set_max_scale(float value) {
_internal_set_max_scale(value);
// @@protoc_insertion_point(field_set:caffe.Sampler.max_scale)
}
// optional float min_aspect_ratio = 3 [default = 1];
inline bool Sampler::_internal_has_min_aspect_ratio() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool Sampler::has_min_aspect_ratio() const {
return _internal_has_min_aspect_ratio();
}
inline void Sampler::clear_min_aspect_ratio() {
min_aspect_ratio_ = 1;
_has_bits_[0] &= ~0x00000004u;
}
inline float Sampler::_internal_min_aspect_ratio() const {
return min_aspect_ratio_;
}
inline float Sampler::min_aspect_ratio() const {
// @@protoc_insertion_point(field_get:caffe.Sampler.min_aspect_ratio)
return _internal_min_aspect_ratio();
}
inline void Sampler::_internal_set_min_aspect_ratio(float value) {
_has_bits_[0] |= 0x00000004u;
min_aspect_ratio_ = value;
}
inline void Sampler::set_min_aspect_ratio(float value) {
_internal_set_min_aspect_ratio(value);
// @@protoc_insertion_point(field_set:caffe.Sampler.min_aspect_ratio)
}
// optional float max_aspect_ratio = 4 [default = 1];
inline bool Sampler::_internal_has_max_aspect_ratio() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool Sampler::has_max_aspect_ratio() const {
return _internal_has_max_aspect_ratio();
}
inline void Sampler::clear_max_aspect_ratio() {
max_aspect_ratio_ = 1;
_has_bits_[0] &= ~0x00000008u;
}
inline float Sampler::_internal_max_aspect_ratio() const {
return max_aspect_ratio_;
}
inline float Sampler::max_aspect_ratio() const {
// @@protoc_insertion_point(field_get:caffe.Sampler.max_aspect_ratio)
return _internal_max_aspect_ratio();
}
inline void Sampler::_internal_set_max_aspect_ratio(float value) {
_has_bits_[0] |= 0x00000008u;
max_aspect_ratio_ = value;
}
inline void Sampler::set_max_aspect_ratio(float value) {
_internal_set_max_aspect_ratio(value);
// @@protoc_insertion_point(field_set:caffe.Sampler.max_aspect_ratio)
}
// -------------------------------------------------------------------
// SampleConstraint
// optional float min_jaccard_overlap = 1;
inline bool SampleConstraint::_internal_has_min_jaccard_overlap() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool SampleConstraint::has_min_jaccard_overlap() const {
return _internal_has_min_jaccard_overlap();
}
inline void SampleConstraint::clear_min_jaccard_overlap() {
min_jaccard_overlap_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline float SampleConstraint::_internal_min_jaccard_overlap() const {
return min_jaccard_overlap_;
}
inline float SampleConstraint::min_jaccard_overlap() const {
// @@protoc_insertion_point(field_get:caffe.SampleConstraint.min_jaccard_overlap)
return _internal_min_jaccard_overlap();
}
inline void SampleConstraint::_internal_set_min_jaccard_overlap(float value) {
_has_bits_[0] |= 0x00000001u;
min_jaccard_overlap_ = value;
}
inline void SampleConstraint::set_min_jaccard_overlap(float value) {
_internal_set_min_jaccard_overlap(value);
// @@protoc_insertion_point(field_set:caffe.SampleConstraint.min_jaccard_overlap)
}
// optional float max_jaccard_overlap = 2;
inline bool SampleConstraint::_internal_has_max_jaccard_overlap() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool SampleConstraint::has_max_jaccard_overlap() const {
return _internal_has_max_jaccard_overlap();
}
inline void SampleConstraint::clear_max_jaccard_overlap() {
max_jaccard_overlap_ = 0;
_has_bits_[0] &= ~0x00000002u;
}
inline float SampleConstraint::_internal_max_jaccard_overlap() const {
return max_jaccard_overlap_;
}
inline float SampleConstraint::max_jaccard_overlap() const {
// @@protoc_insertion_point(field_get:caffe.SampleConstraint.max_jaccard_overlap)
return _internal_max_jaccard_overlap();
}
inline void SampleConstraint::_internal_set_max_jaccard_overlap(float value) {
_has_bits_[0] |= 0x00000002u;
max_jaccard_overlap_ = value;
}
inline void SampleConstraint::set_max_jaccard_overlap(float value) {
_internal_set_max_jaccard_overlap(value);
// @@protoc_insertion_point(field_set:caffe.SampleConstraint.max_jaccard_overlap)
}
// optional float min_sample_coverage = 3;
inline bool SampleConstraint::_internal_has_min_sample_coverage() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool SampleConstraint::has_min_sample_coverage() const {
return _internal_has_min_sample_coverage();
}
inline void SampleConstraint::clear_min_sample_coverage() {
min_sample_coverage_ = 0;
_has_bits_[0] &= ~0x00000004u;
}
inline float SampleConstraint::_internal_min_sample_coverage() const {
return min_sample_coverage_;
}
inline float SampleConstraint::min_sample_coverage() const {
// @@protoc_insertion_point(field_get:caffe.SampleConstraint.min_sample_coverage)
return _internal_min_sample_coverage();
}
inline void SampleConstraint::_internal_set_min_sample_coverage(float value) {
_has_bits_[0] |= 0x00000004u;
min_sample_coverage_ = value;
}
inline void SampleConstraint::set_min_sample_coverage(float value) {
_internal_set_min_sample_coverage(value);
// @@protoc_insertion_point(field_set:caffe.SampleConstraint.min_sample_coverage)
}
// optional float max_sample_coverage = 4;
inline bool SampleConstraint::_internal_has_max_sample_coverage() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool SampleConstraint::has_max_sample_coverage() const {
return _internal_has_max_sample_coverage();
}
inline void SampleConstraint::clear_max_sample_coverage() {
max_sample_coverage_ = 0;
_has_bits_[0] &= ~0x00000008u;
}
inline float SampleConstraint::_internal_max_sample_coverage() const {
return max_sample_coverage_;
}
inline float SampleConstraint::max_sample_coverage() const {
// @@protoc_insertion_point(field_get:caffe.SampleConstraint.max_sample_coverage)
return _internal_max_sample_coverage();
}
inline void SampleConstraint::_internal_set_max_sample_coverage(float value) {
_has_bits_[0] |= 0x00000008u;
max_sample_coverage_ = value;
}
inline void SampleConstraint::set_max_sample_coverage(float value) {
_internal_set_max_sample_coverage(value);
// @@protoc_insertion_point(field_set:caffe.SampleConstraint.max_sample_coverage)
}
// optional float min_object_coverage = 5;
inline bool SampleConstraint::_internal_has_min_object_coverage() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool SampleConstraint::has_min_object_coverage() const {
return _internal_has_min_object_coverage();
}
inline void SampleConstraint::clear_min_object_coverage() {
min_object_coverage_ = 0;
_has_bits_[0] &= ~0x00000010u;
}
inline float SampleConstraint::_internal_min_object_coverage() const {
return min_object_coverage_;
}
inline float SampleConstraint::min_object_coverage() const {
// @@protoc_insertion_point(field_get:caffe.SampleConstraint.min_object_coverage)
return _internal_min_object_coverage();
}
inline void SampleConstraint::_internal_set_min_object_coverage(float value) {
_has_bits_[0] |= 0x00000010u;
min_object_coverage_ = value;
}
inline void SampleConstraint::set_min_object_coverage(float value) {
_internal_set_min_object_coverage(value);
// @@protoc_insertion_point(field_set:caffe.SampleConstraint.min_object_coverage)
}
// optional float max_object_coverage = 6;
inline bool SampleConstraint::_internal_has_max_object_coverage() const {
bool value = (_has_bits_[0] & 0x00000020u) != 0;
return value;
}
inline bool SampleConstraint::has_max_object_coverage() const {
return _internal_has_max_object_coverage();
}
inline void SampleConstraint::clear_max_object_coverage() {
max_object_coverage_ = 0;
_has_bits_[0] &= ~0x00000020u;
}
inline float SampleConstraint::_internal_max_object_coverage() const {
return max_object_coverage_;
}
inline float SampleConstraint::max_object_coverage() const {
// @@protoc_insertion_point(field_get:caffe.SampleConstraint.max_object_coverage)
return _internal_max_object_coverage();
}
inline void SampleConstraint::_internal_set_max_object_coverage(float value) {
_has_bits_[0] |= 0x00000020u;
max_object_coverage_ = value;
}
inline void SampleConstraint::set_max_object_coverage(float value) {
_internal_set_max_object_coverage(value);
// @@protoc_insertion_point(field_set:caffe.SampleConstraint.max_object_coverage)
}
// -------------------------------------------------------------------
// BatchSampler
// optional bool use_original_image = 1 [default = true];
inline bool BatchSampler::_internal_has_use_original_image() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool BatchSampler::has_use_original_image() const {
return _internal_has_use_original_image();
}
inline void BatchSampler::clear_use_original_image() {
use_original_image_ = true;
_has_bits_[0] &= ~0x00000008u;
}
inline bool BatchSampler::_internal_use_original_image() const {
return use_original_image_;
}
inline bool BatchSampler::use_original_image() const {
// @@protoc_insertion_point(field_get:caffe.BatchSampler.use_original_image)
return _internal_use_original_image();
}
inline void BatchSampler::_internal_set_use_original_image(bool value) {
_has_bits_[0] |= 0x00000008u;
use_original_image_ = value;
}
inline void BatchSampler::set_use_original_image(bool value) {
_internal_set_use_original_image(value);
// @@protoc_insertion_point(field_set:caffe.BatchSampler.use_original_image)
}
// optional .caffe.Sampler sampler = 2;
inline bool BatchSampler::_internal_has_sampler() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
PROTOBUF_ASSUME(!value || sampler_ != nullptr);
return value;
}
inline bool BatchSampler::has_sampler() const {
return _internal_has_sampler();
}
inline void BatchSampler::clear_sampler() {
if (sampler_ != nullptr) sampler_->Clear();
_has_bits_[0] &= ~0x00000001u;
}
inline const ::caffe::Sampler& BatchSampler::_internal_sampler() const {
const ::caffe::Sampler* p = sampler_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::Sampler*>(
&::caffe::_Sampler_default_instance_);
}
inline const ::caffe::Sampler& BatchSampler::sampler() const {
// @@protoc_insertion_point(field_get:caffe.BatchSampler.sampler)
return _internal_sampler();
}
inline void BatchSampler::unsafe_arena_set_allocated_sampler(
::caffe::Sampler* sampler) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(sampler_);
}
sampler_ = sampler;
if (sampler) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.BatchSampler.sampler)
}
inline ::caffe::Sampler* BatchSampler::release_sampler() {
_has_bits_[0] &= ~0x00000001u;
::caffe::Sampler* temp = sampler_;
sampler_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::Sampler* BatchSampler::unsafe_arena_release_sampler() {
// @@protoc_insertion_point(field_release:caffe.BatchSampler.sampler)
_has_bits_[0] &= ~0x00000001u;
::caffe::Sampler* temp = sampler_;
sampler_ = nullptr;
return temp;
}
inline ::caffe::Sampler* BatchSampler::_internal_mutable_sampler() {
_has_bits_[0] |= 0x00000001u;
if (sampler_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::Sampler>(GetArena());
sampler_ = p;
}
return sampler_;
}
inline ::caffe::Sampler* BatchSampler::mutable_sampler() {
// @@protoc_insertion_point(field_mutable:caffe.BatchSampler.sampler)
return _internal_mutable_sampler();
}
inline void BatchSampler::set_allocated_sampler(::caffe::Sampler* sampler) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete sampler_;
}
if (sampler) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(sampler);
if (message_arena != submessage_arena) {
sampler = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, sampler, submessage_arena);
}
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
sampler_ = sampler;
// @@protoc_insertion_point(field_set_allocated:caffe.BatchSampler.sampler)
}
// optional .caffe.SampleConstraint sample_constraint = 3;
inline bool BatchSampler::_internal_has_sample_constraint() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
PROTOBUF_ASSUME(!value || sample_constraint_ != nullptr);
return value;
}
inline bool BatchSampler::has_sample_constraint() const {
return _internal_has_sample_constraint();
}
inline void BatchSampler::clear_sample_constraint() {
if (sample_constraint_ != nullptr) sample_constraint_->Clear();
_has_bits_[0] &= ~0x00000002u;
}
inline const ::caffe::SampleConstraint& BatchSampler::_internal_sample_constraint() const {
const ::caffe::SampleConstraint* p = sample_constraint_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::SampleConstraint*>(
&::caffe::_SampleConstraint_default_instance_);
}
inline const ::caffe::SampleConstraint& BatchSampler::sample_constraint() const {
// @@protoc_insertion_point(field_get:caffe.BatchSampler.sample_constraint)
return _internal_sample_constraint();
}
inline void BatchSampler::unsafe_arena_set_allocated_sample_constraint(
::caffe::SampleConstraint* sample_constraint) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(sample_constraint_);
}
sample_constraint_ = sample_constraint;
if (sample_constraint) {
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.BatchSampler.sample_constraint)
}
inline ::caffe::SampleConstraint* BatchSampler::release_sample_constraint() {
_has_bits_[0] &= ~0x00000002u;
::caffe::SampleConstraint* temp = sample_constraint_;
sample_constraint_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::SampleConstraint* BatchSampler::unsafe_arena_release_sample_constraint() {
// @@protoc_insertion_point(field_release:caffe.BatchSampler.sample_constraint)
_has_bits_[0] &= ~0x00000002u;
::caffe::SampleConstraint* temp = sample_constraint_;
sample_constraint_ = nullptr;
return temp;
}
inline ::caffe::SampleConstraint* BatchSampler::_internal_mutable_sample_constraint() {
_has_bits_[0] |= 0x00000002u;
if (sample_constraint_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::SampleConstraint>(GetArena());
sample_constraint_ = p;
}
return sample_constraint_;
}
inline ::caffe::SampleConstraint* BatchSampler::mutable_sample_constraint() {
// @@protoc_insertion_point(field_mutable:caffe.BatchSampler.sample_constraint)
return _internal_mutable_sample_constraint();
}
inline void BatchSampler::set_allocated_sample_constraint(::caffe::SampleConstraint* sample_constraint) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete sample_constraint_;
}
if (sample_constraint) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(sample_constraint);
if (message_arena != submessage_arena) {
sample_constraint = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, sample_constraint, submessage_arena);
}
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
sample_constraint_ = sample_constraint;
// @@protoc_insertion_point(field_set_allocated:caffe.BatchSampler.sample_constraint)
}
// optional uint32 max_sample = 4;
inline bool BatchSampler::_internal_has_max_sample() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool BatchSampler::has_max_sample() const {
return _internal_has_max_sample();
}
inline void BatchSampler::clear_max_sample() {
max_sample_ = 0u;
_has_bits_[0] &= ~0x00000004u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 BatchSampler::_internal_max_sample() const {
return max_sample_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 BatchSampler::max_sample() const {
// @@protoc_insertion_point(field_get:caffe.BatchSampler.max_sample)
return _internal_max_sample();
}
inline void BatchSampler::_internal_set_max_sample(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000004u;
max_sample_ = value;
}
inline void BatchSampler::set_max_sample(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_max_sample(value);
// @@protoc_insertion_point(field_set:caffe.BatchSampler.max_sample)
}
// optional uint32 max_trials = 5 [default = 100];
inline bool BatchSampler::_internal_has_max_trials() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool BatchSampler::has_max_trials() const {
return _internal_has_max_trials();
}
inline void BatchSampler::clear_max_trials() {
max_trials_ = 100u;
_has_bits_[0] &= ~0x00000010u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 BatchSampler::_internal_max_trials() const {
return max_trials_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 BatchSampler::max_trials() const {
// @@protoc_insertion_point(field_get:caffe.BatchSampler.max_trials)
return _internal_max_trials();
}
inline void BatchSampler::_internal_set_max_trials(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000010u;
max_trials_ = value;
}
inline void BatchSampler::set_max_trials(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_max_trials(value);
// @@protoc_insertion_point(field_set:caffe.BatchSampler.max_trials)
}
// -------------------------------------------------------------------
// EmitConstraint
// optional .caffe.EmitConstraint.EmitType emit_type = 1 [default = CENTER];
inline bool EmitConstraint::_internal_has_emit_type() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool EmitConstraint::has_emit_type() const {
return _internal_has_emit_type();
}
inline void EmitConstraint::clear_emit_type() {
emit_type_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline ::caffe::EmitConstraint_EmitType EmitConstraint::_internal_emit_type() const {
return static_cast< ::caffe::EmitConstraint_EmitType >(emit_type_);
}
inline ::caffe::EmitConstraint_EmitType EmitConstraint::emit_type() const {
// @@protoc_insertion_point(field_get:caffe.EmitConstraint.emit_type)
return _internal_emit_type();
}
inline void EmitConstraint::_internal_set_emit_type(::caffe::EmitConstraint_EmitType value) {
assert(::caffe::EmitConstraint_EmitType_IsValid(value));
_has_bits_[0] |= 0x00000001u;
emit_type_ = value;
}
inline void EmitConstraint::set_emit_type(::caffe::EmitConstraint_EmitType value) {
_internal_set_emit_type(value);
// @@protoc_insertion_point(field_set:caffe.EmitConstraint.emit_type)
}
// optional float emit_overlap = 2;
inline bool EmitConstraint::_internal_has_emit_overlap() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool EmitConstraint::has_emit_overlap() const {
return _internal_has_emit_overlap();
}
inline void EmitConstraint::clear_emit_overlap() {
emit_overlap_ = 0;
_has_bits_[0] &= ~0x00000002u;
}
inline float EmitConstraint::_internal_emit_overlap() const {
return emit_overlap_;
}
inline float EmitConstraint::emit_overlap() const {
// @@protoc_insertion_point(field_get:caffe.EmitConstraint.emit_overlap)
return _internal_emit_overlap();
}
inline void EmitConstraint::_internal_set_emit_overlap(float value) {
_has_bits_[0] |= 0x00000002u;
emit_overlap_ = value;
}
inline void EmitConstraint::set_emit_overlap(float value) {
_internal_set_emit_overlap(value);
// @@protoc_insertion_point(field_set:caffe.EmitConstraint.emit_overlap)
}
// -------------------------------------------------------------------
// NormalizedBBox
// optional float xmin = 1;
inline bool NormalizedBBox::_internal_has_xmin() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool NormalizedBBox::has_xmin() const {
return _internal_has_xmin();
}
inline void NormalizedBBox::clear_xmin() {
xmin_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline float NormalizedBBox::_internal_xmin() const {
return xmin_;
}
inline float NormalizedBBox::xmin() const {
// @@protoc_insertion_point(field_get:caffe.NormalizedBBox.xmin)
return _internal_xmin();
}
inline void NormalizedBBox::_internal_set_xmin(float value) {
_has_bits_[0] |= 0x00000001u;
xmin_ = value;
}
inline void NormalizedBBox::set_xmin(float value) {
_internal_set_xmin(value);
// @@protoc_insertion_point(field_set:caffe.NormalizedBBox.xmin)
}
// optional float ymin = 2;
inline bool NormalizedBBox::_internal_has_ymin() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool NormalizedBBox::has_ymin() const {
return _internal_has_ymin();
}
inline void NormalizedBBox::clear_ymin() {
ymin_ = 0;
_has_bits_[0] &= ~0x00000002u;
}
inline float NormalizedBBox::_internal_ymin() const {
return ymin_;
}
inline float NormalizedBBox::ymin() const {
// @@protoc_insertion_point(field_get:caffe.NormalizedBBox.ymin)
return _internal_ymin();
}
inline void NormalizedBBox::_internal_set_ymin(float value) {
_has_bits_[0] |= 0x00000002u;
ymin_ = value;
}
inline void NormalizedBBox::set_ymin(float value) {
_internal_set_ymin(value);
// @@protoc_insertion_point(field_set:caffe.NormalizedBBox.ymin)
}
// optional float xmax = 3;
inline bool NormalizedBBox::_internal_has_xmax() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool NormalizedBBox::has_xmax() const {
return _internal_has_xmax();
}
inline void NormalizedBBox::clear_xmax() {
xmax_ = 0;
_has_bits_[0] &= ~0x00000004u;
}
inline float NormalizedBBox::_internal_xmax() const {
return xmax_;
}
inline float NormalizedBBox::xmax() const {
// @@protoc_insertion_point(field_get:caffe.NormalizedBBox.xmax)
return _internal_xmax();
}
inline void NormalizedBBox::_internal_set_xmax(float value) {
_has_bits_[0] |= 0x00000004u;
xmax_ = value;
}
inline void NormalizedBBox::set_xmax(float value) {
_internal_set_xmax(value);
// @@protoc_insertion_point(field_set:caffe.NormalizedBBox.xmax)
}
// optional float ymax = 4;
inline bool NormalizedBBox::_internal_has_ymax() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool NormalizedBBox::has_ymax() const {
return _internal_has_ymax();
}
inline void NormalizedBBox::clear_ymax() {
ymax_ = 0;
_has_bits_[0] &= ~0x00000008u;
}
inline float NormalizedBBox::_internal_ymax() const {
return ymax_;
}
inline float NormalizedBBox::ymax() const {
// @@protoc_insertion_point(field_get:caffe.NormalizedBBox.ymax)
return _internal_ymax();
}
inline void NormalizedBBox::_internal_set_ymax(float value) {
_has_bits_[0] |= 0x00000008u;
ymax_ = value;
}
inline void NormalizedBBox::set_ymax(float value) {
_internal_set_ymax(value);
// @@protoc_insertion_point(field_set:caffe.NormalizedBBox.ymax)
}
// optional int32 label = 5;
inline bool NormalizedBBox::_internal_has_label() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool NormalizedBBox::has_label() const {
return _internal_has_label();
}
inline void NormalizedBBox::clear_label() {
label_ = 0;
_has_bits_[0] &= ~0x00000010u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 NormalizedBBox::_internal_label() const {
return label_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 NormalizedBBox::label() const {
// @@protoc_insertion_point(field_get:caffe.NormalizedBBox.label)
return _internal_label();
}
inline void NormalizedBBox::_internal_set_label(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000010u;
label_ = value;
}
inline void NormalizedBBox::set_label(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_label(value);
// @@protoc_insertion_point(field_set:caffe.NormalizedBBox.label)
}
// optional bool difficult = 6;
inline bool NormalizedBBox::_internal_has_difficult() const {
bool value = (_has_bits_[0] & 0x00000020u) != 0;
return value;
}
inline bool NormalizedBBox::has_difficult() const {
return _internal_has_difficult();
}
inline void NormalizedBBox::clear_difficult() {
difficult_ = false;
_has_bits_[0] &= ~0x00000020u;
}
inline bool NormalizedBBox::_internal_difficult() const {
return difficult_;
}
inline bool NormalizedBBox::difficult() const {
// @@protoc_insertion_point(field_get:caffe.NormalizedBBox.difficult)
return _internal_difficult();
}
inline void NormalizedBBox::_internal_set_difficult(bool value) {
_has_bits_[0] |= 0x00000020u;
difficult_ = value;
}
inline void NormalizedBBox::set_difficult(bool value) {
_internal_set_difficult(value);
// @@protoc_insertion_point(field_set:caffe.NormalizedBBox.difficult)
}
// optional float score = 7;
inline bool NormalizedBBox::_internal_has_score() const {
bool value = (_has_bits_[0] & 0x00000040u) != 0;
return value;
}
inline bool NormalizedBBox::has_score() const {
return _internal_has_score();
}
inline void NormalizedBBox::clear_score() {
score_ = 0;
_has_bits_[0] &= ~0x00000040u;
}
inline float NormalizedBBox::_internal_score() const {
return score_;
}
inline float NormalizedBBox::score() const {
// @@protoc_insertion_point(field_get:caffe.NormalizedBBox.score)
return _internal_score();
}
inline void NormalizedBBox::_internal_set_score(float value) {
_has_bits_[0] |= 0x00000040u;
score_ = value;
}
inline void NormalizedBBox::set_score(float value) {
_internal_set_score(value);
// @@protoc_insertion_point(field_set:caffe.NormalizedBBox.score)
}
// optional float size = 8;
inline bool NormalizedBBox::_internal_has_size() const {
bool value = (_has_bits_[0] & 0x00000080u) != 0;
return value;
}
inline bool NormalizedBBox::has_size() const {
return _internal_has_size();
}
inline void NormalizedBBox::clear_size() {
size_ = 0;
_has_bits_[0] &= ~0x00000080u;
}
inline float NormalizedBBox::_internal_size() const {
return size_;
}
inline float NormalizedBBox::size() const {
// @@protoc_insertion_point(field_get:caffe.NormalizedBBox.size)
return _internal_size();
}
inline void NormalizedBBox::_internal_set_size(float value) {
_has_bits_[0] |= 0x00000080u;
size_ = value;
}
inline void NormalizedBBox::set_size(float value) {
_internal_set_size(value);
// @@protoc_insertion_point(field_set:caffe.NormalizedBBox.size)
}
// -------------------------------------------------------------------
// Annotation
// optional int32 instance_id = 1 [default = 0];
inline bool Annotation::_internal_has_instance_id() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool Annotation::has_instance_id() const {
return _internal_has_instance_id();
}
inline void Annotation::clear_instance_id() {
instance_id_ = 0;
_has_bits_[0] &= ~0x00000002u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 Annotation::_internal_instance_id() const {
return instance_id_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 Annotation::instance_id() const {
// @@protoc_insertion_point(field_get:caffe.Annotation.instance_id)
return _internal_instance_id();
}
inline void Annotation::_internal_set_instance_id(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000002u;
instance_id_ = value;
}
inline void Annotation::set_instance_id(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_instance_id(value);
// @@protoc_insertion_point(field_set:caffe.Annotation.instance_id)
}
// optional .caffe.NormalizedBBox bbox = 2;
inline bool Annotation::_internal_has_bbox() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
PROTOBUF_ASSUME(!value || bbox_ != nullptr);
return value;
}
inline bool Annotation::has_bbox() const {
return _internal_has_bbox();
}
inline void Annotation::clear_bbox() {
if (bbox_ != nullptr) bbox_->Clear();
_has_bits_[0] &= ~0x00000001u;
}
inline const ::caffe::NormalizedBBox& Annotation::_internal_bbox() const {
const ::caffe::NormalizedBBox* p = bbox_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::NormalizedBBox*>(
&::caffe::_NormalizedBBox_default_instance_);
}
inline const ::caffe::NormalizedBBox& Annotation::bbox() const {
// @@protoc_insertion_point(field_get:caffe.Annotation.bbox)
return _internal_bbox();
}
inline void Annotation::unsafe_arena_set_allocated_bbox(
::caffe::NormalizedBBox* bbox) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(bbox_);
}
bbox_ = bbox;
if (bbox) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.Annotation.bbox)
}
inline ::caffe::NormalizedBBox* Annotation::release_bbox() {
_has_bits_[0] &= ~0x00000001u;
::caffe::NormalizedBBox* temp = bbox_;
bbox_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::NormalizedBBox* Annotation::unsafe_arena_release_bbox() {
// @@protoc_insertion_point(field_release:caffe.Annotation.bbox)
_has_bits_[0] &= ~0x00000001u;
::caffe::NormalizedBBox* temp = bbox_;
bbox_ = nullptr;
return temp;
}
inline ::caffe::NormalizedBBox* Annotation::_internal_mutable_bbox() {
_has_bits_[0] |= 0x00000001u;
if (bbox_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::NormalizedBBox>(GetArena());
bbox_ = p;
}
return bbox_;
}
inline ::caffe::NormalizedBBox* Annotation::mutable_bbox() {
// @@protoc_insertion_point(field_mutable:caffe.Annotation.bbox)
return _internal_mutable_bbox();
}
inline void Annotation::set_allocated_bbox(::caffe::NormalizedBBox* bbox) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete bbox_;
}
if (bbox) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(bbox);
if (message_arena != submessage_arena) {
bbox = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, bbox, submessage_arena);
}
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
bbox_ = bbox;
// @@protoc_insertion_point(field_set_allocated:caffe.Annotation.bbox)
}
// -------------------------------------------------------------------
// AnnotationGroup
// optional int32 group_label = 1;
inline bool AnnotationGroup::_internal_has_group_label() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool AnnotationGroup::has_group_label() const {
return _internal_has_group_label();
}
inline void AnnotationGroup::clear_group_label() {
group_label_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 AnnotationGroup::_internal_group_label() const {
return group_label_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 AnnotationGroup::group_label() const {
// @@protoc_insertion_point(field_get:caffe.AnnotationGroup.group_label)
return _internal_group_label();
}
inline void AnnotationGroup::_internal_set_group_label(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000001u;
group_label_ = value;
}
inline void AnnotationGroup::set_group_label(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_group_label(value);
// @@protoc_insertion_point(field_set:caffe.AnnotationGroup.group_label)
}
// repeated .caffe.Annotation annotation = 2;
inline int AnnotationGroup::_internal_annotation_size() const {
return annotation_.size();
}
inline int AnnotationGroup::annotation_size() const {
return _internal_annotation_size();
}
inline void AnnotationGroup::clear_annotation() {
annotation_.Clear();
}
inline ::caffe::Annotation* AnnotationGroup::mutable_annotation(int index) {
// @@protoc_insertion_point(field_mutable:caffe.AnnotationGroup.annotation)
return annotation_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::Annotation >*
AnnotationGroup::mutable_annotation() {
// @@protoc_insertion_point(field_mutable_list:caffe.AnnotationGroup.annotation)
return &annotation_;
}
inline const ::caffe::Annotation& AnnotationGroup::_internal_annotation(int index) const {
return annotation_.Get(index);
}
inline const ::caffe::Annotation& AnnotationGroup::annotation(int index) const {
// @@protoc_insertion_point(field_get:caffe.AnnotationGroup.annotation)
return _internal_annotation(index);
}
inline ::caffe::Annotation* AnnotationGroup::_internal_add_annotation() {
return annotation_.Add();
}
inline ::caffe::Annotation* AnnotationGroup::add_annotation() {
// @@protoc_insertion_point(field_add:caffe.AnnotationGroup.annotation)
return _internal_add_annotation();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::Annotation >&
AnnotationGroup::annotation() const {
// @@protoc_insertion_point(field_list:caffe.AnnotationGroup.annotation)
return annotation_;
}
// -------------------------------------------------------------------
// AnnotatedDatum
// optional .caffe.Datum datum = 1;
inline bool AnnotatedDatum::_internal_has_datum() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
PROTOBUF_ASSUME(!value || datum_ != nullptr);
return value;
}
inline bool AnnotatedDatum::has_datum() const {
return _internal_has_datum();
}
inline void AnnotatedDatum::clear_datum() {
if (datum_ != nullptr) datum_->Clear();
_has_bits_[0] &= ~0x00000001u;
}
inline const ::caffe::Datum& AnnotatedDatum::_internal_datum() const {
const ::caffe::Datum* p = datum_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::Datum*>(
&::caffe::_Datum_default_instance_);
}
inline const ::caffe::Datum& AnnotatedDatum::datum() const {
// @@protoc_insertion_point(field_get:caffe.AnnotatedDatum.datum)
return _internal_datum();
}
inline void AnnotatedDatum::unsafe_arena_set_allocated_datum(
::caffe::Datum* datum) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(datum_);
}
datum_ = datum;
if (datum) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.AnnotatedDatum.datum)
}
inline ::caffe::Datum* AnnotatedDatum::release_datum() {
_has_bits_[0] &= ~0x00000001u;
::caffe::Datum* temp = datum_;
datum_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::Datum* AnnotatedDatum::unsafe_arena_release_datum() {
// @@protoc_insertion_point(field_release:caffe.AnnotatedDatum.datum)
_has_bits_[0] &= ~0x00000001u;
::caffe::Datum* temp = datum_;
datum_ = nullptr;
return temp;
}
inline ::caffe::Datum* AnnotatedDatum::_internal_mutable_datum() {
_has_bits_[0] |= 0x00000001u;
if (datum_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::Datum>(GetArena());
datum_ = p;
}
return datum_;
}
inline ::caffe::Datum* AnnotatedDatum::mutable_datum() {
// @@protoc_insertion_point(field_mutable:caffe.AnnotatedDatum.datum)
return _internal_mutable_datum();
}
inline void AnnotatedDatum::set_allocated_datum(::caffe::Datum* datum) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete datum_;
}
if (datum) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(datum);
if (message_arena != submessage_arena) {
datum = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, datum, submessage_arena);
}
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
datum_ = datum;
// @@protoc_insertion_point(field_set_allocated:caffe.AnnotatedDatum.datum)
}
// optional .caffe.AnnotatedDatum.AnnotationType type = 2;
inline bool AnnotatedDatum::_internal_has_type() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool AnnotatedDatum::has_type() const {
return _internal_has_type();
}
inline void AnnotatedDatum::clear_type() {
type_ = 0;
_has_bits_[0] &= ~0x00000002u;
}
inline ::caffe::AnnotatedDatum_AnnotationType AnnotatedDatum::_internal_type() const {
return static_cast< ::caffe::AnnotatedDatum_AnnotationType >(type_);
}
inline ::caffe::AnnotatedDatum_AnnotationType AnnotatedDatum::type() const {
// @@protoc_insertion_point(field_get:caffe.AnnotatedDatum.type)
return _internal_type();
}
inline void AnnotatedDatum::_internal_set_type(::caffe::AnnotatedDatum_AnnotationType value) {
assert(::caffe::AnnotatedDatum_AnnotationType_IsValid(value));
_has_bits_[0] |= 0x00000002u;
type_ = value;
}
inline void AnnotatedDatum::set_type(::caffe::AnnotatedDatum_AnnotationType value) {
_internal_set_type(value);
// @@protoc_insertion_point(field_set:caffe.AnnotatedDatum.type)
}
// repeated .caffe.AnnotationGroup annotation_group = 3;
inline int AnnotatedDatum::_internal_annotation_group_size() const {
return annotation_group_.size();
}
inline int AnnotatedDatum::annotation_group_size() const {
return _internal_annotation_group_size();
}
inline void AnnotatedDatum::clear_annotation_group() {
annotation_group_.Clear();
}
inline ::caffe::AnnotationGroup* AnnotatedDatum::mutable_annotation_group(int index) {
// @@protoc_insertion_point(field_mutable:caffe.AnnotatedDatum.annotation_group)
return annotation_group_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::AnnotationGroup >*
AnnotatedDatum::mutable_annotation_group() {
// @@protoc_insertion_point(field_mutable_list:caffe.AnnotatedDatum.annotation_group)
return &annotation_group_;
}
inline const ::caffe::AnnotationGroup& AnnotatedDatum::_internal_annotation_group(int index) const {
return annotation_group_.Get(index);
}
inline const ::caffe::AnnotationGroup& AnnotatedDatum::annotation_group(int index) const {
// @@protoc_insertion_point(field_get:caffe.AnnotatedDatum.annotation_group)
return _internal_annotation_group(index);
}
inline ::caffe::AnnotationGroup* AnnotatedDatum::_internal_add_annotation_group() {
return annotation_group_.Add();
}
inline ::caffe::AnnotationGroup* AnnotatedDatum::add_annotation_group() {
// @@protoc_insertion_point(field_add:caffe.AnnotatedDatum.annotation_group)
return _internal_add_annotation_group();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::AnnotationGroup >&
AnnotatedDatum::annotation_group() const {
// @@protoc_insertion_point(field_list:caffe.AnnotatedDatum.annotation_group)
return annotation_group_;
}
// -------------------------------------------------------------------
// FillerParameter
// optional string type = 1 [default = "constant"];
inline bool FillerParameter::_internal_has_type() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool FillerParameter::has_type() const {
return _internal_has_type();
}
inline void FillerParameter::clear_type() {
type_.ClearToDefault(&::caffe::FillerParameter::_i_give_permission_to_break_this_code_default_type_.get(), GetArena());
_has_bits_[0] &= ~0x00000001u;
}
inline const std::string& FillerParameter::type() const {
// @@protoc_insertion_point(field_get:caffe.FillerParameter.type)
return _internal_type();
}
inline void FillerParameter::set_type(const std::string& value) {
_internal_set_type(value);
// @@protoc_insertion_point(field_set:caffe.FillerParameter.type)
}
inline std::string* FillerParameter::mutable_type() {
// @@protoc_insertion_point(field_mutable:caffe.FillerParameter.type)
return _internal_mutable_type();
}
inline const std::string& FillerParameter::_internal_type() const {
return type_.Get();
}
inline void FillerParameter::_internal_set_type(const std::string& value) {
_has_bits_[0] |= 0x00000001u;
type_.Set(&::caffe::FillerParameter::_i_give_permission_to_break_this_code_default_type_.get(), value, GetArena());
}
inline void FillerParameter::set_type(std::string&& value) {
_has_bits_[0] |= 0x00000001u;
type_.Set(
&::caffe::FillerParameter::_i_give_permission_to_break_this_code_default_type_.get(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.FillerParameter.type)
}
inline void FillerParameter::set_type(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000001u;
type_.Set(&::caffe::FillerParameter::_i_give_permission_to_break_this_code_default_type_.get(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.FillerParameter.type)
}
inline void FillerParameter::set_type(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000001u;
type_.Set(&::caffe::FillerParameter::_i_give_permission_to_break_this_code_default_type_.get(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.FillerParameter.type)
}
inline std::string* FillerParameter::_internal_mutable_type() {
_has_bits_[0] |= 0x00000001u;
return type_.Mutable(&::caffe::FillerParameter::_i_give_permission_to_break_this_code_default_type_.get(), GetArena());
}
inline std::string* FillerParameter::release_type() {
// @@protoc_insertion_point(field_release:caffe.FillerParameter.type)
if (!_internal_has_type()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000001u;
return type_.ReleaseNonDefault(&::caffe::FillerParameter::_i_give_permission_to_break_this_code_default_type_.get(), GetArena());
}
inline void FillerParameter::set_allocated_type(std::string* type) {
if (type != nullptr) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
type_.SetAllocated(&::caffe::FillerParameter::_i_give_permission_to_break_this_code_default_type_.get(), type,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.FillerParameter.type)
}
// optional float value = 2 [default = 0];
inline bool FillerParameter::_internal_has_value() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool FillerParameter::has_value() const {
return _internal_has_value();
}
inline void FillerParameter::clear_value() {
value_ = 0;
_has_bits_[0] &= ~0x00000002u;
}
inline float FillerParameter::_internal_value() const {
return value_;
}
inline float FillerParameter::value() const {
// @@protoc_insertion_point(field_get:caffe.FillerParameter.value)
return _internal_value();
}
inline void FillerParameter::_internal_set_value(float value) {
_has_bits_[0] |= 0x00000002u;
value_ = value;
}
inline void FillerParameter::set_value(float value) {
_internal_set_value(value);
// @@protoc_insertion_point(field_set:caffe.FillerParameter.value)
}
// optional float min = 3 [default = 0];
inline bool FillerParameter::_internal_has_min() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool FillerParameter::has_min() const {
return _internal_has_min();
}
inline void FillerParameter::clear_min() {
min_ = 0;
_has_bits_[0] &= ~0x00000004u;
}
inline float FillerParameter::_internal_min() const {
return min_;
}
inline float FillerParameter::min() const {
// @@protoc_insertion_point(field_get:caffe.FillerParameter.min)
return _internal_min();
}
inline void FillerParameter::_internal_set_min(float value) {
_has_bits_[0] |= 0x00000004u;
min_ = value;
}
inline void FillerParameter::set_min(float value) {
_internal_set_min(value);
// @@protoc_insertion_point(field_set:caffe.FillerParameter.min)
}
// optional float max = 4 [default = 1];
inline bool FillerParameter::_internal_has_max() const {
bool value = (_has_bits_[0] & 0x00000040u) != 0;
return value;
}
inline bool FillerParameter::has_max() const {
return _internal_has_max();
}
inline void FillerParameter::clear_max() {
max_ = 1;
_has_bits_[0] &= ~0x00000040u;
}
inline float FillerParameter::_internal_max() const {
return max_;
}
inline float FillerParameter::max() const {
// @@protoc_insertion_point(field_get:caffe.FillerParameter.max)
return _internal_max();
}
inline void FillerParameter::_internal_set_max(float value) {
_has_bits_[0] |= 0x00000040u;
max_ = value;
}
inline void FillerParameter::set_max(float value) {
_internal_set_max(value);
// @@protoc_insertion_point(field_set:caffe.FillerParameter.max)
}
// optional float mean = 5 [default = 0];
inline bool FillerParameter::_internal_has_mean() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool FillerParameter::has_mean() const {
return _internal_has_mean();
}
inline void FillerParameter::clear_mean() {
mean_ = 0;
_has_bits_[0] &= ~0x00000008u;
}
inline float FillerParameter::_internal_mean() const {
return mean_;
}
inline float FillerParameter::mean() const {
// @@protoc_insertion_point(field_get:caffe.FillerParameter.mean)
return _internal_mean();
}
inline void FillerParameter::_internal_set_mean(float value) {
_has_bits_[0] |= 0x00000008u;
mean_ = value;
}
inline void FillerParameter::set_mean(float value) {
_internal_set_mean(value);
// @@protoc_insertion_point(field_set:caffe.FillerParameter.mean)
}
// optional float std = 6 [default = 1];
inline bool FillerParameter::_internal_has_std() const {
bool value = (_has_bits_[0] & 0x00000080u) != 0;
return value;
}
inline bool FillerParameter::has_std() const {
return _internal_has_std();
}
inline void FillerParameter::clear_std() {
std_ = 1;
_has_bits_[0] &= ~0x00000080u;
}
inline float FillerParameter::_internal_std() const {
return std_;
}
inline float FillerParameter::std() const {
// @@protoc_insertion_point(field_get:caffe.FillerParameter.std)
return _internal_std();
}
inline void FillerParameter::_internal_set_std(float value) {
_has_bits_[0] |= 0x00000080u;
std_ = value;
}
inline void FillerParameter::set_std(float value) {
_internal_set_std(value);
// @@protoc_insertion_point(field_set:caffe.FillerParameter.std)
}
// optional int32 sparse = 7 [default = -1];
inline bool FillerParameter::_internal_has_sparse() const {
bool value = (_has_bits_[0] & 0x00000020u) != 0;
return value;
}
inline bool FillerParameter::has_sparse() const {
return _internal_has_sparse();
}
inline void FillerParameter::clear_sparse() {
sparse_ = -1;
_has_bits_[0] &= ~0x00000020u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 FillerParameter::_internal_sparse() const {
return sparse_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 FillerParameter::sparse() const {
// @@protoc_insertion_point(field_get:caffe.FillerParameter.sparse)
return _internal_sparse();
}
inline void FillerParameter::_internal_set_sparse(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000020u;
sparse_ = value;
}
inline void FillerParameter::set_sparse(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_sparse(value);
// @@protoc_insertion_point(field_set:caffe.FillerParameter.sparse)
}
// optional .caffe.FillerParameter.VarianceNorm variance_norm = 8 [default = FAN_IN];
inline bool FillerParameter::_internal_has_variance_norm() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool FillerParameter::has_variance_norm() const {
return _internal_has_variance_norm();
}
inline void FillerParameter::clear_variance_norm() {
variance_norm_ = 0;
_has_bits_[0] &= ~0x00000010u;
}
inline ::caffe::FillerParameter_VarianceNorm FillerParameter::_internal_variance_norm() const {
return static_cast< ::caffe::FillerParameter_VarianceNorm >(variance_norm_);
}
inline ::caffe::FillerParameter_VarianceNorm FillerParameter::variance_norm() const {
// @@protoc_insertion_point(field_get:caffe.FillerParameter.variance_norm)
return _internal_variance_norm();
}
inline void FillerParameter::_internal_set_variance_norm(::caffe::FillerParameter_VarianceNorm value) {
assert(::caffe::FillerParameter_VarianceNorm_IsValid(value));
_has_bits_[0] |= 0x00000010u;
variance_norm_ = value;
}
inline void FillerParameter::set_variance_norm(::caffe::FillerParameter_VarianceNorm value) {
_internal_set_variance_norm(value);
// @@protoc_insertion_point(field_set:caffe.FillerParameter.variance_norm)
}
// -------------------------------------------------------------------
// NetParameter
// optional string name = 1;
inline bool NetParameter::_internal_has_name() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool NetParameter::has_name() const {
return _internal_has_name();
}
inline void NetParameter::clear_name() {
name_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000001u;
}
inline const std::string& NetParameter::name() const {
// @@protoc_insertion_point(field_get:caffe.NetParameter.name)
return _internal_name();
}
inline void NetParameter::set_name(const std::string& value) {
_internal_set_name(value);
// @@protoc_insertion_point(field_set:caffe.NetParameter.name)
}
inline std::string* NetParameter::mutable_name() {
// @@protoc_insertion_point(field_mutable:caffe.NetParameter.name)
return _internal_mutable_name();
}
inline const std::string& NetParameter::_internal_name() const {
return name_.Get();
}
inline void NetParameter::_internal_set_name(const std::string& value) {
_has_bits_[0] |= 0x00000001u;
name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void NetParameter::set_name(std::string&& value) {
_has_bits_[0] |= 0x00000001u;
name_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.NetParameter.name)
}
inline void NetParameter::set_name(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000001u;
name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.NetParameter.name)
}
inline void NetParameter::set_name(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000001u;
name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.NetParameter.name)
}
inline std::string* NetParameter::_internal_mutable_name() {
_has_bits_[0] |= 0x00000001u;
return name_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* NetParameter::release_name() {
// @@protoc_insertion_point(field_release:caffe.NetParameter.name)
if (!_internal_has_name()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000001u;
return name_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void NetParameter::set_allocated_name(std::string* name) {
if (name != nullptr) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
name_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), name,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.NetParameter.name)
}
// repeated string input = 3;
inline int NetParameter::_internal_input_size() const {
return input_.size();
}
inline int NetParameter::input_size() const {
return _internal_input_size();
}
inline void NetParameter::clear_input() {
input_.Clear();
}
inline std::string* NetParameter::add_input() {
// @@protoc_insertion_point(field_add_mutable:caffe.NetParameter.input)
return _internal_add_input();
}
inline const std::string& NetParameter::_internal_input(int index) const {
return input_.Get(index);
}
inline const std::string& NetParameter::input(int index) const {
// @@protoc_insertion_point(field_get:caffe.NetParameter.input)
return _internal_input(index);
}
inline std::string* NetParameter::mutable_input(int index) {
// @@protoc_insertion_point(field_mutable:caffe.NetParameter.input)
return input_.Mutable(index);
}
inline void NetParameter::set_input(int index, const std::string& value) {
// @@protoc_insertion_point(field_set:caffe.NetParameter.input)
input_.Mutable(index)->assign(value);
}
inline void NetParameter::set_input(int index, std::string&& value) {
// @@protoc_insertion_point(field_set:caffe.NetParameter.input)
input_.Mutable(index)->assign(std::move(value));
}
inline void NetParameter::set_input(int index, const char* value) {
GOOGLE_DCHECK(value != nullptr);
input_.Mutable(index)->assign(value);
// @@protoc_insertion_point(field_set_char:caffe.NetParameter.input)
}
inline 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:caffe.NetParameter.input)
}
inline std::string* NetParameter::_internal_add_input() {
return input_.Add();
}
inline void NetParameter::add_input(const std::string& value) {
input_.Add()->assign(value);
// @@protoc_insertion_point(field_add:caffe.NetParameter.input)
}
inline void NetParameter::add_input(std::string&& value) {
input_.Add(std::move(value));
// @@protoc_insertion_point(field_add:caffe.NetParameter.input)
}
inline void NetParameter::add_input(const char* value) {
GOOGLE_DCHECK(value != nullptr);
input_.Add()->assign(value);
// @@protoc_insertion_point(field_add_char:caffe.NetParameter.input)
}
inline 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:caffe.NetParameter.input)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>&
NetParameter::input() const {
// @@protoc_insertion_point(field_list:caffe.NetParameter.input)
return input_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>*
NetParameter::mutable_input() {
// @@protoc_insertion_point(field_mutable_list:caffe.NetParameter.input)
return &input_;
}
// repeated .caffe.BlobShape input_shape = 8;
inline int NetParameter::_internal_input_shape_size() const {
return input_shape_.size();
}
inline int NetParameter::input_shape_size() const {
return _internal_input_shape_size();
}
inline void NetParameter::clear_input_shape() {
input_shape_.Clear();
}
inline ::caffe::BlobShape* NetParameter::mutable_input_shape(int index) {
// @@protoc_insertion_point(field_mutable:caffe.NetParameter.input_shape)
return input_shape_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape >*
NetParameter::mutable_input_shape() {
// @@protoc_insertion_point(field_mutable_list:caffe.NetParameter.input_shape)
return &input_shape_;
}
inline const ::caffe::BlobShape& NetParameter::_internal_input_shape(int index) const {
return input_shape_.Get(index);
}
inline const ::caffe::BlobShape& NetParameter::input_shape(int index) const {
// @@protoc_insertion_point(field_get:caffe.NetParameter.input_shape)
return _internal_input_shape(index);
}
inline ::caffe::BlobShape* NetParameter::_internal_add_input_shape() {
return input_shape_.Add();
}
inline ::caffe::BlobShape* NetParameter::add_input_shape() {
// @@protoc_insertion_point(field_add:caffe.NetParameter.input_shape)
return _internal_add_input_shape();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape >&
NetParameter::input_shape() const {
// @@protoc_insertion_point(field_list:caffe.NetParameter.input_shape)
return input_shape_;
}
// optional bool initial_skip = 9 [default = false];
inline bool NetParameter::_internal_has_initial_skip() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool NetParameter::has_initial_skip() const {
return _internal_has_initial_skip();
}
inline void NetParameter::clear_initial_skip() {
initial_skip_ = false;
_has_bits_[0] &= ~0x00000004u;
}
inline bool NetParameter::_internal_initial_skip() const {
return initial_skip_;
}
inline bool NetParameter::initial_skip() const {
// @@protoc_insertion_point(field_get:caffe.NetParameter.initial_skip)
return _internal_initial_skip();
}
inline void NetParameter::_internal_set_initial_skip(bool value) {
_has_bits_[0] |= 0x00000004u;
initial_skip_ = value;
}
inline void NetParameter::set_initial_skip(bool value) {
_internal_set_initial_skip(value);
// @@protoc_insertion_point(field_set:caffe.NetParameter.initial_skip)
}
// repeated int32 input_dim = 4;
inline int NetParameter::_internal_input_dim_size() const {
return input_dim_.size();
}
inline int NetParameter::input_dim_size() const {
return _internal_input_dim_size();
}
inline void NetParameter::clear_input_dim() {
input_dim_.Clear();
}
inline ::PROTOBUF_NAMESPACE_ID::int32 NetParameter::_internal_input_dim(int index) const {
return input_dim_.Get(index);
}
inline ::PROTOBUF_NAMESPACE_ID::int32 NetParameter::input_dim(int index) const {
// @@protoc_insertion_point(field_get:caffe.NetParameter.input_dim)
return _internal_input_dim(index);
}
inline void NetParameter::set_input_dim(int index, ::PROTOBUF_NAMESPACE_ID::int32 value) {
input_dim_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.NetParameter.input_dim)
}
inline void NetParameter::_internal_add_input_dim(::PROTOBUF_NAMESPACE_ID::int32 value) {
input_dim_.Add(value);
}
inline void NetParameter::add_input_dim(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_add_input_dim(value);
// @@protoc_insertion_point(field_add:caffe.NetParameter.input_dim)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >&
NetParameter::_internal_input_dim() const {
return input_dim_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >&
NetParameter::input_dim() const {
// @@protoc_insertion_point(field_list:caffe.NetParameter.input_dim)
return _internal_input_dim();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >*
NetParameter::_internal_mutable_input_dim() {
return &input_dim_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >*
NetParameter::mutable_input_dim() {
// @@protoc_insertion_point(field_mutable_list:caffe.NetParameter.input_dim)
return _internal_mutable_input_dim();
}
// optional bool force_backward = 5 [default = false];
inline bool NetParameter::_internal_has_force_backward() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool NetParameter::has_force_backward() const {
return _internal_has_force_backward();
}
inline void NetParameter::clear_force_backward() {
force_backward_ = false;
_has_bits_[0] &= ~0x00000008u;
}
inline bool NetParameter::_internal_force_backward() const {
return force_backward_;
}
inline bool NetParameter::force_backward() const {
// @@protoc_insertion_point(field_get:caffe.NetParameter.force_backward)
return _internal_force_backward();
}
inline void NetParameter::_internal_set_force_backward(bool value) {
_has_bits_[0] |= 0x00000008u;
force_backward_ = value;
}
inline void NetParameter::set_force_backward(bool value) {
_internal_set_force_backward(value);
// @@protoc_insertion_point(field_set:caffe.NetParameter.force_backward)
}
// optional .caffe.NetState state = 6;
inline bool NetParameter::_internal_has_state() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
PROTOBUF_ASSUME(!value || state_ != nullptr);
return value;
}
inline bool NetParameter::has_state() const {
return _internal_has_state();
}
inline void NetParameter::clear_state() {
if (state_ != nullptr) state_->Clear();
_has_bits_[0] &= ~0x00000002u;
}
inline const ::caffe::NetState& NetParameter::_internal_state() const {
const ::caffe::NetState* p = state_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::NetState*>(
&::caffe::_NetState_default_instance_);
}
inline const ::caffe::NetState& NetParameter::state() const {
// @@protoc_insertion_point(field_get:caffe.NetParameter.state)
return _internal_state();
}
inline void NetParameter::unsafe_arena_set_allocated_state(
::caffe::NetState* state) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(state_);
}
state_ = state;
if (state) {
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.NetParameter.state)
}
inline ::caffe::NetState* NetParameter::release_state() {
_has_bits_[0] &= ~0x00000002u;
::caffe::NetState* temp = state_;
state_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::NetState* NetParameter::unsafe_arena_release_state() {
// @@protoc_insertion_point(field_release:caffe.NetParameter.state)
_has_bits_[0] &= ~0x00000002u;
::caffe::NetState* temp = state_;
state_ = nullptr;
return temp;
}
inline ::caffe::NetState* NetParameter::_internal_mutable_state() {
_has_bits_[0] |= 0x00000002u;
if (state_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::NetState>(GetArena());
state_ = p;
}
return state_;
}
inline ::caffe::NetState* NetParameter::mutable_state() {
// @@protoc_insertion_point(field_mutable:caffe.NetParameter.state)
return _internal_mutable_state();
}
inline void NetParameter::set_allocated_state(::caffe::NetState* state) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete state_;
}
if (state) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(state);
if (message_arena != submessage_arena) {
state = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, state, submessage_arena);
}
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
state_ = state;
// @@protoc_insertion_point(field_set_allocated:caffe.NetParameter.state)
}
// optional bool debug_info = 7 [default = false];
inline bool NetParameter::_internal_has_debug_info() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool NetParameter::has_debug_info() const {
return _internal_has_debug_info();
}
inline void NetParameter::clear_debug_info() {
debug_info_ = false;
_has_bits_[0] &= ~0x00000010u;
}
inline bool NetParameter::_internal_debug_info() const {
return debug_info_;
}
inline bool NetParameter::debug_info() const {
// @@protoc_insertion_point(field_get:caffe.NetParameter.debug_info)
return _internal_debug_info();
}
inline void NetParameter::_internal_set_debug_info(bool value) {
_has_bits_[0] |= 0x00000010u;
debug_info_ = value;
}
inline void NetParameter::set_debug_info(bool value) {
_internal_set_debug_info(value);
// @@protoc_insertion_point(field_set:caffe.NetParameter.debug_info)
}
// repeated .caffe.LayerParameter layer = 100;
inline int NetParameter::_internal_layer_size() const {
return layer_.size();
}
inline int NetParameter::layer_size() const {
return _internal_layer_size();
}
inline void NetParameter::clear_layer() {
layer_.Clear();
}
inline ::caffe::LayerParameter* NetParameter::mutable_layer(int index) {
// @@protoc_insertion_point(field_mutable:caffe.NetParameter.layer)
return layer_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::LayerParameter >*
NetParameter::mutable_layer() {
// @@protoc_insertion_point(field_mutable_list:caffe.NetParameter.layer)
return &layer_;
}
inline const ::caffe::LayerParameter& NetParameter::_internal_layer(int index) const {
return layer_.Get(index);
}
inline const ::caffe::LayerParameter& NetParameter::layer(int index) const {
// @@protoc_insertion_point(field_get:caffe.NetParameter.layer)
return _internal_layer(index);
}
inline ::caffe::LayerParameter* NetParameter::_internal_add_layer() {
return layer_.Add();
}
inline ::caffe::LayerParameter* NetParameter::add_layer() {
// @@protoc_insertion_point(field_add:caffe.NetParameter.layer)
return _internal_add_layer();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::LayerParameter >&
NetParameter::layer() const {
// @@protoc_insertion_point(field_list:caffe.NetParameter.layer)
return layer_;
}
// repeated .caffe.V1LayerParameter layers = 2;
inline int NetParameter::_internal_layers_size() const {
return layers_.size();
}
inline int NetParameter::layers_size() const {
return _internal_layers_size();
}
inline void NetParameter::clear_layers() {
layers_.Clear();
}
inline ::caffe::V1LayerParameter* NetParameter::mutable_layers(int index) {
// @@protoc_insertion_point(field_mutable:caffe.NetParameter.layers)
return layers_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::V1LayerParameter >*
NetParameter::mutable_layers() {
// @@protoc_insertion_point(field_mutable_list:caffe.NetParameter.layers)
return &layers_;
}
inline const ::caffe::V1LayerParameter& NetParameter::_internal_layers(int index) const {
return layers_.Get(index);
}
inline const ::caffe::V1LayerParameter& NetParameter::layers(int index) const {
// @@protoc_insertion_point(field_get:caffe.NetParameter.layers)
return _internal_layers(index);
}
inline ::caffe::V1LayerParameter* NetParameter::_internal_add_layers() {
return layers_.Add();
}
inline ::caffe::V1LayerParameter* NetParameter::add_layers() {
// @@protoc_insertion_point(field_add:caffe.NetParameter.layers)
return _internal_add_layers();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::V1LayerParameter >&
NetParameter::layers() const {
// @@protoc_insertion_point(field_list:caffe.NetParameter.layers)
return layers_;
}
// -------------------------------------------------------------------
// SolverParameter
// optional string net = 24;
inline bool SolverParameter::_internal_has_net() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool SolverParameter::has_net() const {
return _internal_has_net();
}
inline void SolverParameter::clear_net() {
net_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000008u;
}
inline const std::string& SolverParameter::net() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.net)
return _internal_net();
}
inline void SolverParameter::set_net(const std::string& value) {
_internal_set_net(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.net)
}
inline std::string* SolverParameter::mutable_net() {
// @@protoc_insertion_point(field_mutable:caffe.SolverParameter.net)
return _internal_mutable_net();
}
inline const std::string& SolverParameter::_internal_net() const {
return net_.Get();
}
inline void SolverParameter::_internal_set_net(const std::string& value) {
_has_bits_[0] |= 0x00000008u;
net_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void SolverParameter::set_net(std::string&& value) {
_has_bits_[0] |= 0x00000008u;
net_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.SolverParameter.net)
}
inline void SolverParameter::set_net(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000008u;
net_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.SolverParameter.net)
}
inline void SolverParameter::set_net(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000008u;
net_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.SolverParameter.net)
}
inline std::string* SolverParameter::_internal_mutable_net() {
_has_bits_[0] |= 0x00000008u;
return net_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* SolverParameter::release_net() {
// @@protoc_insertion_point(field_release:caffe.SolverParameter.net)
if (!_internal_has_net()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000008u;
return net_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void SolverParameter::set_allocated_net(std::string* net) {
if (net != nullptr) {
_has_bits_[0] |= 0x00000008u;
} else {
_has_bits_[0] &= ~0x00000008u;
}
net_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), net,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.SolverParameter.net)
}
// optional .caffe.NetParameter net_param = 25;
inline bool SolverParameter::_internal_has_net_param() const {
bool value = (_has_bits_[0] & 0x00000200u) != 0;
PROTOBUF_ASSUME(!value || net_param_ != nullptr);
return value;
}
inline bool SolverParameter::has_net_param() const {
return _internal_has_net_param();
}
inline void SolverParameter::clear_net_param() {
if (net_param_ != nullptr) net_param_->Clear();
_has_bits_[0] &= ~0x00000200u;
}
inline const ::caffe::NetParameter& SolverParameter::_internal_net_param() const {
const ::caffe::NetParameter* p = net_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::NetParameter*>(
&::caffe::_NetParameter_default_instance_);
}
inline const ::caffe::NetParameter& SolverParameter::net_param() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.net_param)
return _internal_net_param();
}
inline void SolverParameter::unsafe_arena_set_allocated_net_param(
::caffe::NetParameter* net_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(net_param_);
}
net_param_ = net_param;
if (net_param) {
_has_bits_[0] |= 0x00000200u;
} else {
_has_bits_[0] &= ~0x00000200u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.SolverParameter.net_param)
}
inline ::caffe::NetParameter* SolverParameter::release_net_param() {
_has_bits_[0] &= ~0x00000200u;
::caffe::NetParameter* temp = net_param_;
net_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::NetParameter* SolverParameter::unsafe_arena_release_net_param() {
// @@protoc_insertion_point(field_release:caffe.SolverParameter.net_param)
_has_bits_[0] &= ~0x00000200u;
::caffe::NetParameter* temp = net_param_;
net_param_ = nullptr;
return temp;
}
inline ::caffe::NetParameter* SolverParameter::_internal_mutable_net_param() {
_has_bits_[0] |= 0x00000200u;
if (net_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::NetParameter>(GetArena());
net_param_ = p;
}
return net_param_;
}
inline ::caffe::NetParameter* SolverParameter::mutable_net_param() {
// @@protoc_insertion_point(field_mutable:caffe.SolverParameter.net_param)
return _internal_mutable_net_param();
}
inline void SolverParameter::set_allocated_net_param(::caffe::NetParameter* net_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete net_param_;
}
if (net_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(net_param);
if (message_arena != submessage_arena) {
net_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, net_param, submessage_arena);
}
_has_bits_[0] |= 0x00000200u;
} else {
_has_bits_[0] &= ~0x00000200u;
}
net_param_ = net_param;
// @@protoc_insertion_point(field_set_allocated:caffe.SolverParameter.net_param)
}
// optional string train_net = 1;
inline bool SolverParameter::_internal_has_train_net() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool SolverParameter::has_train_net() const {
return _internal_has_train_net();
}
inline void SolverParameter::clear_train_net() {
train_net_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000001u;
}
inline const std::string& SolverParameter::train_net() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.train_net)
return _internal_train_net();
}
inline void SolverParameter::set_train_net(const std::string& value) {
_internal_set_train_net(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.train_net)
}
inline std::string* SolverParameter::mutable_train_net() {
// @@protoc_insertion_point(field_mutable:caffe.SolverParameter.train_net)
return _internal_mutable_train_net();
}
inline const std::string& SolverParameter::_internal_train_net() const {
return train_net_.Get();
}
inline void SolverParameter::_internal_set_train_net(const std::string& value) {
_has_bits_[0] |= 0x00000001u;
train_net_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void SolverParameter::set_train_net(std::string&& value) {
_has_bits_[0] |= 0x00000001u;
train_net_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.SolverParameter.train_net)
}
inline void SolverParameter::set_train_net(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000001u;
train_net_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.SolverParameter.train_net)
}
inline void SolverParameter::set_train_net(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000001u;
train_net_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.SolverParameter.train_net)
}
inline std::string* SolverParameter::_internal_mutable_train_net() {
_has_bits_[0] |= 0x00000001u;
return train_net_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* SolverParameter::release_train_net() {
// @@protoc_insertion_point(field_release:caffe.SolverParameter.train_net)
if (!_internal_has_train_net()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000001u;
return train_net_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void SolverParameter::set_allocated_train_net(std::string* train_net) {
if (train_net != nullptr) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
train_net_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), train_net,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.SolverParameter.train_net)
}
// repeated string test_net = 2;
inline int SolverParameter::_internal_test_net_size() const {
return test_net_.size();
}
inline int SolverParameter::test_net_size() const {
return _internal_test_net_size();
}
inline void SolverParameter::clear_test_net() {
test_net_.Clear();
}
inline std::string* SolverParameter::add_test_net() {
// @@protoc_insertion_point(field_add_mutable:caffe.SolverParameter.test_net)
return _internal_add_test_net();
}
inline const std::string& SolverParameter::_internal_test_net(int index) const {
return test_net_.Get(index);
}
inline const std::string& SolverParameter::test_net(int index) const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.test_net)
return _internal_test_net(index);
}
inline std::string* SolverParameter::mutable_test_net(int index) {
// @@protoc_insertion_point(field_mutable:caffe.SolverParameter.test_net)
return test_net_.Mutable(index);
}
inline void SolverParameter::set_test_net(int index, const std::string& value) {
// @@protoc_insertion_point(field_set:caffe.SolverParameter.test_net)
test_net_.Mutable(index)->assign(value);
}
inline void SolverParameter::set_test_net(int index, std::string&& value) {
// @@protoc_insertion_point(field_set:caffe.SolverParameter.test_net)
test_net_.Mutable(index)->assign(std::move(value));
}
inline void SolverParameter::set_test_net(int index, const char* value) {
GOOGLE_DCHECK(value != nullptr);
test_net_.Mutable(index)->assign(value);
// @@protoc_insertion_point(field_set_char:caffe.SolverParameter.test_net)
}
inline 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:caffe.SolverParameter.test_net)
}
inline std::string* SolverParameter::_internal_add_test_net() {
return test_net_.Add();
}
inline void SolverParameter::add_test_net(const std::string& value) {
test_net_.Add()->assign(value);
// @@protoc_insertion_point(field_add:caffe.SolverParameter.test_net)
}
inline void SolverParameter::add_test_net(std::string&& value) {
test_net_.Add(std::move(value));
// @@protoc_insertion_point(field_add:caffe.SolverParameter.test_net)
}
inline void SolverParameter::add_test_net(const char* value) {
GOOGLE_DCHECK(value != nullptr);
test_net_.Add()->assign(value);
// @@protoc_insertion_point(field_add_char:caffe.SolverParameter.test_net)
}
inline 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:caffe.SolverParameter.test_net)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>&
SolverParameter::test_net() const {
// @@protoc_insertion_point(field_list:caffe.SolverParameter.test_net)
return test_net_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>*
SolverParameter::mutable_test_net() {
// @@protoc_insertion_point(field_mutable_list:caffe.SolverParameter.test_net)
return &test_net_;
}
// optional .caffe.NetParameter train_net_param = 21;
inline bool SolverParameter::_internal_has_train_net_param() const {
bool value = (_has_bits_[0] & 0x00000100u) != 0;
PROTOBUF_ASSUME(!value || train_net_param_ != nullptr);
return value;
}
inline bool SolverParameter::has_train_net_param() const {
return _internal_has_train_net_param();
}
inline void SolverParameter::clear_train_net_param() {
if (train_net_param_ != nullptr) train_net_param_->Clear();
_has_bits_[0] &= ~0x00000100u;
}
inline const ::caffe::NetParameter& SolverParameter::_internal_train_net_param() const {
const ::caffe::NetParameter* p = train_net_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::NetParameter*>(
&::caffe::_NetParameter_default_instance_);
}
inline const ::caffe::NetParameter& SolverParameter::train_net_param() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.train_net_param)
return _internal_train_net_param();
}
inline void SolverParameter::unsafe_arena_set_allocated_train_net_param(
::caffe::NetParameter* train_net_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(train_net_param_);
}
train_net_param_ = train_net_param;
if (train_net_param) {
_has_bits_[0] |= 0x00000100u;
} else {
_has_bits_[0] &= ~0x00000100u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.SolverParameter.train_net_param)
}
inline ::caffe::NetParameter* SolverParameter::release_train_net_param() {
_has_bits_[0] &= ~0x00000100u;
::caffe::NetParameter* temp = train_net_param_;
train_net_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::NetParameter* SolverParameter::unsafe_arena_release_train_net_param() {
// @@protoc_insertion_point(field_release:caffe.SolverParameter.train_net_param)
_has_bits_[0] &= ~0x00000100u;
::caffe::NetParameter* temp = train_net_param_;
train_net_param_ = nullptr;
return temp;
}
inline ::caffe::NetParameter* SolverParameter::_internal_mutable_train_net_param() {
_has_bits_[0] |= 0x00000100u;
if (train_net_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::NetParameter>(GetArena());
train_net_param_ = p;
}
return train_net_param_;
}
inline ::caffe::NetParameter* SolverParameter::mutable_train_net_param() {
// @@protoc_insertion_point(field_mutable:caffe.SolverParameter.train_net_param)
return _internal_mutable_train_net_param();
}
inline void SolverParameter::set_allocated_train_net_param(::caffe::NetParameter* train_net_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete train_net_param_;
}
if (train_net_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(train_net_param);
if (message_arena != submessage_arena) {
train_net_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, train_net_param, submessage_arena);
}
_has_bits_[0] |= 0x00000100u;
} else {
_has_bits_[0] &= ~0x00000100u;
}
train_net_param_ = train_net_param;
// @@protoc_insertion_point(field_set_allocated:caffe.SolverParameter.train_net_param)
}
// repeated .caffe.NetParameter test_net_param = 22;
inline int SolverParameter::_internal_test_net_param_size() const {
return test_net_param_.size();
}
inline int SolverParameter::test_net_param_size() const {
return _internal_test_net_param_size();
}
inline void SolverParameter::clear_test_net_param() {
test_net_param_.Clear();
}
inline ::caffe::NetParameter* SolverParameter::mutable_test_net_param(int index) {
// @@protoc_insertion_point(field_mutable:caffe.SolverParameter.test_net_param)
return test_net_param_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetParameter >*
SolverParameter::mutable_test_net_param() {
// @@protoc_insertion_point(field_mutable_list:caffe.SolverParameter.test_net_param)
return &test_net_param_;
}
inline const ::caffe::NetParameter& SolverParameter::_internal_test_net_param(int index) const {
return test_net_param_.Get(index);
}
inline const ::caffe::NetParameter& SolverParameter::test_net_param(int index) const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.test_net_param)
return _internal_test_net_param(index);
}
inline ::caffe::NetParameter* SolverParameter::_internal_add_test_net_param() {
return test_net_param_.Add();
}
inline ::caffe::NetParameter* SolverParameter::add_test_net_param() {
// @@protoc_insertion_point(field_add:caffe.SolverParameter.test_net_param)
return _internal_add_test_net_param();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetParameter >&
SolverParameter::test_net_param() const {
// @@protoc_insertion_point(field_list:caffe.SolverParameter.test_net_param)
return test_net_param_;
}
// optional .caffe.NetState train_state = 26;
inline bool SolverParameter::_internal_has_train_state() const {
bool value = (_has_bits_[0] & 0x00000400u) != 0;
PROTOBUF_ASSUME(!value || train_state_ != nullptr);
return value;
}
inline bool SolverParameter::has_train_state() const {
return _internal_has_train_state();
}
inline void SolverParameter::clear_train_state() {
if (train_state_ != nullptr) train_state_->Clear();
_has_bits_[0] &= ~0x00000400u;
}
inline const ::caffe::NetState& SolverParameter::_internal_train_state() const {
const ::caffe::NetState* p = train_state_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::NetState*>(
&::caffe::_NetState_default_instance_);
}
inline const ::caffe::NetState& SolverParameter::train_state() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.train_state)
return _internal_train_state();
}
inline void SolverParameter::unsafe_arena_set_allocated_train_state(
::caffe::NetState* train_state) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(train_state_);
}
train_state_ = train_state;
if (train_state) {
_has_bits_[0] |= 0x00000400u;
} else {
_has_bits_[0] &= ~0x00000400u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.SolverParameter.train_state)
}
inline ::caffe::NetState* SolverParameter::release_train_state() {
_has_bits_[0] &= ~0x00000400u;
::caffe::NetState* temp = train_state_;
train_state_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::NetState* SolverParameter::unsafe_arena_release_train_state() {
// @@protoc_insertion_point(field_release:caffe.SolverParameter.train_state)
_has_bits_[0] &= ~0x00000400u;
::caffe::NetState* temp = train_state_;
train_state_ = nullptr;
return temp;
}
inline ::caffe::NetState* SolverParameter::_internal_mutable_train_state() {
_has_bits_[0] |= 0x00000400u;
if (train_state_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::NetState>(GetArena());
train_state_ = p;
}
return train_state_;
}
inline ::caffe::NetState* SolverParameter::mutable_train_state() {
// @@protoc_insertion_point(field_mutable:caffe.SolverParameter.train_state)
return _internal_mutable_train_state();
}
inline void SolverParameter::set_allocated_train_state(::caffe::NetState* train_state) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete train_state_;
}
if (train_state) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(train_state);
if (message_arena != submessage_arena) {
train_state = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, train_state, submessage_arena);
}
_has_bits_[0] |= 0x00000400u;
} else {
_has_bits_[0] &= ~0x00000400u;
}
train_state_ = train_state;
// @@protoc_insertion_point(field_set_allocated:caffe.SolverParameter.train_state)
}
// repeated .caffe.NetState test_state = 27;
inline int SolverParameter::_internal_test_state_size() const {
return test_state_.size();
}
inline int SolverParameter::test_state_size() const {
return _internal_test_state_size();
}
inline void SolverParameter::clear_test_state() {
test_state_.Clear();
}
inline ::caffe::NetState* SolverParameter::mutable_test_state(int index) {
// @@protoc_insertion_point(field_mutable:caffe.SolverParameter.test_state)
return test_state_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetState >*
SolverParameter::mutable_test_state() {
// @@protoc_insertion_point(field_mutable_list:caffe.SolverParameter.test_state)
return &test_state_;
}
inline const ::caffe::NetState& SolverParameter::_internal_test_state(int index) const {
return test_state_.Get(index);
}
inline const ::caffe::NetState& SolverParameter::test_state(int index) const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.test_state)
return _internal_test_state(index);
}
inline ::caffe::NetState* SolverParameter::_internal_add_test_state() {
return test_state_.Add();
}
inline ::caffe::NetState* SolverParameter::add_test_state() {
// @@protoc_insertion_point(field_add:caffe.SolverParameter.test_state)
return _internal_add_test_state();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetState >&
SolverParameter::test_state() const {
// @@protoc_insertion_point(field_list:caffe.SolverParameter.test_state)
return test_state_;
}
// optional string eval_type = 41 [default = "classification"];
inline bool SolverParameter::_internal_has_eval_type() const {
bool value = (_has_bits_[0] & 0x00000040u) != 0;
return value;
}
inline bool SolverParameter::has_eval_type() const {
return _internal_has_eval_type();
}
inline void SolverParameter::clear_eval_type() {
eval_type_.ClearToDefault(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_eval_type_.get(), GetArena());
_has_bits_[0] &= ~0x00000040u;
}
inline const std::string& SolverParameter::eval_type() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.eval_type)
return _internal_eval_type();
}
inline void SolverParameter::set_eval_type(const std::string& value) {
_internal_set_eval_type(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.eval_type)
}
inline std::string* SolverParameter::mutable_eval_type() {
// @@protoc_insertion_point(field_mutable:caffe.SolverParameter.eval_type)
return _internal_mutable_eval_type();
}
inline const std::string& SolverParameter::_internal_eval_type() const {
return eval_type_.Get();
}
inline void SolverParameter::_internal_set_eval_type(const std::string& value) {
_has_bits_[0] |= 0x00000040u;
eval_type_.Set(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_eval_type_.get(), value, GetArena());
}
inline void SolverParameter::set_eval_type(std::string&& value) {
_has_bits_[0] |= 0x00000040u;
eval_type_.Set(
&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_eval_type_.get(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.SolverParameter.eval_type)
}
inline void SolverParameter::set_eval_type(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000040u;
eval_type_.Set(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_eval_type_.get(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.SolverParameter.eval_type)
}
inline void SolverParameter::set_eval_type(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000040u;
eval_type_.Set(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_eval_type_.get(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.SolverParameter.eval_type)
}
inline std::string* SolverParameter::_internal_mutable_eval_type() {
_has_bits_[0] |= 0x00000040u;
return eval_type_.Mutable(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_eval_type_.get(), GetArena());
}
inline std::string* SolverParameter::release_eval_type() {
// @@protoc_insertion_point(field_release:caffe.SolverParameter.eval_type)
if (!_internal_has_eval_type()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000040u;
return eval_type_.ReleaseNonDefault(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_eval_type_.get(), GetArena());
}
inline void SolverParameter::set_allocated_eval_type(std::string* eval_type) {
if (eval_type != nullptr) {
_has_bits_[0] |= 0x00000040u;
} else {
_has_bits_[0] &= ~0x00000040u;
}
eval_type_.SetAllocated(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_eval_type_.get(), eval_type,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.SolverParameter.eval_type)
}
// optional string ap_version = 42 [default = "Integral"];
inline bool SolverParameter::_internal_has_ap_version() const {
bool value = (_has_bits_[0] & 0x00000080u) != 0;
return value;
}
inline bool SolverParameter::has_ap_version() const {
return _internal_has_ap_version();
}
inline void SolverParameter::clear_ap_version() {
ap_version_.ClearToDefault(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_ap_version_.get(), GetArena());
_has_bits_[0] &= ~0x00000080u;
}
inline const std::string& SolverParameter::ap_version() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.ap_version)
return _internal_ap_version();
}
inline void SolverParameter::set_ap_version(const std::string& value) {
_internal_set_ap_version(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.ap_version)
}
inline std::string* SolverParameter::mutable_ap_version() {
// @@protoc_insertion_point(field_mutable:caffe.SolverParameter.ap_version)
return _internal_mutable_ap_version();
}
inline const std::string& SolverParameter::_internal_ap_version() const {
return ap_version_.Get();
}
inline void SolverParameter::_internal_set_ap_version(const std::string& value) {
_has_bits_[0] |= 0x00000080u;
ap_version_.Set(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_ap_version_.get(), value, GetArena());
}
inline void SolverParameter::set_ap_version(std::string&& value) {
_has_bits_[0] |= 0x00000080u;
ap_version_.Set(
&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_ap_version_.get(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.SolverParameter.ap_version)
}
inline void SolverParameter::set_ap_version(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000080u;
ap_version_.Set(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_ap_version_.get(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.SolverParameter.ap_version)
}
inline void SolverParameter::set_ap_version(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000080u;
ap_version_.Set(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_ap_version_.get(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.SolverParameter.ap_version)
}
inline std::string* SolverParameter::_internal_mutable_ap_version() {
_has_bits_[0] |= 0x00000080u;
return ap_version_.Mutable(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_ap_version_.get(), GetArena());
}
inline std::string* SolverParameter::release_ap_version() {
// @@protoc_insertion_point(field_release:caffe.SolverParameter.ap_version)
if (!_internal_has_ap_version()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000080u;
return ap_version_.ReleaseNonDefault(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_ap_version_.get(), GetArena());
}
inline void SolverParameter::set_allocated_ap_version(std::string* ap_version) {
if (ap_version != nullptr) {
_has_bits_[0] |= 0x00000080u;
} else {
_has_bits_[0] &= ~0x00000080u;
}
ap_version_.SetAllocated(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_ap_version_.get(), ap_version,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.SolverParameter.ap_version)
}
// repeated int32 test_iter = 3;
inline int SolverParameter::_internal_test_iter_size() const {
return test_iter_.size();
}
inline int SolverParameter::test_iter_size() const {
return _internal_test_iter_size();
}
inline void SolverParameter::clear_test_iter() {
test_iter_.Clear();
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverParameter::_internal_test_iter(int index) const {
return test_iter_.Get(index);
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverParameter::test_iter(int index) const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.test_iter)
return _internal_test_iter(index);
}
inline void SolverParameter::set_test_iter(int index, ::PROTOBUF_NAMESPACE_ID::int32 value) {
test_iter_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.test_iter)
}
inline void SolverParameter::_internal_add_test_iter(::PROTOBUF_NAMESPACE_ID::int32 value) {
test_iter_.Add(value);
}
inline void SolverParameter::add_test_iter(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_add_test_iter(value);
// @@protoc_insertion_point(field_add:caffe.SolverParameter.test_iter)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >&
SolverParameter::_internal_test_iter() const {
return test_iter_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >&
SolverParameter::test_iter() const {
// @@protoc_insertion_point(field_list:caffe.SolverParameter.test_iter)
return _internal_test_iter();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >*
SolverParameter::_internal_mutable_test_iter() {
return &test_iter_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >*
SolverParameter::mutable_test_iter() {
// @@protoc_insertion_point(field_mutable_list:caffe.SolverParameter.test_iter)
return _internal_mutable_test_iter();
}
// optional int32 test_interval = 4 [default = 0];
inline bool SolverParameter::_internal_has_test_interval() const {
bool value = (_has_bits_[0] & 0x00000800u) != 0;
return value;
}
inline bool SolverParameter::has_test_interval() const {
return _internal_has_test_interval();
}
inline void SolverParameter::clear_test_interval() {
test_interval_ = 0;
_has_bits_[0] &= ~0x00000800u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverParameter::_internal_test_interval() const {
return test_interval_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverParameter::test_interval() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.test_interval)
return _internal_test_interval();
}
inline void SolverParameter::_internal_set_test_interval(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000800u;
test_interval_ = value;
}
inline void SolverParameter::set_test_interval(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_test_interval(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.test_interval)
}
// optional bool test_compute_loss = 19 [default = false];
inline bool SolverParameter::_internal_has_test_compute_loss() const {
bool value = (_has_bits_[0] & 0x00400000u) != 0;
return value;
}
inline bool SolverParameter::has_test_compute_loss() const {
return _internal_has_test_compute_loss();
}
inline void SolverParameter::clear_test_compute_loss() {
test_compute_loss_ = false;
_has_bits_[0] &= ~0x00400000u;
}
inline bool SolverParameter::_internal_test_compute_loss() const {
return test_compute_loss_;
}
inline bool SolverParameter::test_compute_loss() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.test_compute_loss)
return _internal_test_compute_loss();
}
inline void SolverParameter::_internal_set_test_compute_loss(bool value) {
_has_bits_[0] |= 0x00400000u;
test_compute_loss_ = value;
}
inline void SolverParameter::set_test_compute_loss(bool value) {
_internal_set_test_compute_loss(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.test_compute_loss)
}
// optional bool test_initialization = 32 [default = true];
inline bool SolverParameter::_internal_has_test_initialization() const {
bool value = (_has_bits_[0] & 0x20000000u) != 0;
return value;
}
inline bool SolverParameter::has_test_initialization() const {
return _internal_has_test_initialization();
}
inline void SolverParameter::clear_test_initialization() {
test_initialization_ = true;
_has_bits_[0] &= ~0x20000000u;
}
inline bool SolverParameter::_internal_test_initialization() const {
return test_initialization_;
}
inline bool SolverParameter::test_initialization() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.test_initialization)
return _internal_test_initialization();
}
inline void SolverParameter::_internal_set_test_initialization(bool value) {
_has_bits_[0] |= 0x20000000u;
test_initialization_ = value;
}
inline void SolverParameter::set_test_initialization(bool value) {
_internal_set_test_initialization(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.test_initialization)
}
// optional float base_lr = 5;
inline bool SolverParameter::_internal_has_base_lr() const {
bool value = (_has_bits_[0] & 0x00001000u) != 0;
return value;
}
inline bool SolverParameter::has_base_lr() const {
return _internal_has_base_lr();
}
inline void SolverParameter::clear_base_lr() {
base_lr_ = 0;
_has_bits_[0] &= ~0x00001000u;
}
inline float SolverParameter::_internal_base_lr() const {
return base_lr_;
}
inline float SolverParameter::base_lr() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.base_lr)
return _internal_base_lr();
}
inline void SolverParameter::_internal_set_base_lr(float value) {
_has_bits_[0] |= 0x00001000u;
base_lr_ = value;
}
inline void SolverParameter::set_base_lr(float value) {
_internal_set_base_lr(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.base_lr)
}
// optional int32 display = 6;
inline bool SolverParameter::_internal_has_display() const {
bool value = (_has_bits_[0] & 0x00002000u) != 0;
return value;
}
inline bool SolverParameter::has_display() const {
return _internal_has_display();
}
inline void SolverParameter::clear_display() {
display_ = 0;
_has_bits_[0] &= ~0x00002000u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverParameter::_internal_display() const {
return display_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverParameter::display() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.display)
return _internal_display();
}
inline void SolverParameter::_internal_set_display(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00002000u;
display_ = value;
}
inline void SolverParameter::set_display(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_display(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.display)
}
// optional int32 average_loss = 33 [default = 1];
inline bool SolverParameter::_internal_has_average_loss() const {
bool value = (_has_bits_[1] & 0x00000001u) != 0;
return value;
}
inline bool SolverParameter::has_average_loss() const {
return _internal_has_average_loss();
}
inline void SolverParameter::clear_average_loss() {
average_loss_ = 1;
_has_bits_[1] &= ~0x00000001u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverParameter::_internal_average_loss() const {
return average_loss_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverParameter::average_loss() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.average_loss)
return _internal_average_loss();
}
inline void SolverParameter::_internal_set_average_loss(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[1] |= 0x00000001u;
average_loss_ = value;
}
inline void SolverParameter::set_average_loss(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_average_loss(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.average_loss)
}
// optional int32 max_iter = 7;
inline bool SolverParameter::_internal_has_max_iter() const {
bool value = (_has_bits_[0] & 0x00004000u) != 0;
return value;
}
inline bool SolverParameter::has_max_iter() const {
return _internal_has_max_iter();
}
inline void SolverParameter::clear_max_iter() {
max_iter_ = 0;
_has_bits_[0] &= ~0x00004000u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverParameter::_internal_max_iter() const {
return max_iter_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverParameter::max_iter() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.max_iter)
return _internal_max_iter();
}
inline void SolverParameter::_internal_set_max_iter(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00004000u;
max_iter_ = value;
}
inline void SolverParameter::set_max_iter(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_max_iter(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.max_iter)
}
// optional int32 iter_size = 36 [default = 1];
inline bool SolverParameter::_internal_has_iter_size() const {
bool value = (_has_bits_[1] & 0x00000004u) != 0;
return value;
}
inline bool SolverParameter::has_iter_size() const {
return _internal_has_iter_size();
}
inline void SolverParameter::clear_iter_size() {
iter_size_ = 1;
_has_bits_[1] &= ~0x00000004u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverParameter::_internal_iter_size() const {
return iter_size_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverParameter::iter_size() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.iter_size)
return _internal_iter_size();
}
inline void SolverParameter::_internal_set_iter_size(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[1] |= 0x00000004u;
iter_size_ = value;
}
inline void SolverParameter::set_iter_size(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_iter_size(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.iter_size)
}
// optional string lr_policy = 8;
inline bool SolverParameter::_internal_has_lr_policy() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool SolverParameter::has_lr_policy() const {
return _internal_has_lr_policy();
}
inline void SolverParameter::clear_lr_policy() {
lr_policy_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000002u;
}
inline const std::string& SolverParameter::lr_policy() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.lr_policy)
return _internal_lr_policy();
}
inline void SolverParameter::set_lr_policy(const std::string& value) {
_internal_set_lr_policy(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.lr_policy)
}
inline std::string* SolverParameter::mutable_lr_policy() {
// @@protoc_insertion_point(field_mutable:caffe.SolverParameter.lr_policy)
return _internal_mutable_lr_policy();
}
inline const std::string& SolverParameter::_internal_lr_policy() const {
return lr_policy_.Get();
}
inline void SolverParameter::_internal_set_lr_policy(const std::string& value) {
_has_bits_[0] |= 0x00000002u;
lr_policy_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void SolverParameter::set_lr_policy(std::string&& value) {
_has_bits_[0] |= 0x00000002u;
lr_policy_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.SolverParameter.lr_policy)
}
inline void SolverParameter::set_lr_policy(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000002u;
lr_policy_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.SolverParameter.lr_policy)
}
inline void SolverParameter::set_lr_policy(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000002u;
lr_policy_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.SolverParameter.lr_policy)
}
inline std::string* SolverParameter::_internal_mutable_lr_policy() {
_has_bits_[0] |= 0x00000002u;
return lr_policy_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* SolverParameter::release_lr_policy() {
// @@protoc_insertion_point(field_release:caffe.SolverParameter.lr_policy)
if (!_internal_has_lr_policy()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000002u;
return lr_policy_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void SolverParameter::set_allocated_lr_policy(std::string* lr_policy) {
if (lr_policy != nullptr) {
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
lr_policy_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), lr_policy,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.SolverParameter.lr_policy)
}
// optional float gamma = 9;
inline bool SolverParameter::_internal_has_gamma() const {
bool value = (_has_bits_[0] & 0x00008000u) != 0;
return value;
}
inline bool SolverParameter::has_gamma() const {
return _internal_has_gamma();
}
inline void SolverParameter::clear_gamma() {
gamma_ = 0;
_has_bits_[0] &= ~0x00008000u;
}
inline float SolverParameter::_internal_gamma() const {
return gamma_;
}
inline float SolverParameter::gamma() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.gamma)
return _internal_gamma();
}
inline void SolverParameter::_internal_set_gamma(float value) {
_has_bits_[0] |= 0x00008000u;
gamma_ = value;
}
inline void SolverParameter::set_gamma(float value) {
_internal_set_gamma(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.gamma)
}
// optional float power = 10;
inline bool SolverParameter::_internal_has_power() const {
bool value = (_has_bits_[0] & 0x00010000u) != 0;
return value;
}
inline bool SolverParameter::has_power() const {
return _internal_has_power();
}
inline void SolverParameter::clear_power() {
power_ = 0;
_has_bits_[0] &= ~0x00010000u;
}
inline float SolverParameter::_internal_power() const {
return power_;
}
inline float SolverParameter::power() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.power)
return _internal_power();
}
inline void SolverParameter::_internal_set_power(float value) {
_has_bits_[0] |= 0x00010000u;
power_ = value;
}
inline void SolverParameter::set_power(float value) {
_internal_set_power(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.power)
}
// optional float momentum = 11;
inline bool SolverParameter::_internal_has_momentum() const {
bool value = (_has_bits_[0] & 0x00020000u) != 0;
return value;
}
inline bool SolverParameter::has_momentum() const {
return _internal_has_momentum();
}
inline void SolverParameter::clear_momentum() {
momentum_ = 0;
_has_bits_[0] &= ~0x00020000u;
}
inline float SolverParameter::_internal_momentum() const {
return momentum_;
}
inline float SolverParameter::momentum() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.momentum)
return _internal_momentum();
}
inline void SolverParameter::_internal_set_momentum(float value) {
_has_bits_[0] |= 0x00020000u;
momentum_ = value;
}
inline void SolverParameter::set_momentum(float value) {
_internal_set_momentum(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.momentum)
}
// optional float weight_decay = 12;
inline bool SolverParameter::_internal_has_weight_decay() const {
bool value = (_has_bits_[0] & 0x00040000u) != 0;
return value;
}
inline bool SolverParameter::has_weight_decay() const {
return _internal_has_weight_decay();
}
inline void SolverParameter::clear_weight_decay() {
weight_decay_ = 0;
_has_bits_[0] &= ~0x00040000u;
}
inline float SolverParameter::_internal_weight_decay() const {
return weight_decay_;
}
inline float SolverParameter::weight_decay() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.weight_decay)
return _internal_weight_decay();
}
inline void SolverParameter::_internal_set_weight_decay(float value) {
_has_bits_[0] |= 0x00040000u;
weight_decay_ = value;
}
inline void SolverParameter::set_weight_decay(float value) {
_internal_set_weight_decay(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.weight_decay)
}
// optional string regularization_type = 29 [default = "L2"];
inline bool SolverParameter::_internal_has_regularization_type() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool SolverParameter::has_regularization_type() const {
return _internal_has_regularization_type();
}
inline void SolverParameter::clear_regularization_type() {
regularization_type_.ClearToDefault(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_regularization_type_.get(), GetArena());
_has_bits_[0] &= ~0x00000010u;
}
inline const std::string& SolverParameter::regularization_type() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.regularization_type)
return _internal_regularization_type();
}
inline void SolverParameter::set_regularization_type(const std::string& value) {
_internal_set_regularization_type(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.regularization_type)
}
inline std::string* SolverParameter::mutable_regularization_type() {
// @@protoc_insertion_point(field_mutable:caffe.SolverParameter.regularization_type)
return _internal_mutable_regularization_type();
}
inline const std::string& SolverParameter::_internal_regularization_type() const {
return regularization_type_.Get();
}
inline void SolverParameter::_internal_set_regularization_type(const std::string& value) {
_has_bits_[0] |= 0x00000010u;
regularization_type_.Set(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_regularization_type_.get(), value, GetArena());
}
inline void SolverParameter::set_regularization_type(std::string&& value) {
_has_bits_[0] |= 0x00000010u;
regularization_type_.Set(
&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_regularization_type_.get(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.SolverParameter.regularization_type)
}
inline void SolverParameter::set_regularization_type(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000010u;
regularization_type_.Set(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_regularization_type_.get(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.SolverParameter.regularization_type)
}
inline void SolverParameter::set_regularization_type(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000010u;
regularization_type_.Set(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_regularization_type_.get(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.SolverParameter.regularization_type)
}
inline std::string* SolverParameter::_internal_mutable_regularization_type() {
_has_bits_[0] |= 0x00000010u;
return regularization_type_.Mutable(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_regularization_type_.get(), GetArena());
}
inline std::string* SolverParameter::release_regularization_type() {
// @@protoc_insertion_point(field_release:caffe.SolverParameter.regularization_type)
if (!_internal_has_regularization_type()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000010u;
return regularization_type_.ReleaseNonDefault(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_regularization_type_.get(), GetArena());
}
inline void SolverParameter::set_allocated_regularization_type(std::string* regularization_type) {
if (regularization_type != nullptr) {
_has_bits_[0] |= 0x00000010u;
} else {
_has_bits_[0] &= ~0x00000010u;
}
regularization_type_.SetAllocated(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_regularization_type_.get(), regularization_type,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.SolverParameter.regularization_type)
}
// optional int32 stepsize = 13;
inline bool SolverParameter::_internal_has_stepsize() const {
bool value = (_has_bits_[0] & 0x00080000u) != 0;
return value;
}
inline bool SolverParameter::has_stepsize() const {
return _internal_has_stepsize();
}
inline void SolverParameter::clear_stepsize() {
stepsize_ = 0;
_has_bits_[0] &= ~0x00080000u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverParameter::_internal_stepsize() const {
return stepsize_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverParameter::stepsize() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.stepsize)
return _internal_stepsize();
}
inline void SolverParameter::_internal_set_stepsize(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00080000u;
stepsize_ = value;
}
inline void SolverParameter::set_stepsize(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_stepsize(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.stepsize)
}
// repeated int32 stepvalue = 34;
inline int SolverParameter::_internal_stepvalue_size() const {
return stepvalue_.size();
}
inline int SolverParameter::stepvalue_size() const {
return _internal_stepvalue_size();
}
inline void SolverParameter::clear_stepvalue() {
stepvalue_.Clear();
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverParameter::_internal_stepvalue(int index) const {
return stepvalue_.Get(index);
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverParameter::stepvalue(int index) const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.stepvalue)
return _internal_stepvalue(index);
}
inline void SolverParameter::set_stepvalue(int index, ::PROTOBUF_NAMESPACE_ID::int32 value) {
stepvalue_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.stepvalue)
}
inline void SolverParameter::_internal_add_stepvalue(::PROTOBUF_NAMESPACE_ID::int32 value) {
stepvalue_.Add(value);
}
inline void SolverParameter::add_stepvalue(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_add_stepvalue(value);
// @@protoc_insertion_point(field_add:caffe.SolverParameter.stepvalue)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >&
SolverParameter::_internal_stepvalue() const {
return stepvalue_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >&
SolverParameter::stepvalue() const {
// @@protoc_insertion_point(field_list:caffe.SolverParameter.stepvalue)
return _internal_stepvalue();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >*
SolverParameter::_internal_mutable_stepvalue() {
return &stepvalue_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::int32 >*
SolverParameter::mutable_stepvalue() {
// @@protoc_insertion_point(field_mutable_list:caffe.SolverParameter.stepvalue)
return _internal_mutable_stepvalue();
}
// optional float clip_gradients = 35 [default = -1];
inline bool SolverParameter::_internal_has_clip_gradients() const {
bool value = (_has_bits_[1] & 0x00000002u) != 0;
return value;
}
inline bool SolverParameter::has_clip_gradients() const {
return _internal_has_clip_gradients();
}
inline void SolverParameter::clear_clip_gradients() {
clip_gradients_ = -1;
_has_bits_[1] &= ~0x00000002u;
}
inline float SolverParameter::_internal_clip_gradients() const {
return clip_gradients_;
}
inline float SolverParameter::clip_gradients() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.clip_gradients)
return _internal_clip_gradients();
}
inline void SolverParameter::_internal_set_clip_gradients(float value) {
_has_bits_[1] |= 0x00000002u;
clip_gradients_ = value;
}
inline void SolverParameter::set_clip_gradients(float value) {
_internal_set_clip_gradients(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.clip_gradients)
}
// optional int32 snapshot = 14 [default = 0];
inline bool SolverParameter::_internal_has_snapshot() const {
bool value = (_has_bits_[0] & 0x00100000u) != 0;
return value;
}
inline bool SolverParameter::has_snapshot() const {
return _internal_has_snapshot();
}
inline void SolverParameter::clear_snapshot() {
snapshot_ = 0;
_has_bits_[0] &= ~0x00100000u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverParameter::_internal_snapshot() const {
return snapshot_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverParameter::snapshot() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.snapshot)
return _internal_snapshot();
}
inline void SolverParameter::_internal_set_snapshot(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00100000u;
snapshot_ = value;
}
inline void SolverParameter::set_snapshot(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_snapshot(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.snapshot)
}
// optional string snapshot_prefix = 15;
inline bool SolverParameter::_internal_has_snapshot_prefix() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool SolverParameter::has_snapshot_prefix() const {
return _internal_has_snapshot_prefix();
}
inline void SolverParameter::clear_snapshot_prefix() {
snapshot_prefix_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000004u;
}
inline const std::string& SolverParameter::snapshot_prefix() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.snapshot_prefix)
return _internal_snapshot_prefix();
}
inline void SolverParameter::set_snapshot_prefix(const std::string& value) {
_internal_set_snapshot_prefix(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.snapshot_prefix)
}
inline std::string* SolverParameter::mutable_snapshot_prefix() {
// @@protoc_insertion_point(field_mutable:caffe.SolverParameter.snapshot_prefix)
return _internal_mutable_snapshot_prefix();
}
inline const std::string& SolverParameter::_internal_snapshot_prefix() const {
return snapshot_prefix_.Get();
}
inline void SolverParameter::_internal_set_snapshot_prefix(const std::string& value) {
_has_bits_[0] |= 0x00000004u;
snapshot_prefix_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void SolverParameter::set_snapshot_prefix(std::string&& value) {
_has_bits_[0] |= 0x00000004u;
snapshot_prefix_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.SolverParameter.snapshot_prefix)
}
inline void SolverParameter::set_snapshot_prefix(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000004u;
snapshot_prefix_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.SolverParameter.snapshot_prefix)
}
inline void SolverParameter::set_snapshot_prefix(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000004u;
snapshot_prefix_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.SolverParameter.snapshot_prefix)
}
inline std::string* SolverParameter::_internal_mutable_snapshot_prefix() {
_has_bits_[0] |= 0x00000004u;
return snapshot_prefix_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* SolverParameter::release_snapshot_prefix() {
// @@protoc_insertion_point(field_release:caffe.SolverParameter.snapshot_prefix)
if (!_internal_has_snapshot_prefix()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000004u;
return snapshot_prefix_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void SolverParameter::set_allocated_snapshot_prefix(std::string* snapshot_prefix) {
if (snapshot_prefix != nullptr) {
_has_bits_[0] |= 0x00000004u;
} else {
_has_bits_[0] &= ~0x00000004u;
}
snapshot_prefix_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), snapshot_prefix,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.SolverParameter.snapshot_prefix)
}
// optional bool snapshot_diff = 16 [default = false];
inline bool SolverParameter::_internal_has_snapshot_diff() const {
bool value = (_has_bits_[0] & 0x00800000u) != 0;
return value;
}
inline bool SolverParameter::has_snapshot_diff() const {
return _internal_has_snapshot_diff();
}
inline void SolverParameter::clear_snapshot_diff() {
snapshot_diff_ = false;
_has_bits_[0] &= ~0x00800000u;
}
inline bool SolverParameter::_internal_snapshot_diff() const {
return snapshot_diff_;
}
inline bool SolverParameter::snapshot_diff() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.snapshot_diff)
return _internal_snapshot_diff();
}
inline void SolverParameter::_internal_set_snapshot_diff(bool value) {
_has_bits_[0] |= 0x00800000u;
snapshot_diff_ = value;
}
inline void SolverParameter::set_snapshot_diff(bool value) {
_internal_set_snapshot_diff(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.snapshot_diff)
}
// optional .caffe.SolverParameter.SnapshotFormat snapshot_format = 37 [default = BINARYPROTO];
inline bool SolverParameter::_internal_has_snapshot_format() const {
bool value = (_has_bits_[1] & 0x00000008u) != 0;
return value;
}
inline bool SolverParameter::has_snapshot_format() const {
return _internal_has_snapshot_format();
}
inline void SolverParameter::clear_snapshot_format() {
snapshot_format_ = 1;
_has_bits_[1] &= ~0x00000008u;
}
inline ::caffe::SolverParameter_SnapshotFormat SolverParameter::_internal_snapshot_format() const {
return static_cast< ::caffe::SolverParameter_SnapshotFormat >(snapshot_format_);
}
inline ::caffe::SolverParameter_SnapshotFormat SolverParameter::snapshot_format() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.snapshot_format)
return _internal_snapshot_format();
}
inline void SolverParameter::_internal_set_snapshot_format(::caffe::SolverParameter_SnapshotFormat value) {
assert(::caffe::SolverParameter_SnapshotFormat_IsValid(value));
_has_bits_[1] |= 0x00000008u;
snapshot_format_ = value;
}
inline void SolverParameter::set_snapshot_format(::caffe::SolverParameter_SnapshotFormat value) {
_internal_set_snapshot_format(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.snapshot_format)
}
// optional .caffe.SolverParameter.SolverMode solver_mode = 17 [default = GPU];
inline bool SolverParameter::_internal_has_solver_mode() const {
bool value = (_has_bits_[0] & 0x10000000u) != 0;
return value;
}
inline bool SolverParameter::has_solver_mode() const {
return _internal_has_solver_mode();
}
inline void SolverParameter::clear_solver_mode() {
solver_mode_ = 1;
_has_bits_[0] &= ~0x10000000u;
}
inline ::caffe::SolverParameter_SolverMode SolverParameter::_internal_solver_mode() const {
return static_cast< ::caffe::SolverParameter_SolverMode >(solver_mode_);
}
inline ::caffe::SolverParameter_SolverMode SolverParameter::solver_mode() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.solver_mode)
return _internal_solver_mode();
}
inline void SolverParameter::_internal_set_solver_mode(::caffe::SolverParameter_SolverMode value) {
assert(::caffe::SolverParameter_SolverMode_IsValid(value));
_has_bits_[0] |= 0x10000000u;
solver_mode_ = value;
}
inline void SolverParameter::set_solver_mode(::caffe::SolverParameter_SolverMode value) {
_internal_set_solver_mode(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.solver_mode)
}
// optional int32 device_id = 18 [default = 0];
inline bool SolverParameter::_internal_has_device_id() const {
bool value = (_has_bits_[0] & 0x00200000u) != 0;
return value;
}
inline bool SolverParameter::has_device_id() const {
return _internal_has_device_id();
}
inline void SolverParameter::clear_device_id() {
device_id_ = 0;
_has_bits_[0] &= ~0x00200000u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverParameter::_internal_device_id() const {
return device_id_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverParameter::device_id() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.device_id)
return _internal_device_id();
}
inline void SolverParameter::_internal_set_device_id(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00200000u;
device_id_ = value;
}
inline void SolverParameter::set_device_id(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_device_id(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.device_id)
}
// optional int64 random_seed = 20 [default = -1];
inline bool SolverParameter::_internal_has_random_seed() const {
bool value = (_has_bits_[0] & 0x08000000u) != 0;
return value;
}
inline bool SolverParameter::has_random_seed() const {
return _internal_has_random_seed();
}
inline void SolverParameter::clear_random_seed() {
random_seed_ = PROTOBUF_LONGLONG(-1);
_has_bits_[0] &= ~0x08000000u;
}
inline ::PROTOBUF_NAMESPACE_ID::int64 SolverParameter::_internal_random_seed() const {
return random_seed_;
}
inline ::PROTOBUF_NAMESPACE_ID::int64 SolverParameter::random_seed() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.random_seed)
return _internal_random_seed();
}
inline void SolverParameter::_internal_set_random_seed(::PROTOBUF_NAMESPACE_ID::int64 value) {
_has_bits_[0] |= 0x08000000u;
random_seed_ = value;
}
inline void SolverParameter::set_random_seed(::PROTOBUF_NAMESPACE_ID::int64 value) {
_internal_set_random_seed(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.random_seed)
}
// optional string type = 40 [default = "SGD"];
inline bool SolverParameter::_internal_has_type() const {
bool value = (_has_bits_[0] & 0x00000020u) != 0;
return value;
}
inline bool SolverParameter::has_type() const {
return _internal_has_type();
}
inline void SolverParameter::clear_type() {
type_.ClearToDefault(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_type_.get(), GetArena());
_has_bits_[0] &= ~0x00000020u;
}
inline const std::string& SolverParameter::type() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.type)
return _internal_type();
}
inline void SolverParameter::set_type(const std::string& value) {
_internal_set_type(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.type)
}
inline std::string* SolverParameter::mutable_type() {
// @@protoc_insertion_point(field_mutable:caffe.SolverParameter.type)
return _internal_mutable_type();
}
inline const std::string& SolverParameter::_internal_type() const {
return type_.Get();
}
inline void SolverParameter::_internal_set_type(const std::string& value) {
_has_bits_[0] |= 0x00000020u;
type_.Set(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_type_.get(), value, GetArena());
}
inline void SolverParameter::set_type(std::string&& value) {
_has_bits_[0] |= 0x00000020u;
type_.Set(
&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_type_.get(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.SolverParameter.type)
}
inline void SolverParameter::set_type(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000020u;
type_.Set(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_type_.get(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.SolverParameter.type)
}
inline void SolverParameter::set_type(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000020u;
type_.Set(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_type_.get(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.SolverParameter.type)
}
inline std::string* SolverParameter::_internal_mutable_type() {
_has_bits_[0] |= 0x00000020u;
return type_.Mutable(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_type_.get(), GetArena());
}
inline std::string* SolverParameter::release_type() {
// @@protoc_insertion_point(field_release:caffe.SolverParameter.type)
if (!_internal_has_type()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000020u;
return type_.ReleaseNonDefault(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_type_.get(), GetArena());
}
inline void SolverParameter::set_allocated_type(std::string* type) {
if (type != nullptr) {
_has_bits_[0] |= 0x00000020u;
} else {
_has_bits_[0] &= ~0x00000020u;
}
type_.SetAllocated(&::caffe::SolverParameter::_i_give_permission_to_break_this_code_default_type_.get(), type,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.SolverParameter.type)
}
// optional float delta = 31 [default = 1e-08];
inline bool SolverParameter::_internal_has_delta() const {
bool value = (_has_bits_[0] & 0x80000000u) != 0;
return value;
}
inline bool SolverParameter::has_delta() const {
return _internal_has_delta();
}
inline void SolverParameter::clear_delta() {
delta_ = 1e-08f;
_has_bits_[0] &= ~0x80000000u;
}
inline float SolverParameter::_internal_delta() const {
return delta_;
}
inline float SolverParameter::delta() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.delta)
return _internal_delta();
}
inline void SolverParameter::_internal_set_delta(float value) {
_has_bits_[0] |= 0x80000000u;
delta_ = value;
}
inline void SolverParameter::set_delta(float value) {
_internal_set_delta(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.delta)
}
// optional float momentum2 = 39 [default = 0.999];
inline bool SolverParameter::_internal_has_momentum2() const {
bool value = (_has_bits_[1] & 0x00000010u) != 0;
return value;
}
inline bool SolverParameter::has_momentum2() const {
return _internal_has_momentum2();
}
inline void SolverParameter::clear_momentum2() {
momentum2_ = 0.999f;
_has_bits_[1] &= ~0x00000010u;
}
inline float SolverParameter::_internal_momentum2() const {
return momentum2_;
}
inline float SolverParameter::momentum2() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.momentum2)
return _internal_momentum2();
}
inline void SolverParameter::_internal_set_momentum2(float value) {
_has_bits_[1] |= 0x00000010u;
momentum2_ = value;
}
inline void SolverParameter::set_momentum2(float value) {
_internal_set_momentum2(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.momentum2)
}
// optional float rms_decay = 38;
inline bool SolverParameter::_internal_has_rms_decay() const {
bool value = (_has_bits_[0] & 0x04000000u) != 0;
return value;
}
inline bool SolverParameter::has_rms_decay() const {
return _internal_has_rms_decay();
}
inline void SolverParameter::clear_rms_decay() {
rms_decay_ = 0;
_has_bits_[0] &= ~0x04000000u;
}
inline float SolverParameter::_internal_rms_decay() const {
return rms_decay_;
}
inline float SolverParameter::rms_decay() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.rms_decay)
return _internal_rms_decay();
}
inline void SolverParameter::_internal_set_rms_decay(float value) {
_has_bits_[0] |= 0x04000000u;
rms_decay_ = value;
}
inline void SolverParameter::set_rms_decay(float value) {
_internal_set_rms_decay(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.rms_decay)
}
// optional bool debug_info = 23 [default = false];
inline bool SolverParameter::_internal_has_debug_info() const {
bool value = (_has_bits_[0] & 0x01000000u) != 0;
return value;
}
inline bool SolverParameter::has_debug_info() const {
return _internal_has_debug_info();
}
inline void SolverParameter::clear_debug_info() {
debug_info_ = false;
_has_bits_[0] &= ~0x01000000u;
}
inline bool SolverParameter::_internal_debug_info() const {
return debug_info_;
}
inline bool SolverParameter::debug_info() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.debug_info)
return _internal_debug_info();
}
inline void SolverParameter::_internal_set_debug_info(bool value) {
_has_bits_[0] |= 0x01000000u;
debug_info_ = value;
}
inline void SolverParameter::set_debug_info(bool value) {
_internal_set_debug_info(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.debug_info)
}
// optional bool snapshot_after_train = 28 [default = true];
inline bool SolverParameter::_internal_has_snapshot_after_train() const {
bool value = (_has_bits_[0] & 0x40000000u) != 0;
return value;
}
inline bool SolverParameter::has_snapshot_after_train() const {
return _internal_has_snapshot_after_train();
}
inline void SolverParameter::clear_snapshot_after_train() {
snapshot_after_train_ = true;
_has_bits_[0] &= ~0x40000000u;
}
inline bool SolverParameter::_internal_snapshot_after_train() const {
return snapshot_after_train_;
}
inline bool SolverParameter::snapshot_after_train() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.snapshot_after_train)
return _internal_snapshot_after_train();
}
inline void SolverParameter::_internal_set_snapshot_after_train(bool value) {
_has_bits_[0] |= 0x40000000u;
snapshot_after_train_ = value;
}
inline void SolverParameter::set_snapshot_after_train(bool value) {
_internal_set_snapshot_after_train(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.snapshot_after_train)
}
// optional .caffe.SolverParameter.SolverType solver_type = 30 [default = SGD];
inline bool SolverParameter::_internal_has_solver_type() const {
bool value = (_has_bits_[0] & 0x02000000u) != 0;
return value;
}
inline bool SolverParameter::has_solver_type() const {
return _internal_has_solver_type();
}
inline void SolverParameter::clear_solver_type() {
solver_type_ = 0;
_has_bits_[0] &= ~0x02000000u;
}
inline ::caffe::SolverParameter_SolverType SolverParameter::_internal_solver_type() const {
return static_cast< ::caffe::SolverParameter_SolverType >(solver_type_);
}
inline ::caffe::SolverParameter_SolverType SolverParameter::solver_type() const {
// @@protoc_insertion_point(field_get:caffe.SolverParameter.solver_type)
return _internal_solver_type();
}
inline void SolverParameter::_internal_set_solver_type(::caffe::SolverParameter_SolverType value) {
assert(::caffe::SolverParameter_SolverType_IsValid(value));
_has_bits_[0] |= 0x02000000u;
solver_type_ = value;
}
inline void SolverParameter::set_solver_type(::caffe::SolverParameter_SolverType value) {
_internal_set_solver_type(value);
// @@protoc_insertion_point(field_set:caffe.SolverParameter.solver_type)
}
// -------------------------------------------------------------------
// SolverState
// optional int32 iter = 1;
inline bool SolverState::_internal_has_iter() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool SolverState::has_iter() const {
return _internal_has_iter();
}
inline void SolverState::clear_iter() {
iter_ = 0;
_has_bits_[0] &= ~0x00000002u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverState::_internal_iter() const {
return iter_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverState::iter() const {
// @@protoc_insertion_point(field_get:caffe.SolverState.iter)
return _internal_iter();
}
inline void SolverState::_internal_set_iter(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000002u;
iter_ = value;
}
inline void SolverState::set_iter(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_iter(value);
// @@protoc_insertion_point(field_set:caffe.SolverState.iter)
}
// optional string learned_net = 2;
inline bool SolverState::_internal_has_learned_net() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool SolverState::has_learned_net() const {
return _internal_has_learned_net();
}
inline void SolverState::clear_learned_net() {
learned_net_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000001u;
}
inline const std::string& SolverState::learned_net() const {
// @@protoc_insertion_point(field_get:caffe.SolverState.learned_net)
return _internal_learned_net();
}
inline void SolverState::set_learned_net(const std::string& value) {
_internal_set_learned_net(value);
// @@protoc_insertion_point(field_set:caffe.SolverState.learned_net)
}
inline std::string* SolverState::mutable_learned_net() {
// @@protoc_insertion_point(field_mutable:caffe.SolverState.learned_net)
return _internal_mutable_learned_net();
}
inline const std::string& SolverState::_internal_learned_net() const {
return learned_net_.Get();
}
inline void SolverState::_internal_set_learned_net(const std::string& value) {
_has_bits_[0] |= 0x00000001u;
learned_net_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void SolverState::set_learned_net(std::string&& value) {
_has_bits_[0] |= 0x00000001u;
learned_net_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.SolverState.learned_net)
}
inline void SolverState::set_learned_net(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000001u;
learned_net_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.SolverState.learned_net)
}
inline void SolverState::set_learned_net(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000001u;
learned_net_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.SolverState.learned_net)
}
inline std::string* SolverState::_internal_mutable_learned_net() {
_has_bits_[0] |= 0x00000001u;
return learned_net_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* SolverState::release_learned_net() {
// @@protoc_insertion_point(field_release:caffe.SolverState.learned_net)
if (!_internal_has_learned_net()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000001u;
return learned_net_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void SolverState::set_allocated_learned_net(std::string* learned_net) {
if (learned_net != nullptr) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
learned_net_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), learned_net,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.SolverState.learned_net)
}
// repeated .caffe.BlobProto history = 3;
inline int SolverState::_internal_history_size() const {
return history_.size();
}
inline int SolverState::history_size() const {
return _internal_history_size();
}
inline void SolverState::clear_history() {
history_.Clear();
}
inline ::caffe::BlobProto* SolverState::mutable_history(int index) {
// @@protoc_insertion_point(field_mutable:caffe.SolverState.history)
return history_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto >*
SolverState::mutable_history() {
// @@protoc_insertion_point(field_mutable_list:caffe.SolverState.history)
return &history_;
}
inline const ::caffe::BlobProto& SolverState::_internal_history(int index) const {
return history_.Get(index);
}
inline const ::caffe::BlobProto& SolverState::history(int index) const {
// @@protoc_insertion_point(field_get:caffe.SolverState.history)
return _internal_history(index);
}
inline ::caffe::BlobProto* SolverState::_internal_add_history() {
return history_.Add();
}
inline ::caffe::BlobProto* SolverState::add_history() {
// @@protoc_insertion_point(field_add:caffe.SolverState.history)
return _internal_add_history();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto >&
SolverState::history() const {
// @@protoc_insertion_point(field_list:caffe.SolverState.history)
return history_;
}
// optional int32 current_step = 4 [default = 0];
inline bool SolverState::_internal_has_current_step() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool SolverState::has_current_step() const {
return _internal_has_current_step();
}
inline void SolverState::clear_current_step() {
current_step_ = 0;
_has_bits_[0] &= ~0x00000004u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverState::_internal_current_step() const {
return current_step_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SolverState::current_step() const {
// @@protoc_insertion_point(field_get:caffe.SolverState.current_step)
return _internal_current_step();
}
inline void SolverState::_internal_set_current_step(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000004u;
current_step_ = value;
}
inline void SolverState::set_current_step(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_current_step(value);
// @@protoc_insertion_point(field_set:caffe.SolverState.current_step)
}
// -------------------------------------------------------------------
// NetState
// optional .caffe.Phase phase = 1 [default = TEST];
inline bool NetState::_internal_has_phase() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool NetState::has_phase() const {
return _internal_has_phase();
}
inline void NetState::clear_phase() {
phase_ = 1;
_has_bits_[0] &= ~0x00000002u;
}
inline ::caffe::Phase NetState::_internal_phase() const {
return static_cast< ::caffe::Phase >(phase_);
}
inline ::caffe::Phase NetState::phase() const {
// @@protoc_insertion_point(field_get:caffe.NetState.phase)
return _internal_phase();
}
inline void NetState::_internal_set_phase(::caffe::Phase value) {
assert(::caffe::Phase_IsValid(value));
_has_bits_[0] |= 0x00000002u;
phase_ = value;
}
inline void NetState::set_phase(::caffe::Phase value) {
_internal_set_phase(value);
// @@protoc_insertion_point(field_set:caffe.NetState.phase)
}
// optional int32 level = 2 [default = 0];
inline bool NetState::_internal_has_level() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool NetState::has_level() const {
return _internal_has_level();
}
inline void NetState::clear_level() {
level_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 NetState::_internal_level() const {
return level_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 NetState::level() const {
// @@protoc_insertion_point(field_get:caffe.NetState.level)
return _internal_level();
}
inline void NetState::_internal_set_level(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000001u;
level_ = value;
}
inline void NetState::set_level(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_level(value);
// @@protoc_insertion_point(field_set:caffe.NetState.level)
}
// repeated string stage = 3;
inline int NetState::_internal_stage_size() const {
return stage_.size();
}
inline int NetState::stage_size() const {
return _internal_stage_size();
}
inline void NetState::clear_stage() {
stage_.Clear();
}
inline std::string* NetState::add_stage() {
// @@protoc_insertion_point(field_add_mutable:caffe.NetState.stage)
return _internal_add_stage();
}
inline const std::string& NetState::_internal_stage(int index) const {
return stage_.Get(index);
}
inline const std::string& NetState::stage(int index) const {
// @@protoc_insertion_point(field_get:caffe.NetState.stage)
return _internal_stage(index);
}
inline std::string* NetState::mutable_stage(int index) {
// @@protoc_insertion_point(field_mutable:caffe.NetState.stage)
return stage_.Mutable(index);
}
inline void NetState::set_stage(int index, const std::string& value) {
// @@protoc_insertion_point(field_set:caffe.NetState.stage)
stage_.Mutable(index)->assign(value);
}
inline void NetState::set_stage(int index, std::string&& value) {
// @@protoc_insertion_point(field_set:caffe.NetState.stage)
stage_.Mutable(index)->assign(std::move(value));
}
inline void NetState::set_stage(int index, const char* value) {
GOOGLE_DCHECK(value != nullptr);
stage_.Mutable(index)->assign(value);
// @@protoc_insertion_point(field_set_char:caffe.NetState.stage)
}
inline 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:caffe.NetState.stage)
}
inline std::string* NetState::_internal_add_stage() {
return stage_.Add();
}
inline void NetState::add_stage(const std::string& value) {
stage_.Add()->assign(value);
// @@protoc_insertion_point(field_add:caffe.NetState.stage)
}
inline void NetState::add_stage(std::string&& value) {
stage_.Add(std::move(value));
// @@protoc_insertion_point(field_add:caffe.NetState.stage)
}
inline void NetState::add_stage(const char* value) {
GOOGLE_DCHECK(value != nullptr);
stage_.Add()->assign(value);
// @@protoc_insertion_point(field_add_char:caffe.NetState.stage)
}
inline 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:caffe.NetState.stage)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>&
NetState::stage() const {
// @@protoc_insertion_point(field_list:caffe.NetState.stage)
return stage_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>*
NetState::mutable_stage() {
// @@protoc_insertion_point(field_mutable_list:caffe.NetState.stage)
return &stage_;
}
// -------------------------------------------------------------------
// NetStateRule
// optional .caffe.Phase phase = 1;
inline bool NetStateRule::_internal_has_phase() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool NetStateRule::has_phase() const {
return _internal_has_phase();
}
inline void NetStateRule::clear_phase() {
phase_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline ::caffe::Phase NetStateRule::_internal_phase() const {
return static_cast< ::caffe::Phase >(phase_);
}
inline ::caffe::Phase NetStateRule::phase() const {
// @@protoc_insertion_point(field_get:caffe.NetStateRule.phase)
return _internal_phase();
}
inline void NetStateRule::_internal_set_phase(::caffe::Phase value) {
assert(::caffe::Phase_IsValid(value));
_has_bits_[0] |= 0x00000001u;
phase_ = value;
}
inline void NetStateRule::set_phase(::caffe::Phase value) {
_internal_set_phase(value);
// @@protoc_insertion_point(field_set:caffe.NetStateRule.phase)
}
// optional int32 min_level = 2;
inline bool NetStateRule::_internal_has_min_level() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool NetStateRule::has_min_level() const {
return _internal_has_min_level();
}
inline void NetStateRule::clear_min_level() {
min_level_ = 0;
_has_bits_[0] &= ~0x00000002u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 NetStateRule::_internal_min_level() const {
return min_level_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 NetStateRule::min_level() const {
// @@protoc_insertion_point(field_get:caffe.NetStateRule.min_level)
return _internal_min_level();
}
inline void NetStateRule::_internal_set_min_level(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000002u;
min_level_ = value;
}
inline void NetStateRule::set_min_level(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_min_level(value);
// @@protoc_insertion_point(field_set:caffe.NetStateRule.min_level)
}
// optional int32 max_level = 3;
inline bool NetStateRule::_internal_has_max_level() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool NetStateRule::has_max_level() const {
return _internal_has_max_level();
}
inline void NetStateRule::clear_max_level() {
max_level_ = 0;
_has_bits_[0] &= ~0x00000004u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 NetStateRule::_internal_max_level() const {
return max_level_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 NetStateRule::max_level() const {
// @@protoc_insertion_point(field_get:caffe.NetStateRule.max_level)
return _internal_max_level();
}
inline void NetStateRule::_internal_set_max_level(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000004u;
max_level_ = value;
}
inline void NetStateRule::set_max_level(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_max_level(value);
// @@protoc_insertion_point(field_set:caffe.NetStateRule.max_level)
}
// repeated string stage = 4;
inline int NetStateRule::_internal_stage_size() const {
return stage_.size();
}
inline int NetStateRule::stage_size() const {
return _internal_stage_size();
}
inline void NetStateRule::clear_stage() {
stage_.Clear();
}
inline std::string* NetStateRule::add_stage() {
// @@protoc_insertion_point(field_add_mutable:caffe.NetStateRule.stage)
return _internal_add_stage();
}
inline const std::string& NetStateRule::_internal_stage(int index) const {
return stage_.Get(index);
}
inline const std::string& NetStateRule::stage(int index) const {
// @@protoc_insertion_point(field_get:caffe.NetStateRule.stage)
return _internal_stage(index);
}
inline std::string* NetStateRule::mutable_stage(int index) {
// @@protoc_insertion_point(field_mutable:caffe.NetStateRule.stage)
return stage_.Mutable(index);
}
inline void NetStateRule::set_stage(int index, const std::string& value) {
// @@protoc_insertion_point(field_set:caffe.NetStateRule.stage)
stage_.Mutable(index)->assign(value);
}
inline void NetStateRule::set_stage(int index, std::string&& value) {
// @@protoc_insertion_point(field_set:caffe.NetStateRule.stage)
stage_.Mutable(index)->assign(std::move(value));
}
inline void NetStateRule::set_stage(int index, const char* value) {
GOOGLE_DCHECK(value != nullptr);
stage_.Mutable(index)->assign(value);
// @@protoc_insertion_point(field_set_char:caffe.NetStateRule.stage)
}
inline 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:caffe.NetStateRule.stage)
}
inline std::string* NetStateRule::_internal_add_stage() {
return stage_.Add();
}
inline void NetStateRule::add_stage(const std::string& value) {
stage_.Add()->assign(value);
// @@protoc_insertion_point(field_add:caffe.NetStateRule.stage)
}
inline void NetStateRule::add_stage(std::string&& value) {
stage_.Add(std::move(value));
// @@protoc_insertion_point(field_add:caffe.NetStateRule.stage)
}
inline void NetStateRule::add_stage(const char* value) {
GOOGLE_DCHECK(value != nullptr);
stage_.Add()->assign(value);
// @@protoc_insertion_point(field_add_char:caffe.NetStateRule.stage)
}
inline 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:caffe.NetStateRule.stage)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>&
NetStateRule::stage() const {
// @@protoc_insertion_point(field_list:caffe.NetStateRule.stage)
return stage_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>*
NetStateRule::mutable_stage() {
// @@protoc_insertion_point(field_mutable_list:caffe.NetStateRule.stage)
return &stage_;
}
// repeated string not_stage = 5;
inline int NetStateRule::_internal_not_stage_size() const {
return not_stage_.size();
}
inline int NetStateRule::not_stage_size() const {
return _internal_not_stage_size();
}
inline void NetStateRule::clear_not_stage() {
not_stage_.Clear();
}
inline std::string* NetStateRule::add_not_stage() {
// @@protoc_insertion_point(field_add_mutable:caffe.NetStateRule.not_stage)
return _internal_add_not_stage();
}
inline const std::string& NetStateRule::_internal_not_stage(int index) const {
return not_stage_.Get(index);
}
inline const std::string& NetStateRule::not_stage(int index) const {
// @@protoc_insertion_point(field_get:caffe.NetStateRule.not_stage)
return _internal_not_stage(index);
}
inline std::string* NetStateRule::mutable_not_stage(int index) {
// @@protoc_insertion_point(field_mutable:caffe.NetStateRule.not_stage)
return not_stage_.Mutable(index);
}
inline void NetStateRule::set_not_stage(int index, const std::string& value) {
// @@protoc_insertion_point(field_set:caffe.NetStateRule.not_stage)
not_stage_.Mutable(index)->assign(value);
}
inline void NetStateRule::set_not_stage(int index, std::string&& value) {
// @@protoc_insertion_point(field_set:caffe.NetStateRule.not_stage)
not_stage_.Mutable(index)->assign(std::move(value));
}
inline void NetStateRule::set_not_stage(int index, const char* value) {
GOOGLE_DCHECK(value != nullptr);
not_stage_.Mutable(index)->assign(value);
// @@protoc_insertion_point(field_set_char:caffe.NetStateRule.not_stage)
}
inline 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:caffe.NetStateRule.not_stage)
}
inline std::string* NetStateRule::_internal_add_not_stage() {
return not_stage_.Add();
}
inline void NetStateRule::add_not_stage(const std::string& value) {
not_stage_.Add()->assign(value);
// @@protoc_insertion_point(field_add:caffe.NetStateRule.not_stage)
}
inline void NetStateRule::add_not_stage(std::string&& value) {
not_stage_.Add(std::move(value));
// @@protoc_insertion_point(field_add:caffe.NetStateRule.not_stage)
}
inline void NetStateRule::add_not_stage(const char* value) {
GOOGLE_DCHECK(value != nullptr);
not_stage_.Add()->assign(value);
// @@protoc_insertion_point(field_add_char:caffe.NetStateRule.not_stage)
}
inline 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:caffe.NetStateRule.not_stage)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>&
NetStateRule::not_stage() const {
// @@protoc_insertion_point(field_list:caffe.NetStateRule.not_stage)
return not_stage_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>*
NetStateRule::mutable_not_stage() {
// @@protoc_insertion_point(field_mutable_list:caffe.NetStateRule.not_stage)
return ¬_stage_;
}
// -------------------------------------------------------------------
// ParamSpec
// optional string name = 1;
inline bool ParamSpec::_internal_has_name() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool ParamSpec::has_name() const {
return _internal_has_name();
}
inline void ParamSpec::clear_name() {
name_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000001u;
}
inline const std::string& ParamSpec::name() const {
// @@protoc_insertion_point(field_get:caffe.ParamSpec.name)
return _internal_name();
}
inline void ParamSpec::set_name(const std::string& value) {
_internal_set_name(value);
// @@protoc_insertion_point(field_set:caffe.ParamSpec.name)
}
inline std::string* ParamSpec::mutable_name() {
// @@protoc_insertion_point(field_mutable:caffe.ParamSpec.name)
return _internal_mutable_name();
}
inline const std::string& ParamSpec::_internal_name() const {
return name_.Get();
}
inline void ParamSpec::_internal_set_name(const std::string& value) {
_has_bits_[0] |= 0x00000001u;
name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void ParamSpec::set_name(std::string&& value) {
_has_bits_[0] |= 0x00000001u;
name_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.ParamSpec.name)
}
inline void ParamSpec::set_name(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000001u;
name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.ParamSpec.name)
}
inline void ParamSpec::set_name(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000001u;
name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.ParamSpec.name)
}
inline std::string* ParamSpec::_internal_mutable_name() {
_has_bits_[0] |= 0x00000001u;
return name_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* ParamSpec::release_name() {
// @@protoc_insertion_point(field_release:caffe.ParamSpec.name)
if (!_internal_has_name()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000001u;
return name_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void ParamSpec::set_allocated_name(std::string* name) {
if (name != nullptr) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
name_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), name,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.ParamSpec.name)
}
// optional .caffe.ParamSpec.DimCheckMode share_mode = 2;
inline bool ParamSpec::_internal_has_share_mode() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool ParamSpec::has_share_mode() const {
return _internal_has_share_mode();
}
inline void ParamSpec::clear_share_mode() {
share_mode_ = 0;
_has_bits_[0] &= ~0x00000002u;
}
inline ::caffe::ParamSpec_DimCheckMode ParamSpec::_internal_share_mode() const {
return static_cast< ::caffe::ParamSpec_DimCheckMode >(share_mode_);
}
inline ::caffe::ParamSpec_DimCheckMode ParamSpec::share_mode() const {
// @@protoc_insertion_point(field_get:caffe.ParamSpec.share_mode)
return _internal_share_mode();
}
inline void ParamSpec::_internal_set_share_mode(::caffe::ParamSpec_DimCheckMode value) {
assert(::caffe::ParamSpec_DimCheckMode_IsValid(value));
_has_bits_[0] |= 0x00000002u;
share_mode_ = value;
}
inline void ParamSpec::set_share_mode(::caffe::ParamSpec_DimCheckMode value) {
_internal_set_share_mode(value);
// @@protoc_insertion_point(field_set:caffe.ParamSpec.share_mode)
}
// optional float lr_mult = 3 [default = 1];
inline bool ParamSpec::_internal_has_lr_mult() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool ParamSpec::has_lr_mult() const {
return _internal_has_lr_mult();
}
inline void ParamSpec::clear_lr_mult() {
lr_mult_ = 1;
_has_bits_[0] &= ~0x00000004u;
}
inline float ParamSpec::_internal_lr_mult() const {
return lr_mult_;
}
inline float ParamSpec::lr_mult() const {
// @@protoc_insertion_point(field_get:caffe.ParamSpec.lr_mult)
return _internal_lr_mult();
}
inline void ParamSpec::_internal_set_lr_mult(float value) {
_has_bits_[0] |= 0x00000004u;
lr_mult_ = value;
}
inline void ParamSpec::set_lr_mult(float value) {
_internal_set_lr_mult(value);
// @@protoc_insertion_point(field_set:caffe.ParamSpec.lr_mult)
}
// optional float decay_mult = 4 [default = 1];
inline bool ParamSpec::_internal_has_decay_mult() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool ParamSpec::has_decay_mult() const {
return _internal_has_decay_mult();
}
inline void ParamSpec::clear_decay_mult() {
decay_mult_ = 1;
_has_bits_[0] &= ~0x00000008u;
}
inline float ParamSpec::_internal_decay_mult() const {
return decay_mult_;
}
inline float ParamSpec::decay_mult() const {
// @@protoc_insertion_point(field_get:caffe.ParamSpec.decay_mult)
return _internal_decay_mult();
}
inline void ParamSpec::_internal_set_decay_mult(float value) {
_has_bits_[0] |= 0x00000008u;
decay_mult_ = value;
}
inline void ParamSpec::set_decay_mult(float value) {
_internal_set_decay_mult(value);
// @@protoc_insertion_point(field_set:caffe.ParamSpec.decay_mult)
}
// -------------------------------------------------------------------
// LayerParameter
// optional string name = 1;
inline bool LayerParameter::_internal_has_name() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool LayerParameter::has_name() const {
return _internal_has_name();
}
inline void LayerParameter::clear_name() {
name_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000001u;
}
inline const std::string& LayerParameter::name() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.name)
return _internal_name();
}
inline void LayerParameter::set_name(const std::string& value) {
_internal_set_name(value);
// @@protoc_insertion_point(field_set:caffe.LayerParameter.name)
}
inline std::string* LayerParameter::mutable_name() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.name)
return _internal_mutable_name();
}
inline const std::string& LayerParameter::_internal_name() const {
return name_.Get();
}
inline void LayerParameter::_internal_set_name(const std::string& value) {
_has_bits_[0] |= 0x00000001u;
name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void LayerParameter::set_name(std::string&& value) {
_has_bits_[0] |= 0x00000001u;
name_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.LayerParameter.name)
}
inline void LayerParameter::set_name(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000001u;
name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.LayerParameter.name)
}
inline void LayerParameter::set_name(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000001u;
name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.LayerParameter.name)
}
inline std::string* LayerParameter::_internal_mutable_name() {
_has_bits_[0] |= 0x00000001u;
return name_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* LayerParameter::release_name() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.name)
if (!_internal_has_name()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000001u;
return name_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void LayerParameter::set_allocated_name(std::string* name) {
if (name != nullptr) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
name_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), name,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.name)
}
// optional string type = 2;
inline bool LayerParameter::_internal_has_type() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool LayerParameter::has_type() const {
return _internal_has_type();
}
inline void LayerParameter::clear_type() {
type_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000002u;
}
inline const std::string& LayerParameter::type() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.type)
return _internal_type();
}
inline void LayerParameter::set_type(const std::string& value) {
_internal_set_type(value);
// @@protoc_insertion_point(field_set:caffe.LayerParameter.type)
}
inline std::string* LayerParameter::mutable_type() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.type)
return _internal_mutable_type();
}
inline const std::string& LayerParameter::_internal_type() const {
return type_.Get();
}
inline void LayerParameter::_internal_set_type(const std::string& value) {
_has_bits_[0] |= 0x00000002u;
type_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void LayerParameter::set_type(std::string&& value) {
_has_bits_[0] |= 0x00000002u;
type_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.LayerParameter.type)
}
inline void LayerParameter::set_type(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000002u;
type_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.LayerParameter.type)
}
inline void LayerParameter::set_type(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000002u;
type_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.LayerParameter.type)
}
inline std::string* LayerParameter::_internal_mutable_type() {
_has_bits_[0] |= 0x00000002u;
return type_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* LayerParameter::release_type() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.type)
if (!_internal_has_type()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000002u;
return type_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void LayerParameter::set_allocated_type(std::string* type) {
if (type != nullptr) {
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
type_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), type,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.type)
}
// repeated string bottom = 3;
inline int LayerParameter::_internal_bottom_size() const {
return bottom_.size();
}
inline int LayerParameter::bottom_size() const {
return _internal_bottom_size();
}
inline void LayerParameter::clear_bottom() {
bottom_.Clear();
}
inline std::string* LayerParameter::add_bottom() {
// @@protoc_insertion_point(field_add_mutable:caffe.LayerParameter.bottom)
return _internal_add_bottom();
}
inline const std::string& LayerParameter::_internal_bottom(int index) const {
return bottom_.Get(index);
}
inline const std::string& LayerParameter::bottom(int index) const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.bottom)
return _internal_bottom(index);
}
inline std::string* LayerParameter::mutable_bottom(int index) {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.bottom)
return bottom_.Mutable(index);
}
inline void LayerParameter::set_bottom(int index, const std::string& value) {
// @@protoc_insertion_point(field_set:caffe.LayerParameter.bottom)
bottom_.Mutable(index)->assign(value);
}
inline void LayerParameter::set_bottom(int index, std::string&& value) {
// @@protoc_insertion_point(field_set:caffe.LayerParameter.bottom)
bottom_.Mutable(index)->assign(std::move(value));
}
inline void LayerParameter::set_bottom(int index, const char* value) {
GOOGLE_DCHECK(value != nullptr);
bottom_.Mutable(index)->assign(value);
// @@protoc_insertion_point(field_set_char:caffe.LayerParameter.bottom)
}
inline 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:caffe.LayerParameter.bottom)
}
inline std::string* LayerParameter::_internal_add_bottom() {
return bottom_.Add();
}
inline void LayerParameter::add_bottom(const std::string& value) {
bottom_.Add()->assign(value);
// @@protoc_insertion_point(field_add:caffe.LayerParameter.bottom)
}
inline void LayerParameter::add_bottom(std::string&& value) {
bottom_.Add(std::move(value));
// @@protoc_insertion_point(field_add:caffe.LayerParameter.bottom)
}
inline void LayerParameter::add_bottom(const char* value) {
GOOGLE_DCHECK(value != nullptr);
bottom_.Add()->assign(value);
// @@protoc_insertion_point(field_add_char:caffe.LayerParameter.bottom)
}
inline 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:caffe.LayerParameter.bottom)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>&
LayerParameter::bottom() const {
// @@protoc_insertion_point(field_list:caffe.LayerParameter.bottom)
return bottom_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>*
LayerParameter::mutable_bottom() {
// @@protoc_insertion_point(field_mutable_list:caffe.LayerParameter.bottom)
return &bottom_;
}
// repeated string top = 4;
inline int LayerParameter::_internal_top_size() const {
return top_.size();
}
inline int LayerParameter::top_size() const {
return _internal_top_size();
}
inline void LayerParameter::clear_top() {
top_.Clear();
}
inline std::string* LayerParameter::add_top() {
// @@protoc_insertion_point(field_add_mutable:caffe.LayerParameter.top)
return _internal_add_top();
}
inline const std::string& LayerParameter::_internal_top(int index) const {
return top_.Get(index);
}
inline const std::string& LayerParameter::top(int index) const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.top)
return _internal_top(index);
}
inline std::string* LayerParameter::mutable_top(int index) {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.top)
return top_.Mutable(index);
}
inline void LayerParameter::set_top(int index, const std::string& value) {
// @@protoc_insertion_point(field_set:caffe.LayerParameter.top)
top_.Mutable(index)->assign(value);
}
inline void LayerParameter::set_top(int index, std::string&& value) {
// @@protoc_insertion_point(field_set:caffe.LayerParameter.top)
top_.Mutable(index)->assign(std::move(value));
}
inline void LayerParameter::set_top(int index, const char* value) {
GOOGLE_DCHECK(value != nullptr);
top_.Mutable(index)->assign(value);
// @@protoc_insertion_point(field_set_char:caffe.LayerParameter.top)
}
inline 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:caffe.LayerParameter.top)
}
inline std::string* LayerParameter::_internal_add_top() {
return top_.Add();
}
inline void LayerParameter::add_top(const std::string& value) {
top_.Add()->assign(value);
// @@protoc_insertion_point(field_add:caffe.LayerParameter.top)
}
inline void LayerParameter::add_top(std::string&& value) {
top_.Add(std::move(value));
// @@protoc_insertion_point(field_add:caffe.LayerParameter.top)
}
inline void LayerParameter::add_top(const char* value) {
GOOGLE_DCHECK(value != nullptr);
top_.Add()->assign(value);
// @@protoc_insertion_point(field_add_char:caffe.LayerParameter.top)
}
inline 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:caffe.LayerParameter.top)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>&
LayerParameter::top() const {
// @@protoc_insertion_point(field_list:caffe.LayerParameter.top)
return top_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>*
LayerParameter::mutable_top() {
// @@protoc_insertion_point(field_mutable_list:caffe.LayerParameter.top)
return &top_;
}
// optional .caffe.Phase phase = 10;
inline bool LayerParameter::_internal_has_phase() const {
bool value = (_has_bits_[2] & 0x00000001u) != 0;
return value;
}
inline bool LayerParameter::has_phase() const {
return _internal_has_phase();
}
inline void LayerParameter::clear_phase() {
phase_ = 0;
_has_bits_[2] &= ~0x00000001u;
}
inline ::caffe::Phase LayerParameter::_internal_phase() const {
return static_cast< ::caffe::Phase >(phase_);
}
inline ::caffe::Phase LayerParameter::phase() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.phase)
return _internal_phase();
}
inline void LayerParameter::_internal_set_phase(::caffe::Phase value) {
assert(::caffe::Phase_IsValid(value));
_has_bits_[2] |= 0x00000001u;
phase_ = value;
}
inline void LayerParameter::set_phase(::caffe::Phase value) {
_internal_set_phase(value);
// @@protoc_insertion_point(field_set:caffe.LayerParameter.phase)
}
// repeated float loss_weight = 5;
inline int LayerParameter::_internal_loss_weight_size() const {
return loss_weight_.size();
}
inline int LayerParameter::loss_weight_size() const {
return _internal_loss_weight_size();
}
inline void LayerParameter::clear_loss_weight() {
loss_weight_.Clear();
}
inline float LayerParameter::_internal_loss_weight(int index) const {
return loss_weight_.Get(index);
}
inline float LayerParameter::loss_weight(int index) const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.loss_weight)
return _internal_loss_weight(index);
}
inline void LayerParameter::set_loss_weight(int index, float value) {
loss_weight_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.LayerParameter.loss_weight)
}
inline void LayerParameter::_internal_add_loss_weight(float value) {
loss_weight_.Add(value);
}
inline void LayerParameter::add_loss_weight(float value) {
_internal_add_loss_weight(value);
// @@protoc_insertion_point(field_add:caffe.LayerParameter.loss_weight)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
LayerParameter::_internal_loss_weight() const {
return loss_weight_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
LayerParameter::loss_weight() const {
// @@protoc_insertion_point(field_list:caffe.LayerParameter.loss_weight)
return _internal_loss_weight();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
LayerParameter::_internal_mutable_loss_weight() {
return &loss_weight_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
LayerParameter::mutable_loss_weight() {
// @@protoc_insertion_point(field_mutable_list:caffe.LayerParameter.loss_weight)
return _internal_mutable_loss_weight();
}
// repeated .caffe.ParamSpec param = 6;
inline int LayerParameter::_internal_param_size() const {
return param_.size();
}
inline int LayerParameter::param_size() const {
return _internal_param_size();
}
inline void LayerParameter::clear_param() {
param_.Clear();
}
inline ::caffe::ParamSpec* LayerParameter::mutable_param(int index) {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.param)
return param_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::ParamSpec >*
LayerParameter::mutable_param() {
// @@protoc_insertion_point(field_mutable_list:caffe.LayerParameter.param)
return ¶m_;
}
inline const ::caffe::ParamSpec& LayerParameter::_internal_param(int index) const {
return param_.Get(index);
}
inline const ::caffe::ParamSpec& LayerParameter::param(int index) const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.param)
return _internal_param(index);
}
inline ::caffe::ParamSpec* LayerParameter::_internal_add_param() {
return param_.Add();
}
inline ::caffe::ParamSpec* LayerParameter::add_param() {
// @@protoc_insertion_point(field_add:caffe.LayerParameter.param)
return _internal_add_param();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::ParamSpec >&
LayerParameter::param() const {
// @@protoc_insertion_point(field_list:caffe.LayerParameter.param)
return param_;
}
// repeated .caffe.BlobProto blobs = 7;
inline int LayerParameter::_internal_blobs_size() const {
return blobs_.size();
}
inline int LayerParameter::blobs_size() const {
return _internal_blobs_size();
}
inline void LayerParameter::clear_blobs() {
blobs_.Clear();
}
inline ::caffe::BlobProto* LayerParameter::mutable_blobs(int index) {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.blobs)
return blobs_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto >*
LayerParameter::mutable_blobs() {
// @@protoc_insertion_point(field_mutable_list:caffe.LayerParameter.blobs)
return &blobs_;
}
inline const ::caffe::BlobProto& LayerParameter::_internal_blobs(int index) const {
return blobs_.Get(index);
}
inline const ::caffe::BlobProto& LayerParameter::blobs(int index) const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.blobs)
return _internal_blobs(index);
}
inline ::caffe::BlobProto* LayerParameter::_internal_add_blobs() {
return blobs_.Add();
}
inline ::caffe::BlobProto* LayerParameter::add_blobs() {
// @@protoc_insertion_point(field_add:caffe.LayerParameter.blobs)
return _internal_add_blobs();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto >&
LayerParameter::blobs() const {
// @@protoc_insertion_point(field_list:caffe.LayerParameter.blobs)
return blobs_;
}
// repeated bool propagate_down = 11;
inline int LayerParameter::_internal_propagate_down_size() const {
return propagate_down_.size();
}
inline int LayerParameter::propagate_down_size() const {
return _internal_propagate_down_size();
}
inline void LayerParameter::clear_propagate_down() {
propagate_down_.Clear();
}
inline bool LayerParameter::_internal_propagate_down(int index) const {
return propagate_down_.Get(index);
}
inline bool LayerParameter::propagate_down(int index) const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.propagate_down)
return _internal_propagate_down(index);
}
inline void LayerParameter::set_propagate_down(int index, bool value) {
propagate_down_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.LayerParameter.propagate_down)
}
inline void LayerParameter::_internal_add_propagate_down(bool value) {
propagate_down_.Add(value);
}
inline void LayerParameter::add_propagate_down(bool value) {
_internal_add_propagate_down(value);
// @@protoc_insertion_point(field_add:caffe.LayerParameter.propagate_down)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< bool >&
LayerParameter::_internal_propagate_down() const {
return propagate_down_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< bool >&
LayerParameter::propagate_down() const {
// @@protoc_insertion_point(field_list:caffe.LayerParameter.propagate_down)
return _internal_propagate_down();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< bool >*
LayerParameter::_internal_mutable_propagate_down() {
return &propagate_down_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< bool >*
LayerParameter::mutable_propagate_down() {
// @@protoc_insertion_point(field_mutable_list:caffe.LayerParameter.propagate_down)
return _internal_mutable_propagate_down();
}
// repeated .caffe.NetStateRule include = 8;
inline int LayerParameter::_internal_include_size() const {
return include_.size();
}
inline int LayerParameter::include_size() const {
return _internal_include_size();
}
inline void LayerParameter::clear_include() {
include_.Clear();
}
inline ::caffe::NetStateRule* LayerParameter::mutable_include(int index) {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.include)
return include_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetStateRule >*
LayerParameter::mutable_include() {
// @@protoc_insertion_point(field_mutable_list:caffe.LayerParameter.include)
return &include_;
}
inline const ::caffe::NetStateRule& LayerParameter::_internal_include(int index) const {
return include_.Get(index);
}
inline const ::caffe::NetStateRule& LayerParameter::include(int index) const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.include)
return _internal_include(index);
}
inline ::caffe::NetStateRule* LayerParameter::_internal_add_include() {
return include_.Add();
}
inline ::caffe::NetStateRule* LayerParameter::add_include() {
// @@protoc_insertion_point(field_add:caffe.LayerParameter.include)
return _internal_add_include();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetStateRule >&
LayerParameter::include() const {
// @@protoc_insertion_point(field_list:caffe.LayerParameter.include)
return include_;
}
// repeated .caffe.NetStateRule exclude = 9;
inline int LayerParameter::_internal_exclude_size() const {
return exclude_.size();
}
inline int LayerParameter::exclude_size() const {
return _internal_exclude_size();
}
inline void LayerParameter::clear_exclude() {
exclude_.Clear();
}
inline ::caffe::NetStateRule* LayerParameter::mutable_exclude(int index) {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.exclude)
return exclude_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetStateRule >*
LayerParameter::mutable_exclude() {
// @@protoc_insertion_point(field_mutable_list:caffe.LayerParameter.exclude)
return &exclude_;
}
inline const ::caffe::NetStateRule& LayerParameter::_internal_exclude(int index) const {
return exclude_.Get(index);
}
inline const ::caffe::NetStateRule& LayerParameter::exclude(int index) const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.exclude)
return _internal_exclude(index);
}
inline ::caffe::NetStateRule* LayerParameter::_internal_add_exclude() {
return exclude_.Add();
}
inline ::caffe::NetStateRule* LayerParameter::add_exclude() {
// @@protoc_insertion_point(field_add:caffe.LayerParameter.exclude)
return _internal_add_exclude();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetStateRule >&
LayerParameter::exclude() const {
// @@protoc_insertion_point(field_list:caffe.LayerParameter.exclude)
return exclude_;
}
// optional .caffe.TransformationParameter transform_param = 100;
inline bool LayerParameter::_internal_has_transform_param() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
PROTOBUF_ASSUME(!value || transform_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_transform_param() const {
return _internal_has_transform_param();
}
inline void LayerParameter::clear_transform_param() {
if (transform_param_ != nullptr) transform_param_->Clear();
_has_bits_[0] &= ~0x00000004u;
}
inline const ::caffe::TransformationParameter& LayerParameter::_internal_transform_param() const {
const ::caffe::TransformationParameter* p = transform_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::TransformationParameter*>(
&::caffe::_TransformationParameter_default_instance_);
}
inline const ::caffe::TransformationParameter& LayerParameter::transform_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.transform_param)
return _internal_transform_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_transform_param(
::caffe::TransformationParameter* transform_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(transform_param_);
}
transform_param_ = transform_param;
if (transform_param) {
_has_bits_[0] |= 0x00000004u;
} else {
_has_bits_[0] &= ~0x00000004u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.transform_param)
}
inline ::caffe::TransformationParameter* LayerParameter::release_transform_param() {
_has_bits_[0] &= ~0x00000004u;
::caffe::TransformationParameter* temp = transform_param_;
transform_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::TransformationParameter* LayerParameter::unsafe_arena_release_transform_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.transform_param)
_has_bits_[0] &= ~0x00000004u;
::caffe::TransformationParameter* temp = transform_param_;
transform_param_ = nullptr;
return temp;
}
inline ::caffe::TransformationParameter* LayerParameter::_internal_mutable_transform_param() {
_has_bits_[0] |= 0x00000004u;
if (transform_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::TransformationParameter>(GetArena());
transform_param_ = p;
}
return transform_param_;
}
inline ::caffe::TransformationParameter* LayerParameter::mutable_transform_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.transform_param)
return _internal_mutable_transform_param();
}
inline void LayerParameter::set_allocated_transform_param(::caffe::TransformationParameter* transform_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete transform_param_;
}
if (transform_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(transform_param);
if (message_arena != submessage_arena) {
transform_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, transform_param, submessage_arena);
}
_has_bits_[0] |= 0x00000004u;
} else {
_has_bits_[0] &= ~0x00000004u;
}
transform_param_ = transform_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.transform_param)
}
// optional .caffe.LossParameter loss_param = 101;
inline bool LayerParameter::_internal_has_loss_param() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
PROTOBUF_ASSUME(!value || loss_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_loss_param() const {
return _internal_has_loss_param();
}
inline void LayerParameter::clear_loss_param() {
if (loss_param_ != nullptr) loss_param_->Clear();
_has_bits_[0] &= ~0x00000008u;
}
inline const ::caffe::LossParameter& LayerParameter::_internal_loss_param() const {
const ::caffe::LossParameter* p = loss_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::LossParameter*>(
&::caffe::_LossParameter_default_instance_);
}
inline const ::caffe::LossParameter& LayerParameter::loss_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.loss_param)
return _internal_loss_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_loss_param(
::caffe::LossParameter* loss_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(loss_param_);
}
loss_param_ = loss_param;
if (loss_param) {
_has_bits_[0] |= 0x00000008u;
} else {
_has_bits_[0] &= ~0x00000008u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.loss_param)
}
inline ::caffe::LossParameter* LayerParameter::release_loss_param() {
_has_bits_[0] &= ~0x00000008u;
::caffe::LossParameter* temp = loss_param_;
loss_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::LossParameter* LayerParameter::unsafe_arena_release_loss_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.loss_param)
_has_bits_[0] &= ~0x00000008u;
::caffe::LossParameter* temp = loss_param_;
loss_param_ = nullptr;
return temp;
}
inline ::caffe::LossParameter* LayerParameter::_internal_mutable_loss_param() {
_has_bits_[0] |= 0x00000008u;
if (loss_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::LossParameter>(GetArena());
loss_param_ = p;
}
return loss_param_;
}
inline ::caffe::LossParameter* LayerParameter::mutable_loss_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.loss_param)
return _internal_mutable_loss_param();
}
inline void LayerParameter::set_allocated_loss_param(::caffe::LossParameter* loss_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete loss_param_;
}
if (loss_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(loss_param);
if (message_arena != submessage_arena) {
loss_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, loss_param, submessage_arena);
}
_has_bits_[0] |= 0x00000008u;
} else {
_has_bits_[0] &= ~0x00000008u;
}
loss_param_ = loss_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.loss_param)
}
// optional .caffe.AccuracyParameter accuracy_param = 102;
inline bool LayerParameter::_internal_has_accuracy_param() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
PROTOBUF_ASSUME(!value || accuracy_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_accuracy_param() const {
return _internal_has_accuracy_param();
}
inline void LayerParameter::clear_accuracy_param() {
if (accuracy_param_ != nullptr) accuracy_param_->Clear();
_has_bits_[0] &= ~0x00000010u;
}
inline const ::caffe::AccuracyParameter& LayerParameter::_internal_accuracy_param() const {
const ::caffe::AccuracyParameter* p = accuracy_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::AccuracyParameter*>(
&::caffe::_AccuracyParameter_default_instance_);
}
inline const ::caffe::AccuracyParameter& LayerParameter::accuracy_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.accuracy_param)
return _internal_accuracy_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_accuracy_param(
::caffe::AccuracyParameter* accuracy_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(accuracy_param_);
}
accuracy_param_ = accuracy_param;
if (accuracy_param) {
_has_bits_[0] |= 0x00000010u;
} else {
_has_bits_[0] &= ~0x00000010u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.accuracy_param)
}
inline ::caffe::AccuracyParameter* LayerParameter::release_accuracy_param() {
_has_bits_[0] &= ~0x00000010u;
::caffe::AccuracyParameter* temp = accuracy_param_;
accuracy_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::AccuracyParameter* LayerParameter::unsafe_arena_release_accuracy_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.accuracy_param)
_has_bits_[0] &= ~0x00000010u;
::caffe::AccuracyParameter* temp = accuracy_param_;
accuracy_param_ = nullptr;
return temp;
}
inline ::caffe::AccuracyParameter* LayerParameter::_internal_mutable_accuracy_param() {
_has_bits_[0] |= 0x00000010u;
if (accuracy_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::AccuracyParameter>(GetArena());
accuracy_param_ = p;
}
return accuracy_param_;
}
inline ::caffe::AccuracyParameter* LayerParameter::mutable_accuracy_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.accuracy_param)
return _internal_mutable_accuracy_param();
}
inline void LayerParameter::set_allocated_accuracy_param(::caffe::AccuracyParameter* accuracy_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete accuracy_param_;
}
if (accuracy_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(accuracy_param);
if (message_arena != submessage_arena) {
accuracy_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, accuracy_param, submessage_arena);
}
_has_bits_[0] |= 0x00000010u;
} else {
_has_bits_[0] &= ~0x00000010u;
}
accuracy_param_ = accuracy_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.accuracy_param)
}
// optional .caffe.AnnotatedDataParameter annotated_data_param = 200;
inline bool LayerParameter::_internal_has_annotated_data_param() const {
bool value = (_has_bits_[1] & 0x00400000u) != 0;
PROTOBUF_ASSUME(!value || annotated_data_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_annotated_data_param() const {
return _internal_has_annotated_data_param();
}
inline void LayerParameter::clear_annotated_data_param() {
if (annotated_data_param_ != nullptr) annotated_data_param_->Clear();
_has_bits_[1] &= ~0x00400000u;
}
inline const ::caffe::AnnotatedDataParameter& LayerParameter::_internal_annotated_data_param() const {
const ::caffe::AnnotatedDataParameter* p = annotated_data_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::AnnotatedDataParameter*>(
&::caffe::_AnnotatedDataParameter_default_instance_);
}
inline const ::caffe::AnnotatedDataParameter& LayerParameter::annotated_data_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.annotated_data_param)
return _internal_annotated_data_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_annotated_data_param(
::caffe::AnnotatedDataParameter* annotated_data_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(annotated_data_param_);
}
annotated_data_param_ = annotated_data_param;
if (annotated_data_param) {
_has_bits_[1] |= 0x00400000u;
} else {
_has_bits_[1] &= ~0x00400000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.annotated_data_param)
}
inline ::caffe::AnnotatedDataParameter* LayerParameter::release_annotated_data_param() {
_has_bits_[1] &= ~0x00400000u;
::caffe::AnnotatedDataParameter* temp = annotated_data_param_;
annotated_data_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::AnnotatedDataParameter* LayerParameter::unsafe_arena_release_annotated_data_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.annotated_data_param)
_has_bits_[1] &= ~0x00400000u;
::caffe::AnnotatedDataParameter* temp = annotated_data_param_;
annotated_data_param_ = nullptr;
return temp;
}
inline ::caffe::AnnotatedDataParameter* LayerParameter::_internal_mutable_annotated_data_param() {
_has_bits_[1] |= 0x00400000u;
if (annotated_data_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::AnnotatedDataParameter>(GetArena());
annotated_data_param_ = p;
}
return annotated_data_param_;
}
inline ::caffe::AnnotatedDataParameter* LayerParameter::mutable_annotated_data_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.annotated_data_param)
return _internal_mutable_annotated_data_param();
}
inline void LayerParameter::set_allocated_annotated_data_param(::caffe::AnnotatedDataParameter* annotated_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete annotated_data_param_;
}
if (annotated_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(annotated_data_param);
if (message_arena != submessage_arena) {
annotated_data_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, annotated_data_param, submessage_arena);
}
_has_bits_[1] |= 0x00400000u;
} else {
_has_bits_[1] &= ~0x00400000u;
}
annotated_data_param_ = annotated_data_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.annotated_data_param)
}
// optional .caffe.ArgMaxParameter argmax_param = 103;
inline bool LayerParameter::_internal_has_argmax_param() const {
bool value = (_has_bits_[0] & 0x00000020u) != 0;
PROTOBUF_ASSUME(!value || argmax_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_argmax_param() const {
return _internal_has_argmax_param();
}
inline void LayerParameter::clear_argmax_param() {
if (argmax_param_ != nullptr) argmax_param_->Clear();
_has_bits_[0] &= ~0x00000020u;
}
inline const ::caffe::ArgMaxParameter& LayerParameter::_internal_argmax_param() const {
const ::caffe::ArgMaxParameter* p = argmax_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ArgMaxParameter*>(
&::caffe::_ArgMaxParameter_default_instance_);
}
inline const ::caffe::ArgMaxParameter& LayerParameter::argmax_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.argmax_param)
return _internal_argmax_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_argmax_param(
::caffe::ArgMaxParameter* argmax_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(argmax_param_);
}
argmax_param_ = argmax_param;
if (argmax_param) {
_has_bits_[0] |= 0x00000020u;
} else {
_has_bits_[0] &= ~0x00000020u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.argmax_param)
}
inline ::caffe::ArgMaxParameter* LayerParameter::release_argmax_param() {
_has_bits_[0] &= ~0x00000020u;
::caffe::ArgMaxParameter* temp = argmax_param_;
argmax_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ArgMaxParameter* LayerParameter::unsafe_arena_release_argmax_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.argmax_param)
_has_bits_[0] &= ~0x00000020u;
::caffe::ArgMaxParameter* temp = argmax_param_;
argmax_param_ = nullptr;
return temp;
}
inline ::caffe::ArgMaxParameter* LayerParameter::_internal_mutable_argmax_param() {
_has_bits_[0] |= 0x00000020u;
if (argmax_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ArgMaxParameter>(GetArena());
argmax_param_ = p;
}
return argmax_param_;
}
inline ::caffe::ArgMaxParameter* LayerParameter::mutable_argmax_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.argmax_param)
return _internal_mutable_argmax_param();
}
inline void LayerParameter::set_allocated_argmax_param(::caffe::ArgMaxParameter* argmax_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete argmax_param_;
}
if (argmax_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(argmax_param);
if (message_arena != submessage_arena) {
argmax_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, argmax_param, submessage_arena);
}
_has_bits_[0] |= 0x00000020u;
} else {
_has_bits_[0] &= ~0x00000020u;
}
argmax_param_ = argmax_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.argmax_param)
}
// optional .caffe.BatchNormParameter batch_norm_param = 139;
inline bool LayerParameter::_internal_has_batch_norm_param() const {
bool value = (_has_bits_[1] & 0x00000200u) != 0;
PROTOBUF_ASSUME(!value || batch_norm_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_batch_norm_param() const {
return _internal_has_batch_norm_param();
}
inline void LayerParameter::clear_batch_norm_param() {
if (batch_norm_param_ != nullptr) batch_norm_param_->Clear();
_has_bits_[1] &= ~0x00000200u;
}
inline const ::caffe::BatchNormParameter& LayerParameter::_internal_batch_norm_param() const {
const ::caffe::BatchNormParameter* p = batch_norm_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::BatchNormParameter*>(
&::caffe::_BatchNormParameter_default_instance_);
}
inline const ::caffe::BatchNormParameter& LayerParameter::batch_norm_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.batch_norm_param)
return _internal_batch_norm_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_batch_norm_param(
::caffe::BatchNormParameter* batch_norm_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(batch_norm_param_);
}
batch_norm_param_ = batch_norm_param;
if (batch_norm_param) {
_has_bits_[1] |= 0x00000200u;
} else {
_has_bits_[1] &= ~0x00000200u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.batch_norm_param)
}
inline ::caffe::BatchNormParameter* LayerParameter::release_batch_norm_param() {
_has_bits_[1] &= ~0x00000200u;
::caffe::BatchNormParameter* temp = batch_norm_param_;
batch_norm_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::BatchNormParameter* LayerParameter::unsafe_arena_release_batch_norm_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.batch_norm_param)
_has_bits_[1] &= ~0x00000200u;
::caffe::BatchNormParameter* temp = batch_norm_param_;
batch_norm_param_ = nullptr;
return temp;
}
inline ::caffe::BatchNormParameter* LayerParameter::_internal_mutable_batch_norm_param() {
_has_bits_[1] |= 0x00000200u;
if (batch_norm_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::BatchNormParameter>(GetArena());
batch_norm_param_ = p;
}
return batch_norm_param_;
}
inline ::caffe::BatchNormParameter* LayerParameter::mutable_batch_norm_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.batch_norm_param)
return _internal_mutable_batch_norm_param();
}
inline void LayerParameter::set_allocated_batch_norm_param(::caffe::BatchNormParameter* batch_norm_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete batch_norm_param_;
}
if (batch_norm_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(batch_norm_param);
if (message_arena != submessage_arena) {
batch_norm_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, batch_norm_param, submessage_arena);
}
_has_bits_[1] |= 0x00000200u;
} else {
_has_bits_[1] &= ~0x00000200u;
}
batch_norm_param_ = batch_norm_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.batch_norm_param)
}
// optional .caffe.BiasParameter bias_param = 141;
inline bool LayerParameter::_internal_has_bias_param() const {
bool value = (_has_bits_[1] & 0x00000800u) != 0;
PROTOBUF_ASSUME(!value || bias_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_bias_param() const {
return _internal_has_bias_param();
}
inline void LayerParameter::clear_bias_param() {
if (bias_param_ != nullptr) bias_param_->Clear();
_has_bits_[1] &= ~0x00000800u;
}
inline const ::caffe::BiasParameter& LayerParameter::_internal_bias_param() const {
const ::caffe::BiasParameter* p = bias_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::BiasParameter*>(
&::caffe::_BiasParameter_default_instance_);
}
inline const ::caffe::BiasParameter& LayerParameter::bias_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.bias_param)
return _internal_bias_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_bias_param(
::caffe::BiasParameter* bias_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(bias_param_);
}
bias_param_ = bias_param;
if (bias_param) {
_has_bits_[1] |= 0x00000800u;
} else {
_has_bits_[1] &= ~0x00000800u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.bias_param)
}
inline ::caffe::BiasParameter* LayerParameter::release_bias_param() {
_has_bits_[1] &= ~0x00000800u;
::caffe::BiasParameter* temp = bias_param_;
bias_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::BiasParameter* LayerParameter::unsafe_arena_release_bias_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.bias_param)
_has_bits_[1] &= ~0x00000800u;
::caffe::BiasParameter* temp = bias_param_;
bias_param_ = nullptr;
return temp;
}
inline ::caffe::BiasParameter* LayerParameter::_internal_mutable_bias_param() {
_has_bits_[1] |= 0x00000800u;
if (bias_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::BiasParameter>(GetArena());
bias_param_ = p;
}
return bias_param_;
}
inline ::caffe::BiasParameter* LayerParameter::mutable_bias_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.bias_param)
return _internal_mutable_bias_param();
}
inline void LayerParameter::set_allocated_bias_param(::caffe::BiasParameter* bias_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete bias_param_;
}
if (bias_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(bias_param);
if (message_arena != submessage_arena) {
bias_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, bias_param, submessage_arena);
}
_has_bits_[1] |= 0x00000800u;
} else {
_has_bits_[1] &= ~0x00000800u;
}
bias_param_ = bias_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.bias_param)
}
// optional .caffe.ConcatParameter concat_param = 104;
inline bool LayerParameter::_internal_has_concat_param() const {
bool value = (_has_bits_[0] & 0x00000040u) != 0;
PROTOBUF_ASSUME(!value || concat_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_concat_param() const {
return _internal_has_concat_param();
}
inline void LayerParameter::clear_concat_param() {
if (concat_param_ != nullptr) concat_param_->Clear();
_has_bits_[0] &= ~0x00000040u;
}
inline const ::caffe::ConcatParameter& LayerParameter::_internal_concat_param() const {
const ::caffe::ConcatParameter* p = concat_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ConcatParameter*>(
&::caffe::_ConcatParameter_default_instance_);
}
inline const ::caffe::ConcatParameter& LayerParameter::concat_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.concat_param)
return _internal_concat_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_concat_param(
::caffe::ConcatParameter* concat_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(concat_param_);
}
concat_param_ = concat_param;
if (concat_param) {
_has_bits_[0] |= 0x00000040u;
} else {
_has_bits_[0] &= ~0x00000040u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.concat_param)
}
inline ::caffe::ConcatParameter* LayerParameter::release_concat_param() {
_has_bits_[0] &= ~0x00000040u;
::caffe::ConcatParameter* temp = concat_param_;
concat_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ConcatParameter* LayerParameter::unsafe_arena_release_concat_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.concat_param)
_has_bits_[0] &= ~0x00000040u;
::caffe::ConcatParameter* temp = concat_param_;
concat_param_ = nullptr;
return temp;
}
inline ::caffe::ConcatParameter* LayerParameter::_internal_mutable_concat_param() {
_has_bits_[0] |= 0x00000040u;
if (concat_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ConcatParameter>(GetArena());
concat_param_ = p;
}
return concat_param_;
}
inline ::caffe::ConcatParameter* LayerParameter::mutable_concat_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.concat_param)
return _internal_mutable_concat_param();
}
inline void LayerParameter::set_allocated_concat_param(::caffe::ConcatParameter* concat_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete concat_param_;
}
if (concat_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(concat_param);
if (message_arena != submessage_arena) {
concat_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, concat_param, submessage_arena);
}
_has_bits_[0] |= 0x00000040u;
} else {
_has_bits_[0] &= ~0x00000040u;
}
concat_param_ = concat_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.concat_param)
}
// optional .caffe.ContrastiveLossParameter contrastive_loss_param = 105;
inline bool LayerParameter::_internal_has_contrastive_loss_param() const {
bool value = (_has_bits_[0] & 0x00000080u) != 0;
PROTOBUF_ASSUME(!value || contrastive_loss_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_contrastive_loss_param() const {
return _internal_has_contrastive_loss_param();
}
inline void LayerParameter::clear_contrastive_loss_param() {
if (contrastive_loss_param_ != nullptr) contrastive_loss_param_->Clear();
_has_bits_[0] &= ~0x00000080u;
}
inline const ::caffe::ContrastiveLossParameter& LayerParameter::_internal_contrastive_loss_param() const {
const ::caffe::ContrastiveLossParameter* p = contrastive_loss_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ContrastiveLossParameter*>(
&::caffe::_ContrastiveLossParameter_default_instance_);
}
inline const ::caffe::ContrastiveLossParameter& LayerParameter::contrastive_loss_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.contrastive_loss_param)
return _internal_contrastive_loss_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_contrastive_loss_param(
::caffe::ContrastiveLossParameter* contrastive_loss_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(contrastive_loss_param_);
}
contrastive_loss_param_ = contrastive_loss_param;
if (contrastive_loss_param) {
_has_bits_[0] |= 0x00000080u;
} else {
_has_bits_[0] &= ~0x00000080u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.contrastive_loss_param)
}
inline ::caffe::ContrastiveLossParameter* LayerParameter::release_contrastive_loss_param() {
_has_bits_[0] &= ~0x00000080u;
::caffe::ContrastiveLossParameter* temp = contrastive_loss_param_;
contrastive_loss_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ContrastiveLossParameter* LayerParameter::unsafe_arena_release_contrastive_loss_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.contrastive_loss_param)
_has_bits_[0] &= ~0x00000080u;
::caffe::ContrastiveLossParameter* temp = contrastive_loss_param_;
contrastive_loss_param_ = nullptr;
return temp;
}
inline ::caffe::ContrastiveLossParameter* LayerParameter::_internal_mutable_contrastive_loss_param() {
_has_bits_[0] |= 0x00000080u;
if (contrastive_loss_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ContrastiveLossParameter>(GetArena());
contrastive_loss_param_ = p;
}
return contrastive_loss_param_;
}
inline ::caffe::ContrastiveLossParameter* LayerParameter::mutable_contrastive_loss_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.contrastive_loss_param)
return _internal_mutable_contrastive_loss_param();
}
inline void LayerParameter::set_allocated_contrastive_loss_param(::caffe::ContrastiveLossParameter* contrastive_loss_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete contrastive_loss_param_;
}
if (contrastive_loss_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(contrastive_loss_param);
if (message_arena != submessage_arena) {
contrastive_loss_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, contrastive_loss_param, submessage_arena);
}
_has_bits_[0] |= 0x00000080u;
} else {
_has_bits_[0] &= ~0x00000080u;
}
contrastive_loss_param_ = contrastive_loss_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.contrastive_loss_param)
}
// optional .caffe.ConvolutionParameter convolution_param = 106;
inline bool LayerParameter::_internal_has_convolution_param() const {
bool value = (_has_bits_[0] & 0x00000100u) != 0;
PROTOBUF_ASSUME(!value || convolution_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_convolution_param() const {
return _internal_has_convolution_param();
}
inline void LayerParameter::clear_convolution_param() {
if (convolution_param_ != nullptr) convolution_param_->Clear();
_has_bits_[0] &= ~0x00000100u;
}
inline const ::caffe::ConvolutionParameter& LayerParameter::_internal_convolution_param() const {
const ::caffe::ConvolutionParameter* p = convolution_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ConvolutionParameter*>(
&::caffe::_ConvolutionParameter_default_instance_);
}
inline const ::caffe::ConvolutionParameter& LayerParameter::convolution_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.convolution_param)
return _internal_convolution_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_convolution_param(
::caffe::ConvolutionParameter* convolution_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(convolution_param_);
}
convolution_param_ = convolution_param;
if (convolution_param) {
_has_bits_[0] |= 0x00000100u;
} else {
_has_bits_[0] &= ~0x00000100u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.convolution_param)
}
inline ::caffe::ConvolutionParameter* LayerParameter::release_convolution_param() {
_has_bits_[0] &= ~0x00000100u;
::caffe::ConvolutionParameter* temp = convolution_param_;
convolution_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ConvolutionParameter* LayerParameter::unsafe_arena_release_convolution_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.convolution_param)
_has_bits_[0] &= ~0x00000100u;
::caffe::ConvolutionParameter* temp = convolution_param_;
convolution_param_ = nullptr;
return temp;
}
inline ::caffe::ConvolutionParameter* LayerParameter::_internal_mutable_convolution_param() {
_has_bits_[0] |= 0x00000100u;
if (convolution_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ConvolutionParameter>(GetArena());
convolution_param_ = p;
}
return convolution_param_;
}
inline ::caffe::ConvolutionParameter* LayerParameter::mutable_convolution_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.convolution_param)
return _internal_mutable_convolution_param();
}
inline void LayerParameter::set_allocated_convolution_param(::caffe::ConvolutionParameter* convolution_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete convolution_param_;
}
if (convolution_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(convolution_param);
if (message_arena != submessage_arena) {
convolution_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, convolution_param, submessage_arena);
}
_has_bits_[0] |= 0x00000100u;
} else {
_has_bits_[0] &= ~0x00000100u;
}
convolution_param_ = convolution_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.convolution_param)
}
// optional .caffe.CropParameter crop_param = 144;
inline bool LayerParameter::_internal_has_crop_param() const {
bool value = (_has_bits_[1] & 0x00004000u) != 0;
PROTOBUF_ASSUME(!value || crop_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_crop_param() const {
return _internal_has_crop_param();
}
inline void LayerParameter::clear_crop_param() {
if (crop_param_ != nullptr) crop_param_->Clear();
_has_bits_[1] &= ~0x00004000u;
}
inline const ::caffe::CropParameter& LayerParameter::_internal_crop_param() const {
const ::caffe::CropParameter* p = crop_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::CropParameter*>(
&::caffe::_CropParameter_default_instance_);
}
inline const ::caffe::CropParameter& LayerParameter::crop_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.crop_param)
return _internal_crop_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_crop_param(
::caffe::CropParameter* crop_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(crop_param_);
}
crop_param_ = crop_param;
if (crop_param) {
_has_bits_[1] |= 0x00004000u;
} else {
_has_bits_[1] &= ~0x00004000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.crop_param)
}
inline ::caffe::CropParameter* LayerParameter::release_crop_param() {
_has_bits_[1] &= ~0x00004000u;
::caffe::CropParameter* temp = crop_param_;
crop_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::CropParameter* LayerParameter::unsafe_arena_release_crop_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.crop_param)
_has_bits_[1] &= ~0x00004000u;
::caffe::CropParameter* temp = crop_param_;
crop_param_ = nullptr;
return temp;
}
inline ::caffe::CropParameter* LayerParameter::_internal_mutable_crop_param() {
_has_bits_[1] |= 0x00004000u;
if (crop_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::CropParameter>(GetArena());
crop_param_ = p;
}
return crop_param_;
}
inline ::caffe::CropParameter* LayerParameter::mutable_crop_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.crop_param)
return _internal_mutable_crop_param();
}
inline void LayerParameter::set_allocated_crop_param(::caffe::CropParameter* crop_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete crop_param_;
}
if (crop_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(crop_param);
if (message_arena != submessage_arena) {
crop_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, crop_param, submessage_arena);
}
_has_bits_[1] |= 0x00004000u;
} else {
_has_bits_[1] &= ~0x00004000u;
}
crop_param_ = crop_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.crop_param)
}
// optional .caffe.DataParameter data_param = 107;
inline bool LayerParameter::_internal_has_data_param() const {
bool value = (_has_bits_[0] & 0x00000200u) != 0;
PROTOBUF_ASSUME(!value || data_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_data_param() const {
return _internal_has_data_param();
}
inline void LayerParameter::clear_data_param() {
if (data_param_ != nullptr) data_param_->Clear();
_has_bits_[0] &= ~0x00000200u;
}
inline const ::caffe::DataParameter& LayerParameter::_internal_data_param() const {
const ::caffe::DataParameter* p = data_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::DataParameter*>(
&::caffe::_DataParameter_default_instance_);
}
inline const ::caffe::DataParameter& LayerParameter::data_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.data_param)
return _internal_data_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_data_param(
::caffe::DataParameter* data_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(data_param_);
}
data_param_ = data_param;
if (data_param) {
_has_bits_[0] |= 0x00000200u;
} else {
_has_bits_[0] &= ~0x00000200u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.data_param)
}
inline ::caffe::DataParameter* LayerParameter::release_data_param() {
_has_bits_[0] &= ~0x00000200u;
::caffe::DataParameter* temp = data_param_;
data_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::DataParameter* LayerParameter::unsafe_arena_release_data_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.data_param)
_has_bits_[0] &= ~0x00000200u;
::caffe::DataParameter* temp = data_param_;
data_param_ = nullptr;
return temp;
}
inline ::caffe::DataParameter* LayerParameter::_internal_mutable_data_param() {
_has_bits_[0] |= 0x00000200u;
if (data_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::DataParameter>(GetArena());
data_param_ = p;
}
return data_param_;
}
inline ::caffe::DataParameter* LayerParameter::mutable_data_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.data_param)
return _internal_mutable_data_param();
}
inline void LayerParameter::set_allocated_data_param(::caffe::DataParameter* data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete data_param_;
}
if (data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(data_param);
if (message_arena != submessage_arena) {
data_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, data_param, submessage_arena);
}
_has_bits_[0] |= 0x00000200u;
} else {
_has_bits_[0] &= ~0x00000200u;
}
data_param_ = data_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.data_param)
}
// optional .caffe.DetectionEvaluateParameter detection_evaluate_param = 205;
inline bool LayerParameter::_internal_has_detection_evaluate_param() const {
bool value = (_has_bits_[1] & 0x08000000u) != 0;
PROTOBUF_ASSUME(!value || detection_evaluate_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_detection_evaluate_param() const {
return _internal_has_detection_evaluate_param();
}
inline void LayerParameter::clear_detection_evaluate_param() {
if (detection_evaluate_param_ != nullptr) detection_evaluate_param_->Clear();
_has_bits_[1] &= ~0x08000000u;
}
inline const ::caffe::DetectionEvaluateParameter& LayerParameter::_internal_detection_evaluate_param() const {
const ::caffe::DetectionEvaluateParameter* p = detection_evaluate_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::DetectionEvaluateParameter*>(
&::caffe::_DetectionEvaluateParameter_default_instance_);
}
inline const ::caffe::DetectionEvaluateParameter& LayerParameter::detection_evaluate_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.detection_evaluate_param)
return _internal_detection_evaluate_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_detection_evaluate_param(
::caffe::DetectionEvaluateParameter* detection_evaluate_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(detection_evaluate_param_);
}
detection_evaluate_param_ = detection_evaluate_param;
if (detection_evaluate_param) {
_has_bits_[1] |= 0x08000000u;
} else {
_has_bits_[1] &= ~0x08000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.detection_evaluate_param)
}
inline ::caffe::DetectionEvaluateParameter* LayerParameter::release_detection_evaluate_param() {
_has_bits_[1] &= ~0x08000000u;
::caffe::DetectionEvaluateParameter* temp = detection_evaluate_param_;
detection_evaluate_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::DetectionEvaluateParameter* LayerParameter::unsafe_arena_release_detection_evaluate_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.detection_evaluate_param)
_has_bits_[1] &= ~0x08000000u;
::caffe::DetectionEvaluateParameter* temp = detection_evaluate_param_;
detection_evaluate_param_ = nullptr;
return temp;
}
inline ::caffe::DetectionEvaluateParameter* LayerParameter::_internal_mutable_detection_evaluate_param() {
_has_bits_[1] |= 0x08000000u;
if (detection_evaluate_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::DetectionEvaluateParameter>(GetArena());
detection_evaluate_param_ = p;
}
return detection_evaluate_param_;
}
inline ::caffe::DetectionEvaluateParameter* LayerParameter::mutable_detection_evaluate_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.detection_evaluate_param)
return _internal_mutable_detection_evaluate_param();
}
inline void LayerParameter::set_allocated_detection_evaluate_param(::caffe::DetectionEvaluateParameter* detection_evaluate_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete detection_evaluate_param_;
}
if (detection_evaluate_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(detection_evaluate_param);
if (message_arena != submessage_arena) {
detection_evaluate_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, detection_evaluate_param, submessage_arena);
}
_has_bits_[1] |= 0x08000000u;
} else {
_has_bits_[1] &= ~0x08000000u;
}
detection_evaluate_param_ = detection_evaluate_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.detection_evaluate_param)
}
// optional .caffe.DetectionOutputParameter detection_output_param = 204;
inline bool LayerParameter::_internal_has_detection_output_param() const {
bool value = (_has_bits_[1] & 0x04000000u) != 0;
PROTOBUF_ASSUME(!value || detection_output_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_detection_output_param() const {
return _internal_has_detection_output_param();
}
inline void LayerParameter::clear_detection_output_param() {
if (detection_output_param_ != nullptr) detection_output_param_->Clear();
_has_bits_[1] &= ~0x04000000u;
}
inline const ::caffe::DetectionOutputParameter& LayerParameter::_internal_detection_output_param() const {
const ::caffe::DetectionOutputParameter* p = detection_output_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::DetectionOutputParameter*>(
&::caffe::_DetectionOutputParameter_default_instance_);
}
inline const ::caffe::DetectionOutputParameter& LayerParameter::detection_output_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.detection_output_param)
return _internal_detection_output_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_detection_output_param(
::caffe::DetectionOutputParameter* detection_output_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(detection_output_param_);
}
detection_output_param_ = detection_output_param;
if (detection_output_param) {
_has_bits_[1] |= 0x04000000u;
} else {
_has_bits_[1] &= ~0x04000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.detection_output_param)
}
inline ::caffe::DetectionOutputParameter* LayerParameter::release_detection_output_param() {
_has_bits_[1] &= ~0x04000000u;
::caffe::DetectionOutputParameter* temp = detection_output_param_;
detection_output_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::DetectionOutputParameter* LayerParameter::unsafe_arena_release_detection_output_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.detection_output_param)
_has_bits_[1] &= ~0x04000000u;
::caffe::DetectionOutputParameter* temp = detection_output_param_;
detection_output_param_ = nullptr;
return temp;
}
inline ::caffe::DetectionOutputParameter* LayerParameter::_internal_mutable_detection_output_param() {
_has_bits_[1] |= 0x04000000u;
if (detection_output_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::DetectionOutputParameter>(GetArena());
detection_output_param_ = p;
}
return detection_output_param_;
}
inline ::caffe::DetectionOutputParameter* LayerParameter::mutable_detection_output_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.detection_output_param)
return _internal_mutable_detection_output_param();
}
inline void LayerParameter::set_allocated_detection_output_param(::caffe::DetectionOutputParameter* detection_output_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete detection_output_param_;
}
if (detection_output_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(detection_output_param);
if (message_arena != submessage_arena) {
detection_output_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, detection_output_param, submessage_arena);
}
_has_bits_[1] |= 0x04000000u;
} else {
_has_bits_[1] &= ~0x04000000u;
}
detection_output_param_ = detection_output_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.detection_output_param)
}
// optional .caffe.DropoutParameter dropout_param = 108;
inline bool LayerParameter::_internal_has_dropout_param() const {
bool value = (_has_bits_[0] & 0x00000400u) != 0;
PROTOBUF_ASSUME(!value || dropout_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_dropout_param() const {
return _internal_has_dropout_param();
}
inline void LayerParameter::clear_dropout_param() {
if (dropout_param_ != nullptr) dropout_param_->Clear();
_has_bits_[0] &= ~0x00000400u;
}
inline const ::caffe::DropoutParameter& LayerParameter::_internal_dropout_param() const {
const ::caffe::DropoutParameter* p = dropout_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::DropoutParameter*>(
&::caffe::_DropoutParameter_default_instance_);
}
inline const ::caffe::DropoutParameter& LayerParameter::dropout_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.dropout_param)
return _internal_dropout_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_dropout_param(
::caffe::DropoutParameter* dropout_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(dropout_param_);
}
dropout_param_ = dropout_param;
if (dropout_param) {
_has_bits_[0] |= 0x00000400u;
} else {
_has_bits_[0] &= ~0x00000400u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.dropout_param)
}
inline ::caffe::DropoutParameter* LayerParameter::release_dropout_param() {
_has_bits_[0] &= ~0x00000400u;
::caffe::DropoutParameter* temp = dropout_param_;
dropout_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::DropoutParameter* LayerParameter::unsafe_arena_release_dropout_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.dropout_param)
_has_bits_[0] &= ~0x00000400u;
::caffe::DropoutParameter* temp = dropout_param_;
dropout_param_ = nullptr;
return temp;
}
inline ::caffe::DropoutParameter* LayerParameter::_internal_mutable_dropout_param() {
_has_bits_[0] |= 0x00000400u;
if (dropout_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::DropoutParameter>(GetArena());
dropout_param_ = p;
}
return dropout_param_;
}
inline ::caffe::DropoutParameter* LayerParameter::mutable_dropout_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.dropout_param)
return _internal_mutable_dropout_param();
}
inline void LayerParameter::set_allocated_dropout_param(::caffe::DropoutParameter* dropout_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete dropout_param_;
}
if (dropout_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(dropout_param);
if (message_arena != submessage_arena) {
dropout_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, dropout_param, submessage_arena);
}
_has_bits_[0] |= 0x00000400u;
} else {
_has_bits_[0] &= ~0x00000400u;
}
dropout_param_ = dropout_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.dropout_param)
}
// optional .caffe.DummyDataParameter dummy_data_param = 109;
inline bool LayerParameter::_internal_has_dummy_data_param() const {
bool value = (_has_bits_[0] & 0x00000800u) != 0;
PROTOBUF_ASSUME(!value || dummy_data_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_dummy_data_param() const {
return _internal_has_dummy_data_param();
}
inline void LayerParameter::clear_dummy_data_param() {
if (dummy_data_param_ != nullptr) dummy_data_param_->Clear();
_has_bits_[0] &= ~0x00000800u;
}
inline const ::caffe::DummyDataParameter& LayerParameter::_internal_dummy_data_param() const {
const ::caffe::DummyDataParameter* p = dummy_data_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::DummyDataParameter*>(
&::caffe::_DummyDataParameter_default_instance_);
}
inline const ::caffe::DummyDataParameter& LayerParameter::dummy_data_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.dummy_data_param)
return _internal_dummy_data_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_dummy_data_param(
::caffe::DummyDataParameter* dummy_data_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(dummy_data_param_);
}
dummy_data_param_ = dummy_data_param;
if (dummy_data_param) {
_has_bits_[0] |= 0x00000800u;
} else {
_has_bits_[0] &= ~0x00000800u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.dummy_data_param)
}
inline ::caffe::DummyDataParameter* LayerParameter::release_dummy_data_param() {
_has_bits_[0] &= ~0x00000800u;
::caffe::DummyDataParameter* temp = dummy_data_param_;
dummy_data_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::DummyDataParameter* LayerParameter::unsafe_arena_release_dummy_data_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.dummy_data_param)
_has_bits_[0] &= ~0x00000800u;
::caffe::DummyDataParameter* temp = dummy_data_param_;
dummy_data_param_ = nullptr;
return temp;
}
inline ::caffe::DummyDataParameter* LayerParameter::_internal_mutable_dummy_data_param() {
_has_bits_[0] |= 0x00000800u;
if (dummy_data_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::DummyDataParameter>(GetArena());
dummy_data_param_ = p;
}
return dummy_data_param_;
}
inline ::caffe::DummyDataParameter* LayerParameter::mutable_dummy_data_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.dummy_data_param)
return _internal_mutable_dummy_data_param();
}
inline void LayerParameter::set_allocated_dummy_data_param(::caffe::DummyDataParameter* dummy_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete dummy_data_param_;
}
if (dummy_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(dummy_data_param);
if (message_arena != submessage_arena) {
dummy_data_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, dummy_data_param, submessage_arena);
}
_has_bits_[0] |= 0x00000800u;
} else {
_has_bits_[0] &= ~0x00000800u;
}
dummy_data_param_ = dummy_data_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.dummy_data_param)
}
// optional .caffe.EltwiseParameter eltwise_param = 110;
inline bool LayerParameter::_internal_has_eltwise_param() const {
bool value = (_has_bits_[0] & 0x00001000u) != 0;
PROTOBUF_ASSUME(!value || eltwise_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_eltwise_param() const {
return _internal_has_eltwise_param();
}
inline void LayerParameter::clear_eltwise_param() {
if (eltwise_param_ != nullptr) eltwise_param_->Clear();
_has_bits_[0] &= ~0x00001000u;
}
inline const ::caffe::EltwiseParameter& LayerParameter::_internal_eltwise_param() const {
const ::caffe::EltwiseParameter* p = eltwise_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::EltwiseParameter*>(
&::caffe::_EltwiseParameter_default_instance_);
}
inline const ::caffe::EltwiseParameter& LayerParameter::eltwise_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.eltwise_param)
return _internal_eltwise_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_eltwise_param(
::caffe::EltwiseParameter* eltwise_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(eltwise_param_);
}
eltwise_param_ = eltwise_param;
if (eltwise_param) {
_has_bits_[0] |= 0x00001000u;
} else {
_has_bits_[0] &= ~0x00001000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.eltwise_param)
}
inline ::caffe::EltwiseParameter* LayerParameter::release_eltwise_param() {
_has_bits_[0] &= ~0x00001000u;
::caffe::EltwiseParameter* temp = eltwise_param_;
eltwise_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::EltwiseParameter* LayerParameter::unsafe_arena_release_eltwise_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.eltwise_param)
_has_bits_[0] &= ~0x00001000u;
::caffe::EltwiseParameter* temp = eltwise_param_;
eltwise_param_ = nullptr;
return temp;
}
inline ::caffe::EltwiseParameter* LayerParameter::_internal_mutable_eltwise_param() {
_has_bits_[0] |= 0x00001000u;
if (eltwise_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::EltwiseParameter>(GetArena());
eltwise_param_ = p;
}
return eltwise_param_;
}
inline ::caffe::EltwiseParameter* LayerParameter::mutable_eltwise_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.eltwise_param)
return _internal_mutable_eltwise_param();
}
inline void LayerParameter::set_allocated_eltwise_param(::caffe::EltwiseParameter* eltwise_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete eltwise_param_;
}
if (eltwise_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(eltwise_param);
if (message_arena != submessage_arena) {
eltwise_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, eltwise_param, submessage_arena);
}
_has_bits_[0] |= 0x00001000u;
} else {
_has_bits_[0] &= ~0x00001000u;
}
eltwise_param_ = eltwise_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.eltwise_param)
}
// optional .caffe.ELUParameter elu_param = 140;
inline bool LayerParameter::_internal_has_elu_param() const {
bool value = (_has_bits_[1] & 0x00000400u) != 0;
PROTOBUF_ASSUME(!value || elu_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_elu_param() const {
return _internal_has_elu_param();
}
inline void LayerParameter::clear_elu_param() {
if (elu_param_ != nullptr) elu_param_->Clear();
_has_bits_[1] &= ~0x00000400u;
}
inline const ::caffe::ELUParameter& LayerParameter::_internal_elu_param() const {
const ::caffe::ELUParameter* p = elu_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ELUParameter*>(
&::caffe::_ELUParameter_default_instance_);
}
inline const ::caffe::ELUParameter& LayerParameter::elu_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.elu_param)
return _internal_elu_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_elu_param(
::caffe::ELUParameter* elu_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(elu_param_);
}
elu_param_ = elu_param;
if (elu_param) {
_has_bits_[1] |= 0x00000400u;
} else {
_has_bits_[1] &= ~0x00000400u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.elu_param)
}
inline ::caffe::ELUParameter* LayerParameter::release_elu_param() {
_has_bits_[1] &= ~0x00000400u;
::caffe::ELUParameter* temp = elu_param_;
elu_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ELUParameter* LayerParameter::unsafe_arena_release_elu_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.elu_param)
_has_bits_[1] &= ~0x00000400u;
::caffe::ELUParameter* temp = elu_param_;
elu_param_ = nullptr;
return temp;
}
inline ::caffe::ELUParameter* LayerParameter::_internal_mutable_elu_param() {
_has_bits_[1] |= 0x00000400u;
if (elu_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ELUParameter>(GetArena());
elu_param_ = p;
}
return elu_param_;
}
inline ::caffe::ELUParameter* LayerParameter::mutable_elu_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.elu_param)
return _internal_mutable_elu_param();
}
inline void LayerParameter::set_allocated_elu_param(::caffe::ELUParameter* elu_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete elu_param_;
}
if (elu_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(elu_param);
if (message_arena != submessage_arena) {
elu_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, elu_param, submessage_arena);
}
_has_bits_[1] |= 0x00000400u;
} else {
_has_bits_[1] &= ~0x00000400u;
}
elu_param_ = elu_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.elu_param)
}
// optional .caffe.EmbedParameter embed_param = 137;
inline bool LayerParameter::_internal_has_embed_param() const {
bool value = (_has_bits_[1] & 0x00000080u) != 0;
PROTOBUF_ASSUME(!value || embed_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_embed_param() const {
return _internal_has_embed_param();
}
inline void LayerParameter::clear_embed_param() {
if (embed_param_ != nullptr) embed_param_->Clear();
_has_bits_[1] &= ~0x00000080u;
}
inline const ::caffe::EmbedParameter& LayerParameter::_internal_embed_param() const {
const ::caffe::EmbedParameter* p = embed_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::EmbedParameter*>(
&::caffe::_EmbedParameter_default_instance_);
}
inline const ::caffe::EmbedParameter& LayerParameter::embed_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.embed_param)
return _internal_embed_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_embed_param(
::caffe::EmbedParameter* embed_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(embed_param_);
}
embed_param_ = embed_param;
if (embed_param) {
_has_bits_[1] |= 0x00000080u;
} else {
_has_bits_[1] &= ~0x00000080u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.embed_param)
}
inline ::caffe::EmbedParameter* LayerParameter::release_embed_param() {
_has_bits_[1] &= ~0x00000080u;
::caffe::EmbedParameter* temp = embed_param_;
embed_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::EmbedParameter* LayerParameter::unsafe_arena_release_embed_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.embed_param)
_has_bits_[1] &= ~0x00000080u;
::caffe::EmbedParameter* temp = embed_param_;
embed_param_ = nullptr;
return temp;
}
inline ::caffe::EmbedParameter* LayerParameter::_internal_mutable_embed_param() {
_has_bits_[1] |= 0x00000080u;
if (embed_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::EmbedParameter>(GetArena());
embed_param_ = p;
}
return embed_param_;
}
inline ::caffe::EmbedParameter* LayerParameter::mutable_embed_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.embed_param)
return _internal_mutable_embed_param();
}
inline void LayerParameter::set_allocated_embed_param(::caffe::EmbedParameter* embed_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete embed_param_;
}
if (embed_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(embed_param);
if (message_arena != submessage_arena) {
embed_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, embed_param, submessage_arena);
}
_has_bits_[1] |= 0x00000080u;
} else {
_has_bits_[1] &= ~0x00000080u;
}
embed_param_ = embed_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.embed_param)
}
// optional .caffe.ExpParameter exp_param = 111;
inline bool LayerParameter::_internal_has_exp_param() const {
bool value = (_has_bits_[0] & 0x00002000u) != 0;
PROTOBUF_ASSUME(!value || exp_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_exp_param() const {
return _internal_has_exp_param();
}
inline void LayerParameter::clear_exp_param() {
if (exp_param_ != nullptr) exp_param_->Clear();
_has_bits_[0] &= ~0x00002000u;
}
inline const ::caffe::ExpParameter& LayerParameter::_internal_exp_param() const {
const ::caffe::ExpParameter* p = exp_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ExpParameter*>(
&::caffe::_ExpParameter_default_instance_);
}
inline const ::caffe::ExpParameter& LayerParameter::exp_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.exp_param)
return _internal_exp_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_exp_param(
::caffe::ExpParameter* exp_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(exp_param_);
}
exp_param_ = exp_param;
if (exp_param) {
_has_bits_[0] |= 0x00002000u;
} else {
_has_bits_[0] &= ~0x00002000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.exp_param)
}
inline ::caffe::ExpParameter* LayerParameter::release_exp_param() {
_has_bits_[0] &= ~0x00002000u;
::caffe::ExpParameter* temp = exp_param_;
exp_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ExpParameter* LayerParameter::unsafe_arena_release_exp_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.exp_param)
_has_bits_[0] &= ~0x00002000u;
::caffe::ExpParameter* temp = exp_param_;
exp_param_ = nullptr;
return temp;
}
inline ::caffe::ExpParameter* LayerParameter::_internal_mutable_exp_param() {
_has_bits_[0] |= 0x00002000u;
if (exp_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ExpParameter>(GetArena());
exp_param_ = p;
}
return exp_param_;
}
inline ::caffe::ExpParameter* LayerParameter::mutable_exp_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.exp_param)
return _internal_mutable_exp_param();
}
inline void LayerParameter::set_allocated_exp_param(::caffe::ExpParameter* exp_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete exp_param_;
}
if (exp_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(exp_param);
if (message_arena != submessage_arena) {
exp_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, exp_param, submessage_arena);
}
_has_bits_[0] |= 0x00002000u;
} else {
_has_bits_[0] &= ~0x00002000u;
}
exp_param_ = exp_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.exp_param)
}
// optional .caffe.FlattenParameter flatten_param = 135;
inline bool LayerParameter::_internal_has_flatten_param() const {
bool value = (_has_bits_[1] & 0x00000020u) != 0;
PROTOBUF_ASSUME(!value || flatten_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_flatten_param() const {
return _internal_has_flatten_param();
}
inline void LayerParameter::clear_flatten_param() {
if (flatten_param_ != nullptr) flatten_param_->Clear();
_has_bits_[1] &= ~0x00000020u;
}
inline const ::caffe::FlattenParameter& LayerParameter::_internal_flatten_param() const {
const ::caffe::FlattenParameter* p = flatten_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::FlattenParameter*>(
&::caffe::_FlattenParameter_default_instance_);
}
inline const ::caffe::FlattenParameter& LayerParameter::flatten_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.flatten_param)
return _internal_flatten_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_flatten_param(
::caffe::FlattenParameter* flatten_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(flatten_param_);
}
flatten_param_ = flatten_param;
if (flatten_param) {
_has_bits_[1] |= 0x00000020u;
} else {
_has_bits_[1] &= ~0x00000020u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.flatten_param)
}
inline ::caffe::FlattenParameter* LayerParameter::release_flatten_param() {
_has_bits_[1] &= ~0x00000020u;
::caffe::FlattenParameter* temp = flatten_param_;
flatten_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::FlattenParameter* LayerParameter::unsafe_arena_release_flatten_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.flatten_param)
_has_bits_[1] &= ~0x00000020u;
::caffe::FlattenParameter* temp = flatten_param_;
flatten_param_ = nullptr;
return temp;
}
inline ::caffe::FlattenParameter* LayerParameter::_internal_mutable_flatten_param() {
_has_bits_[1] |= 0x00000020u;
if (flatten_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::FlattenParameter>(GetArena());
flatten_param_ = p;
}
return flatten_param_;
}
inline ::caffe::FlattenParameter* LayerParameter::mutable_flatten_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.flatten_param)
return _internal_mutable_flatten_param();
}
inline void LayerParameter::set_allocated_flatten_param(::caffe::FlattenParameter* flatten_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete flatten_param_;
}
if (flatten_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(flatten_param);
if (message_arena != submessage_arena) {
flatten_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, flatten_param, submessage_arena);
}
_has_bits_[1] |= 0x00000020u;
} else {
_has_bits_[1] &= ~0x00000020u;
}
flatten_param_ = flatten_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.flatten_param)
}
// optional .caffe.HDF5DataParameter hdf5_data_param = 112;
inline bool LayerParameter::_internal_has_hdf5_data_param() const {
bool value = (_has_bits_[0] & 0x00004000u) != 0;
PROTOBUF_ASSUME(!value || hdf5_data_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_hdf5_data_param() const {
return _internal_has_hdf5_data_param();
}
inline void LayerParameter::clear_hdf5_data_param() {
if (hdf5_data_param_ != nullptr) hdf5_data_param_->Clear();
_has_bits_[0] &= ~0x00004000u;
}
inline const ::caffe::HDF5DataParameter& LayerParameter::_internal_hdf5_data_param() const {
const ::caffe::HDF5DataParameter* p = hdf5_data_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::HDF5DataParameter*>(
&::caffe::_HDF5DataParameter_default_instance_);
}
inline const ::caffe::HDF5DataParameter& LayerParameter::hdf5_data_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.hdf5_data_param)
return _internal_hdf5_data_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_hdf5_data_param(
::caffe::HDF5DataParameter* hdf5_data_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(hdf5_data_param_);
}
hdf5_data_param_ = hdf5_data_param;
if (hdf5_data_param) {
_has_bits_[0] |= 0x00004000u;
} else {
_has_bits_[0] &= ~0x00004000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.hdf5_data_param)
}
inline ::caffe::HDF5DataParameter* LayerParameter::release_hdf5_data_param() {
_has_bits_[0] &= ~0x00004000u;
::caffe::HDF5DataParameter* temp = hdf5_data_param_;
hdf5_data_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::HDF5DataParameter* LayerParameter::unsafe_arena_release_hdf5_data_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.hdf5_data_param)
_has_bits_[0] &= ~0x00004000u;
::caffe::HDF5DataParameter* temp = hdf5_data_param_;
hdf5_data_param_ = nullptr;
return temp;
}
inline ::caffe::HDF5DataParameter* LayerParameter::_internal_mutable_hdf5_data_param() {
_has_bits_[0] |= 0x00004000u;
if (hdf5_data_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::HDF5DataParameter>(GetArena());
hdf5_data_param_ = p;
}
return hdf5_data_param_;
}
inline ::caffe::HDF5DataParameter* LayerParameter::mutable_hdf5_data_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.hdf5_data_param)
return _internal_mutable_hdf5_data_param();
}
inline void LayerParameter::set_allocated_hdf5_data_param(::caffe::HDF5DataParameter* hdf5_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete hdf5_data_param_;
}
if (hdf5_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(hdf5_data_param);
if (message_arena != submessage_arena) {
hdf5_data_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, hdf5_data_param, submessage_arena);
}
_has_bits_[0] |= 0x00004000u;
} else {
_has_bits_[0] &= ~0x00004000u;
}
hdf5_data_param_ = hdf5_data_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.hdf5_data_param)
}
// optional .caffe.HDF5OutputParameter hdf5_output_param = 113;
inline bool LayerParameter::_internal_has_hdf5_output_param() const {
bool value = (_has_bits_[0] & 0x00008000u) != 0;
PROTOBUF_ASSUME(!value || hdf5_output_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_hdf5_output_param() const {
return _internal_has_hdf5_output_param();
}
inline void LayerParameter::clear_hdf5_output_param() {
if (hdf5_output_param_ != nullptr) hdf5_output_param_->Clear();
_has_bits_[0] &= ~0x00008000u;
}
inline const ::caffe::HDF5OutputParameter& LayerParameter::_internal_hdf5_output_param() const {
const ::caffe::HDF5OutputParameter* p = hdf5_output_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::HDF5OutputParameter*>(
&::caffe::_HDF5OutputParameter_default_instance_);
}
inline const ::caffe::HDF5OutputParameter& LayerParameter::hdf5_output_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.hdf5_output_param)
return _internal_hdf5_output_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_hdf5_output_param(
::caffe::HDF5OutputParameter* hdf5_output_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(hdf5_output_param_);
}
hdf5_output_param_ = hdf5_output_param;
if (hdf5_output_param) {
_has_bits_[0] |= 0x00008000u;
} else {
_has_bits_[0] &= ~0x00008000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.hdf5_output_param)
}
inline ::caffe::HDF5OutputParameter* LayerParameter::release_hdf5_output_param() {
_has_bits_[0] &= ~0x00008000u;
::caffe::HDF5OutputParameter* temp = hdf5_output_param_;
hdf5_output_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::HDF5OutputParameter* LayerParameter::unsafe_arena_release_hdf5_output_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.hdf5_output_param)
_has_bits_[0] &= ~0x00008000u;
::caffe::HDF5OutputParameter* temp = hdf5_output_param_;
hdf5_output_param_ = nullptr;
return temp;
}
inline ::caffe::HDF5OutputParameter* LayerParameter::_internal_mutable_hdf5_output_param() {
_has_bits_[0] |= 0x00008000u;
if (hdf5_output_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::HDF5OutputParameter>(GetArena());
hdf5_output_param_ = p;
}
return hdf5_output_param_;
}
inline ::caffe::HDF5OutputParameter* LayerParameter::mutable_hdf5_output_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.hdf5_output_param)
return _internal_mutable_hdf5_output_param();
}
inline void LayerParameter::set_allocated_hdf5_output_param(::caffe::HDF5OutputParameter* hdf5_output_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete hdf5_output_param_;
}
if (hdf5_output_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(hdf5_output_param);
if (message_arena != submessage_arena) {
hdf5_output_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, hdf5_output_param, submessage_arena);
}
_has_bits_[0] |= 0x00008000u;
} else {
_has_bits_[0] &= ~0x00008000u;
}
hdf5_output_param_ = hdf5_output_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.hdf5_output_param)
}
// optional .caffe.HingeLossParameter hinge_loss_param = 114;
inline bool LayerParameter::_internal_has_hinge_loss_param() const {
bool value = (_has_bits_[0] & 0x00010000u) != 0;
PROTOBUF_ASSUME(!value || hinge_loss_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_hinge_loss_param() const {
return _internal_has_hinge_loss_param();
}
inline void LayerParameter::clear_hinge_loss_param() {
if (hinge_loss_param_ != nullptr) hinge_loss_param_->Clear();
_has_bits_[0] &= ~0x00010000u;
}
inline const ::caffe::HingeLossParameter& LayerParameter::_internal_hinge_loss_param() const {
const ::caffe::HingeLossParameter* p = hinge_loss_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::HingeLossParameter*>(
&::caffe::_HingeLossParameter_default_instance_);
}
inline const ::caffe::HingeLossParameter& LayerParameter::hinge_loss_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.hinge_loss_param)
return _internal_hinge_loss_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_hinge_loss_param(
::caffe::HingeLossParameter* hinge_loss_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(hinge_loss_param_);
}
hinge_loss_param_ = hinge_loss_param;
if (hinge_loss_param) {
_has_bits_[0] |= 0x00010000u;
} else {
_has_bits_[0] &= ~0x00010000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.hinge_loss_param)
}
inline ::caffe::HingeLossParameter* LayerParameter::release_hinge_loss_param() {
_has_bits_[0] &= ~0x00010000u;
::caffe::HingeLossParameter* temp = hinge_loss_param_;
hinge_loss_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::HingeLossParameter* LayerParameter::unsafe_arena_release_hinge_loss_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.hinge_loss_param)
_has_bits_[0] &= ~0x00010000u;
::caffe::HingeLossParameter* temp = hinge_loss_param_;
hinge_loss_param_ = nullptr;
return temp;
}
inline ::caffe::HingeLossParameter* LayerParameter::_internal_mutable_hinge_loss_param() {
_has_bits_[0] |= 0x00010000u;
if (hinge_loss_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::HingeLossParameter>(GetArena());
hinge_loss_param_ = p;
}
return hinge_loss_param_;
}
inline ::caffe::HingeLossParameter* LayerParameter::mutable_hinge_loss_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.hinge_loss_param)
return _internal_mutable_hinge_loss_param();
}
inline void LayerParameter::set_allocated_hinge_loss_param(::caffe::HingeLossParameter* hinge_loss_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete hinge_loss_param_;
}
if (hinge_loss_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(hinge_loss_param);
if (message_arena != submessage_arena) {
hinge_loss_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, hinge_loss_param, submessage_arena);
}
_has_bits_[0] |= 0x00010000u;
} else {
_has_bits_[0] &= ~0x00010000u;
}
hinge_loss_param_ = hinge_loss_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.hinge_loss_param)
}
// optional .caffe.ImageDataParameter image_data_param = 115;
inline bool LayerParameter::_internal_has_image_data_param() const {
bool value = (_has_bits_[0] & 0x00020000u) != 0;
PROTOBUF_ASSUME(!value || image_data_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_image_data_param() const {
return _internal_has_image_data_param();
}
inline void LayerParameter::clear_image_data_param() {
if (image_data_param_ != nullptr) image_data_param_->Clear();
_has_bits_[0] &= ~0x00020000u;
}
inline const ::caffe::ImageDataParameter& LayerParameter::_internal_image_data_param() const {
const ::caffe::ImageDataParameter* p = image_data_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ImageDataParameter*>(
&::caffe::_ImageDataParameter_default_instance_);
}
inline const ::caffe::ImageDataParameter& LayerParameter::image_data_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.image_data_param)
return _internal_image_data_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_image_data_param(
::caffe::ImageDataParameter* image_data_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(image_data_param_);
}
image_data_param_ = image_data_param;
if (image_data_param) {
_has_bits_[0] |= 0x00020000u;
} else {
_has_bits_[0] &= ~0x00020000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.image_data_param)
}
inline ::caffe::ImageDataParameter* LayerParameter::release_image_data_param() {
_has_bits_[0] &= ~0x00020000u;
::caffe::ImageDataParameter* temp = image_data_param_;
image_data_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ImageDataParameter* LayerParameter::unsafe_arena_release_image_data_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.image_data_param)
_has_bits_[0] &= ~0x00020000u;
::caffe::ImageDataParameter* temp = image_data_param_;
image_data_param_ = nullptr;
return temp;
}
inline ::caffe::ImageDataParameter* LayerParameter::_internal_mutable_image_data_param() {
_has_bits_[0] |= 0x00020000u;
if (image_data_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ImageDataParameter>(GetArena());
image_data_param_ = p;
}
return image_data_param_;
}
inline ::caffe::ImageDataParameter* LayerParameter::mutable_image_data_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.image_data_param)
return _internal_mutable_image_data_param();
}
inline void LayerParameter::set_allocated_image_data_param(::caffe::ImageDataParameter* image_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete image_data_param_;
}
if (image_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(image_data_param);
if (message_arena != submessage_arena) {
image_data_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, image_data_param, submessage_arena);
}
_has_bits_[0] |= 0x00020000u;
} else {
_has_bits_[0] &= ~0x00020000u;
}
image_data_param_ = image_data_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.image_data_param)
}
// optional .caffe.InfogainLossParameter infogain_loss_param = 116;
inline bool LayerParameter::_internal_has_infogain_loss_param() const {
bool value = (_has_bits_[0] & 0x00040000u) != 0;
PROTOBUF_ASSUME(!value || infogain_loss_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_infogain_loss_param() const {
return _internal_has_infogain_loss_param();
}
inline void LayerParameter::clear_infogain_loss_param() {
if (infogain_loss_param_ != nullptr) infogain_loss_param_->Clear();
_has_bits_[0] &= ~0x00040000u;
}
inline const ::caffe::InfogainLossParameter& LayerParameter::_internal_infogain_loss_param() const {
const ::caffe::InfogainLossParameter* p = infogain_loss_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::InfogainLossParameter*>(
&::caffe::_InfogainLossParameter_default_instance_);
}
inline const ::caffe::InfogainLossParameter& LayerParameter::infogain_loss_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.infogain_loss_param)
return _internal_infogain_loss_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_infogain_loss_param(
::caffe::InfogainLossParameter* infogain_loss_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(infogain_loss_param_);
}
infogain_loss_param_ = infogain_loss_param;
if (infogain_loss_param) {
_has_bits_[0] |= 0x00040000u;
} else {
_has_bits_[0] &= ~0x00040000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.infogain_loss_param)
}
inline ::caffe::InfogainLossParameter* LayerParameter::release_infogain_loss_param() {
_has_bits_[0] &= ~0x00040000u;
::caffe::InfogainLossParameter* temp = infogain_loss_param_;
infogain_loss_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::InfogainLossParameter* LayerParameter::unsafe_arena_release_infogain_loss_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.infogain_loss_param)
_has_bits_[0] &= ~0x00040000u;
::caffe::InfogainLossParameter* temp = infogain_loss_param_;
infogain_loss_param_ = nullptr;
return temp;
}
inline ::caffe::InfogainLossParameter* LayerParameter::_internal_mutable_infogain_loss_param() {
_has_bits_[0] |= 0x00040000u;
if (infogain_loss_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::InfogainLossParameter>(GetArena());
infogain_loss_param_ = p;
}
return infogain_loss_param_;
}
inline ::caffe::InfogainLossParameter* LayerParameter::mutable_infogain_loss_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.infogain_loss_param)
return _internal_mutable_infogain_loss_param();
}
inline void LayerParameter::set_allocated_infogain_loss_param(::caffe::InfogainLossParameter* infogain_loss_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete infogain_loss_param_;
}
if (infogain_loss_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(infogain_loss_param);
if (message_arena != submessage_arena) {
infogain_loss_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, infogain_loss_param, submessage_arena);
}
_has_bits_[0] |= 0x00040000u;
} else {
_has_bits_[0] &= ~0x00040000u;
}
infogain_loss_param_ = infogain_loss_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.infogain_loss_param)
}
// optional .caffe.InnerProductParameter inner_product_param = 117;
inline bool LayerParameter::_internal_has_inner_product_param() const {
bool value = (_has_bits_[0] & 0x00080000u) != 0;
PROTOBUF_ASSUME(!value || inner_product_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_inner_product_param() const {
return _internal_has_inner_product_param();
}
inline void LayerParameter::clear_inner_product_param() {
if (inner_product_param_ != nullptr) inner_product_param_->Clear();
_has_bits_[0] &= ~0x00080000u;
}
inline const ::caffe::InnerProductParameter& LayerParameter::_internal_inner_product_param() const {
const ::caffe::InnerProductParameter* p = inner_product_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::InnerProductParameter*>(
&::caffe::_InnerProductParameter_default_instance_);
}
inline const ::caffe::InnerProductParameter& LayerParameter::inner_product_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.inner_product_param)
return _internal_inner_product_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_inner_product_param(
::caffe::InnerProductParameter* inner_product_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(inner_product_param_);
}
inner_product_param_ = inner_product_param;
if (inner_product_param) {
_has_bits_[0] |= 0x00080000u;
} else {
_has_bits_[0] &= ~0x00080000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.inner_product_param)
}
inline ::caffe::InnerProductParameter* LayerParameter::release_inner_product_param() {
_has_bits_[0] &= ~0x00080000u;
::caffe::InnerProductParameter* temp = inner_product_param_;
inner_product_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::InnerProductParameter* LayerParameter::unsafe_arena_release_inner_product_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.inner_product_param)
_has_bits_[0] &= ~0x00080000u;
::caffe::InnerProductParameter* temp = inner_product_param_;
inner_product_param_ = nullptr;
return temp;
}
inline ::caffe::InnerProductParameter* LayerParameter::_internal_mutable_inner_product_param() {
_has_bits_[0] |= 0x00080000u;
if (inner_product_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::InnerProductParameter>(GetArena());
inner_product_param_ = p;
}
return inner_product_param_;
}
inline ::caffe::InnerProductParameter* LayerParameter::mutable_inner_product_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.inner_product_param)
return _internal_mutable_inner_product_param();
}
inline void LayerParameter::set_allocated_inner_product_param(::caffe::InnerProductParameter* inner_product_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete inner_product_param_;
}
if (inner_product_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(inner_product_param);
if (message_arena != submessage_arena) {
inner_product_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, inner_product_param, submessage_arena);
}
_has_bits_[0] |= 0x00080000u;
} else {
_has_bits_[0] &= ~0x00080000u;
}
inner_product_param_ = inner_product_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.inner_product_param)
}
// optional .caffe.InputParameter input_param = 143;
inline bool LayerParameter::_internal_has_input_param() const {
bool value = (_has_bits_[1] & 0x00002000u) != 0;
PROTOBUF_ASSUME(!value || input_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_input_param() const {
return _internal_has_input_param();
}
inline void LayerParameter::clear_input_param() {
if (input_param_ != nullptr) input_param_->Clear();
_has_bits_[1] &= ~0x00002000u;
}
inline const ::caffe::InputParameter& LayerParameter::_internal_input_param() const {
const ::caffe::InputParameter* p = input_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::InputParameter*>(
&::caffe::_InputParameter_default_instance_);
}
inline const ::caffe::InputParameter& LayerParameter::input_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.input_param)
return _internal_input_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_input_param(
::caffe::InputParameter* input_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(input_param_);
}
input_param_ = input_param;
if (input_param) {
_has_bits_[1] |= 0x00002000u;
} else {
_has_bits_[1] &= ~0x00002000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.input_param)
}
inline ::caffe::InputParameter* LayerParameter::release_input_param() {
_has_bits_[1] &= ~0x00002000u;
::caffe::InputParameter* temp = input_param_;
input_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::InputParameter* LayerParameter::unsafe_arena_release_input_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.input_param)
_has_bits_[1] &= ~0x00002000u;
::caffe::InputParameter* temp = input_param_;
input_param_ = nullptr;
return temp;
}
inline ::caffe::InputParameter* LayerParameter::_internal_mutable_input_param() {
_has_bits_[1] |= 0x00002000u;
if (input_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::InputParameter>(GetArena());
input_param_ = p;
}
return input_param_;
}
inline ::caffe::InputParameter* LayerParameter::mutable_input_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.input_param)
return _internal_mutable_input_param();
}
inline void LayerParameter::set_allocated_input_param(::caffe::InputParameter* input_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete input_param_;
}
if (input_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(input_param);
if (message_arena != submessage_arena) {
input_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, input_param, submessage_arena);
}
_has_bits_[1] |= 0x00002000u;
} else {
_has_bits_[1] &= ~0x00002000u;
}
input_param_ = input_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.input_param)
}
// optional .caffe.LogParameter log_param = 134;
inline bool LayerParameter::_internal_has_log_param() const {
bool value = (_has_bits_[1] & 0x00000010u) != 0;
PROTOBUF_ASSUME(!value || log_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_log_param() const {
return _internal_has_log_param();
}
inline void LayerParameter::clear_log_param() {
if (log_param_ != nullptr) log_param_->Clear();
_has_bits_[1] &= ~0x00000010u;
}
inline const ::caffe::LogParameter& LayerParameter::_internal_log_param() const {
const ::caffe::LogParameter* p = log_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::LogParameter*>(
&::caffe::_LogParameter_default_instance_);
}
inline const ::caffe::LogParameter& LayerParameter::log_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.log_param)
return _internal_log_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_log_param(
::caffe::LogParameter* log_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(log_param_);
}
log_param_ = log_param;
if (log_param) {
_has_bits_[1] |= 0x00000010u;
} else {
_has_bits_[1] &= ~0x00000010u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.log_param)
}
inline ::caffe::LogParameter* LayerParameter::release_log_param() {
_has_bits_[1] &= ~0x00000010u;
::caffe::LogParameter* temp = log_param_;
log_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::LogParameter* LayerParameter::unsafe_arena_release_log_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.log_param)
_has_bits_[1] &= ~0x00000010u;
::caffe::LogParameter* temp = log_param_;
log_param_ = nullptr;
return temp;
}
inline ::caffe::LogParameter* LayerParameter::_internal_mutable_log_param() {
_has_bits_[1] |= 0x00000010u;
if (log_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::LogParameter>(GetArena());
log_param_ = p;
}
return log_param_;
}
inline ::caffe::LogParameter* LayerParameter::mutable_log_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.log_param)
return _internal_mutable_log_param();
}
inline void LayerParameter::set_allocated_log_param(::caffe::LogParameter* log_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete log_param_;
}
if (log_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(log_param);
if (message_arena != submessage_arena) {
log_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, log_param, submessage_arena);
}
_has_bits_[1] |= 0x00000010u;
} else {
_has_bits_[1] &= ~0x00000010u;
}
log_param_ = log_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.log_param)
}
// optional .caffe.LRNParameter lrn_param = 118;
inline bool LayerParameter::_internal_has_lrn_param() const {
bool value = (_has_bits_[0] & 0x00100000u) != 0;
PROTOBUF_ASSUME(!value || lrn_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_lrn_param() const {
return _internal_has_lrn_param();
}
inline void LayerParameter::clear_lrn_param() {
if (lrn_param_ != nullptr) lrn_param_->Clear();
_has_bits_[0] &= ~0x00100000u;
}
inline const ::caffe::LRNParameter& LayerParameter::_internal_lrn_param() const {
const ::caffe::LRNParameter* p = lrn_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::LRNParameter*>(
&::caffe::_LRNParameter_default_instance_);
}
inline const ::caffe::LRNParameter& LayerParameter::lrn_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.lrn_param)
return _internal_lrn_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_lrn_param(
::caffe::LRNParameter* lrn_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(lrn_param_);
}
lrn_param_ = lrn_param;
if (lrn_param) {
_has_bits_[0] |= 0x00100000u;
} else {
_has_bits_[0] &= ~0x00100000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.lrn_param)
}
inline ::caffe::LRNParameter* LayerParameter::release_lrn_param() {
_has_bits_[0] &= ~0x00100000u;
::caffe::LRNParameter* temp = lrn_param_;
lrn_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::LRNParameter* LayerParameter::unsafe_arena_release_lrn_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.lrn_param)
_has_bits_[0] &= ~0x00100000u;
::caffe::LRNParameter* temp = lrn_param_;
lrn_param_ = nullptr;
return temp;
}
inline ::caffe::LRNParameter* LayerParameter::_internal_mutable_lrn_param() {
_has_bits_[0] |= 0x00100000u;
if (lrn_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::LRNParameter>(GetArena());
lrn_param_ = p;
}
return lrn_param_;
}
inline ::caffe::LRNParameter* LayerParameter::mutable_lrn_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.lrn_param)
return _internal_mutable_lrn_param();
}
inline void LayerParameter::set_allocated_lrn_param(::caffe::LRNParameter* lrn_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete lrn_param_;
}
if (lrn_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(lrn_param);
if (message_arena != submessage_arena) {
lrn_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, lrn_param, submessage_arena);
}
_has_bits_[0] |= 0x00100000u;
} else {
_has_bits_[0] &= ~0x00100000u;
}
lrn_param_ = lrn_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.lrn_param)
}
// optional .caffe.MemoryDataParameter memory_data_param = 119;
inline bool LayerParameter::_internal_has_memory_data_param() const {
bool value = (_has_bits_[0] & 0x00200000u) != 0;
PROTOBUF_ASSUME(!value || memory_data_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_memory_data_param() const {
return _internal_has_memory_data_param();
}
inline void LayerParameter::clear_memory_data_param() {
if (memory_data_param_ != nullptr) memory_data_param_->Clear();
_has_bits_[0] &= ~0x00200000u;
}
inline const ::caffe::MemoryDataParameter& LayerParameter::_internal_memory_data_param() const {
const ::caffe::MemoryDataParameter* p = memory_data_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::MemoryDataParameter*>(
&::caffe::_MemoryDataParameter_default_instance_);
}
inline const ::caffe::MemoryDataParameter& LayerParameter::memory_data_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.memory_data_param)
return _internal_memory_data_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_memory_data_param(
::caffe::MemoryDataParameter* memory_data_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(memory_data_param_);
}
memory_data_param_ = memory_data_param;
if (memory_data_param) {
_has_bits_[0] |= 0x00200000u;
} else {
_has_bits_[0] &= ~0x00200000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.memory_data_param)
}
inline ::caffe::MemoryDataParameter* LayerParameter::release_memory_data_param() {
_has_bits_[0] &= ~0x00200000u;
::caffe::MemoryDataParameter* temp = memory_data_param_;
memory_data_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::MemoryDataParameter* LayerParameter::unsafe_arena_release_memory_data_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.memory_data_param)
_has_bits_[0] &= ~0x00200000u;
::caffe::MemoryDataParameter* temp = memory_data_param_;
memory_data_param_ = nullptr;
return temp;
}
inline ::caffe::MemoryDataParameter* LayerParameter::_internal_mutable_memory_data_param() {
_has_bits_[0] |= 0x00200000u;
if (memory_data_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::MemoryDataParameter>(GetArena());
memory_data_param_ = p;
}
return memory_data_param_;
}
inline ::caffe::MemoryDataParameter* LayerParameter::mutable_memory_data_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.memory_data_param)
return _internal_mutable_memory_data_param();
}
inline void LayerParameter::set_allocated_memory_data_param(::caffe::MemoryDataParameter* memory_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete memory_data_param_;
}
if (memory_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(memory_data_param);
if (message_arena != submessage_arena) {
memory_data_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, memory_data_param, submessage_arena);
}
_has_bits_[0] |= 0x00200000u;
} else {
_has_bits_[0] &= ~0x00200000u;
}
memory_data_param_ = memory_data_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.memory_data_param)
}
// optional .caffe.MultiBoxLossParameter multibox_loss_param = 201;
inline bool LayerParameter::_internal_has_multibox_loss_param() const {
bool value = (_has_bits_[1] & 0x00800000u) != 0;
PROTOBUF_ASSUME(!value || multibox_loss_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_multibox_loss_param() const {
return _internal_has_multibox_loss_param();
}
inline void LayerParameter::clear_multibox_loss_param() {
if (multibox_loss_param_ != nullptr) multibox_loss_param_->Clear();
_has_bits_[1] &= ~0x00800000u;
}
inline const ::caffe::MultiBoxLossParameter& LayerParameter::_internal_multibox_loss_param() const {
const ::caffe::MultiBoxLossParameter* p = multibox_loss_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::MultiBoxLossParameter*>(
&::caffe::_MultiBoxLossParameter_default_instance_);
}
inline const ::caffe::MultiBoxLossParameter& LayerParameter::multibox_loss_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.multibox_loss_param)
return _internal_multibox_loss_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_multibox_loss_param(
::caffe::MultiBoxLossParameter* multibox_loss_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(multibox_loss_param_);
}
multibox_loss_param_ = multibox_loss_param;
if (multibox_loss_param) {
_has_bits_[1] |= 0x00800000u;
} else {
_has_bits_[1] &= ~0x00800000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.multibox_loss_param)
}
inline ::caffe::MultiBoxLossParameter* LayerParameter::release_multibox_loss_param() {
_has_bits_[1] &= ~0x00800000u;
::caffe::MultiBoxLossParameter* temp = multibox_loss_param_;
multibox_loss_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::MultiBoxLossParameter* LayerParameter::unsafe_arena_release_multibox_loss_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.multibox_loss_param)
_has_bits_[1] &= ~0x00800000u;
::caffe::MultiBoxLossParameter* temp = multibox_loss_param_;
multibox_loss_param_ = nullptr;
return temp;
}
inline ::caffe::MultiBoxLossParameter* LayerParameter::_internal_mutable_multibox_loss_param() {
_has_bits_[1] |= 0x00800000u;
if (multibox_loss_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::MultiBoxLossParameter>(GetArena());
multibox_loss_param_ = p;
}
return multibox_loss_param_;
}
inline ::caffe::MultiBoxLossParameter* LayerParameter::mutable_multibox_loss_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.multibox_loss_param)
return _internal_mutable_multibox_loss_param();
}
inline void LayerParameter::set_allocated_multibox_loss_param(::caffe::MultiBoxLossParameter* multibox_loss_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete multibox_loss_param_;
}
if (multibox_loss_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(multibox_loss_param);
if (message_arena != submessage_arena) {
multibox_loss_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, multibox_loss_param, submessage_arena);
}
_has_bits_[1] |= 0x00800000u;
} else {
_has_bits_[1] &= ~0x00800000u;
}
multibox_loss_param_ = multibox_loss_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.multibox_loss_param)
}
// optional .caffe.MVNParameter mvn_param = 120;
inline bool LayerParameter::_internal_has_mvn_param() const {
bool value = (_has_bits_[0] & 0x00400000u) != 0;
PROTOBUF_ASSUME(!value || mvn_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_mvn_param() const {
return _internal_has_mvn_param();
}
inline void LayerParameter::clear_mvn_param() {
if (mvn_param_ != nullptr) mvn_param_->Clear();
_has_bits_[0] &= ~0x00400000u;
}
inline const ::caffe::MVNParameter& LayerParameter::_internal_mvn_param() const {
const ::caffe::MVNParameter* p = mvn_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::MVNParameter*>(
&::caffe::_MVNParameter_default_instance_);
}
inline const ::caffe::MVNParameter& LayerParameter::mvn_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.mvn_param)
return _internal_mvn_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_mvn_param(
::caffe::MVNParameter* mvn_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(mvn_param_);
}
mvn_param_ = mvn_param;
if (mvn_param) {
_has_bits_[0] |= 0x00400000u;
} else {
_has_bits_[0] &= ~0x00400000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.mvn_param)
}
inline ::caffe::MVNParameter* LayerParameter::release_mvn_param() {
_has_bits_[0] &= ~0x00400000u;
::caffe::MVNParameter* temp = mvn_param_;
mvn_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::MVNParameter* LayerParameter::unsafe_arena_release_mvn_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.mvn_param)
_has_bits_[0] &= ~0x00400000u;
::caffe::MVNParameter* temp = mvn_param_;
mvn_param_ = nullptr;
return temp;
}
inline ::caffe::MVNParameter* LayerParameter::_internal_mutable_mvn_param() {
_has_bits_[0] |= 0x00400000u;
if (mvn_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::MVNParameter>(GetArena());
mvn_param_ = p;
}
return mvn_param_;
}
inline ::caffe::MVNParameter* LayerParameter::mutable_mvn_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.mvn_param)
return _internal_mutable_mvn_param();
}
inline void LayerParameter::set_allocated_mvn_param(::caffe::MVNParameter* mvn_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete mvn_param_;
}
if (mvn_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(mvn_param);
if (message_arena != submessage_arena) {
mvn_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, mvn_param, submessage_arena);
}
_has_bits_[0] |= 0x00400000u;
} else {
_has_bits_[0] &= ~0x00400000u;
}
mvn_param_ = mvn_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.mvn_param)
}
// optional .caffe.NormalizeParameter norm_param = 206;
inline bool LayerParameter::_internal_has_norm_param() const {
bool value = (_has_bits_[1] & 0x10000000u) != 0;
PROTOBUF_ASSUME(!value || norm_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_norm_param() const {
return _internal_has_norm_param();
}
inline void LayerParameter::clear_norm_param() {
if (norm_param_ != nullptr) norm_param_->Clear();
_has_bits_[1] &= ~0x10000000u;
}
inline const ::caffe::NormalizeParameter& LayerParameter::_internal_norm_param() const {
const ::caffe::NormalizeParameter* p = norm_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::NormalizeParameter*>(
&::caffe::_NormalizeParameter_default_instance_);
}
inline const ::caffe::NormalizeParameter& LayerParameter::norm_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.norm_param)
return _internal_norm_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_norm_param(
::caffe::NormalizeParameter* norm_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(norm_param_);
}
norm_param_ = norm_param;
if (norm_param) {
_has_bits_[1] |= 0x10000000u;
} else {
_has_bits_[1] &= ~0x10000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.norm_param)
}
inline ::caffe::NormalizeParameter* LayerParameter::release_norm_param() {
_has_bits_[1] &= ~0x10000000u;
::caffe::NormalizeParameter* temp = norm_param_;
norm_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::NormalizeParameter* LayerParameter::unsafe_arena_release_norm_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.norm_param)
_has_bits_[1] &= ~0x10000000u;
::caffe::NormalizeParameter* temp = norm_param_;
norm_param_ = nullptr;
return temp;
}
inline ::caffe::NormalizeParameter* LayerParameter::_internal_mutable_norm_param() {
_has_bits_[1] |= 0x10000000u;
if (norm_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::NormalizeParameter>(GetArena());
norm_param_ = p;
}
return norm_param_;
}
inline ::caffe::NormalizeParameter* LayerParameter::mutable_norm_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.norm_param)
return _internal_mutable_norm_param();
}
inline void LayerParameter::set_allocated_norm_param(::caffe::NormalizeParameter* norm_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete norm_param_;
}
if (norm_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(norm_param);
if (message_arena != submessage_arena) {
norm_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, norm_param, submessage_arena);
}
_has_bits_[1] |= 0x10000000u;
} else {
_has_bits_[1] &= ~0x10000000u;
}
norm_param_ = norm_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.norm_param)
}
// optional .caffe.ParameterParameter parameter_param = 145;
inline bool LayerParameter::_internal_has_parameter_param() const {
bool value = (_has_bits_[1] & 0x00008000u) != 0;
PROTOBUF_ASSUME(!value || parameter_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_parameter_param() const {
return _internal_has_parameter_param();
}
inline void LayerParameter::clear_parameter_param() {
if (parameter_param_ != nullptr) parameter_param_->Clear();
_has_bits_[1] &= ~0x00008000u;
}
inline const ::caffe::ParameterParameter& LayerParameter::_internal_parameter_param() const {
const ::caffe::ParameterParameter* p = parameter_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ParameterParameter*>(
&::caffe::_ParameterParameter_default_instance_);
}
inline const ::caffe::ParameterParameter& LayerParameter::parameter_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.parameter_param)
return _internal_parameter_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_parameter_param(
::caffe::ParameterParameter* parameter_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(parameter_param_);
}
parameter_param_ = parameter_param;
if (parameter_param) {
_has_bits_[1] |= 0x00008000u;
} else {
_has_bits_[1] &= ~0x00008000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.parameter_param)
}
inline ::caffe::ParameterParameter* LayerParameter::release_parameter_param() {
_has_bits_[1] &= ~0x00008000u;
::caffe::ParameterParameter* temp = parameter_param_;
parameter_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ParameterParameter* LayerParameter::unsafe_arena_release_parameter_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.parameter_param)
_has_bits_[1] &= ~0x00008000u;
::caffe::ParameterParameter* temp = parameter_param_;
parameter_param_ = nullptr;
return temp;
}
inline ::caffe::ParameterParameter* LayerParameter::_internal_mutable_parameter_param() {
_has_bits_[1] |= 0x00008000u;
if (parameter_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ParameterParameter>(GetArena());
parameter_param_ = p;
}
return parameter_param_;
}
inline ::caffe::ParameterParameter* LayerParameter::mutable_parameter_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.parameter_param)
return _internal_mutable_parameter_param();
}
inline void LayerParameter::set_allocated_parameter_param(::caffe::ParameterParameter* parameter_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete parameter_param_;
}
if (parameter_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(parameter_param);
if (message_arena != submessage_arena) {
parameter_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, parameter_param, submessage_arena);
}
_has_bits_[1] |= 0x00008000u;
} else {
_has_bits_[1] &= ~0x00008000u;
}
parameter_param_ = parameter_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.parameter_param)
}
// optional .caffe.PermuteParameter permute_param = 202;
inline bool LayerParameter::_internal_has_permute_param() const {
bool value = (_has_bits_[1] & 0x01000000u) != 0;
PROTOBUF_ASSUME(!value || permute_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_permute_param() const {
return _internal_has_permute_param();
}
inline void LayerParameter::clear_permute_param() {
if (permute_param_ != nullptr) permute_param_->Clear();
_has_bits_[1] &= ~0x01000000u;
}
inline const ::caffe::PermuteParameter& LayerParameter::_internal_permute_param() const {
const ::caffe::PermuteParameter* p = permute_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::PermuteParameter*>(
&::caffe::_PermuteParameter_default_instance_);
}
inline const ::caffe::PermuteParameter& LayerParameter::permute_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.permute_param)
return _internal_permute_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_permute_param(
::caffe::PermuteParameter* permute_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(permute_param_);
}
permute_param_ = permute_param;
if (permute_param) {
_has_bits_[1] |= 0x01000000u;
} else {
_has_bits_[1] &= ~0x01000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.permute_param)
}
inline ::caffe::PermuteParameter* LayerParameter::release_permute_param() {
_has_bits_[1] &= ~0x01000000u;
::caffe::PermuteParameter* temp = permute_param_;
permute_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::PermuteParameter* LayerParameter::unsafe_arena_release_permute_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.permute_param)
_has_bits_[1] &= ~0x01000000u;
::caffe::PermuteParameter* temp = permute_param_;
permute_param_ = nullptr;
return temp;
}
inline ::caffe::PermuteParameter* LayerParameter::_internal_mutable_permute_param() {
_has_bits_[1] |= 0x01000000u;
if (permute_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::PermuteParameter>(GetArena());
permute_param_ = p;
}
return permute_param_;
}
inline ::caffe::PermuteParameter* LayerParameter::mutable_permute_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.permute_param)
return _internal_mutable_permute_param();
}
inline void LayerParameter::set_allocated_permute_param(::caffe::PermuteParameter* permute_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete permute_param_;
}
if (permute_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(permute_param);
if (message_arena != submessage_arena) {
permute_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, permute_param, submessage_arena);
}
_has_bits_[1] |= 0x01000000u;
} else {
_has_bits_[1] &= ~0x01000000u;
}
permute_param_ = permute_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.permute_param)
}
// optional .caffe.PoolingParameter pooling_param = 121;
inline bool LayerParameter::_internal_has_pooling_param() const {
bool value = (_has_bits_[0] & 0x00800000u) != 0;
PROTOBUF_ASSUME(!value || pooling_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_pooling_param() const {
return _internal_has_pooling_param();
}
inline void LayerParameter::clear_pooling_param() {
if (pooling_param_ != nullptr) pooling_param_->Clear();
_has_bits_[0] &= ~0x00800000u;
}
inline const ::caffe::PoolingParameter& LayerParameter::_internal_pooling_param() const {
const ::caffe::PoolingParameter* p = pooling_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::PoolingParameter*>(
&::caffe::_PoolingParameter_default_instance_);
}
inline const ::caffe::PoolingParameter& LayerParameter::pooling_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.pooling_param)
return _internal_pooling_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_pooling_param(
::caffe::PoolingParameter* pooling_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(pooling_param_);
}
pooling_param_ = pooling_param;
if (pooling_param) {
_has_bits_[0] |= 0x00800000u;
} else {
_has_bits_[0] &= ~0x00800000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.pooling_param)
}
inline ::caffe::PoolingParameter* LayerParameter::release_pooling_param() {
_has_bits_[0] &= ~0x00800000u;
::caffe::PoolingParameter* temp = pooling_param_;
pooling_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::PoolingParameter* LayerParameter::unsafe_arena_release_pooling_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.pooling_param)
_has_bits_[0] &= ~0x00800000u;
::caffe::PoolingParameter* temp = pooling_param_;
pooling_param_ = nullptr;
return temp;
}
inline ::caffe::PoolingParameter* LayerParameter::_internal_mutable_pooling_param() {
_has_bits_[0] |= 0x00800000u;
if (pooling_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::PoolingParameter>(GetArena());
pooling_param_ = p;
}
return pooling_param_;
}
inline ::caffe::PoolingParameter* LayerParameter::mutable_pooling_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.pooling_param)
return _internal_mutable_pooling_param();
}
inline void LayerParameter::set_allocated_pooling_param(::caffe::PoolingParameter* pooling_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete pooling_param_;
}
if (pooling_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(pooling_param);
if (message_arena != submessage_arena) {
pooling_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, pooling_param, submessage_arena);
}
_has_bits_[0] |= 0x00800000u;
} else {
_has_bits_[0] &= ~0x00800000u;
}
pooling_param_ = pooling_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.pooling_param)
}
// optional .caffe.PowerParameter power_param = 122;
inline bool LayerParameter::_internal_has_power_param() const {
bool value = (_has_bits_[0] & 0x01000000u) != 0;
PROTOBUF_ASSUME(!value || power_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_power_param() const {
return _internal_has_power_param();
}
inline void LayerParameter::clear_power_param() {
if (power_param_ != nullptr) power_param_->Clear();
_has_bits_[0] &= ~0x01000000u;
}
inline const ::caffe::PowerParameter& LayerParameter::_internal_power_param() const {
const ::caffe::PowerParameter* p = power_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::PowerParameter*>(
&::caffe::_PowerParameter_default_instance_);
}
inline const ::caffe::PowerParameter& LayerParameter::power_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.power_param)
return _internal_power_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_power_param(
::caffe::PowerParameter* power_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(power_param_);
}
power_param_ = power_param;
if (power_param) {
_has_bits_[0] |= 0x01000000u;
} else {
_has_bits_[0] &= ~0x01000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.power_param)
}
inline ::caffe::PowerParameter* LayerParameter::release_power_param() {
_has_bits_[0] &= ~0x01000000u;
::caffe::PowerParameter* temp = power_param_;
power_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::PowerParameter* LayerParameter::unsafe_arena_release_power_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.power_param)
_has_bits_[0] &= ~0x01000000u;
::caffe::PowerParameter* temp = power_param_;
power_param_ = nullptr;
return temp;
}
inline ::caffe::PowerParameter* LayerParameter::_internal_mutable_power_param() {
_has_bits_[0] |= 0x01000000u;
if (power_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::PowerParameter>(GetArena());
power_param_ = p;
}
return power_param_;
}
inline ::caffe::PowerParameter* LayerParameter::mutable_power_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.power_param)
return _internal_mutable_power_param();
}
inline void LayerParameter::set_allocated_power_param(::caffe::PowerParameter* power_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete power_param_;
}
if (power_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(power_param);
if (message_arena != submessage_arena) {
power_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, power_param, submessage_arena);
}
_has_bits_[0] |= 0x01000000u;
} else {
_has_bits_[0] &= ~0x01000000u;
}
power_param_ = power_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.power_param)
}
// optional .caffe.PReLUParameter prelu_param = 131;
inline bool LayerParameter::_internal_has_prelu_param() const {
bool value = (_has_bits_[1] & 0x00000002u) != 0;
PROTOBUF_ASSUME(!value || prelu_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_prelu_param() const {
return _internal_has_prelu_param();
}
inline void LayerParameter::clear_prelu_param() {
if (prelu_param_ != nullptr) prelu_param_->Clear();
_has_bits_[1] &= ~0x00000002u;
}
inline const ::caffe::PReLUParameter& LayerParameter::_internal_prelu_param() const {
const ::caffe::PReLUParameter* p = prelu_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::PReLUParameter*>(
&::caffe::_PReLUParameter_default_instance_);
}
inline const ::caffe::PReLUParameter& LayerParameter::prelu_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.prelu_param)
return _internal_prelu_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_prelu_param(
::caffe::PReLUParameter* prelu_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(prelu_param_);
}
prelu_param_ = prelu_param;
if (prelu_param) {
_has_bits_[1] |= 0x00000002u;
} else {
_has_bits_[1] &= ~0x00000002u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.prelu_param)
}
inline ::caffe::PReLUParameter* LayerParameter::release_prelu_param() {
_has_bits_[1] &= ~0x00000002u;
::caffe::PReLUParameter* temp = prelu_param_;
prelu_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::PReLUParameter* LayerParameter::unsafe_arena_release_prelu_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.prelu_param)
_has_bits_[1] &= ~0x00000002u;
::caffe::PReLUParameter* temp = prelu_param_;
prelu_param_ = nullptr;
return temp;
}
inline ::caffe::PReLUParameter* LayerParameter::_internal_mutable_prelu_param() {
_has_bits_[1] |= 0x00000002u;
if (prelu_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::PReLUParameter>(GetArena());
prelu_param_ = p;
}
return prelu_param_;
}
inline ::caffe::PReLUParameter* LayerParameter::mutable_prelu_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.prelu_param)
return _internal_mutable_prelu_param();
}
inline void LayerParameter::set_allocated_prelu_param(::caffe::PReLUParameter* prelu_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete prelu_param_;
}
if (prelu_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(prelu_param);
if (message_arena != submessage_arena) {
prelu_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, prelu_param, submessage_arena);
}
_has_bits_[1] |= 0x00000002u;
} else {
_has_bits_[1] &= ~0x00000002u;
}
prelu_param_ = prelu_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.prelu_param)
}
// optional .caffe.PriorBoxParameter prior_box_param = 203;
inline bool LayerParameter::_internal_has_prior_box_param() const {
bool value = (_has_bits_[1] & 0x02000000u) != 0;
PROTOBUF_ASSUME(!value || prior_box_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_prior_box_param() const {
return _internal_has_prior_box_param();
}
inline void LayerParameter::clear_prior_box_param() {
if (prior_box_param_ != nullptr) prior_box_param_->Clear();
_has_bits_[1] &= ~0x02000000u;
}
inline const ::caffe::PriorBoxParameter& LayerParameter::_internal_prior_box_param() const {
const ::caffe::PriorBoxParameter* p = prior_box_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::PriorBoxParameter*>(
&::caffe::_PriorBoxParameter_default_instance_);
}
inline const ::caffe::PriorBoxParameter& LayerParameter::prior_box_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.prior_box_param)
return _internal_prior_box_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_prior_box_param(
::caffe::PriorBoxParameter* prior_box_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(prior_box_param_);
}
prior_box_param_ = prior_box_param;
if (prior_box_param) {
_has_bits_[1] |= 0x02000000u;
} else {
_has_bits_[1] &= ~0x02000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.prior_box_param)
}
inline ::caffe::PriorBoxParameter* LayerParameter::release_prior_box_param() {
_has_bits_[1] &= ~0x02000000u;
::caffe::PriorBoxParameter* temp = prior_box_param_;
prior_box_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::PriorBoxParameter* LayerParameter::unsafe_arena_release_prior_box_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.prior_box_param)
_has_bits_[1] &= ~0x02000000u;
::caffe::PriorBoxParameter* temp = prior_box_param_;
prior_box_param_ = nullptr;
return temp;
}
inline ::caffe::PriorBoxParameter* LayerParameter::_internal_mutable_prior_box_param() {
_has_bits_[1] |= 0x02000000u;
if (prior_box_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::PriorBoxParameter>(GetArena());
prior_box_param_ = p;
}
return prior_box_param_;
}
inline ::caffe::PriorBoxParameter* LayerParameter::mutable_prior_box_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.prior_box_param)
return _internal_mutable_prior_box_param();
}
inline void LayerParameter::set_allocated_prior_box_param(::caffe::PriorBoxParameter* prior_box_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete prior_box_param_;
}
if (prior_box_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(prior_box_param);
if (message_arena != submessage_arena) {
prior_box_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, prior_box_param, submessage_arena);
}
_has_bits_[1] |= 0x02000000u;
} else {
_has_bits_[1] &= ~0x02000000u;
}
prior_box_param_ = prior_box_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.prior_box_param)
}
// optional .caffe.PythonParameter python_param = 130;
inline bool LayerParameter::_internal_has_python_param() const {
bool value = (_has_bits_[1] & 0x00000001u) != 0;
PROTOBUF_ASSUME(!value || python_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_python_param() const {
return _internal_has_python_param();
}
inline void LayerParameter::clear_python_param() {
if (python_param_ != nullptr) python_param_->Clear();
_has_bits_[1] &= ~0x00000001u;
}
inline const ::caffe::PythonParameter& LayerParameter::_internal_python_param() const {
const ::caffe::PythonParameter* p = python_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::PythonParameter*>(
&::caffe::_PythonParameter_default_instance_);
}
inline const ::caffe::PythonParameter& LayerParameter::python_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.python_param)
return _internal_python_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_python_param(
::caffe::PythonParameter* python_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(python_param_);
}
python_param_ = python_param;
if (python_param) {
_has_bits_[1] |= 0x00000001u;
} else {
_has_bits_[1] &= ~0x00000001u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.python_param)
}
inline ::caffe::PythonParameter* LayerParameter::release_python_param() {
_has_bits_[1] &= ~0x00000001u;
::caffe::PythonParameter* temp = python_param_;
python_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::PythonParameter* LayerParameter::unsafe_arena_release_python_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.python_param)
_has_bits_[1] &= ~0x00000001u;
::caffe::PythonParameter* temp = python_param_;
python_param_ = nullptr;
return temp;
}
inline ::caffe::PythonParameter* LayerParameter::_internal_mutable_python_param() {
_has_bits_[1] |= 0x00000001u;
if (python_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::PythonParameter>(GetArena());
python_param_ = p;
}
return python_param_;
}
inline ::caffe::PythonParameter* LayerParameter::mutable_python_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.python_param)
return _internal_mutable_python_param();
}
inline void LayerParameter::set_allocated_python_param(::caffe::PythonParameter* python_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete python_param_;
}
if (python_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(python_param);
if (message_arena != submessage_arena) {
python_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, python_param, submessage_arena);
}
_has_bits_[1] |= 0x00000001u;
} else {
_has_bits_[1] &= ~0x00000001u;
}
python_param_ = python_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.python_param)
}
// optional .caffe.RecurrentParameter recurrent_param = 146;
inline bool LayerParameter::_internal_has_recurrent_param() const {
bool value = (_has_bits_[1] & 0x00010000u) != 0;
PROTOBUF_ASSUME(!value || recurrent_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_recurrent_param() const {
return _internal_has_recurrent_param();
}
inline void LayerParameter::clear_recurrent_param() {
if (recurrent_param_ != nullptr) recurrent_param_->Clear();
_has_bits_[1] &= ~0x00010000u;
}
inline const ::caffe::RecurrentParameter& LayerParameter::_internal_recurrent_param() const {
const ::caffe::RecurrentParameter* p = recurrent_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::RecurrentParameter*>(
&::caffe::_RecurrentParameter_default_instance_);
}
inline const ::caffe::RecurrentParameter& LayerParameter::recurrent_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.recurrent_param)
return _internal_recurrent_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_recurrent_param(
::caffe::RecurrentParameter* recurrent_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(recurrent_param_);
}
recurrent_param_ = recurrent_param;
if (recurrent_param) {
_has_bits_[1] |= 0x00010000u;
} else {
_has_bits_[1] &= ~0x00010000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.recurrent_param)
}
inline ::caffe::RecurrentParameter* LayerParameter::release_recurrent_param() {
_has_bits_[1] &= ~0x00010000u;
::caffe::RecurrentParameter* temp = recurrent_param_;
recurrent_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::RecurrentParameter* LayerParameter::unsafe_arena_release_recurrent_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.recurrent_param)
_has_bits_[1] &= ~0x00010000u;
::caffe::RecurrentParameter* temp = recurrent_param_;
recurrent_param_ = nullptr;
return temp;
}
inline ::caffe::RecurrentParameter* LayerParameter::_internal_mutable_recurrent_param() {
_has_bits_[1] |= 0x00010000u;
if (recurrent_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::RecurrentParameter>(GetArena());
recurrent_param_ = p;
}
return recurrent_param_;
}
inline ::caffe::RecurrentParameter* LayerParameter::mutable_recurrent_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.recurrent_param)
return _internal_mutable_recurrent_param();
}
inline void LayerParameter::set_allocated_recurrent_param(::caffe::RecurrentParameter* recurrent_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete recurrent_param_;
}
if (recurrent_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(recurrent_param);
if (message_arena != submessage_arena) {
recurrent_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, recurrent_param, submessage_arena);
}
_has_bits_[1] |= 0x00010000u;
} else {
_has_bits_[1] &= ~0x00010000u;
}
recurrent_param_ = recurrent_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.recurrent_param)
}
// optional .caffe.ReductionParameter reduction_param = 136;
inline bool LayerParameter::_internal_has_reduction_param() const {
bool value = (_has_bits_[1] & 0x00000040u) != 0;
PROTOBUF_ASSUME(!value || reduction_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_reduction_param() const {
return _internal_has_reduction_param();
}
inline void LayerParameter::clear_reduction_param() {
if (reduction_param_ != nullptr) reduction_param_->Clear();
_has_bits_[1] &= ~0x00000040u;
}
inline const ::caffe::ReductionParameter& LayerParameter::_internal_reduction_param() const {
const ::caffe::ReductionParameter* p = reduction_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ReductionParameter*>(
&::caffe::_ReductionParameter_default_instance_);
}
inline const ::caffe::ReductionParameter& LayerParameter::reduction_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.reduction_param)
return _internal_reduction_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_reduction_param(
::caffe::ReductionParameter* reduction_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(reduction_param_);
}
reduction_param_ = reduction_param;
if (reduction_param) {
_has_bits_[1] |= 0x00000040u;
} else {
_has_bits_[1] &= ~0x00000040u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.reduction_param)
}
inline ::caffe::ReductionParameter* LayerParameter::release_reduction_param() {
_has_bits_[1] &= ~0x00000040u;
::caffe::ReductionParameter* temp = reduction_param_;
reduction_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ReductionParameter* LayerParameter::unsafe_arena_release_reduction_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.reduction_param)
_has_bits_[1] &= ~0x00000040u;
::caffe::ReductionParameter* temp = reduction_param_;
reduction_param_ = nullptr;
return temp;
}
inline ::caffe::ReductionParameter* LayerParameter::_internal_mutable_reduction_param() {
_has_bits_[1] |= 0x00000040u;
if (reduction_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ReductionParameter>(GetArena());
reduction_param_ = p;
}
return reduction_param_;
}
inline ::caffe::ReductionParameter* LayerParameter::mutable_reduction_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.reduction_param)
return _internal_mutable_reduction_param();
}
inline void LayerParameter::set_allocated_reduction_param(::caffe::ReductionParameter* reduction_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete reduction_param_;
}
if (reduction_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(reduction_param);
if (message_arena != submessage_arena) {
reduction_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, reduction_param, submessage_arena);
}
_has_bits_[1] |= 0x00000040u;
} else {
_has_bits_[1] &= ~0x00000040u;
}
reduction_param_ = reduction_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.reduction_param)
}
// optional .caffe.ReLUParameter relu_param = 123;
inline bool LayerParameter::_internal_has_relu_param() const {
bool value = (_has_bits_[0] & 0x02000000u) != 0;
PROTOBUF_ASSUME(!value || relu_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_relu_param() const {
return _internal_has_relu_param();
}
inline void LayerParameter::clear_relu_param() {
if (relu_param_ != nullptr) relu_param_->Clear();
_has_bits_[0] &= ~0x02000000u;
}
inline const ::caffe::ReLUParameter& LayerParameter::_internal_relu_param() const {
const ::caffe::ReLUParameter* p = relu_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ReLUParameter*>(
&::caffe::_ReLUParameter_default_instance_);
}
inline const ::caffe::ReLUParameter& LayerParameter::relu_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.relu_param)
return _internal_relu_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_relu_param(
::caffe::ReLUParameter* relu_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(relu_param_);
}
relu_param_ = relu_param;
if (relu_param) {
_has_bits_[0] |= 0x02000000u;
} else {
_has_bits_[0] &= ~0x02000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.relu_param)
}
inline ::caffe::ReLUParameter* LayerParameter::release_relu_param() {
_has_bits_[0] &= ~0x02000000u;
::caffe::ReLUParameter* temp = relu_param_;
relu_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ReLUParameter* LayerParameter::unsafe_arena_release_relu_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.relu_param)
_has_bits_[0] &= ~0x02000000u;
::caffe::ReLUParameter* temp = relu_param_;
relu_param_ = nullptr;
return temp;
}
inline ::caffe::ReLUParameter* LayerParameter::_internal_mutable_relu_param() {
_has_bits_[0] |= 0x02000000u;
if (relu_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ReLUParameter>(GetArena());
relu_param_ = p;
}
return relu_param_;
}
inline ::caffe::ReLUParameter* LayerParameter::mutable_relu_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.relu_param)
return _internal_mutable_relu_param();
}
inline void LayerParameter::set_allocated_relu_param(::caffe::ReLUParameter* relu_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete relu_param_;
}
if (relu_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(relu_param);
if (message_arena != submessage_arena) {
relu_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, relu_param, submessage_arena);
}
_has_bits_[0] |= 0x02000000u;
} else {
_has_bits_[0] &= ~0x02000000u;
}
relu_param_ = relu_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.relu_param)
}
// optional .caffe.ReshapeParameter reshape_param = 133;
inline bool LayerParameter::_internal_has_reshape_param() const {
bool value = (_has_bits_[1] & 0x00000008u) != 0;
PROTOBUF_ASSUME(!value || reshape_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_reshape_param() const {
return _internal_has_reshape_param();
}
inline void LayerParameter::clear_reshape_param() {
if (reshape_param_ != nullptr) reshape_param_->Clear();
_has_bits_[1] &= ~0x00000008u;
}
inline const ::caffe::ReshapeParameter& LayerParameter::_internal_reshape_param() const {
const ::caffe::ReshapeParameter* p = reshape_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ReshapeParameter*>(
&::caffe::_ReshapeParameter_default_instance_);
}
inline const ::caffe::ReshapeParameter& LayerParameter::reshape_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.reshape_param)
return _internal_reshape_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_reshape_param(
::caffe::ReshapeParameter* reshape_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(reshape_param_);
}
reshape_param_ = reshape_param;
if (reshape_param) {
_has_bits_[1] |= 0x00000008u;
} else {
_has_bits_[1] &= ~0x00000008u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.reshape_param)
}
inline ::caffe::ReshapeParameter* LayerParameter::release_reshape_param() {
_has_bits_[1] &= ~0x00000008u;
::caffe::ReshapeParameter* temp = reshape_param_;
reshape_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ReshapeParameter* LayerParameter::unsafe_arena_release_reshape_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.reshape_param)
_has_bits_[1] &= ~0x00000008u;
::caffe::ReshapeParameter* temp = reshape_param_;
reshape_param_ = nullptr;
return temp;
}
inline ::caffe::ReshapeParameter* LayerParameter::_internal_mutable_reshape_param() {
_has_bits_[1] |= 0x00000008u;
if (reshape_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ReshapeParameter>(GetArena());
reshape_param_ = p;
}
return reshape_param_;
}
inline ::caffe::ReshapeParameter* LayerParameter::mutable_reshape_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.reshape_param)
return _internal_mutable_reshape_param();
}
inline void LayerParameter::set_allocated_reshape_param(::caffe::ReshapeParameter* reshape_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete reshape_param_;
}
if (reshape_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(reshape_param);
if (message_arena != submessage_arena) {
reshape_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, reshape_param, submessage_arena);
}
_has_bits_[1] |= 0x00000008u;
} else {
_has_bits_[1] &= ~0x00000008u;
}
reshape_param_ = reshape_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.reshape_param)
}
// optional .caffe.ROIPoolingParameter roi_pooling_param = 147;
inline bool LayerParameter::_internal_has_roi_pooling_param() const {
bool value = (_has_bits_[1] & 0x00020000u) != 0;
PROTOBUF_ASSUME(!value || roi_pooling_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_roi_pooling_param() const {
return _internal_has_roi_pooling_param();
}
inline void LayerParameter::clear_roi_pooling_param() {
if (roi_pooling_param_ != nullptr) roi_pooling_param_->Clear();
_has_bits_[1] &= ~0x00020000u;
}
inline const ::caffe::ROIPoolingParameter& LayerParameter::_internal_roi_pooling_param() const {
const ::caffe::ROIPoolingParameter* p = roi_pooling_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ROIPoolingParameter*>(
&::caffe::_ROIPoolingParameter_default_instance_);
}
inline const ::caffe::ROIPoolingParameter& LayerParameter::roi_pooling_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.roi_pooling_param)
return _internal_roi_pooling_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_roi_pooling_param(
::caffe::ROIPoolingParameter* roi_pooling_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(roi_pooling_param_);
}
roi_pooling_param_ = roi_pooling_param;
if (roi_pooling_param) {
_has_bits_[1] |= 0x00020000u;
} else {
_has_bits_[1] &= ~0x00020000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.roi_pooling_param)
}
inline ::caffe::ROIPoolingParameter* LayerParameter::release_roi_pooling_param() {
_has_bits_[1] &= ~0x00020000u;
::caffe::ROIPoolingParameter* temp = roi_pooling_param_;
roi_pooling_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ROIPoolingParameter* LayerParameter::unsafe_arena_release_roi_pooling_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.roi_pooling_param)
_has_bits_[1] &= ~0x00020000u;
::caffe::ROIPoolingParameter* temp = roi_pooling_param_;
roi_pooling_param_ = nullptr;
return temp;
}
inline ::caffe::ROIPoolingParameter* LayerParameter::_internal_mutable_roi_pooling_param() {
_has_bits_[1] |= 0x00020000u;
if (roi_pooling_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ROIPoolingParameter>(GetArena());
roi_pooling_param_ = p;
}
return roi_pooling_param_;
}
inline ::caffe::ROIPoolingParameter* LayerParameter::mutable_roi_pooling_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.roi_pooling_param)
return _internal_mutable_roi_pooling_param();
}
inline void LayerParameter::set_allocated_roi_pooling_param(::caffe::ROIPoolingParameter* roi_pooling_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete roi_pooling_param_;
}
if (roi_pooling_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(roi_pooling_param);
if (message_arena != submessage_arena) {
roi_pooling_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, roi_pooling_param, submessage_arena);
}
_has_bits_[1] |= 0x00020000u;
} else {
_has_bits_[1] &= ~0x00020000u;
}
roi_pooling_param_ = roi_pooling_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.roi_pooling_param)
}
// optional .caffe.ScaleParameter scale_param = 142;
inline bool LayerParameter::_internal_has_scale_param() const {
bool value = (_has_bits_[1] & 0x00001000u) != 0;
PROTOBUF_ASSUME(!value || scale_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_scale_param() const {
return _internal_has_scale_param();
}
inline void LayerParameter::clear_scale_param() {
if (scale_param_ != nullptr) scale_param_->Clear();
_has_bits_[1] &= ~0x00001000u;
}
inline const ::caffe::ScaleParameter& LayerParameter::_internal_scale_param() const {
const ::caffe::ScaleParameter* p = scale_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ScaleParameter*>(
&::caffe::_ScaleParameter_default_instance_);
}
inline const ::caffe::ScaleParameter& LayerParameter::scale_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.scale_param)
return _internal_scale_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_scale_param(
::caffe::ScaleParameter* scale_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(scale_param_);
}
scale_param_ = scale_param;
if (scale_param) {
_has_bits_[1] |= 0x00001000u;
} else {
_has_bits_[1] &= ~0x00001000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.scale_param)
}
inline ::caffe::ScaleParameter* LayerParameter::release_scale_param() {
_has_bits_[1] &= ~0x00001000u;
::caffe::ScaleParameter* temp = scale_param_;
scale_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ScaleParameter* LayerParameter::unsafe_arena_release_scale_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.scale_param)
_has_bits_[1] &= ~0x00001000u;
::caffe::ScaleParameter* temp = scale_param_;
scale_param_ = nullptr;
return temp;
}
inline ::caffe::ScaleParameter* LayerParameter::_internal_mutable_scale_param() {
_has_bits_[1] |= 0x00001000u;
if (scale_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ScaleParameter>(GetArena());
scale_param_ = p;
}
return scale_param_;
}
inline ::caffe::ScaleParameter* LayerParameter::mutable_scale_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.scale_param)
return _internal_mutable_scale_param();
}
inline void LayerParameter::set_allocated_scale_param(::caffe::ScaleParameter* scale_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete scale_param_;
}
if (scale_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(scale_param);
if (message_arena != submessage_arena) {
scale_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, scale_param, submessage_arena);
}
_has_bits_[1] |= 0x00001000u;
} else {
_has_bits_[1] &= ~0x00001000u;
}
scale_param_ = scale_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.scale_param)
}
// optional .caffe.SigmoidParameter sigmoid_param = 124;
inline bool LayerParameter::_internal_has_sigmoid_param() const {
bool value = (_has_bits_[0] & 0x04000000u) != 0;
PROTOBUF_ASSUME(!value || sigmoid_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_sigmoid_param() const {
return _internal_has_sigmoid_param();
}
inline void LayerParameter::clear_sigmoid_param() {
if (sigmoid_param_ != nullptr) sigmoid_param_->Clear();
_has_bits_[0] &= ~0x04000000u;
}
inline const ::caffe::SigmoidParameter& LayerParameter::_internal_sigmoid_param() const {
const ::caffe::SigmoidParameter* p = sigmoid_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::SigmoidParameter*>(
&::caffe::_SigmoidParameter_default_instance_);
}
inline const ::caffe::SigmoidParameter& LayerParameter::sigmoid_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.sigmoid_param)
return _internal_sigmoid_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_sigmoid_param(
::caffe::SigmoidParameter* sigmoid_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(sigmoid_param_);
}
sigmoid_param_ = sigmoid_param;
if (sigmoid_param) {
_has_bits_[0] |= 0x04000000u;
} else {
_has_bits_[0] &= ~0x04000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.sigmoid_param)
}
inline ::caffe::SigmoidParameter* LayerParameter::release_sigmoid_param() {
_has_bits_[0] &= ~0x04000000u;
::caffe::SigmoidParameter* temp = sigmoid_param_;
sigmoid_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::SigmoidParameter* LayerParameter::unsafe_arena_release_sigmoid_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.sigmoid_param)
_has_bits_[0] &= ~0x04000000u;
::caffe::SigmoidParameter* temp = sigmoid_param_;
sigmoid_param_ = nullptr;
return temp;
}
inline ::caffe::SigmoidParameter* LayerParameter::_internal_mutable_sigmoid_param() {
_has_bits_[0] |= 0x04000000u;
if (sigmoid_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::SigmoidParameter>(GetArena());
sigmoid_param_ = p;
}
return sigmoid_param_;
}
inline ::caffe::SigmoidParameter* LayerParameter::mutable_sigmoid_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.sigmoid_param)
return _internal_mutable_sigmoid_param();
}
inline void LayerParameter::set_allocated_sigmoid_param(::caffe::SigmoidParameter* sigmoid_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete sigmoid_param_;
}
if (sigmoid_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(sigmoid_param);
if (message_arena != submessage_arena) {
sigmoid_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, sigmoid_param, submessage_arena);
}
_has_bits_[0] |= 0x04000000u;
} else {
_has_bits_[0] &= ~0x04000000u;
}
sigmoid_param_ = sigmoid_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.sigmoid_param)
}
// optional .caffe.SmoothL1LossParameter smooth_l1_loss_param = 148;
inline bool LayerParameter::_internal_has_smooth_l1_loss_param() const {
bool value = (_has_bits_[1] & 0x00040000u) != 0;
PROTOBUF_ASSUME(!value || smooth_l1_loss_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_smooth_l1_loss_param() const {
return _internal_has_smooth_l1_loss_param();
}
inline void LayerParameter::clear_smooth_l1_loss_param() {
if (smooth_l1_loss_param_ != nullptr) smooth_l1_loss_param_->Clear();
_has_bits_[1] &= ~0x00040000u;
}
inline const ::caffe::SmoothL1LossParameter& LayerParameter::_internal_smooth_l1_loss_param() const {
const ::caffe::SmoothL1LossParameter* p = smooth_l1_loss_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::SmoothL1LossParameter*>(
&::caffe::_SmoothL1LossParameter_default_instance_);
}
inline const ::caffe::SmoothL1LossParameter& LayerParameter::smooth_l1_loss_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.smooth_l1_loss_param)
return _internal_smooth_l1_loss_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_smooth_l1_loss_param(
::caffe::SmoothL1LossParameter* smooth_l1_loss_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(smooth_l1_loss_param_);
}
smooth_l1_loss_param_ = smooth_l1_loss_param;
if (smooth_l1_loss_param) {
_has_bits_[1] |= 0x00040000u;
} else {
_has_bits_[1] &= ~0x00040000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.smooth_l1_loss_param)
}
inline ::caffe::SmoothL1LossParameter* LayerParameter::release_smooth_l1_loss_param() {
_has_bits_[1] &= ~0x00040000u;
::caffe::SmoothL1LossParameter* temp = smooth_l1_loss_param_;
smooth_l1_loss_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::SmoothL1LossParameter* LayerParameter::unsafe_arena_release_smooth_l1_loss_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.smooth_l1_loss_param)
_has_bits_[1] &= ~0x00040000u;
::caffe::SmoothL1LossParameter* temp = smooth_l1_loss_param_;
smooth_l1_loss_param_ = nullptr;
return temp;
}
inline ::caffe::SmoothL1LossParameter* LayerParameter::_internal_mutable_smooth_l1_loss_param() {
_has_bits_[1] |= 0x00040000u;
if (smooth_l1_loss_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::SmoothL1LossParameter>(GetArena());
smooth_l1_loss_param_ = p;
}
return smooth_l1_loss_param_;
}
inline ::caffe::SmoothL1LossParameter* LayerParameter::mutable_smooth_l1_loss_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.smooth_l1_loss_param)
return _internal_mutable_smooth_l1_loss_param();
}
inline void LayerParameter::set_allocated_smooth_l1_loss_param(::caffe::SmoothL1LossParameter* smooth_l1_loss_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete smooth_l1_loss_param_;
}
if (smooth_l1_loss_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(smooth_l1_loss_param);
if (message_arena != submessage_arena) {
smooth_l1_loss_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, smooth_l1_loss_param, submessage_arena);
}
_has_bits_[1] |= 0x00040000u;
} else {
_has_bits_[1] &= ~0x00040000u;
}
smooth_l1_loss_param_ = smooth_l1_loss_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.smooth_l1_loss_param)
}
// optional .caffe.SoftmaxParameter softmax_param = 125;
inline bool LayerParameter::_internal_has_softmax_param() const {
bool value = (_has_bits_[0] & 0x08000000u) != 0;
PROTOBUF_ASSUME(!value || softmax_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_softmax_param() const {
return _internal_has_softmax_param();
}
inline void LayerParameter::clear_softmax_param() {
if (softmax_param_ != nullptr) softmax_param_->Clear();
_has_bits_[0] &= ~0x08000000u;
}
inline const ::caffe::SoftmaxParameter& LayerParameter::_internal_softmax_param() const {
const ::caffe::SoftmaxParameter* p = softmax_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::SoftmaxParameter*>(
&::caffe::_SoftmaxParameter_default_instance_);
}
inline const ::caffe::SoftmaxParameter& LayerParameter::softmax_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.softmax_param)
return _internal_softmax_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_softmax_param(
::caffe::SoftmaxParameter* softmax_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(softmax_param_);
}
softmax_param_ = softmax_param;
if (softmax_param) {
_has_bits_[0] |= 0x08000000u;
} else {
_has_bits_[0] &= ~0x08000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.softmax_param)
}
inline ::caffe::SoftmaxParameter* LayerParameter::release_softmax_param() {
_has_bits_[0] &= ~0x08000000u;
::caffe::SoftmaxParameter* temp = softmax_param_;
softmax_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::SoftmaxParameter* LayerParameter::unsafe_arena_release_softmax_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.softmax_param)
_has_bits_[0] &= ~0x08000000u;
::caffe::SoftmaxParameter* temp = softmax_param_;
softmax_param_ = nullptr;
return temp;
}
inline ::caffe::SoftmaxParameter* LayerParameter::_internal_mutable_softmax_param() {
_has_bits_[0] |= 0x08000000u;
if (softmax_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::SoftmaxParameter>(GetArena());
softmax_param_ = p;
}
return softmax_param_;
}
inline ::caffe::SoftmaxParameter* LayerParameter::mutable_softmax_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.softmax_param)
return _internal_mutable_softmax_param();
}
inline void LayerParameter::set_allocated_softmax_param(::caffe::SoftmaxParameter* softmax_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete softmax_param_;
}
if (softmax_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(softmax_param);
if (message_arena != submessage_arena) {
softmax_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, softmax_param, submessage_arena);
}
_has_bits_[0] |= 0x08000000u;
} else {
_has_bits_[0] &= ~0x08000000u;
}
softmax_param_ = softmax_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.softmax_param)
}
// optional .caffe.SPPParameter spp_param = 132;
inline bool LayerParameter::_internal_has_spp_param() const {
bool value = (_has_bits_[1] & 0x00000004u) != 0;
PROTOBUF_ASSUME(!value || spp_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_spp_param() const {
return _internal_has_spp_param();
}
inline void LayerParameter::clear_spp_param() {
if (spp_param_ != nullptr) spp_param_->Clear();
_has_bits_[1] &= ~0x00000004u;
}
inline const ::caffe::SPPParameter& LayerParameter::_internal_spp_param() const {
const ::caffe::SPPParameter* p = spp_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::SPPParameter*>(
&::caffe::_SPPParameter_default_instance_);
}
inline const ::caffe::SPPParameter& LayerParameter::spp_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.spp_param)
return _internal_spp_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_spp_param(
::caffe::SPPParameter* spp_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(spp_param_);
}
spp_param_ = spp_param;
if (spp_param) {
_has_bits_[1] |= 0x00000004u;
} else {
_has_bits_[1] &= ~0x00000004u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.spp_param)
}
inline ::caffe::SPPParameter* LayerParameter::release_spp_param() {
_has_bits_[1] &= ~0x00000004u;
::caffe::SPPParameter* temp = spp_param_;
spp_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::SPPParameter* LayerParameter::unsafe_arena_release_spp_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.spp_param)
_has_bits_[1] &= ~0x00000004u;
::caffe::SPPParameter* temp = spp_param_;
spp_param_ = nullptr;
return temp;
}
inline ::caffe::SPPParameter* LayerParameter::_internal_mutable_spp_param() {
_has_bits_[1] |= 0x00000004u;
if (spp_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::SPPParameter>(GetArena());
spp_param_ = p;
}
return spp_param_;
}
inline ::caffe::SPPParameter* LayerParameter::mutable_spp_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.spp_param)
return _internal_mutable_spp_param();
}
inline void LayerParameter::set_allocated_spp_param(::caffe::SPPParameter* spp_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete spp_param_;
}
if (spp_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(spp_param);
if (message_arena != submessage_arena) {
spp_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, spp_param, submessage_arena);
}
_has_bits_[1] |= 0x00000004u;
} else {
_has_bits_[1] &= ~0x00000004u;
}
spp_param_ = spp_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.spp_param)
}
// optional .caffe.SliceParameter slice_param = 126;
inline bool LayerParameter::_internal_has_slice_param() const {
bool value = (_has_bits_[0] & 0x10000000u) != 0;
PROTOBUF_ASSUME(!value || slice_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_slice_param() const {
return _internal_has_slice_param();
}
inline void LayerParameter::clear_slice_param() {
if (slice_param_ != nullptr) slice_param_->Clear();
_has_bits_[0] &= ~0x10000000u;
}
inline const ::caffe::SliceParameter& LayerParameter::_internal_slice_param() const {
const ::caffe::SliceParameter* p = slice_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::SliceParameter*>(
&::caffe::_SliceParameter_default_instance_);
}
inline const ::caffe::SliceParameter& LayerParameter::slice_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.slice_param)
return _internal_slice_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_slice_param(
::caffe::SliceParameter* slice_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(slice_param_);
}
slice_param_ = slice_param;
if (slice_param) {
_has_bits_[0] |= 0x10000000u;
} else {
_has_bits_[0] &= ~0x10000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.slice_param)
}
inline ::caffe::SliceParameter* LayerParameter::release_slice_param() {
_has_bits_[0] &= ~0x10000000u;
::caffe::SliceParameter* temp = slice_param_;
slice_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::SliceParameter* LayerParameter::unsafe_arena_release_slice_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.slice_param)
_has_bits_[0] &= ~0x10000000u;
::caffe::SliceParameter* temp = slice_param_;
slice_param_ = nullptr;
return temp;
}
inline ::caffe::SliceParameter* LayerParameter::_internal_mutable_slice_param() {
_has_bits_[0] |= 0x10000000u;
if (slice_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::SliceParameter>(GetArena());
slice_param_ = p;
}
return slice_param_;
}
inline ::caffe::SliceParameter* LayerParameter::mutable_slice_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.slice_param)
return _internal_mutable_slice_param();
}
inline void LayerParameter::set_allocated_slice_param(::caffe::SliceParameter* slice_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete slice_param_;
}
if (slice_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(slice_param);
if (message_arena != submessage_arena) {
slice_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, slice_param, submessage_arena);
}
_has_bits_[0] |= 0x10000000u;
} else {
_has_bits_[0] &= ~0x10000000u;
}
slice_param_ = slice_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.slice_param)
}
// optional .caffe.TanHParameter tanh_param = 127;
inline bool LayerParameter::_internal_has_tanh_param() const {
bool value = (_has_bits_[0] & 0x20000000u) != 0;
PROTOBUF_ASSUME(!value || tanh_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_tanh_param() const {
return _internal_has_tanh_param();
}
inline void LayerParameter::clear_tanh_param() {
if (tanh_param_ != nullptr) tanh_param_->Clear();
_has_bits_[0] &= ~0x20000000u;
}
inline const ::caffe::TanHParameter& LayerParameter::_internal_tanh_param() const {
const ::caffe::TanHParameter* p = tanh_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::TanHParameter*>(
&::caffe::_TanHParameter_default_instance_);
}
inline const ::caffe::TanHParameter& LayerParameter::tanh_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.tanh_param)
return _internal_tanh_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_tanh_param(
::caffe::TanHParameter* tanh_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(tanh_param_);
}
tanh_param_ = tanh_param;
if (tanh_param) {
_has_bits_[0] |= 0x20000000u;
} else {
_has_bits_[0] &= ~0x20000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.tanh_param)
}
inline ::caffe::TanHParameter* LayerParameter::release_tanh_param() {
_has_bits_[0] &= ~0x20000000u;
::caffe::TanHParameter* temp = tanh_param_;
tanh_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::TanHParameter* LayerParameter::unsafe_arena_release_tanh_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.tanh_param)
_has_bits_[0] &= ~0x20000000u;
::caffe::TanHParameter* temp = tanh_param_;
tanh_param_ = nullptr;
return temp;
}
inline ::caffe::TanHParameter* LayerParameter::_internal_mutable_tanh_param() {
_has_bits_[0] |= 0x20000000u;
if (tanh_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::TanHParameter>(GetArena());
tanh_param_ = p;
}
return tanh_param_;
}
inline ::caffe::TanHParameter* LayerParameter::mutable_tanh_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.tanh_param)
return _internal_mutable_tanh_param();
}
inline void LayerParameter::set_allocated_tanh_param(::caffe::TanHParameter* tanh_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete tanh_param_;
}
if (tanh_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(tanh_param);
if (message_arena != submessage_arena) {
tanh_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, tanh_param, submessage_arena);
}
_has_bits_[0] |= 0x20000000u;
} else {
_has_bits_[0] &= ~0x20000000u;
}
tanh_param_ = tanh_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.tanh_param)
}
// optional .caffe.ThresholdParameter threshold_param = 128;
inline bool LayerParameter::_internal_has_threshold_param() const {
bool value = (_has_bits_[0] & 0x40000000u) != 0;
PROTOBUF_ASSUME(!value || threshold_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_threshold_param() const {
return _internal_has_threshold_param();
}
inline void LayerParameter::clear_threshold_param() {
if (threshold_param_ != nullptr) threshold_param_->Clear();
_has_bits_[0] &= ~0x40000000u;
}
inline const ::caffe::ThresholdParameter& LayerParameter::_internal_threshold_param() const {
const ::caffe::ThresholdParameter* p = threshold_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ThresholdParameter*>(
&::caffe::_ThresholdParameter_default_instance_);
}
inline const ::caffe::ThresholdParameter& LayerParameter::threshold_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.threshold_param)
return _internal_threshold_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_threshold_param(
::caffe::ThresholdParameter* threshold_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(threshold_param_);
}
threshold_param_ = threshold_param;
if (threshold_param) {
_has_bits_[0] |= 0x40000000u;
} else {
_has_bits_[0] &= ~0x40000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.threshold_param)
}
inline ::caffe::ThresholdParameter* LayerParameter::release_threshold_param() {
_has_bits_[0] &= ~0x40000000u;
::caffe::ThresholdParameter* temp = threshold_param_;
threshold_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ThresholdParameter* LayerParameter::unsafe_arena_release_threshold_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.threshold_param)
_has_bits_[0] &= ~0x40000000u;
::caffe::ThresholdParameter* temp = threshold_param_;
threshold_param_ = nullptr;
return temp;
}
inline ::caffe::ThresholdParameter* LayerParameter::_internal_mutable_threshold_param() {
_has_bits_[0] |= 0x40000000u;
if (threshold_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ThresholdParameter>(GetArena());
threshold_param_ = p;
}
return threshold_param_;
}
inline ::caffe::ThresholdParameter* LayerParameter::mutable_threshold_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.threshold_param)
return _internal_mutable_threshold_param();
}
inline void LayerParameter::set_allocated_threshold_param(::caffe::ThresholdParameter* threshold_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete threshold_param_;
}
if (threshold_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(threshold_param);
if (message_arena != submessage_arena) {
threshold_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, threshold_param, submessage_arena);
}
_has_bits_[0] |= 0x40000000u;
} else {
_has_bits_[0] &= ~0x40000000u;
}
threshold_param_ = threshold_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.threshold_param)
}
// optional .caffe.TileParameter tile_param = 138;
inline bool LayerParameter::_internal_has_tile_param() const {
bool value = (_has_bits_[1] & 0x00000100u) != 0;
PROTOBUF_ASSUME(!value || tile_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_tile_param() const {
return _internal_has_tile_param();
}
inline void LayerParameter::clear_tile_param() {
if (tile_param_ != nullptr) tile_param_->Clear();
_has_bits_[1] &= ~0x00000100u;
}
inline const ::caffe::TileParameter& LayerParameter::_internal_tile_param() const {
const ::caffe::TileParameter* p = tile_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::TileParameter*>(
&::caffe::_TileParameter_default_instance_);
}
inline const ::caffe::TileParameter& LayerParameter::tile_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.tile_param)
return _internal_tile_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_tile_param(
::caffe::TileParameter* tile_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(tile_param_);
}
tile_param_ = tile_param;
if (tile_param) {
_has_bits_[1] |= 0x00000100u;
} else {
_has_bits_[1] &= ~0x00000100u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.tile_param)
}
inline ::caffe::TileParameter* LayerParameter::release_tile_param() {
_has_bits_[1] &= ~0x00000100u;
::caffe::TileParameter* temp = tile_param_;
tile_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::TileParameter* LayerParameter::unsafe_arena_release_tile_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.tile_param)
_has_bits_[1] &= ~0x00000100u;
::caffe::TileParameter* temp = tile_param_;
tile_param_ = nullptr;
return temp;
}
inline ::caffe::TileParameter* LayerParameter::_internal_mutable_tile_param() {
_has_bits_[1] |= 0x00000100u;
if (tile_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::TileParameter>(GetArena());
tile_param_ = p;
}
return tile_param_;
}
inline ::caffe::TileParameter* LayerParameter::mutable_tile_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.tile_param)
return _internal_mutable_tile_param();
}
inline void LayerParameter::set_allocated_tile_param(::caffe::TileParameter* tile_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete tile_param_;
}
if (tile_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(tile_param);
if (message_arena != submessage_arena) {
tile_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, tile_param, submessage_arena);
}
_has_bits_[1] |= 0x00000100u;
} else {
_has_bits_[1] &= ~0x00000100u;
}
tile_param_ = tile_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.tile_param)
}
// optional .caffe.VideoDataParameter video_data_param = 207;
inline bool LayerParameter::_internal_has_video_data_param() const {
bool value = (_has_bits_[1] & 0x20000000u) != 0;
PROTOBUF_ASSUME(!value || video_data_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_video_data_param() const {
return _internal_has_video_data_param();
}
inline void LayerParameter::clear_video_data_param() {
if (video_data_param_ != nullptr) video_data_param_->Clear();
_has_bits_[1] &= ~0x20000000u;
}
inline const ::caffe::VideoDataParameter& LayerParameter::_internal_video_data_param() const {
const ::caffe::VideoDataParameter* p = video_data_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::VideoDataParameter*>(
&::caffe::_VideoDataParameter_default_instance_);
}
inline const ::caffe::VideoDataParameter& LayerParameter::video_data_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.video_data_param)
return _internal_video_data_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_video_data_param(
::caffe::VideoDataParameter* video_data_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(video_data_param_);
}
video_data_param_ = video_data_param;
if (video_data_param) {
_has_bits_[1] |= 0x20000000u;
} else {
_has_bits_[1] &= ~0x20000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.video_data_param)
}
inline ::caffe::VideoDataParameter* LayerParameter::release_video_data_param() {
_has_bits_[1] &= ~0x20000000u;
::caffe::VideoDataParameter* temp = video_data_param_;
video_data_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::VideoDataParameter* LayerParameter::unsafe_arena_release_video_data_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.video_data_param)
_has_bits_[1] &= ~0x20000000u;
::caffe::VideoDataParameter* temp = video_data_param_;
video_data_param_ = nullptr;
return temp;
}
inline ::caffe::VideoDataParameter* LayerParameter::_internal_mutable_video_data_param() {
_has_bits_[1] |= 0x20000000u;
if (video_data_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::VideoDataParameter>(GetArena());
video_data_param_ = p;
}
return video_data_param_;
}
inline ::caffe::VideoDataParameter* LayerParameter::mutable_video_data_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.video_data_param)
return _internal_mutable_video_data_param();
}
inline void LayerParameter::set_allocated_video_data_param(::caffe::VideoDataParameter* video_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete video_data_param_;
}
if (video_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(video_data_param);
if (message_arena != submessage_arena) {
video_data_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, video_data_param, submessage_arena);
}
_has_bits_[1] |= 0x20000000u;
} else {
_has_bits_[1] &= ~0x20000000u;
}
video_data_param_ = video_data_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.video_data_param)
}
// optional .caffe.WindowDataParameter window_data_param = 129;
inline bool LayerParameter::_internal_has_window_data_param() const {
bool value = (_has_bits_[0] & 0x80000000u) != 0;
PROTOBUF_ASSUME(!value || window_data_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_window_data_param() const {
return _internal_has_window_data_param();
}
inline void LayerParameter::clear_window_data_param() {
if (window_data_param_ != nullptr) window_data_param_->Clear();
_has_bits_[0] &= ~0x80000000u;
}
inline const ::caffe::WindowDataParameter& LayerParameter::_internal_window_data_param() const {
const ::caffe::WindowDataParameter* p = window_data_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::WindowDataParameter*>(
&::caffe::_WindowDataParameter_default_instance_);
}
inline const ::caffe::WindowDataParameter& LayerParameter::window_data_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.window_data_param)
return _internal_window_data_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_window_data_param(
::caffe::WindowDataParameter* window_data_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(window_data_param_);
}
window_data_param_ = window_data_param;
if (window_data_param) {
_has_bits_[0] |= 0x80000000u;
} else {
_has_bits_[0] &= ~0x80000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.window_data_param)
}
inline ::caffe::WindowDataParameter* LayerParameter::release_window_data_param() {
_has_bits_[0] &= ~0x80000000u;
::caffe::WindowDataParameter* temp = window_data_param_;
window_data_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::WindowDataParameter* LayerParameter::unsafe_arena_release_window_data_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.window_data_param)
_has_bits_[0] &= ~0x80000000u;
::caffe::WindowDataParameter* temp = window_data_param_;
window_data_param_ = nullptr;
return temp;
}
inline ::caffe::WindowDataParameter* LayerParameter::_internal_mutable_window_data_param() {
_has_bits_[0] |= 0x80000000u;
if (window_data_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::WindowDataParameter>(GetArena());
window_data_param_ = p;
}
return window_data_param_;
}
inline ::caffe::WindowDataParameter* LayerParameter::mutable_window_data_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.window_data_param)
return _internal_mutable_window_data_param();
}
inline void LayerParameter::set_allocated_window_data_param(::caffe::WindowDataParameter* window_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete window_data_param_;
}
if (window_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(window_data_param);
if (message_arena != submessage_arena) {
window_data_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, window_data_param, submessage_arena);
}
_has_bits_[0] |= 0x80000000u;
} else {
_has_bits_[0] &= ~0x80000000u;
}
window_data_param_ = window_data_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.window_data_param)
}
// optional .caffe.MILDataParameter mil_data_param = 5065028;
inline bool LayerParameter::_internal_has_mil_data_param() const {
bool value = (_has_bits_[1] & 0x40000000u) != 0;
PROTOBUF_ASSUME(!value || mil_data_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_mil_data_param() const {
return _internal_has_mil_data_param();
}
inline void LayerParameter::clear_mil_data_param() {
if (mil_data_param_ != nullptr) mil_data_param_->Clear();
_has_bits_[1] &= ~0x40000000u;
}
inline const ::caffe::MILDataParameter& LayerParameter::_internal_mil_data_param() const {
const ::caffe::MILDataParameter* p = mil_data_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::MILDataParameter*>(
&::caffe::_MILDataParameter_default_instance_);
}
inline const ::caffe::MILDataParameter& LayerParameter::mil_data_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.mil_data_param)
return _internal_mil_data_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_mil_data_param(
::caffe::MILDataParameter* mil_data_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(mil_data_param_);
}
mil_data_param_ = mil_data_param;
if (mil_data_param) {
_has_bits_[1] |= 0x40000000u;
} else {
_has_bits_[1] &= ~0x40000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.mil_data_param)
}
inline ::caffe::MILDataParameter* LayerParameter::release_mil_data_param() {
_has_bits_[1] &= ~0x40000000u;
::caffe::MILDataParameter* temp = mil_data_param_;
mil_data_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::MILDataParameter* LayerParameter::unsafe_arena_release_mil_data_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.mil_data_param)
_has_bits_[1] &= ~0x40000000u;
::caffe::MILDataParameter* temp = mil_data_param_;
mil_data_param_ = nullptr;
return temp;
}
inline ::caffe::MILDataParameter* LayerParameter::_internal_mutable_mil_data_param() {
_has_bits_[1] |= 0x40000000u;
if (mil_data_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::MILDataParameter>(GetArena());
mil_data_param_ = p;
}
return mil_data_param_;
}
inline ::caffe::MILDataParameter* LayerParameter::mutable_mil_data_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.mil_data_param)
return _internal_mutable_mil_data_param();
}
inline void LayerParameter::set_allocated_mil_data_param(::caffe::MILDataParameter* mil_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete mil_data_param_;
}
if (mil_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(mil_data_param);
if (message_arena != submessage_arena) {
mil_data_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, mil_data_param, submessage_arena);
}
_has_bits_[1] |= 0x40000000u;
} else {
_has_bits_[1] &= ~0x40000000u;
}
mil_data_param_ = mil_data_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.mil_data_param)
}
// optional .caffe.MILParameter mil_param = 5065036;
inline bool LayerParameter::_internal_has_mil_param() const {
bool value = (_has_bits_[1] & 0x80000000u) != 0;
PROTOBUF_ASSUME(!value || mil_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_mil_param() const {
return _internal_has_mil_param();
}
inline void LayerParameter::clear_mil_param() {
if (mil_param_ != nullptr) mil_param_->Clear();
_has_bits_[1] &= ~0x80000000u;
}
inline const ::caffe::MILParameter& LayerParameter::_internal_mil_param() const {
const ::caffe::MILParameter* p = mil_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::MILParameter*>(
&::caffe::_MILParameter_default_instance_);
}
inline const ::caffe::MILParameter& LayerParameter::mil_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.mil_param)
return _internal_mil_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_mil_param(
::caffe::MILParameter* mil_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(mil_param_);
}
mil_param_ = mil_param;
if (mil_param) {
_has_bits_[1] |= 0x80000000u;
} else {
_has_bits_[1] &= ~0x80000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.mil_param)
}
inline ::caffe::MILParameter* LayerParameter::release_mil_param() {
_has_bits_[1] &= ~0x80000000u;
::caffe::MILParameter* temp = mil_param_;
mil_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::MILParameter* LayerParameter::unsafe_arena_release_mil_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.mil_param)
_has_bits_[1] &= ~0x80000000u;
::caffe::MILParameter* temp = mil_param_;
mil_param_ = nullptr;
return temp;
}
inline ::caffe::MILParameter* LayerParameter::_internal_mutable_mil_param() {
_has_bits_[1] |= 0x80000000u;
if (mil_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::MILParameter>(GetArena());
mil_param_ = p;
}
return mil_param_;
}
inline ::caffe::MILParameter* LayerParameter::mutable_mil_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.mil_param)
return _internal_mutable_mil_param();
}
inline void LayerParameter::set_allocated_mil_param(::caffe::MILParameter* mil_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete mil_param_;
}
if (mil_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(mil_param);
if (message_arena != submessage_arena) {
mil_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, mil_param, submessage_arena);
}
_has_bits_[1] |= 0x80000000u;
} else {
_has_bits_[1] &= ~0x80000000u;
}
mil_param_ = mil_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.mil_param)
}
// optional .caffe.FaceDataParameter face_data_param = 150;
inline bool LayerParameter::_internal_has_face_data_param() const {
bool value = (_has_bits_[1] & 0x00080000u) != 0;
PROTOBUF_ASSUME(!value || face_data_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_face_data_param() const {
return _internal_has_face_data_param();
}
inline void LayerParameter::clear_face_data_param() {
if (face_data_param_ != nullptr) face_data_param_->Clear();
_has_bits_[1] &= ~0x00080000u;
}
inline const ::caffe::FaceDataParameter& LayerParameter::_internal_face_data_param() const {
const ::caffe::FaceDataParameter* p = face_data_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::FaceDataParameter*>(
&::caffe::_FaceDataParameter_default_instance_);
}
inline const ::caffe::FaceDataParameter& LayerParameter::face_data_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.face_data_param)
return _internal_face_data_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_face_data_param(
::caffe::FaceDataParameter* face_data_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(face_data_param_);
}
face_data_param_ = face_data_param;
if (face_data_param) {
_has_bits_[1] |= 0x00080000u;
} else {
_has_bits_[1] &= ~0x00080000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.face_data_param)
}
inline ::caffe::FaceDataParameter* LayerParameter::release_face_data_param() {
_has_bits_[1] &= ~0x00080000u;
::caffe::FaceDataParameter* temp = face_data_param_;
face_data_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::FaceDataParameter* LayerParameter::unsafe_arena_release_face_data_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.face_data_param)
_has_bits_[1] &= ~0x00080000u;
::caffe::FaceDataParameter* temp = face_data_param_;
face_data_param_ = nullptr;
return temp;
}
inline ::caffe::FaceDataParameter* LayerParameter::_internal_mutable_face_data_param() {
_has_bits_[1] |= 0x00080000u;
if (face_data_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::FaceDataParameter>(GetArena());
face_data_param_ = p;
}
return face_data_param_;
}
inline ::caffe::FaceDataParameter* LayerParameter::mutable_face_data_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.face_data_param)
return _internal_mutable_face_data_param();
}
inline void LayerParameter::set_allocated_face_data_param(::caffe::FaceDataParameter* face_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete face_data_param_;
}
if (face_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(face_data_param);
if (message_arena != submessage_arena) {
face_data_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, face_data_param, submessage_arena);
}
_has_bits_[1] |= 0x00080000u;
} else {
_has_bits_[1] &= ~0x00080000u;
}
face_data_param_ = face_data_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.face_data_param)
}
// optional .caffe.UpsampleParameter upsample_param = 151;
inline bool LayerParameter::_internal_has_upsample_param() const {
bool value = (_has_bits_[1] & 0x00100000u) != 0;
PROTOBUF_ASSUME(!value || upsample_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_upsample_param() const {
return _internal_has_upsample_param();
}
inline void LayerParameter::clear_upsample_param() {
if (upsample_param_ != nullptr) upsample_param_->Clear();
_has_bits_[1] &= ~0x00100000u;
}
inline const ::caffe::UpsampleParameter& LayerParameter::_internal_upsample_param() const {
const ::caffe::UpsampleParameter* p = upsample_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::UpsampleParameter*>(
&::caffe::_UpsampleParameter_default_instance_);
}
inline const ::caffe::UpsampleParameter& LayerParameter::upsample_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.upsample_param)
return _internal_upsample_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_upsample_param(
::caffe::UpsampleParameter* upsample_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(upsample_param_);
}
upsample_param_ = upsample_param;
if (upsample_param) {
_has_bits_[1] |= 0x00100000u;
} else {
_has_bits_[1] &= ~0x00100000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.upsample_param)
}
inline ::caffe::UpsampleParameter* LayerParameter::release_upsample_param() {
_has_bits_[1] &= ~0x00100000u;
::caffe::UpsampleParameter* temp = upsample_param_;
upsample_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::UpsampleParameter* LayerParameter::unsafe_arena_release_upsample_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.upsample_param)
_has_bits_[1] &= ~0x00100000u;
::caffe::UpsampleParameter* temp = upsample_param_;
upsample_param_ = nullptr;
return temp;
}
inline ::caffe::UpsampleParameter* LayerParameter::_internal_mutable_upsample_param() {
_has_bits_[1] |= 0x00100000u;
if (upsample_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::UpsampleParameter>(GetArena());
upsample_param_ = p;
}
return upsample_param_;
}
inline ::caffe::UpsampleParameter* LayerParameter::mutable_upsample_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.upsample_param)
return _internal_mutable_upsample_param();
}
inline void LayerParameter::set_allocated_upsample_param(::caffe::UpsampleParameter* upsample_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete upsample_param_;
}
if (upsample_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(upsample_param);
if (message_arena != submessage_arena) {
upsample_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, upsample_param, submessage_arena);
}
_has_bits_[1] |= 0x00100000u;
} else {
_has_bits_[1] &= ~0x00100000u;
}
upsample_param_ = upsample_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.upsample_param)
}
// optional .caffe.ConnectParameter connect_param = 152;
inline bool LayerParameter::_internal_has_connect_param() const {
bool value = (_has_bits_[1] & 0x00200000u) != 0;
PROTOBUF_ASSUME(!value || connect_param_ != nullptr);
return value;
}
inline bool LayerParameter::has_connect_param() const {
return _internal_has_connect_param();
}
inline void LayerParameter::clear_connect_param() {
if (connect_param_ != nullptr) connect_param_->Clear();
_has_bits_[1] &= ~0x00200000u;
}
inline const ::caffe::ConnectParameter& LayerParameter::_internal_connect_param() const {
const ::caffe::ConnectParameter* p = connect_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ConnectParameter*>(
&::caffe::_ConnectParameter_default_instance_);
}
inline const ::caffe::ConnectParameter& LayerParameter::connect_param() const {
// @@protoc_insertion_point(field_get:caffe.LayerParameter.connect_param)
return _internal_connect_param();
}
inline void LayerParameter::unsafe_arena_set_allocated_connect_param(
::caffe::ConnectParameter* connect_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(connect_param_);
}
connect_param_ = connect_param;
if (connect_param) {
_has_bits_[1] |= 0x00200000u;
} else {
_has_bits_[1] &= ~0x00200000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.LayerParameter.connect_param)
}
inline ::caffe::ConnectParameter* LayerParameter::release_connect_param() {
_has_bits_[1] &= ~0x00200000u;
::caffe::ConnectParameter* temp = connect_param_;
connect_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ConnectParameter* LayerParameter::unsafe_arena_release_connect_param() {
// @@protoc_insertion_point(field_release:caffe.LayerParameter.connect_param)
_has_bits_[1] &= ~0x00200000u;
::caffe::ConnectParameter* temp = connect_param_;
connect_param_ = nullptr;
return temp;
}
inline ::caffe::ConnectParameter* LayerParameter::_internal_mutable_connect_param() {
_has_bits_[1] |= 0x00200000u;
if (connect_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ConnectParameter>(GetArena());
connect_param_ = p;
}
return connect_param_;
}
inline ::caffe::ConnectParameter* LayerParameter::mutable_connect_param() {
// @@protoc_insertion_point(field_mutable:caffe.LayerParameter.connect_param)
return _internal_mutable_connect_param();
}
inline void LayerParameter::set_allocated_connect_param(::caffe::ConnectParameter* connect_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete connect_param_;
}
if (connect_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(connect_param);
if (message_arena != submessage_arena) {
connect_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, connect_param, submessage_arena);
}
_has_bits_[1] |= 0x00200000u;
} else {
_has_bits_[1] &= ~0x00200000u;
}
connect_param_ = connect_param;
// @@protoc_insertion_point(field_set_allocated:caffe.LayerParameter.connect_param)
}
// -------------------------------------------------------------------
// TransformationParameter
// optional float scale = 1 [default = 1];
inline bool TransformationParameter::_internal_has_scale() const {
bool value = (_has_bits_[0] & 0x00000400u) != 0;
return value;
}
inline bool TransformationParameter::has_scale() const {
return _internal_has_scale();
}
inline void TransformationParameter::clear_scale() {
scale_ = 1;
_has_bits_[0] &= ~0x00000400u;
}
inline float TransformationParameter::_internal_scale() const {
return scale_;
}
inline float TransformationParameter::scale() const {
// @@protoc_insertion_point(field_get:caffe.TransformationParameter.scale)
return _internal_scale();
}
inline void TransformationParameter::_internal_set_scale(float value) {
_has_bits_[0] |= 0x00000400u;
scale_ = value;
}
inline void TransformationParameter::set_scale(float value) {
_internal_set_scale(value);
// @@protoc_insertion_point(field_set:caffe.TransformationParameter.scale)
}
// optional bool mirror = 2 [default = false];
inline bool TransformationParameter::_internal_has_mirror() const {
bool value = (_has_bits_[0] & 0x00000020u) != 0;
return value;
}
inline bool TransformationParameter::has_mirror() const {
return _internal_has_mirror();
}
inline void TransformationParameter::clear_mirror() {
mirror_ = false;
_has_bits_[0] &= ~0x00000020u;
}
inline bool TransformationParameter::_internal_mirror() const {
return mirror_;
}
inline bool TransformationParameter::mirror() const {
// @@protoc_insertion_point(field_get:caffe.TransformationParameter.mirror)
return _internal_mirror();
}
inline void TransformationParameter::_internal_set_mirror(bool value) {
_has_bits_[0] |= 0x00000020u;
mirror_ = value;
}
inline void TransformationParameter::set_mirror(bool value) {
_internal_set_mirror(value);
// @@protoc_insertion_point(field_set:caffe.TransformationParameter.mirror)
}
// optional uint32 crop_size = 3 [default = 0];
inline bool TransformationParameter::_internal_has_crop_size() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool TransformationParameter::has_crop_size() const {
return _internal_has_crop_size();
}
inline void TransformationParameter::clear_crop_size() {
crop_size_ = 0u;
_has_bits_[0] &= ~0x00000010u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 TransformationParameter::_internal_crop_size() const {
return crop_size_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 TransformationParameter::crop_size() const {
// @@protoc_insertion_point(field_get:caffe.TransformationParameter.crop_size)
return _internal_crop_size();
}
inline void TransformationParameter::_internal_set_crop_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000010u;
crop_size_ = value;
}
inline void TransformationParameter::set_crop_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_crop_size(value);
// @@protoc_insertion_point(field_set:caffe.TransformationParameter.crop_size)
}
// optional uint32 crop_h = 11 [default = 0];
inline bool TransformationParameter::_internal_has_crop_h() const {
bool value = (_has_bits_[0] & 0x00000100u) != 0;
return value;
}
inline bool TransformationParameter::has_crop_h() const {
return _internal_has_crop_h();
}
inline void TransformationParameter::clear_crop_h() {
crop_h_ = 0u;
_has_bits_[0] &= ~0x00000100u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 TransformationParameter::_internal_crop_h() const {
return crop_h_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 TransformationParameter::crop_h() const {
// @@protoc_insertion_point(field_get:caffe.TransformationParameter.crop_h)
return _internal_crop_h();
}
inline void TransformationParameter::_internal_set_crop_h(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000100u;
crop_h_ = value;
}
inline void TransformationParameter::set_crop_h(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_crop_h(value);
// @@protoc_insertion_point(field_set:caffe.TransformationParameter.crop_h)
}
// optional uint32 crop_w = 12 [default = 0];
inline bool TransformationParameter::_internal_has_crop_w() const {
bool value = (_has_bits_[0] & 0x00000200u) != 0;
return value;
}
inline bool TransformationParameter::has_crop_w() const {
return _internal_has_crop_w();
}
inline void TransformationParameter::clear_crop_w() {
crop_w_ = 0u;
_has_bits_[0] &= ~0x00000200u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 TransformationParameter::_internal_crop_w() const {
return crop_w_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 TransformationParameter::crop_w() const {
// @@protoc_insertion_point(field_get:caffe.TransformationParameter.crop_w)
return _internal_crop_w();
}
inline void TransformationParameter::_internal_set_crop_w(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000200u;
crop_w_ = value;
}
inline void TransformationParameter::set_crop_w(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_crop_w(value);
// @@protoc_insertion_point(field_set:caffe.TransformationParameter.crop_w)
}
// optional string mean_file = 4;
inline bool TransformationParameter::_internal_has_mean_file() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool TransformationParameter::has_mean_file() const {
return _internal_has_mean_file();
}
inline void TransformationParameter::clear_mean_file() {
mean_file_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000001u;
}
inline const std::string& TransformationParameter::mean_file() const {
// @@protoc_insertion_point(field_get:caffe.TransformationParameter.mean_file)
return _internal_mean_file();
}
inline void TransformationParameter::set_mean_file(const std::string& value) {
_internal_set_mean_file(value);
// @@protoc_insertion_point(field_set:caffe.TransformationParameter.mean_file)
}
inline std::string* TransformationParameter::mutable_mean_file() {
// @@protoc_insertion_point(field_mutable:caffe.TransformationParameter.mean_file)
return _internal_mutable_mean_file();
}
inline const std::string& TransformationParameter::_internal_mean_file() const {
return mean_file_.Get();
}
inline void TransformationParameter::_internal_set_mean_file(const std::string& value) {
_has_bits_[0] |= 0x00000001u;
mean_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void TransformationParameter::set_mean_file(std::string&& value) {
_has_bits_[0] |= 0x00000001u;
mean_file_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.TransformationParameter.mean_file)
}
inline void TransformationParameter::set_mean_file(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000001u;
mean_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.TransformationParameter.mean_file)
}
inline void TransformationParameter::set_mean_file(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000001u;
mean_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.TransformationParameter.mean_file)
}
inline std::string* TransformationParameter::_internal_mutable_mean_file() {
_has_bits_[0] |= 0x00000001u;
return mean_file_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* TransformationParameter::release_mean_file() {
// @@protoc_insertion_point(field_release:caffe.TransformationParameter.mean_file)
if (!_internal_has_mean_file()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000001u;
return mean_file_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void TransformationParameter::set_allocated_mean_file(std::string* mean_file) {
if (mean_file != nullptr) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
mean_file_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), mean_file,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.TransformationParameter.mean_file)
}
// repeated float mean_value = 5;
inline int TransformationParameter::_internal_mean_value_size() const {
return mean_value_.size();
}
inline int TransformationParameter::mean_value_size() const {
return _internal_mean_value_size();
}
inline void TransformationParameter::clear_mean_value() {
mean_value_.Clear();
}
inline float TransformationParameter::_internal_mean_value(int index) const {
return mean_value_.Get(index);
}
inline float TransformationParameter::mean_value(int index) const {
// @@protoc_insertion_point(field_get:caffe.TransformationParameter.mean_value)
return _internal_mean_value(index);
}
inline void TransformationParameter::set_mean_value(int index, float value) {
mean_value_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.TransformationParameter.mean_value)
}
inline void TransformationParameter::_internal_add_mean_value(float value) {
mean_value_.Add(value);
}
inline void TransformationParameter::add_mean_value(float value) {
_internal_add_mean_value(value);
// @@protoc_insertion_point(field_add:caffe.TransformationParameter.mean_value)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
TransformationParameter::_internal_mean_value() const {
return mean_value_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
TransformationParameter::mean_value() const {
// @@protoc_insertion_point(field_list:caffe.TransformationParameter.mean_value)
return _internal_mean_value();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
TransformationParameter::_internal_mutable_mean_value() {
return &mean_value_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
TransformationParameter::mutable_mean_value() {
// @@protoc_insertion_point(field_mutable_list:caffe.TransformationParameter.mean_value)
return _internal_mutable_mean_value();
}
// optional bool force_color = 6 [default = false];
inline bool TransformationParameter::_internal_has_force_color() const {
bool value = (_has_bits_[0] & 0x00000040u) != 0;
return value;
}
inline bool TransformationParameter::has_force_color() const {
return _internal_has_force_color();
}
inline void TransformationParameter::clear_force_color() {
force_color_ = false;
_has_bits_[0] &= ~0x00000040u;
}
inline bool TransformationParameter::_internal_force_color() const {
return force_color_;
}
inline bool TransformationParameter::force_color() const {
// @@protoc_insertion_point(field_get:caffe.TransformationParameter.force_color)
return _internal_force_color();
}
inline void TransformationParameter::_internal_set_force_color(bool value) {
_has_bits_[0] |= 0x00000040u;
force_color_ = value;
}
inline void TransformationParameter::set_force_color(bool value) {
_internal_set_force_color(value);
// @@protoc_insertion_point(field_set:caffe.TransformationParameter.force_color)
}
// optional bool force_gray = 7 [default = false];
inline bool TransformationParameter::_internal_has_force_gray() const {
bool value = (_has_bits_[0] & 0x00000080u) != 0;
return value;
}
inline bool TransformationParameter::has_force_gray() const {
return _internal_has_force_gray();
}
inline void TransformationParameter::clear_force_gray() {
force_gray_ = false;
_has_bits_[0] &= ~0x00000080u;
}
inline bool TransformationParameter::_internal_force_gray() const {
return force_gray_;
}
inline bool TransformationParameter::force_gray() const {
// @@protoc_insertion_point(field_get:caffe.TransformationParameter.force_gray)
return _internal_force_gray();
}
inline void TransformationParameter::_internal_set_force_gray(bool value) {
_has_bits_[0] |= 0x00000080u;
force_gray_ = value;
}
inline void TransformationParameter::set_force_gray(bool value) {
_internal_set_force_gray(value);
// @@protoc_insertion_point(field_set:caffe.TransformationParameter.force_gray)
}
// optional .caffe.ResizeParameter resize_param = 8;
inline bool TransformationParameter::_internal_has_resize_param() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
PROTOBUF_ASSUME(!value || resize_param_ != nullptr);
return value;
}
inline bool TransformationParameter::has_resize_param() const {
return _internal_has_resize_param();
}
inline void TransformationParameter::clear_resize_param() {
if (resize_param_ != nullptr) resize_param_->Clear();
_has_bits_[0] &= ~0x00000002u;
}
inline const ::caffe::ResizeParameter& TransformationParameter::_internal_resize_param() const {
const ::caffe::ResizeParameter* p = resize_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ResizeParameter*>(
&::caffe::_ResizeParameter_default_instance_);
}
inline const ::caffe::ResizeParameter& TransformationParameter::resize_param() const {
// @@protoc_insertion_point(field_get:caffe.TransformationParameter.resize_param)
return _internal_resize_param();
}
inline void TransformationParameter::unsafe_arena_set_allocated_resize_param(
::caffe::ResizeParameter* resize_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(resize_param_);
}
resize_param_ = resize_param;
if (resize_param) {
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.TransformationParameter.resize_param)
}
inline ::caffe::ResizeParameter* TransformationParameter::release_resize_param() {
_has_bits_[0] &= ~0x00000002u;
::caffe::ResizeParameter* temp = resize_param_;
resize_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ResizeParameter* TransformationParameter::unsafe_arena_release_resize_param() {
// @@protoc_insertion_point(field_release:caffe.TransformationParameter.resize_param)
_has_bits_[0] &= ~0x00000002u;
::caffe::ResizeParameter* temp = resize_param_;
resize_param_ = nullptr;
return temp;
}
inline ::caffe::ResizeParameter* TransformationParameter::_internal_mutable_resize_param() {
_has_bits_[0] |= 0x00000002u;
if (resize_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ResizeParameter>(GetArena());
resize_param_ = p;
}
return resize_param_;
}
inline ::caffe::ResizeParameter* TransformationParameter::mutable_resize_param() {
// @@protoc_insertion_point(field_mutable:caffe.TransformationParameter.resize_param)
return _internal_mutable_resize_param();
}
inline void TransformationParameter::set_allocated_resize_param(::caffe::ResizeParameter* resize_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete resize_param_;
}
if (resize_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(resize_param);
if (message_arena != submessage_arena) {
resize_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, resize_param, submessage_arena);
}
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
resize_param_ = resize_param;
// @@protoc_insertion_point(field_set_allocated:caffe.TransformationParameter.resize_param)
}
// optional .caffe.NoiseParameter noise_param = 9;
inline bool TransformationParameter::_internal_has_noise_param() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
PROTOBUF_ASSUME(!value || noise_param_ != nullptr);
return value;
}
inline bool TransformationParameter::has_noise_param() const {
return _internal_has_noise_param();
}
inline void TransformationParameter::clear_noise_param() {
if (noise_param_ != nullptr) noise_param_->Clear();
_has_bits_[0] &= ~0x00000004u;
}
inline const ::caffe::NoiseParameter& TransformationParameter::_internal_noise_param() const {
const ::caffe::NoiseParameter* p = noise_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::NoiseParameter*>(
&::caffe::_NoiseParameter_default_instance_);
}
inline const ::caffe::NoiseParameter& TransformationParameter::noise_param() const {
// @@protoc_insertion_point(field_get:caffe.TransformationParameter.noise_param)
return _internal_noise_param();
}
inline void TransformationParameter::unsafe_arena_set_allocated_noise_param(
::caffe::NoiseParameter* noise_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(noise_param_);
}
noise_param_ = noise_param;
if (noise_param) {
_has_bits_[0] |= 0x00000004u;
} else {
_has_bits_[0] &= ~0x00000004u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.TransformationParameter.noise_param)
}
inline ::caffe::NoiseParameter* TransformationParameter::release_noise_param() {
_has_bits_[0] &= ~0x00000004u;
::caffe::NoiseParameter* temp = noise_param_;
noise_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::NoiseParameter* TransformationParameter::unsafe_arena_release_noise_param() {
// @@protoc_insertion_point(field_release:caffe.TransformationParameter.noise_param)
_has_bits_[0] &= ~0x00000004u;
::caffe::NoiseParameter* temp = noise_param_;
noise_param_ = nullptr;
return temp;
}
inline ::caffe::NoiseParameter* TransformationParameter::_internal_mutable_noise_param() {
_has_bits_[0] |= 0x00000004u;
if (noise_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::NoiseParameter>(GetArena());
noise_param_ = p;
}
return noise_param_;
}
inline ::caffe::NoiseParameter* TransformationParameter::mutable_noise_param() {
// @@protoc_insertion_point(field_mutable:caffe.TransformationParameter.noise_param)
return _internal_mutable_noise_param();
}
inline void TransformationParameter::set_allocated_noise_param(::caffe::NoiseParameter* noise_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete noise_param_;
}
if (noise_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(noise_param);
if (message_arena != submessage_arena) {
noise_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, noise_param, submessage_arena);
}
_has_bits_[0] |= 0x00000004u;
} else {
_has_bits_[0] &= ~0x00000004u;
}
noise_param_ = noise_param;
// @@protoc_insertion_point(field_set_allocated:caffe.TransformationParameter.noise_param)
}
// optional .caffe.EmitConstraint emit_constraint = 10;
inline bool TransformationParameter::_internal_has_emit_constraint() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
PROTOBUF_ASSUME(!value || emit_constraint_ != nullptr);
return value;
}
inline bool TransformationParameter::has_emit_constraint() const {
return _internal_has_emit_constraint();
}
inline void TransformationParameter::clear_emit_constraint() {
if (emit_constraint_ != nullptr) emit_constraint_->Clear();
_has_bits_[0] &= ~0x00000008u;
}
inline const ::caffe::EmitConstraint& TransformationParameter::_internal_emit_constraint() const {
const ::caffe::EmitConstraint* p = emit_constraint_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::EmitConstraint*>(
&::caffe::_EmitConstraint_default_instance_);
}
inline const ::caffe::EmitConstraint& TransformationParameter::emit_constraint() const {
// @@protoc_insertion_point(field_get:caffe.TransformationParameter.emit_constraint)
return _internal_emit_constraint();
}
inline void TransformationParameter::unsafe_arena_set_allocated_emit_constraint(
::caffe::EmitConstraint* emit_constraint) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(emit_constraint_);
}
emit_constraint_ = emit_constraint;
if (emit_constraint) {
_has_bits_[0] |= 0x00000008u;
} else {
_has_bits_[0] &= ~0x00000008u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.TransformationParameter.emit_constraint)
}
inline ::caffe::EmitConstraint* TransformationParameter::release_emit_constraint() {
_has_bits_[0] &= ~0x00000008u;
::caffe::EmitConstraint* temp = emit_constraint_;
emit_constraint_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::EmitConstraint* TransformationParameter::unsafe_arena_release_emit_constraint() {
// @@protoc_insertion_point(field_release:caffe.TransformationParameter.emit_constraint)
_has_bits_[0] &= ~0x00000008u;
::caffe::EmitConstraint* temp = emit_constraint_;
emit_constraint_ = nullptr;
return temp;
}
inline ::caffe::EmitConstraint* TransformationParameter::_internal_mutable_emit_constraint() {
_has_bits_[0] |= 0x00000008u;
if (emit_constraint_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::EmitConstraint>(GetArena());
emit_constraint_ = p;
}
return emit_constraint_;
}
inline ::caffe::EmitConstraint* TransformationParameter::mutable_emit_constraint() {
// @@protoc_insertion_point(field_mutable:caffe.TransformationParameter.emit_constraint)
return _internal_mutable_emit_constraint();
}
inline void TransformationParameter::set_allocated_emit_constraint(::caffe::EmitConstraint* emit_constraint) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete emit_constraint_;
}
if (emit_constraint) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(emit_constraint);
if (message_arena != submessage_arena) {
emit_constraint = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, emit_constraint, submessage_arena);
}
_has_bits_[0] |= 0x00000008u;
} else {
_has_bits_[0] &= ~0x00000008u;
}
emit_constraint_ = emit_constraint;
// @@protoc_insertion_point(field_set_allocated:caffe.TransformationParameter.emit_constraint)
}
// -------------------------------------------------------------------
// ResizeParameter
// optional float prob = 1 [default = 1];
inline bool ResizeParameter::_internal_has_prob() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool ResizeParameter::has_prob() const {
return _internal_has_prob();
}
inline void ResizeParameter::clear_prob() {
prob_ = 1;
_has_bits_[0] &= ~0x00000008u;
}
inline float ResizeParameter::_internal_prob() const {
return prob_;
}
inline float ResizeParameter::prob() const {
// @@protoc_insertion_point(field_get:caffe.ResizeParameter.prob)
return _internal_prob();
}
inline void ResizeParameter::_internal_set_prob(float value) {
_has_bits_[0] |= 0x00000008u;
prob_ = value;
}
inline void ResizeParameter::set_prob(float value) {
_internal_set_prob(value);
// @@protoc_insertion_point(field_set:caffe.ResizeParameter.prob)
}
// optional .caffe.ResizeParameter.Resize_mode resize_mode = 2 [default = WARP];
inline bool ResizeParameter::_internal_has_resize_mode() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool ResizeParameter::has_resize_mode() const {
return _internal_has_resize_mode();
}
inline void ResizeParameter::clear_resize_mode() {
resize_mode_ = 1;
_has_bits_[0] &= ~0x00000010u;
}
inline ::caffe::ResizeParameter_Resize_mode ResizeParameter::_internal_resize_mode() const {
return static_cast< ::caffe::ResizeParameter_Resize_mode >(resize_mode_);
}
inline ::caffe::ResizeParameter_Resize_mode ResizeParameter::resize_mode() const {
// @@protoc_insertion_point(field_get:caffe.ResizeParameter.resize_mode)
return _internal_resize_mode();
}
inline void ResizeParameter::_internal_set_resize_mode(::caffe::ResizeParameter_Resize_mode value) {
assert(::caffe::ResizeParameter_Resize_mode_IsValid(value));
_has_bits_[0] |= 0x00000010u;
resize_mode_ = value;
}
inline void ResizeParameter::set_resize_mode(::caffe::ResizeParameter_Resize_mode value) {
_internal_set_resize_mode(value);
// @@protoc_insertion_point(field_set:caffe.ResizeParameter.resize_mode)
}
// optional uint32 height = 3 [default = 0];
inline bool ResizeParameter::_internal_has_height() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool ResizeParameter::has_height() const {
return _internal_has_height();
}
inline void ResizeParameter::clear_height() {
height_ = 0u;
_has_bits_[0] &= ~0x00000001u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ResizeParameter::_internal_height() const {
return height_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ResizeParameter::height() const {
// @@protoc_insertion_point(field_get:caffe.ResizeParameter.height)
return _internal_height();
}
inline void ResizeParameter::_internal_set_height(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000001u;
height_ = value;
}
inline void ResizeParameter::set_height(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_height(value);
// @@protoc_insertion_point(field_set:caffe.ResizeParameter.height)
}
// optional uint32 width = 4 [default = 0];
inline bool ResizeParameter::_internal_has_width() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool ResizeParameter::has_width() const {
return _internal_has_width();
}
inline void ResizeParameter::clear_width() {
width_ = 0u;
_has_bits_[0] &= ~0x00000002u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ResizeParameter::_internal_width() const {
return width_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ResizeParameter::width() const {
// @@protoc_insertion_point(field_get:caffe.ResizeParameter.width)
return _internal_width();
}
inline void ResizeParameter::_internal_set_width(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000002u;
width_ = value;
}
inline void ResizeParameter::set_width(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_width(value);
// @@protoc_insertion_point(field_set:caffe.ResizeParameter.width)
}
// optional .caffe.ResizeParameter.Pad_mode pad_mode = 5 [default = CONSTANT];
inline bool ResizeParameter::_internal_has_pad_mode() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool ResizeParameter::has_pad_mode() const {
return _internal_has_pad_mode();
}
inline void ResizeParameter::clear_pad_mode() {
pad_mode_ = 1;
_has_bits_[0] &= ~0x00000004u;
}
inline ::caffe::ResizeParameter_Pad_mode ResizeParameter::_internal_pad_mode() const {
return static_cast< ::caffe::ResizeParameter_Pad_mode >(pad_mode_);
}
inline ::caffe::ResizeParameter_Pad_mode ResizeParameter::pad_mode() const {
// @@protoc_insertion_point(field_get:caffe.ResizeParameter.pad_mode)
return _internal_pad_mode();
}
inline void ResizeParameter::_internal_set_pad_mode(::caffe::ResizeParameter_Pad_mode value) {
assert(::caffe::ResizeParameter_Pad_mode_IsValid(value));
_has_bits_[0] |= 0x00000004u;
pad_mode_ = value;
}
inline void ResizeParameter::set_pad_mode(::caffe::ResizeParameter_Pad_mode value) {
_internal_set_pad_mode(value);
// @@protoc_insertion_point(field_set:caffe.ResizeParameter.pad_mode)
}
// repeated float pad_value = 6;
inline int ResizeParameter::_internal_pad_value_size() const {
return pad_value_.size();
}
inline int ResizeParameter::pad_value_size() const {
return _internal_pad_value_size();
}
inline void ResizeParameter::clear_pad_value() {
pad_value_.Clear();
}
inline float ResizeParameter::_internal_pad_value(int index) const {
return pad_value_.Get(index);
}
inline float ResizeParameter::pad_value(int index) const {
// @@protoc_insertion_point(field_get:caffe.ResizeParameter.pad_value)
return _internal_pad_value(index);
}
inline void ResizeParameter::set_pad_value(int index, float value) {
pad_value_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.ResizeParameter.pad_value)
}
inline void ResizeParameter::_internal_add_pad_value(float value) {
pad_value_.Add(value);
}
inline void ResizeParameter::add_pad_value(float value) {
_internal_add_pad_value(value);
// @@protoc_insertion_point(field_add:caffe.ResizeParameter.pad_value)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
ResizeParameter::_internal_pad_value() const {
return pad_value_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
ResizeParameter::pad_value() const {
// @@protoc_insertion_point(field_list:caffe.ResizeParameter.pad_value)
return _internal_pad_value();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
ResizeParameter::_internal_mutable_pad_value() {
return &pad_value_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
ResizeParameter::mutable_pad_value() {
// @@protoc_insertion_point(field_mutable_list:caffe.ResizeParameter.pad_value)
return _internal_mutable_pad_value();
}
// repeated .caffe.ResizeParameter.Interp_mode interp_mode = 7;
inline int ResizeParameter::_internal_interp_mode_size() const {
return interp_mode_.size();
}
inline int ResizeParameter::interp_mode_size() const {
return _internal_interp_mode_size();
}
inline void ResizeParameter::clear_interp_mode() {
interp_mode_.Clear();
}
inline ::caffe::ResizeParameter_Interp_mode ResizeParameter::_internal_interp_mode(int index) const {
return static_cast< ::caffe::ResizeParameter_Interp_mode >(interp_mode_.Get(index));
}
inline ::caffe::ResizeParameter_Interp_mode ResizeParameter::interp_mode(int index) const {
// @@protoc_insertion_point(field_get:caffe.ResizeParameter.interp_mode)
return _internal_interp_mode(index);
}
inline void ResizeParameter::set_interp_mode(int index, ::caffe::ResizeParameter_Interp_mode value) {
assert(::caffe::ResizeParameter_Interp_mode_IsValid(value));
interp_mode_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.ResizeParameter.interp_mode)
}
inline void ResizeParameter::_internal_add_interp_mode(::caffe::ResizeParameter_Interp_mode value) {
assert(::caffe::ResizeParameter_Interp_mode_IsValid(value));
interp_mode_.Add(value);
}
inline void ResizeParameter::add_interp_mode(::caffe::ResizeParameter_Interp_mode value) {
// @@protoc_insertion_point(field_add:caffe.ResizeParameter.interp_mode)
_internal_add_interp_mode(value);
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField<int>&
ResizeParameter::interp_mode() const {
// @@protoc_insertion_point(field_list:caffe.ResizeParameter.interp_mode)
return interp_mode_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField<int>*
ResizeParameter::_internal_mutable_interp_mode() {
return &interp_mode_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField<int>*
ResizeParameter::mutable_interp_mode() {
// @@protoc_insertion_point(field_mutable_list:caffe.ResizeParameter.interp_mode)
return _internal_mutable_interp_mode();
}
// -------------------------------------------------------------------
// SaltPepperParameter
// optional float fraction = 1 [default = 0];
inline bool SaltPepperParameter::_internal_has_fraction() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool SaltPepperParameter::has_fraction() const {
return _internal_has_fraction();
}
inline void SaltPepperParameter::clear_fraction() {
fraction_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline float SaltPepperParameter::_internal_fraction() const {
return fraction_;
}
inline float SaltPepperParameter::fraction() const {
// @@protoc_insertion_point(field_get:caffe.SaltPepperParameter.fraction)
return _internal_fraction();
}
inline void SaltPepperParameter::_internal_set_fraction(float value) {
_has_bits_[0] |= 0x00000001u;
fraction_ = value;
}
inline void SaltPepperParameter::set_fraction(float value) {
_internal_set_fraction(value);
// @@protoc_insertion_point(field_set:caffe.SaltPepperParameter.fraction)
}
// repeated float value = 2;
inline int SaltPepperParameter::_internal_value_size() const {
return value_.size();
}
inline int SaltPepperParameter::value_size() const {
return _internal_value_size();
}
inline void SaltPepperParameter::clear_value() {
value_.Clear();
}
inline float SaltPepperParameter::_internal_value(int index) const {
return value_.Get(index);
}
inline float SaltPepperParameter::value(int index) const {
// @@protoc_insertion_point(field_get:caffe.SaltPepperParameter.value)
return _internal_value(index);
}
inline void SaltPepperParameter::set_value(int index, float value) {
value_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.SaltPepperParameter.value)
}
inline void SaltPepperParameter::_internal_add_value(float value) {
value_.Add(value);
}
inline void SaltPepperParameter::add_value(float value) {
_internal_add_value(value);
// @@protoc_insertion_point(field_add:caffe.SaltPepperParameter.value)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
SaltPepperParameter::_internal_value() const {
return value_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
SaltPepperParameter::value() const {
// @@protoc_insertion_point(field_list:caffe.SaltPepperParameter.value)
return _internal_value();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
SaltPepperParameter::_internal_mutable_value() {
return &value_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
SaltPepperParameter::mutable_value() {
// @@protoc_insertion_point(field_mutable_list:caffe.SaltPepperParameter.value)
return _internal_mutable_value();
}
// -------------------------------------------------------------------
// NoiseParameter
// optional float prob = 1 [default = 0];
inline bool NoiseParameter::_internal_has_prob() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool NoiseParameter::has_prob() const {
return _internal_has_prob();
}
inline void NoiseParameter::clear_prob() {
prob_ = 0;
_has_bits_[0] &= ~0x00000002u;
}
inline float NoiseParameter::_internal_prob() const {
return prob_;
}
inline float NoiseParameter::prob() const {
// @@protoc_insertion_point(field_get:caffe.NoiseParameter.prob)
return _internal_prob();
}
inline void NoiseParameter::_internal_set_prob(float value) {
_has_bits_[0] |= 0x00000002u;
prob_ = value;
}
inline void NoiseParameter::set_prob(float value) {
_internal_set_prob(value);
// @@protoc_insertion_point(field_set:caffe.NoiseParameter.prob)
}
// optional bool hist_eq = 2 [default = false];
inline bool NoiseParameter::_internal_has_hist_eq() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool NoiseParameter::has_hist_eq() const {
return _internal_has_hist_eq();
}
inline void NoiseParameter::clear_hist_eq() {
hist_eq_ = false;
_has_bits_[0] &= ~0x00000004u;
}
inline bool NoiseParameter::_internal_hist_eq() const {
return hist_eq_;
}
inline bool NoiseParameter::hist_eq() const {
// @@protoc_insertion_point(field_get:caffe.NoiseParameter.hist_eq)
return _internal_hist_eq();
}
inline void NoiseParameter::_internal_set_hist_eq(bool value) {
_has_bits_[0] |= 0x00000004u;
hist_eq_ = value;
}
inline void NoiseParameter::set_hist_eq(bool value) {
_internal_set_hist_eq(value);
// @@protoc_insertion_point(field_set:caffe.NoiseParameter.hist_eq)
}
// optional bool inverse = 3 [default = false];
inline bool NoiseParameter::_internal_has_inverse() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool NoiseParameter::has_inverse() const {
return _internal_has_inverse();
}
inline void NoiseParameter::clear_inverse() {
inverse_ = false;
_has_bits_[0] &= ~0x00000008u;
}
inline bool NoiseParameter::_internal_inverse() const {
return inverse_;
}
inline bool NoiseParameter::inverse() const {
// @@protoc_insertion_point(field_get:caffe.NoiseParameter.inverse)
return _internal_inverse();
}
inline void NoiseParameter::_internal_set_inverse(bool value) {
_has_bits_[0] |= 0x00000008u;
inverse_ = value;
}
inline void NoiseParameter::set_inverse(bool value) {
_internal_set_inverse(value);
// @@protoc_insertion_point(field_set:caffe.NoiseParameter.inverse)
}
// optional bool decolorize = 4 [default = false];
inline bool NoiseParameter::_internal_has_decolorize() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool NoiseParameter::has_decolorize() const {
return _internal_has_decolorize();
}
inline void NoiseParameter::clear_decolorize() {
decolorize_ = false;
_has_bits_[0] &= ~0x00000010u;
}
inline bool NoiseParameter::_internal_decolorize() const {
return decolorize_;
}
inline bool NoiseParameter::decolorize() const {
// @@protoc_insertion_point(field_get:caffe.NoiseParameter.decolorize)
return _internal_decolorize();
}
inline void NoiseParameter::_internal_set_decolorize(bool value) {
_has_bits_[0] |= 0x00000010u;
decolorize_ = value;
}
inline void NoiseParameter::set_decolorize(bool value) {
_internal_set_decolorize(value);
// @@protoc_insertion_point(field_set:caffe.NoiseParameter.decolorize)
}
// optional bool gauss_blur = 5 [default = false];
inline bool NoiseParameter::_internal_has_gauss_blur() const {
bool value = (_has_bits_[0] & 0x00000020u) != 0;
return value;
}
inline bool NoiseParameter::has_gauss_blur() const {
return _internal_has_gauss_blur();
}
inline void NoiseParameter::clear_gauss_blur() {
gauss_blur_ = false;
_has_bits_[0] &= ~0x00000020u;
}
inline bool NoiseParameter::_internal_gauss_blur() const {
return gauss_blur_;
}
inline bool NoiseParameter::gauss_blur() const {
// @@protoc_insertion_point(field_get:caffe.NoiseParameter.gauss_blur)
return _internal_gauss_blur();
}
inline void NoiseParameter::_internal_set_gauss_blur(bool value) {
_has_bits_[0] |= 0x00000020u;
gauss_blur_ = value;
}
inline void NoiseParameter::set_gauss_blur(bool value) {
_internal_set_gauss_blur(value);
// @@protoc_insertion_point(field_set:caffe.NoiseParameter.gauss_blur)
}
// optional float jpeg = 6 [default = -1];
inline bool NoiseParameter::_internal_has_jpeg() const {
bool value = (_has_bits_[0] & 0x00001000u) != 0;
return value;
}
inline bool NoiseParameter::has_jpeg() const {
return _internal_has_jpeg();
}
inline void NoiseParameter::clear_jpeg() {
jpeg_ = -1;
_has_bits_[0] &= ~0x00001000u;
}
inline float NoiseParameter::_internal_jpeg() const {
return jpeg_;
}
inline float NoiseParameter::jpeg() const {
// @@protoc_insertion_point(field_get:caffe.NoiseParameter.jpeg)
return _internal_jpeg();
}
inline void NoiseParameter::_internal_set_jpeg(float value) {
_has_bits_[0] |= 0x00001000u;
jpeg_ = value;
}
inline void NoiseParameter::set_jpeg(float value) {
_internal_set_jpeg(value);
// @@protoc_insertion_point(field_set:caffe.NoiseParameter.jpeg)
}
// optional bool posterize = 7 [default = false];
inline bool NoiseParameter::_internal_has_posterize() const {
bool value = (_has_bits_[0] & 0x00000040u) != 0;
return value;
}
inline bool NoiseParameter::has_posterize() const {
return _internal_has_posterize();
}
inline void NoiseParameter::clear_posterize() {
posterize_ = false;
_has_bits_[0] &= ~0x00000040u;
}
inline bool NoiseParameter::_internal_posterize() const {
return posterize_;
}
inline bool NoiseParameter::posterize() const {
// @@protoc_insertion_point(field_get:caffe.NoiseParameter.posterize)
return _internal_posterize();
}
inline void NoiseParameter::_internal_set_posterize(bool value) {
_has_bits_[0] |= 0x00000040u;
posterize_ = value;
}
inline void NoiseParameter::set_posterize(bool value) {
_internal_set_posterize(value);
// @@protoc_insertion_point(field_set:caffe.NoiseParameter.posterize)
}
// optional bool erode = 8 [default = false];
inline bool NoiseParameter::_internal_has_erode() const {
bool value = (_has_bits_[0] & 0x00000080u) != 0;
return value;
}
inline bool NoiseParameter::has_erode() const {
return _internal_has_erode();
}
inline void NoiseParameter::clear_erode() {
erode_ = false;
_has_bits_[0] &= ~0x00000080u;
}
inline bool NoiseParameter::_internal_erode() const {
return erode_;
}
inline bool NoiseParameter::erode() const {
// @@protoc_insertion_point(field_get:caffe.NoiseParameter.erode)
return _internal_erode();
}
inline void NoiseParameter::_internal_set_erode(bool value) {
_has_bits_[0] |= 0x00000080u;
erode_ = value;
}
inline void NoiseParameter::set_erode(bool value) {
_internal_set_erode(value);
// @@protoc_insertion_point(field_set:caffe.NoiseParameter.erode)
}
// optional bool saltpepper = 9 [default = false];
inline bool NoiseParameter::_internal_has_saltpepper() const {
bool value = (_has_bits_[0] & 0x00000100u) != 0;
return value;
}
inline bool NoiseParameter::has_saltpepper() const {
return _internal_has_saltpepper();
}
inline void NoiseParameter::clear_saltpepper() {
saltpepper_ = false;
_has_bits_[0] &= ~0x00000100u;
}
inline bool NoiseParameter::_internal_saltpepper() const {
return saltpepper_;
}
inline bool NoiseParameter::saltpepper() const {
// @@protoc_insertion_point(field_get:caffe.NoiseParameter.saltpepper)
return _internal_saltpepper();
}
inline void NoiseParameter::_internal_set_saltpepper(bool value) {
_has_bits_[0] |= 0x00000100u;
saltpepper_ = value;
}
inline void NoiseParameter::set_saltpepper(bool value) {
_internal_set_saltpepper(value);
// @@protoc_insertion_point(field_set:caffe.NoiseParameter.saltpepper)
}
// optional .caffe.SaltPepperParameter saltpepper_param = 10;
inline bool NoiseParameter::_internal_has_saltpepper_param() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
PROTOBUF_ASSUME(!value || saltpepper_param_ != nullptr);
return value;
}
inline bool NoiseParameter::has_saltpepper_param() const {
return _internal_has_saltpepper_param();
}
inline void NoiseParameter::clear_saltpepper_param() {
if (saltpepper_param_ != nullptr) saltpepper_param_->Clear();
_has_bits_[0] &= ~0x00000001u;
}
inline const ::caffe::SaltPepperParameter& NoiseParameter::_internal_saltpepper_param() const {
const ::caffe::SaltPepperParameter* p = saltpepper_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::SaltPepperParameter*>(
&::caffe::_SaltPepperParameter_default_instance_);
}
inline const ::caffe::SaltPepperParameter& NoiseParameter::saltpepper_param() const {
// @@protoc_insertion_point(field_get:caffe.NoiseParameter.saltpepper_param)
return _internal_saltpepper_param();
}
inline void NoiseParameter::unsafe_arena_set_allocated_saltpepper_param(
::caffe::SaltPepperParameter* saltpepper_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(saltpepper_param_);
}
saltpepper_param_ = saltpepper_param;
if (saltpepper_param) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.NoiseParameter.saltpepper_param)
}
inline ::caffe::SaltPepperParameter* NoiseParameter::release_saltpepper_param() {
_has_bits_[0] &= ~0x00000001u;
::caffe::SaltPepperParameter* temp = saltpepper_param_;
saltpepper_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::SaltPepperParameter* NoiseParameter::unsafe_arena_release_saltpepper_param() {
// @@protoc_insertion_point(field_release:caffe.NoiseParameter.saltpepper_param)
_has_bits_[0] &= ~0x00000001u;
::caffe::SaltPepperParameter* temp = saltpepper_param_;
saltpepper_param_ = nullptr;
return temp;
}
inline ::caffe::SaltPepperParameter* NoiseParameter::_internal_mutable_saltpepper_param() {
_has_bits_[0] |= 0x00000001u;
if (saltpepper_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::SaltPepperParameter>(GetArena());
saltpepper_param_ = p;
}
return saltpepper_param_;
}
inline ::caffe::SaltPepperParameter* NoiseParameter::mutable_saltpepper_param() {
// @@protoc_insertion_point(field_mutable:caffe.NoiseParameter.saltpepper_param)
return _internal_mutable_saltpepper_param();
}
inline void NoiseParameter::set_allocated_saltpepper_param(::caffe::SaltPepperParameter* saltpepper_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete saltpepper_param_;
}
if (saltpepper_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(saltpepper_param);
if (message_arena != submessage_arena) {
saltpepper_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, saltpepper_param, submessage_arena);
}
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
saltpepper_param_ = saltpepper_param;
// @@protoc_insertion_point(field_set_allocated:caffe.NoiseParameter.saltpepper_param)
}
// optional bool clahe = 11 [default = false];
inline bool NoiseParameter::_internal_has_clahe() const {
bool value = (_has_bits_[0] & 0x00000200u) != 0;
return value;
}
inline bool NoiseParameter::has_clahe() const {
return _internal_has_clahe();
}
inline void NoiseParameter::clear_clahe() {
clahe_ = false;
_has_bits_[0] &= ~0x00000200u;
}
inline bool NoiseParameter::_internal_clahe() const {
return clahe_;
}
inline bool NoiseParameter::clahe() const {
// @@protoc_insertion_point(field_get:caffe.NoiseParameter.clahe)
return _internal_clahe();
}
inline void NoiseParameter::_internal_set_clahe(bool value) {
_has_bits_[0] |= 0x00000200u;
clahe_ = value;
}
inline void NoiseParameter::set_clahe(bool value) {
_internal_set_clahe(value);
// @@protoc_insertion_point(field_set:caffe.NoiseParameter.clahe)
}
// optional bool convert_to_hsv = 12 [default = false];
inline bool NoiseParameter::_internal_has_convert_to_hsv() const {
bool value = (_has_bits_[0] & 0x00000400u) != 0;
return value;
}
inline bool NoiseParameter::has_convert_to_hsv() const {
return _internal_has_convert_to_hsv();
}
inline void NoiseParameter::clear_convert_to_hsv() {
convert_to_hsv_ = false;
_has_bits_[0] &= ~0x00000400u;
}
inline bool NoiseParameter::_internal_convert_to_hsv() const {
return convert_to_hsv_;
}
inline bool NoiseParameter::convert_to_hsv() const {
// @@protoc_insertion_point(field_get:caffe.NoiseParameter.convert_to_hsv)
return _internal_convert_to_hsv();
}
inline void NoiseParameter::_internal_set_convert_to_hsv(bool value) {
_has_bits_[0] |= 0x00000400u;
convert_to_hsv_ = value;
}
inline void NoiseParameter::set_convert_to_hsv(bool value) {
_internal_set_convert_to_hsv(value);
// @@protoc_insertion_point(field_set:caffe.NoiseParameter.convert_to_hsv)
}
// optional bool convert_to_lab = 13 [default = false];
inline bool NoiseParameter::_internal_has_convert_to_lab() const {
bool value = (_has_bits_[0] & 0x00000800u) != 0;
return value;
}
inline bool NoiseParameter::has_convert_to_lab() const {
return _internal_has_convert_to_lab();
}
inline void NoiseParameter::clear_convert_to_lab() {
convert_to_lab_ = false;
_has_bits_[0] &= ~0x00000800u;
}
inline bool NoiseParameter::_internal_convert_to_lab() const {
return convert_to_lab_;
}
inline bool NoiseParameter::convert_to_lab() const {
// @@protoc_insertion_point(field_get:caffe.NoiseParameter.convert_to_lab)
return _internal_convert_to_lab();
}
inline void NoiseParameter::_internal_set_convert_to_lab(bool value) {
_has_bits_[0] |= 0x00000800u;
convert_to_lab_ = value;
}
inline void NoiseParameter::set_convert_to_lab(bool value) {
_internal_set_convert_to_lab(value);
// @@protoc_insertion_point(field_set:caffe.NoiseParameter.convert_to_lab)
}
// -------------------------------------------------------------------
// LossParameter
// optional int32 ignore_label = 1;
inline bool LossParameter::_internal_has_ignore_label() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool LossParameter::has_ignore_label() const {
return _internal_has_ignore_label();
}
inline void LossParameter::clear_ignore_label() {
ignore_label_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 LossParameter::_internal_ignore_label() const {
return ignore_label_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 LossParameter::ignore_label() const {
// @@protoc_insertion_point(field_get:caffe.LossParameter.ignore_label)
return _internal_ignore_label();
}
inline void LossParameter::_internal_set_ignore_label(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000001u;
ignore_label_ = value;
}
inline void LossParameter::set_ignore_label(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_ignore_label(value);
// @@protoc_insertion_point(field_set:caffe.LossParameter.ignore_label)
}
// optional .caffe.LossParameter.NormalizationMode normalization = 3 [default = VALID];
inline bool LossParameter::_internal_has_normalization() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool LossParameter::has_normalization() const {
return _internal_has_normalization();
}
inline void LossParameter::clear_normalization() {
normalization_ = 1;
_has_bits_[0] &= ~0x00000004u;
}
inline ::caffe::LossParameter_NormalizationMode LossParameter::_internal_normalization() const {
return static_cast< ::caffe::LossParameter_NormalizationMode >(normalization_);
}
inline ::caffe::LossParameter_NormalizationMode LossParameter::normalization() const {
// @@protoc_insertion_point(field_get:caffe.LossParameter.normalization)
return _internal_normalization();
}
inline void LossParameter::_internal_set_normalization(::caffe::LossParameter_NormalizationMode value) {
assert(::caffe::LossParameter_NormalizationMode_IsValid(value));
_has_bits_[0] |= 0x00000004u;
normalization_ = value;
}
inline void LossParameter::set_normalization(::caffe::LossParameter_NormalizationMode value) {
_internal_set_normalization(value);
// @@protoc_insertion_point(field_set:caffe.LossParameter.normalization)
}
// optional bool normalize = 2;
inline bool LossParameter::_internal_has_normalize() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool LossParameter::has_normalize() const {
return _internal_has_normalize();
}
inline void LossParameter::clear_normalize() {
normalize_ = false;
_has_bits_[0] &= ~0x00000002u;
}
inline bool LossParameter::_internal_normalize() const {
return normalize_;
}
inline bool LossParameter::normalize() const {
// @@protoc_insertion_point(field_get:caffe.LossParameter.normalize)
return _internal_normalize();
}
inline void LossParameter::_internal_set_normalize(bool value) {
_has_bits_[0] |= 0x00000002u;
normalize_ = value;
}
inline void LossParameter::set_normalize(bool value) {
_internal_set_normalize(value);
// @@protoc_insertion_point(field_set:caffe.LossParameter.normalize)
}
// -------------------------------------------------------------------
// AccuracyParameter
// optional uint32 top_k = 1 [default = 1];
inline bool AccuracyParameter::_internal_has_top_k() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool AccuracyParameter::has_top_k() const {
return _internal_has_top_k();
}
inline void AccuracyParameter::clear_top_k() {
top_k_ = 1u;
_has_bits_[0] &= ~0x00000002u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 AccuracyParameter::_internal_top_k() const {
return top_k_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 AccuracyParameter::top_k() const {
// @@protoc_insertion_point(field_get:caffe.AccuracyParameter.top_k)
return _internal_top_k();
}
inline void AccuracyParameter::_internal_set_top_k(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000002u;
top_k_ = value;
}
inline void AccuracyParameter::set_top_k(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_top_k(value);
// @@protoc_insertion_point(field_set:caffe.AccuracyParameter.top_k)
}
// optional int32 axis = 2 [default = 1];
inline bool AccuracyParameter::_internal_has_axis() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool AccuracyParameter::has_axis() const {
return _internal_has_axis();
}
inline void AccuracyParameter::clear_axis() {
axis_ = 1;
_has_bits_[0] &= ~0x00000004u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 AccuracyParameter::_internal_axis() const {
return axis_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 AccuracyParameter::axis() const {
// @@protoc_insertion_point(field_get:caffe.AccuracyParameter.axis)
return _internal_axis();
}
inline void AccuracyParameter::_internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000004u;
axis_ = value;
}
inline void AccuracyParameter::set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_axis(value);
// @@protoc_insertion_point(field_set:caffe.AccuracyParameter.axis)
}
// optional int32 ignore_label = 3;
inline bool AccuracyParameter::_internal_has_ignore_label() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool AccuracyParameter::has_ignore_label() const {
return _internal_has_ignore_label();
}
inline void AccuracyParameter::clear_ignore_label() {
ignore_label_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 AccuracyParameter::_internal_ignore_label() const {
return ignore_label_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 AccuracyParameter::ignore_label() const {
// @@protoc_insertion_point(field_get:caffe.AccuracyParameter.ignore_label)
return _internal_ignore_label();
}
inline void AccuracyParameter::_internal_set_ignore_label(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000001u;
ignore_label_ = value;
}
inline void AccuracyParameter::set_ignore_label(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_ignore_label(value);
// @@protoc_insertion_point(field_set:caffe.AccuracyParameter.ignore_label)
}
// -------------------------------------------------------------------
// AnnotatedDataParameter
// repeated .caffe.BatchSampler batch_sampler = 1;
inline int AnnotatedDataParameter::_internal_batch_sampler_size() const {
return batch_sampler_.size();
}
inline int AnnotatedDataParameter::batch_sampler_size() const {
return _internal_batch_sampler_size();
}
inline void AnnotatedDataParameter::clear_batch_sampler() {
batch_sampler_.Clear();
}
inline ::caffe::BatchSampler* AnnotatedDataParameter::mutable_batch_sampler(int index) {
// @@protoc_insertion_point(field_mutable:caffe.AnnotatedDataParameter.batch_sampler)
return batch_sampler_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BatchSampler >*
AnnotatedDataParameter::mutable_batch_sampler() {
// @@protoc_insertion_point(field_mutable_list:caffe.AnnotatedDataParameter.batch_sampler)
return &batch_sampler_;
}
inline const ::caffe::BatchSampler& AnnotatedDataParameter::_internal_batch_sampler(int index) const {
return batch_sampler_.Get(index);
}
inline const ::caffe::BatchSampler& AnnotatedDataParameter::batch_sampler(int index) const {
// @@protoc_insertion_point(field_get:caffe.AnnotatedDataParameter.batch_sampler)
return _internal_batch_sampler(index);
}
inline ::caffe::BatchSampler* AnnotatedDataParameter::_internal_add_batch_sampler() {
return batch_sampler_.Add();
}
inline ::caffe::BatchSampler* AnnotatedDataParameter::add_batch_sampler() {
// @@protoc_insertion_point(field_add:caffe.AnnotatedDataParameter.batch_sampler)
return _internal_add_batch_sampler();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BatchSampler >&
AnnotatedDataParameter::batch_sampler() const {
// @@protoc_insertion_point(field_list:caffe.AnnotatedDataParameter.batch_sampler)
return batch_sampler_;
}
// optional string label_map_file = 2;
inline bool AnnotatedDataParameter::_internal_has_label_map_file() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool AnnotatedDataParameter::has_label_map_file() const {
return _internal_has_label_map_file();
}
inline void AnnotatedDataParameter::clear_label_map_file() {
label_map_file_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000001u;
}
inline const std::string& AnnotatedDataParameter::label_map_file() const {
// @@protoc_insertion_point(field_get:caffe.AnnotatedDataParameter.label_map_file)
return _internal_label_map_file();
}
inline void AnnotatedDataParameter::set_label_map_file(const std::string& value) {
_internal_set_label_map_file(value);
// @@protoc_insertion_point(field_set:caffe.AnnotatedDataParameter.label_map_file)
}
inline std::string* AnnotatedDataParameter::mutable_label_map_file() {
// @@protoc_insertion_point(field_mutable:caffe.AnnotatedDataParameter.label_map_file)
return _internal_mutable_label_map_file();
}
inline const std::string& AnnotatedDataParameter::_internal_label_map_file() const {
return label_map_file_.Get();
}
inline void AnnotatedDataParameter::_internal_set_label_map_file(const std::string& value) {
_has_bits_[0] |= 0x00000001u;
label_map_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void AnnotatedDataParameter::set_label_map_file(std::string&& value) {
_has_bits_[0] |= 0x00000001u;
label_map_file_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.AnnotatedDataParameter.label_map_file)
}
inline void AnnotatedDataParameter::set_label_map_file(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000001u;
label_map_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.AnnotatedDataParameter.label_map_file)
}
inline void AnnotatedDataParameter::set_label_map_file(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000001u;
label_map_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.AnnotatedDataParameter.label_map_file)
}
inline std::string* AnnotatedDataParameter::_internal_mutable_label_map_file() {
_has_bits_[0] |= 0x00000001u;
return label_map_file_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* AnnotatedDataParameter::release_label_map_file() {
// @@protoc_insertion_point(field_release:caffe.AnnotatedDataParameter.label_map_file)
if (!_internal_has_label_map_file()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000001u;
return label_map_file_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void AnnotatedDataParameter::set_allocated_label_map_file(std::string* label_map_file) {
if (label_map_file != nullptr) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
label_map_file_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), label_map_file,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.AnnotatedDataParameter.label_map_file)
}
// -------------------------------------------------------------------
// ArgMaxParameter
// optional bool out_max_val = 1 [default = false];
inline bool ArgMaxParameter::_internal_has_out_max_val() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool ArgMaxParameter::has_out_max_val() const {
return _internal_has_out_max_val();
}
inline void ArgMaxParameter::clear_out_max_val() {
out_max_val_ = false;
_has_bits_[0] &= ~0x00000001u;
}
inline bool ArgMaxParameter::_internal_out_max_val() const {
return out_max_val_;
}
inline bool ArgMaxParameter::out_max_val() const {
// @@protoc_insertion_point(field_get:caffe.ArgMaxParameter.out_max_val)
return _internal_out_max_val();
}
inline void ArgMaxParameter::_internal_set_out_max_val(bool value) {
_has_bits_[0] |= 0x00000001u;
out_max_val_ = value;
}
inline void ArgMaxParameter::set_out_max_val(bool value) {
_internal_set_out_max_val(value);
// @@protoc_insertion_point(field_set:caffe.ArgMaxParameter.out_max_val)
}
// optional uint32 top_k = 2 [default = 1];
inline bool ArgMaxParameter::_internal_has_top_k() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool ArgMaxParameter::has_top_k() const {
return _internal_has_top_k();
}
inline void ArgMaxParameter::clear_top_k() {
top_k_ = 1u;
_has_bits_[0] &= ~0x00000004u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ArgMaxParameter::_internal_top_k() const {
return top_k_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ArgMaxParameter::top_k() const {
// @@protoc_insertion_point(field_get:caffe.ArgMaxParameter.top_k)
return _internal_top_k();
}
inline void ArgMaxParameter::_internal_set_top_k(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000004u;
top_k_ = value;
}
inline void ArgMaxParameter::set_top_k(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_top_k(value);
// @@protoc_insertion_point(field_set:caffe.ArgMaxParameter.top_k)
}
// optional int32 axis = 3;
inline bool ArgMaxParameter::_internal_has_axis() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool ArgMaxParameter::has_axis() const {
return _internal_has_axis();
}
inline void ArgMaxParameter::clear_axis() {
axis_ = 0;
_has_bits_[0] &= ~0x00000002u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 ArgMaxParameter::_internal_axis() const {
return axis_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 ArgMaxParameter::axis() const {
// @@protoc_insertion_point(field_get:caffe.ArgMaxParameter.axis)
return _internal_axis();
}
inline void ArgMaxParameter::_internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000002u;
axis_ = value;
}
inline void ArgMaxParameter::set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_axis(value);
// @@protoc_insertion_point(field_set:caffe.ArgMaxParameter.axis)
}
// -------------------------------------------------------------------
// ConcatParameter
// optional int32 axis = 2 [default = 1];
inline bool ConcatParameter::_internal_has_axis() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool ConcatParameter::has_axis() const {
return _internal_has_axis();
}
inline void ConcatParameter::clear_axis() {
axis_ = 1;
_has_bits_[0] &= ~0x00000002u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 ConcatParameter::_internal_axis() const {
return axis_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 ConcatParameter::axis() const {
// @@protoc_insertion_point(field_get:caffe.ConcatParameter.axis)
return _internal_axis();
}
inline void ConcatParameter::_internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000002u;
axis_ = value;
}
inline void ConcatParameter::set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_axis(value);
// @@protoc_insertion_point(field_set:caffe.ConcatParameter.axis)
}
// optional uint32 concat_dim = 1 [default = 1];
inline bool ConcatParameter::_internal_has_concat_dim() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool ConcatParameter::has_concat_dim() const {
return _internal_has_concat_dim();
}
inline void ConcatParameter::clear_concat_dim() {
concat_dim_ = 1u;
_has_bits_[0] &= ~0x00000001u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConcatParameter::_internal_concat_dim() const {
return concat_dim_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConcatParameter::concat_dim() const {
// @@protoc_insertion_point(field_get:caffe.ConcatParameter.concat_dim)
return _internal_concat_dim();
}
inline void ConcatParameter::_internal_set_concat_dim(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000001u;
concat_dim_ = value;
}
inline void ConcatParameter::set_concat_dim(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_concat_dim(value);
// @@protoc_insertion_point(field_set:caffe.ConcatParameter.concat_dim)
}
// -------------------------------------------------------------------
// BatchNormParameter
// optional bool use_global_stats = 1;
inline bool BatchNormParameter::_internal_has_use_global_stats() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool BatchNormParameter::has_use_global_stats() const {
return _internal_has_use_global_stats();
}
inline void BatchNormParameter::clear_use_global_stats() {
use_global_stats_ = false;
_has_bits_[0] &= ~0x00000001u;
}
inline bool BatchNormParameter::_internal_use_global_stats() const {
return use_global_stats_;
}
inline bool BatchNormParameter::use_global_stats() const {
// @@protoc_insertion_point(field_get:caffe.BatchNormParameter.use_global_stats)
return _internal_use_global_stats();
}
inline void BatchNormParameter::_internal_set_use_global_stats(bool value) {
_has_bits_[0] |= 0x00000001u;
use_global_stats_ = value;
}
inline void BatchNormParameter::set_use_global_stats(bool value) {
_internal_set_use_global_stats(value);
// @@protoc_insertion_point(field_set:caffe.BatchNormParameter.use_global_stats)
}
// optional float moving_average_fraction = 2 [default = 0.999];
inline bool BatchNormParameter::_internal_has_moving_average_fraction() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool BatchNormParameter::has_moving_average_fraction() const {
return _internal_has_moving_average_fraction();
}
inline void BatchNormParameter::clear_moving_average_fraction() {
moving_average_fraction_ = 0.999f;
_has_bits_[0] &= ~0x00000002u;
}
inline float BatchNormParameter::_internal_moving_average_fraction() const {
return moving_average_fraction_;
}
inline float BatchNormParameter::moving_average_fraction() const {
// @@protoc_insertion_point(field_get:caffe.BatchNormParameter.moving_average_fraction)
return _internal_moving_average_fraction();
}
inline void BatchNormParameter::_internal_set_moving_average_fraction(float value) {
_has_bits_[0] |= 0x00000002u;
moving_average_fraction_ = value;
}
inline void BatchNormParameter::set_moving_average_fraction(float value) {
_internal_set_moving_average_fraction(value);
// @@protoc_insertion_point(field_set:caffe.BatchNormParameter.moving_average_fraction)
}
// optional float eps = 3 [default = 1e-05];
inline bool BatchNormParameter::_internal_has_eps() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool BatchNormParameter::has_eps() const {
return _internal_has_eps();
}
inline void BatchNormParameter::clear_eps() {
eps_ = 1e-05f;
_has_bits_[0] &= ~0x00000004u;
}
inline float BatchNormParameter::_internal_eps() const {
return eps_;
}
inline float BatchNormParameter::eps() const {
// @@protoc_insertion_point(field_get:caffe.BatchNormParameter.eps)
return _internal_eps();
}
inline void BatchNormParameter::_internal_set_eps(float value) {
_has_bits_[0] |= 0x00000004u;
eps_ = value;
}
inline void BatchNormParameter::set_eps(float value) {
_internal_set_eps(value);
// @@protoc_insertion_point(field_set:caffe.BatchNormParameter.eps)
}
// -------------------------------------------------------------------
// BiasParameter
// optional int32 axis = 1 [default = 1];
inline bool BiasParameter::_internal_has_axis() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool BiasParameter::has_axis() const {
return _internal_has_axis();
}
inline void BiasParameter::clear_axis() {
axis_ = 1;
_has_bits_[0] &= ~0x00000002u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 BiasParameter::_internal_axis() const {
return axis_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 BiasParameter::axis() const {
// @@protoc_insertion_point(field_get:caffe.BiasParameter.axis)
return _internal_axis();
}
inline void BiasParameter::_internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000002u;
axis_ = value;
}
inline void BiasParameter::set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_axis(value);
// @@protoc_insertion_point(field_set:caffe.BiasParameter.axis)
}
// optional int32 num_axes = 2 [default = 1];
inline bool BiasParameter::_internal_has_num_axes() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool BiasParameter::has_num_axes() const {
return _internal_has_num_axes();
}
inline void BiasParameter::clear_num_axes() {
num_axes_ = 1;
_has_bits_[0] &= ~0x00000004u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 BiasParameter::_internal_num_axes() const {
return num_axes_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 BiasParameter::num_axes() const {
// @@protoc_insertion_point(field_get:caffe.BiasParameter.num_axes)
return _internal_num_axes();
}
inline void BiasParameter::_internal_set_num_axes(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000004u;
num_axes_ = value;
}
inline void BiasParameter::set_num_axes(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_num_axes(value);
// @@protoc_insertion_point(field_set:caffe.BiasParameter.num_axes)
}
// optional .caffe.FillerParameter filler = 3;
inline bool BiasParameter::_internal_has_filler() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
PROTOBUF_ASSUME(!value || filler_ != nullptr);
return value;
}
inline bool BiasParameter::has_filler() const {
return _internal_has_filler();
}
inline void BiasParameter::clear_filler() {
if (filler_ != nullptr) filler_->Clear();
_has_bits_[0] &= ~0x00000001u;
}
inline const ::caffe::FillerParameter& BiasParameter::_internal_filler() const {
const ::caffe::FillerParameter* p = filler_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::FillerParameter*>(
&::caffe::_FillerParameter_default_instance_);
}
inline const ::caffe::FillerParameter& BiasParameter::filler() const {
// @@protoc_insertion_point(field_get:caffe.BiasParameter.filler)
return _internal_filler();
}
inline void BiasParameter::unsafe_arena_set_allocated_filler(
::caffe::FillerParameter* filler) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(filler_);
}
filler_ = filler;
if (filler) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.BiasParameter.filler)
}
inline ::caffe::FillerParameter* BiasParameter::release_filler() {
_has_bits_[0] &= ~0x00000001u;
::caffe::FillerParameter* temp = filler_;
filler_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::FillerParameter* BiasParameter::unsafe_arena_release_filler() {
// @@protoc_insertion_point(field_release:caffe.BiasParameter.filler)
_has_bits_[0] &= ~0x00000001u;
::caffe::FillerParameter* temp = filler_;
filler_ = nullptr;
return temp;
}
inline ::caffe::FillerParameter* BiasParameter::_internal_mutable_filler() {
_has_bits_[0] |= 0x00000001u;
if (filler_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::FillerParameter>(GetArena());
filler_ = p;
}
return filler_;
}
inline ::caffe::FillerParameter* BiasParameter::mutable_filler() {
// @@protoc_insertion_point(field_mutable:caffe.BiasParameter.filler)
return _internal_mutable_filler();
}
inline void BiasParameter::set_allocated_filler(::caffe::FillerParameter* filler) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete filler_;
}
if (filler) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(filler);
if (message_arena != submessage_arena) {
filler = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, filler, submessage_arena);
}
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
filler_ = filler;
// @@protoc_insertion_point(field_set_allocated:caffe.BiasParameter.filler)
}
// -------------------------------------------------------------------
// ContrastiveLossParameter
// optional float margin = 1 [default = 1];
inline bool ContrastiveLossParameter::_internal_has_margin() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool ContrastiveLossParameter::has_margin() const {
return _internal_has_margin();
}
inline void ContrastiveLossParameter::clear_margin() {
margin_ = 1;
_has_bits_[0] &= ~0x00000002u;
}
inline float ContrastiveLossParameter::_internal_margin() const {
return margin_;
}
inline float ContrastiveLossParameter::margin() const {
// @@protoc_insertion_point(field_get:caffe.ContrastiveLossParameter.margin)
return _internal_margin();
}
inline void ContrastiveLossParameter::_internal_set_margin(float value) {
_has_bits_[0] |= 0x00000002u;
margin_ = value;
}
inline void ContrastiveLossParameter::set_margin(float value) {
_internal_set_margin(value);
// @@protoc_insertion_point(field_set:caffe.ContrastiveLossParameter.margin)
}
// optional bool legacy_version = 2 [default = false];
inline bool ContrastiveLossParameter::_internal_has_legacy_version() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool ContrastiveLossParameter::has_legacy_version() const {
return _internal_has_legacy_version();
}
inline void ContrastiveLossParameter::clear_legacy_version() {
legacy_version_ = false;
_has_bits_[0] &= ~0x00000001u;
}
inline bool ContrastiveLossParameter::_internal_legacy_version() const {
return legacy_version_;
}
inline bool ContrastiveLossParameter::legacy_version() const {
// @@protoc_insertion_point(field_get:caffe.ContrastiveLossParameter.legacy_version)
return _internal_legacy_version();
}
inline void ContrastiveLossParameter::_internal_set_legacy_version(bool value) {
_has_bits_[0] |= 0x00000001u;
legacy_version_ = value;
}
inline void ContrastiveLossParameter::set_legacy_version(bool value) {
_internal_set_legacy_version(value);
// @@protoc_insertion_point(field_set:caffe.ContrastiveLossParameter.legacy_version)
}
// -------------------------------------------------------------------
// ConvolutionParameter
// optional uint32 num_output = 1;
inline bool ConvolutionParameter::_internal_has_num_output() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool ConvolutionParameter::has_num_output() const {
return _internal_has_num_output();
}
inline void ConvolutionParameter::clear_num_output() {
num_output_ = 0u;
_has_bits_[0] &= ~0x00000004u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::_internal_num_output() const {
return num_output_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::num_output() const {
// @@protoc_insertion_point(field_get:caffe.ConvolutionParameter.num_output)
return _internal_num_output();
}
inline void ConvolutionParameter::_internal_set_num_output(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000004u;
num_output_ = value;
}
inline void ConvolutionParameter::set_num_output(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_num_output(value);
// @@protoc_insertion_point(field_set:caffe.ConvolutionParameter.num_output)
}
// optional bool bias_term = 2 [default = true];
inline bool ConvolutionParameter::_internal_has_bias_term() const {
bool value = (_has_bits_[0] & 0x00001000u) != 0;
return value;
}
inline bool ConvolutionParameter::has_bias_term() const {
return _internal_has_bias_term();
}
inline void ConvolutionParameter::clear_bias_term() {
bias_term_ = true;
_has_bits_[0] &= ~0x00001000u;
}
inline bool ConvolutionParameter::_internal_bias_term() const {
return bias_term_;
}
inline bool ConvolutionParameter::bias_term() const {
// @@protoc_insertion_point(field_get:caffe.ConvolutionParameter.bias_term)
return _internal_bias_term();
}
inline void ConvolutionParameter::_internal_set_bias_term(bool value) {
_has_bits_[0] |= 0x00001000u;
bias_term_ = value;
}
inline void ConvolutionParameter::set_bias_term(bool value) {
_internal_set_bias_term(value);
// @@protoc_insertion_point(field_set:caffe.ConvolutionParameter.bias_term)
}
// repeated uint32 pad = 3;
inline int ConvolutionParameter::_internal_pad_size() const {
return pad_.size();
}
inline int ConvolutionParameter::pad_size() const {
return _internal_pad_size();
}
inline void ConvolutionParameter::clear_pad() {
pad_.Clear();
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::_internal_pad(int index) const {
return pad_.Get(index);
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::pad(int index) const {
// @@protoc_insertion_point(field_get:caffe.ConvolutionParameter.pad)
return _internal_pad(index);
}
inline void ConvolutionParameter::set_pad(int index, ::PROTOBUF_NAMESPACE_ID::uint32 value) {
pad_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.ConvolutionParameter.pad)
}
inline void ConvolutionParameter::_internal_add_pad(::PROTOBUF_NAMESPACE_ID::uint32 value) {
pad_.Add(value);
}
inline void ConvolutionParameter::add_pad(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_add_pad(value);
// @@protoc_insertion_point(field_add:caffe.ConvolutionParameter.pad)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
ConvolutionParameter::_internal_pad() const {
return pad_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
ConvolutionParameter::pad() const {
// @@protoc_insertion_point(field_list:caffe.ConvolutionParameter.pad)
return _internal_pad();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
ConvolutionParameter::_internal_mutable_pad() {
return &pad_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
ConvolutionParameter::mutable_pad() {
// @@protoc_insertion_point(field_mutable_list:caffe.ConvolutionParameter.pad)
return _internal_mutable_pad();
}
// repeated uint32 kernel_size = 4;
inline int ConvolutionParameter::_internal_kernel_size_size() const {
return kernel_size_.size();
}
inline int ConvolutionParameter::kernel_size_size() const {
return _internal_kernel_size_size();
}
inline void ConvolutionParameter::clear_kernel_size() {
kernel_size_.Clear();
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::_internal_kernel_size(int index) const {
return kernel_size_.Get(index);
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::kernel_size(int index) const {
// @@protoc_insertion_point(field_get:caffe.ConvolutionParameter.kernel_size)
return _internal_kernel_size(index);
}
inline void ConvolutionParameter::set_kernel_size(int index, ::PROTOBUF_NAMESPACE_ID::uint32 value) {
kernel_size_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.ConvolutionParameter.kernel_size)
}
inline void ConvolutionParameter::_internal_add_kernel_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
kernel_size_.Add(value);
}
inline void ConvolutionParameter::add_kernel_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_add_kernel_size(value);
// @@protoc_insertion_point(field_add:caffe.ConvolutionParameter.kernel_size)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
ConvolutionParameter::_internal_kernel_size() const {
return kernel_size_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
ConvolutionParameter::kernel_size() const {
// @@protoc_insertion_point(field_list:caffe.ConvolutionParameter.kernel_size)
return _internal_kernel_size();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
ConvolutionParameter::_internal_mutable_kernel_size() {
return &kernel_size_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
ConvolutionParameter::mutable_kernel_size() {
// @@protoc_insertion_point(field_mutable_list:caffe.ConvolutionParameter.kernel_size)
return _internal_mutable_kernel_size();
}
// repeated uint32 stride = 6;
inline int ConvolutionParameter::_internal_stride_size() const {
return stride_.size();
}
inline int ConvolutionParameter::stride_size() const {
return _internal_stride_size();
}
inline void ConvolutionParameter::clear_stride() {
stride_.Clear();
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::_internal_stride(int index) const {
return stride_.Get(index);
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::stride(int index) const {
// @@protoc_insertion_point(field_get:caffe.ConvolutionParameter.stride)
return _internal_stride(index);
}
inline void ConvolutionParameter::set_stride(int index, ::PROTOBUF_NAMESPACE_ID::uint32 value) {
stride_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.ConvolutionParameter.stride)
}
inline void ConvolutionParameter::_internal_add_stride(::PROTOBUF_NAMESPACE_ID::uint32 value) {
stride_.Add(value);
}
inline void ConvolutionParameter::add_stride(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_add_stride(value);
// @@protoc_insertion_point(field_add:caffe.ConvolutionParameter.stride)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
ConvolutionParameter::_internal_stride() const {
return stride_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
ConvolutionParameter::stride() const {
// @@protoc_insertion_point(field_list:caffe.ConvolutionParameter.stride)
return _internal_stride();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
ConvolutionParameter::_internal_mutable_stride() {
return &stride_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
ConvolutionParameter::mutable_stride() {
// @@protoc_insertion_point(field_mutable_list:caffe.ConvolutionParameter.stride)
return _internal_mutable_stride();
}
// repeated uint32 dilation = 18;
inline int ConvolutionParameter::_internal_dilation_size() const {
return dilation_.size();
}
inline int ConvolutionParameter::dilation_size() const {
return _internal_dilation_size();
}
inline void ConvolutionParameter::clear_dilation() {
dilation_.Clear();
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::_internal_dilation(int index) const {
return dilation_.Get(index);
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::dilation(int index) const {
// @@protoc_insertion_point(field_get:caffe.ConvolutionParameter.dilation)
return _internal_dilation(index);
}
inline void ConvolutionParameter::set_dilation(int index, ::PROTOBUF_NAMESPACE_ID::uint32 value) {
dilation_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.ConvolutionParameter.dilation)
}
inline void ConvolutionParameter::_internal_add_dilation(::PROTOBUF_NAMESPACE_ID::uint32 value) {
dilation_.Add(value);
}
inline void ConvolutionParameter::add_dilation(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_add_dilation(value);
// @@protoc_insertion_point(field_add:caffe.ConvolutionParameter.dilation)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
ConvolutionParameter::_internal_dilation() const {
return dilation_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
ConvolutionParameter::dilation() const {
// @@protoc_insertion_point(field_list:caffe.ConvolutionParameter.dilation)
return _internal_dilation();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
ConvolutionParameter::_internal_mutable_dilation() {
return &dilation_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
ConvolutionParameter::mutable_dilation() {
// @@protoc_insertion_point(field_mutable_list:caffe.ConvolutionParameter.dilation)
return _internal_mutable_dilation();
}
// optional uint32 pad_h = 9 [default = 0];
inline bool ConvolutionParameter::_internal_has_pad_h() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool ConvolutionParameter::has_pad_h() const {
return _internal_has_pad_h();
}
inline void ConvolutionParameter::clear_pad_h() {
pad_h_ = 0u;
_has_bits_[0] &= ~0x00000008u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::_internal_pad_h() const {
return pad_h_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::pad_h() const {
// @@protoc_insertion_point(field_get:caffe.ConvolutionParameter.pad_h)
return _internal_pad_h();
}
inline void ConvolutionParameter::_internal_set_pad_h(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000008u;
pad_h_ = value;
}
inline void ConvolutionParameter::set_pad_h(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_pad_h(value);
// @@protoc_insertion_point(field_set:caffe.ConvolutionParameter.pad_h)
}
// optional uint32 pad_w = 10 [default = 0];
inline bool ConvolutionParameter::_internal_has_pad_w() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool ConvolutionParameter::has_pad_w() const {
return _internal_has_pad_w();
}
inline void ConvolutionParameter::clear_pad_w() {
pad_w_ = 0u;
_has_bits_[0] &= ~0x00000010u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::_internal_pad_w() const {
return pad_w_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::pad_w() const {
// @@protoc_insertion_point(field_get:caffe.ConvolutionParameter.pad_w)
return _internal_pad_w();
}
inline void ConvolutionParameter::_internal_set_pad_w(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000010u;
pad_w_ = value;
}
inline void ConvolutionParameter::set_pad_w(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_pad_w(value);
// @@protoc_insertion_point(field_set:caffe.ConvolutionParameter.pad_w)
}
// optional uint32 kernel_h = 11;
inline bool ConvolutionParameter::_internal_has_kernel_h() const {
bool value = (_has_bits_[0] & 0x00000020u) != 0;
return value;
}
inline bool ConvolutionParameter::has_kernel_h() const {
return _internal_has_kernel_h();
}
inline void ConvolutionParameter::clear_kernel_h() {
kernel_h_ = 0u;
_has_bits_[0] &= ~0x00000020u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::_internal_kernel_h() const {
return kernel_h_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::kernel_h() const {
// @@protoc_insertion_point(field_get:caffe.ConvolutionParameter.kernel_h)
return _internal_kernel_h();
}
inline void ConvolutionParameter::_internal_set_kernel_h(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000020u;
kernel_h_ = value;
}
inline void ConvolutionParameter::set_kernel_h(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_kernel_h(value);
// @@protoc_insertion_point(field_set:caffe.ConvolutionParameter.kernel_h)
}
// optional uint32 kernel_w = 12;
inline bool ConvolutionParameter::_internal_has_kernel_w() const {
bool value = (_has_bits_[0] & 0x00000040u) != 0;
return value;
}
inline bool ConvolutionParameter::has_kernel_w() const {
return _internal_has_kernel_w();
}
inline void ConvolutionParameter::clear_kernel_w() {
kernel_w_ = 0u;
_has_bits_[0] &= ~0x00000040u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::_internal_kernel_w() const {
return kernel_w_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::kernel_w() const {
// @@protoc_insertion_point(field_get:caffe.ConvolutionParameter.kernel_w)
return _internal_kernel_w();
}
inline void ConvolutionParameter::_internal_set_kernel_w(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000040u;
kernel_w_ = value;
}
inline void ConvolutionParameter::set_kernel_w(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_kernel_w(value);
// @@protoc_insertion_point(field_set:caffe.ConvolutionParameter.kernel_w)
}
// optional uint32 stride_h = 13;
inline bool ConvolutionParameter::_internal_has_stride_h() const {
bool value = (_has_bits_[0] & 0x00000080u) != 0;
return value;
}
inline bool ConvolutionParameter::has_stride_h() const {
return _internal_has_stride_h();
}
inline void ConvolutionParameter::clear_stride_h() {
stride_h_ = 0u;
_has_bits_[0] &= ~0x00000080u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::_internal_stride_h() const {
return stride_h_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::stride_h() const {
// @@protoc_insertion_point(field_get:caffe.ConvolutionParameter.stride_h)
return _internal_stride_h();
}
inline void ConvolutionParameter::_internal_set_stride_h(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000080u;
stride_h_ = value;
}
inline void ConvolutionParameter::set_stride_h(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_stride_h(value);
// @@protoc_insertion_point(field_set:caffe.ConvolutionParameter.stride_h)
}
// optional uint32 stride_w = 14;
inline bool ConvolutionParameter::_internal_has_stride_w() const {
bool value = (_has_bits_[0] & 0x00000100u) != 0;
return value;
}
inline bool ConvolutionParameter::has_stride_w() const {
return _internal_has_stride_w();
}
inline void ConvolutionParameter::clear_stride_w() {
stride_w_ = 0u;
_has_bits_[0] &= ~0x00000100u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::_internal_stride_w() const {
return stride_w_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::stride_w() const {
// @@protoc_insertion_point(field_get:caffe.ConvolutionParameter.stride_w)
return _internal_stride_w();
}
inline void ConvolutionParameter::_internal_set_stride_w(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000100u;
stride_w_ = value;
}
inline void ConvolutionParameter::set_stride_w(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_stride_w(value);
// @@protoc_insertion_point(field_set:caffe.ConvolutionParameter.stride_w)
}
// optional uint32 group = 5 [default = 1];
inline bool ConvolutionParameter::_internal_has_group() const {
bool value = (_has_bits_[0] & 0x00002000u) != 0;
return value;
}
inline bool ConvolutionParameter::has_group() const {
return _internal_has_group();
}
inline void ConvolutionParameter::clear_group() {
group_ = 1u;
_has_bits_[0] &= ~0x00002000u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::_internal_group() const {
return group_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ConvolutionParameter::group() const {
// @@protoc_insertion_point(field_get:caffe.ConvolutionParameter.group)
return _internal_group();
}
inline void ConvolutionParameter::_internal_set_group(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00002000u;
group_ = value;
}
inline void ConvolutionParameter::set_group(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_group(value);
// @@protoc_insertion_point(field_set:caffe.ConvolutionParameter.group)
}
// optional .caffe.FillerParameter weight_filler = 7;
inline bool ConvolutionParameter::_internal_has_weight_filler() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
PROTOBUF_ASSUME(!value || weight_filler_ != nullptr);
return value;
}
inline bool ConvolutionParameter::has_weight_filler() const {
return _internal_has_weight_filler();
}
inline void ConvolutionParameter::clear_weight_filler() {
if (weight_filler_ != nullptr) weight_filler_->Clear();
_has_bits_[0] &= ~0x00000001u;
}
inline const ::caffe::FillerParameter& ConvolutionParameter::_internal_weight_filler() const {
const ::caffe::FillerParameter* p = weight_filler_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::FillerParameter*>(
&::caffe::_FillerParameter_default_instance_);
}
inline const ::caffe::FillerParameter& ConvolutionParameter::weight_filler() const {
// @@protoc_insertion_point(field_get:caffe.ConvolutionParameter.weight_filler)
return _internal_weight_filler();
}
inline void ConvolutionParameter::unsafe_arena_set_allocated_weight_filler(
::caffe::FillerParameter* weight_filler) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(weight_filler_);
}
weight_filler_ = weight_filler;
if (weight_filler) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.ConvolutionParameter.weight_filler)
}
inline ::caffe::FillerParameter* ConvolutionParameter::release_weight_filler() {
_has_bits_[0] &= ~0x00000001u;
::caffe::FillerParameter* temp = weight_filler_;
weight_filler_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::FillerParameter* ConvolutionParameter::unsafe_arena_release_weight_filler() {
// @@protoc_insertion_point(field_release:caffe.ConvolutionParameter.weight_filler)
_has_bits_[0] &= ~0x00000001u;
::caffe::FillerParameter* temp = weight_filler_;
weight_filler_ = nullptr;
return temp;
}
inline ::caffe::FillerParameter* ConvolutionParameter::_internal_mutable_weight_filler() {
_has_bits_[0] |= 0x00000001u;
if (weight_filler_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::FillerParameter>(GetArena());
weight_filler_ = p;
}
return weight_filler_;
}
inline ::caffe::FillerParameter* ConvolutionParameter::mutable_weight_filler() {
// @@protoc_insertion_point(field_mutable:caffe.ConvolutionParameter.weight_filler)
return _internal_mutable_weight_filler();
}
inline void ConvolutionParameter::set_allocated_weight_filler(::caffe::FillerParameter* weight_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete weight_filler_;
}
if (weight_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(weight_filler);
if (message_arena != submessage_arena) {
weight_filler = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, weight_filler, submessage_arena);
}
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
weight_filler_ = weight_filler;
// @@protoc_insertion_point(field_set_allocated:caffe.ConvolutionParameter.weight_filler)
}
// optional .caffe.FillerParameter bias_filler = 8;
inline bool ConvolutionParameter::_internal_has_bias_filler() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
PROTOBUF_ASSUME(!value || bias_filler_ != nullptr);
return value;
}
inline bool ConvolutionParameter::has_bias_filler() const {
return _internal_has_bias_filler();
}
inline void ConvolutionParameter::clear_bias_filler() {
if (bias_filler_ != nullptr) bias_filler_->Clear();
_has_bits_[0] &= ~0x00000002u;
}
inline const ::caffe::FillerParameter& ConvolutionParameter::_internal_bias_filler() const {
const ::caffe::FillerParameter* p = bias_filler_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::FillerParameter*>(
&::caffe::_FillerParameter_default_instance_);
}
inline const ::caffe::FillerParameter& ConvolutionParameter::bias_filler() const {
// @@protoc_insertion_point(field_get:caffe.ConvolutionParameter.bias_filler)
return _internal_bias_filler();
}
inline void ConvolutionParameter::unsafe_arena_set_allocated_bias_filler(
::caffe::FillerParameter* bias_filler) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(bias_filler_);
}
bias_filler_ = bias_filler;
if (bias_filler) {
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.ConvolutionParameter.bias_filler)
}
inline ::caffe::FillerParameter* ConvolutionParameter::release_bias_filler() {
_has_bits_[0] &= ~0x00000002u;
::caffe::FillerParameter* temp = bias_filler_;
bias_filler_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::FillerParameter* ConvolutionParameter::unsafe_arena_release_bias_filler() {
// @@protoc_insertion_point(field_release:caffe.ConvolutionParameter.bias_filler)
_has_bits_[0] &= ~0x00000002u;
::caffe::FillerParameter* temp = bias_filler_;
bias_filler_ = nullptr;
return temp;
}
inline ::caffe::FillerParameter* ConvolutionParameter::_internal_mutable_bias_filler() {
_has_bits_[0] |= 0x00000002u;
if (bias_filler_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::FillerParameter>(GetArena());
bias_filler_ = p;
}
return bias_filler_;
}
inline ::caffe::FillerParameter* ConvolutionParameter::mutable_bias_filler() {
// @@protoc_insertion_point(field_mutable:caffe.ConvolutionParameter.bias_filler)
return _internal_mutable_bias_filler();
}
inline void ConvolutionParameter::set_allocated_bias_filler(::caffe::FillerParameter* bias_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete bias_filler_;
}
if (bias_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(bias_filler);
if (message_arena != submessage_arena) {
bias_filler = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, bias_filler, submessage_arena);
}
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
bias_filler_ = bias_filler;
// @@protoc_insertion_point(field_set_allocated:caffe.ConvolutionParameter.bias_filler)
}
// optional .caffe.ConvolutionParameter.Engine engine = 15 [default = DEFAULT];
inline bool ConvolutionParameter::_internal_has_engine() const {
bool value = (_has_bits_[0] & 0x00000200u) != 0;
return value;
}
inline bool ConvolutionParameter::has_engine() const {
return _internal_has_engine();
}
inline void ConvolutionParameter::clear_engine() {
engine_ = 0;
_has_bits_[0] &= ~0x00000200u;
}
inline ::caffe::ConvolutionParameter_Engine ConvolutionParameter::_internal_engine() const {
return static_cast< ::caffe::ConvolutionParameter_Engine >(engine_);
}
inline ::caffe::ConvolutionParameter_Engine ConvolutionParameter::engine() const {
// @@protoc_insertion_point(field_get:caffe.ConvolutionParameter.engine)
return _internal_engine();
}
inline void ConvolutionParameter::_internal_set_engine(::caffe::ConvolutionParameter_Engine value) {
assert(::caffe::ConvolutionParameter_Engine_IsValid(value));
_has_bits_[0] |= 0x00000200u;
engine_ = value;
}
inline void ConvolutionParameter::set_engine(::caffe::ConvolutionParameter_Engine value) {
_internal_set_engine(value);
// @@protoc_insertion_point(field_set:caffe.ConvolutionParameter.engine)
}
// optional int32 axis = 16 [default = 1];
inline bool ConvolutionParameter::_internal_has_axis() const {
bool value = (_has_bits_[0] & 0x00000800u) != 0;
return value;
}
inline bool ConvolutionParameter::has_axis() const {
return _internal_has_axis();
}
inline void ConvolutionParameter::clear_axis() {
axis_ = 1;
_has_bits_[0] &= ~0x00000800u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 ConvolutionParameter::_internal_axis() const {
return axis_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 ConvolutionParameter::axis() const {
// @@protoc_insertion_point(field_get:caffe.ConvolutionParameter.axis)
return _internal_axis();
}
inline void ConvolutionParameter::_internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000800u;
axis_ = value;
}
inline void ConvolutionParameter::set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_axis(value);
// @@protoc_insertion_point(field_set:caffe.ConvolutionParameter.axis)
}
// optional bool force_nd_im2col = 17 [default = false];
inline bool ConvolutionParameter::_internal_has_force_nd_im2col() const {
bool value = (_has_bits_[0] & 0x00000400u) != 0;
return value;
}
inline bool ConvolutionParameter::has_force_nd_im2col() const {
return _internal_has_force_nd_im2col();
}
inline void ConvolutionParameter::clear_force_nd_im2col() {
force_nd_im2col_ = false;
_has_bits_[0] &= ~0x00000400u;
}
inline bool ConvolutionParameter::_internal_force_nd_im2col() const {
return force_nd_im2col_;
}
inline bool ConvolutionParameter::force_nd_im2col() const {
// @@protoc_insertion_point(field_get:caffe.ConvolutionParameter.force_nd_im2col)
return _internal_force_nd_im2col();
}
inline void ConvolutionParameter::_internal_set_force_nd_im2col(bool value) {
_has_bits_[0] |= 0x00000400u;
force_nd_im2col_ = value;
}
inline void ConvolutionParameter::set_force_nd_im2col(bool value) {
_internal_set_force_nd_im2col(value);
// @@protoc_insertion_point(field_set:caffe.ConvolutionParameter.force_nd_im2col)
}
// -------------------------------------------------------------------
// CropParameter
// optional int32 axis = 1 [default = 2];
inline bool CropParameter::_internal_has_axis() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool CropParameter::has_axis() const {
return _internal_has_axis();
}
inline void CropParameter::clear_axis() {
axis_ = 2;
_has_bits_[0] &= ~0x00000001u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 CropParameter::_internal_axis() const {
return axis_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 CropParameter::axis() const {
// @@protoc_insertion_point(field_get:caffe.CropParameter.axis)
return _internal_axis();
}
inline void CropParameter::_internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000001u;
axis_ = value;
}
inline void CropParameter::set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_axis(value);
// @@protoc_insertion_point(field_set:caffe.CropParameter.axis)
}
// repeated uint32 offset = 2;
inline int CropParameter::_internal_offset_size() const {
return offset_.size();
}
inline int CropParameter::offset_size() const {
return _internal_offset_size();
}
inline void CropParameter::clear_offset() {
offset_.Clear();
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 CropParameter::_internal_offset(int index) const {
return offset_.Get(index);
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 CropParameter::offset(int index) const {
// @@protoc_insertion_point(field_get:caffe.CropParameter.offset)
return _internal_offset(index);
}
inline void CropParameter::set_offset(int index, ::PROTOBUF_NAMESPACE_ID::uint32 value) {
offset_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.CropParameter.offset)
}
inline void CropParameter::_internal_add_offset(::PROTOBUF_NAMESPACE_ID::uint32 value) {
offset_.Add(value);
}
inline void CropParameter::add_offset(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_add_offset(value);
// @@protoc_insertion_point(field_add:caffe.CropParameter.offset)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
CropParameter::_internal_offset() const {
return offset_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
CropParameter::offset() const {
// @@protoc_insertion_point(field_list:caffe.CropParameter.offset)
return _internal_offset();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
CropParameter::_internal_mutable_offset() {
return &offset_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
CropParameter::mutable_offset() {
// @@protoc_insertion_point(field_mutable_list:caffe.CropParameter.offset)
return _internal_mutable_offset();
}
// -------------------------------------------------------------------
// DataParameter
// optional string source = 1;
inline bool DataParameter::_internal_has_source() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool DataParameter::has_source() const {
return _internal_has_source();
}
inline void DataParameter::clear_source() {
source_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000001u;
}
inline const std::string& DataParameter::source() const {
// @@protoc_insertion_point(field_get:caffe.DataParameter.source)
return _internal_source();
}
inline void DataParameter::set_source(const std::string& value) {
_internal_set_source(value);
// @@protoc_insertion_point(field_set:caffe.DataParameter.source)
}
inline std::string* DataParameter::mutable_source() {
// @@protoc_insertion_point(field_mutable:caffe.DataParameter.source)
return _internal_mutable_source();
}
inline const std::string& DataParameter::_internal_source() const {
return source_.Get();
}
inline void DataParameter::_internal_set_source(const std::string& value) {
_has_bits_[0] |= 0x00000001u;
source_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void DataParameter::set_source(std::string&& value) {
_has_bits_[0] |= 0x00000001u;
source_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.DataParameter.source)
}
inline void DataParameter::set_source(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000001u;
source_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.DataParameter.source)
}
inline void DataParameter::set_source(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000001u;
source_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.DataParameter.source)
}
inline std::string* DataParameter::_internal_mutable_source() {
_has_bits_[0] |= 0x00000001u;
return source_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* DataParameter::release_source() {
// @@protoc_insertion_point(field_release:caffe.DataParameter.source)
if (!_internal_has_source()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000001u;
return source_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void DataParameter::set_allocated_source(std::string* source) {
if (source != nullptr) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
source_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), source,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.DataParameter.source)
}
// optional uint32 batch_size = 4;
inline bool DataParameter::_internal_has_batch_size() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool DataParameter::has_batch_size() const {
return _internal_has_batch_size();
}
inline void DataParameter::clear_batch_size() {
batch_size_ = 0u;
_has_bits_[0] &= ~0x00000004u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 DataParameter::_internal_batch_size() const {
return batch_size_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 DataParameter::batch_size() const {
// @@protoc_insertion_point(field_get:caffe.DataParameter.batch_size)
return _internal_batch_size();
}
inline void DataParameter::_internal_set_batch_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000004u;
batch_size_ = value;
}
inline void DataParameter::set_batch_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_batch_size(value);
// @@protoc_insertion_point(field_set:caffe.DataParameter.batch_size)
}
// optional uint32 rand_skip = 7 [default = 0];
inline bool DataParameter::_internal_has_rand_skip() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool DataParameter::has_rand_skip() const {
return _internal_has_rand_skip();
}
inline void DataParameter::clear_rand_skip() {
rand_skip_ = 0u;
_has_bits_[0] &= ~0x00000010u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 DataParameter::_internal_rand_skip() const {
return rand_skip_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 DataParameter::rand_skip() const {
// @@protoc_insertion_point(field_get:caffe.DataParameter.rand_skip)
return _internal_rand_skip();
}
inline void DataParameter::_internal_set_rand_skip(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000010u;
rand_skip_ = value;
}
inline void DataParameter::set_rand_skip(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_rand_skip(value);
// @@protoc_insertion_point(field_set:caffe.DataParameter.rand_skip)
}
// optional .caffe.DataParameter.DB backend = 8 [default = LEVELDB];
inline bool DataParameter::_internal_has_backend() const {
bool value = (_has_bits_[0] & 0x00000080u) != 0;
return value;
}
inline bool DataParameter::has_backend() const {
return _internal_has_backend();
}
inline void DataParameter::clear_backend() {
backend_ = 0;
_has_bits_[0] &= ~0x00000080u;
}
inline ::caffe::DataParameter_DB DataParameter::_internal_backend() const {
return static_cast< ::caffe::DataParameter_DB >(backend_);
}
inline ::caffe::DataParameter_DB DataParameter::backend() const {
// @@protoc_insertion_point(field_get:caffe.DataParameter.backend)
return _internal_backend();
}
inline void DataParameter::_internal_set_backend(::caffe::DataParameter_DB value) {
assert(::caffe::DataParameter_DB_IsValid(value));
_has_bits_[0] |= 0x00000080u;
backend_ = value;
}
inline void DataParameter::set_backend(::caffe::DataParameter_DB value) {
_internal_set_backend(value);
// @@protoc_insertion_point(field_set:caffe.DataParameter.backend)
}
// optional float scale = 2 [default = 1];
inline bool DataParameter::_internal_has_scale() const {
bool value = (_has_bits_[0] & 0x00000100u) != 0;
return value;
}
inline bool DataParameter::has_scale() const {
return _internal_has_scale();
}
inline void DataParameter::clear_scale() {
scale_ = 1;
_has_bits_[0] &= ~0x00000100u;
}
inline float DataParameter::_internal_scale() const {
return scale_;
}
inline float DataParameter::scale() const {
// @@protoc_insertion_point(field_get:caffe.DataParameter.scale)
return _internal_scale();
}
inline void DataParameter::_internal_set_scale(float value) {
_has_bits_[0] |= 0x00000100u;
scale_ = value;
}
inline void DataParameter::set_scale(float value) {
_internal_set_scale(value);
// @@protoc_insertion_point(field_set:caffe.DataParameter.scale)
}
// optional string mean_file = 3;
inline bool DataParameter::_internal_has_mean_file() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool DataParameter::has_mean_file() const {
return _internal_has_mean_file();
}
inline void DataParameter::clear_mean_file() {
mean_file_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000002u;
}
inline const std::string& DataParameter::mean_file() const {
// @@protoc_insertion_point(field_get:caffe.DataParameter.mean_file)
return _internal_mean_file();
}
inline void DataParameter::set_mean_file(const std::string& value) {
_internal_set_mean_file(value);
// @@protoc_insertion_point(field_set:caffe.DataParameter.mean_file)
}
inline std::string* DataParameter::mutable_mean_file() {
// @@protoc_insertion_point(field_mutable:caffe.DataParameter.mean_file)
return _internal_mutable_mean_file();
}
inline const std::string& DataParameter::_internal_mean_file() const {
return mean_file_.Get();
}
inline void DataParameter::_internal_set_mean_file(const std::string& value) {
_has_bits_[0] |= 0x00000002u;
mean_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void DataParameter::set_mean_file(std::string&& value) {
_has_bits_[0] |= 0x00000002u;
mean_file_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.DataParameter.mean_file)
}
inline void DataParameter::set_mean_file(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000002u;
mean_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.DataParameter.mean_file)
}
inline void DataParameter::set_mean_file(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000002u;
mean_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.DataParameter.mean_file)
}
inline std::string* DataParameter::_internal_mutable_mean_file() {
_has_bits_[0] |= 0x00000002u;
return mean_file_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* DataParameter::release_mean_file() {
// @@protoc_insertion_point(field_release:caffe.DataParameter.mean_file)
if (!_internal_has_mean_file()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000002u;
return mean_file_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void DataParameter::set_allocated_mean_file(std::string* mean_file) {
if (mean_file != nullptr) {
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
mean_file_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), mean_file,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.DataParameter.mean_file)
}
// optional uint32 crop_size = 5 [default = 0];
inline bool DataParameter::_internal_has_crop_size() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool DataParameter::has_crop_size() const {
return _internal_has_crop_size();
}
inline void DataParameter::clear_crop_size() {
crop_size_ = 0u;
_has_bits_[0] &= ~0x00000008u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 DataParameter::_internal_crop_size() const {
return crop_size_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 DataParameter::crop_size() const {
// @@protoc_insertion_point(field_get:caffe.DataParameter.crop_size)
return _internal_crop_size();
}
inline void DataParameter::_internal_set_crop_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000008u;
crop_size_ = value;
}
inline void DataParameter::set_crop_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_crop_size(value);
// @@protoc_insertion_point(field_set:caffe.DataParameter.crop_size)
}
// optional bool mirror = 6 [default = false];
inline bool DataParameter::_internal_has_mirror() const {
bool value = (_has_bits_[0] & 0x00000020u) != 0;
return value;
}
inline bool DataParameter::has_mirror() const {
return _internal_has_mirror();
}
inline void DataParameter::clear_mirror() {
mirror_ = false;
_has_bits_[0] &= ~0x00000020u;
}
inline bool DataParameter::_internal_mirror() const {
return mirror_;
}
inline bool DataParameter::mirror() const {
// @@protoc_insertion_point(field_get:caffe.DataParameter.mirror)
return _internal_mirror();
}
inline void DataParameter::_internal_set_mirror(bool value) {
_has_bits_[0] |= 0x00000020u;
mirror_ = value;
}
inline void DataParameter::set_mirror(bool value) {
_internal_set_mirror(value);
// @@protoc_insertion_point(field_set:caffe.DataParameter.mirror)
}
// optional bool force_encoded_color = 9 [default = false];
inline bool DataParameter::_internal_has_force_encoded_color() const {
bool value = (_has_bits_[0] & 0x00000040u) != 0;
return value;
}
inline bool DataParameter::has_force_encoded_color() const {
return _internal_has_force_encoded_color();
}
inline void DataParameter::clear_force_encoded_color() {
force_encoded_color_ = false;
_has_bits_[0] &= ~0x00000040u;
}
inline bool DataParameter::_internal_force_encoded_color() const {
return force_encoded_color_;
}
inline bool DataParameter::force_encoded_color() const {
// @@protoc_insertion_point(field_get:caffe.DataParameter.force_encoded_color)
return _internal_force_encoded_color();
}
inline void DataParameter::_internal_set_force_encoded_color(bool value) {
_has_bits_[0] |= 0x00000040u;
force_encoded_color_ = value;
}
inline void DataParameter::set_force_encoded_color(bool value) {
_internal_set_force_encoded_color(value);
// @@protoc_insertion_point(field_set:caffe.DataParameter.force_encoded_color)
}
// optional uint32 prefetch = 10 [default = 4];
inline bool DataParameter::_internal_has_prefetch() const {
bool value = (_has_bits_[0] & 0x00000200u) != 0;
return value;
}
inline bool DataParameter::has_prefetch() const {
return _internal_has_prefetch();
}
inline void DataParameter::clear_prefetch() {
prefetch_ = 4u;
_has_bits_[0] &= ~0x00000200u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 DataParameter::_internal_prefetch() const {
return prefetch_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 DataParameter::prefetch() const {
// @@protoc_insertion_point(field_get:caffe.DataParameter.prefetch)
return _internal_prefetch();
}
inline void DataParameter::_internal_set_prefetch(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000200u;
prefetch_ = value;
}
inline void DataParameter::set_prefetch(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_prefetch(value);
// @@protoc_insertion_point(field_set:caffe.DataParameter.prefetch)
}
// -------------------------------------------------------------------
// DetectionEvaluateParameter
// optional uint32 num_classes = 1;
inline bool DetectionEvaluateParameter::_internal_has_num_classes() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool DetectionEvaluateParameter::has_num_classes() const {
return _internal_has_num_classes();
}
inline void DetectionEvaluateParameter::clear_num_classes() {
num_classes_ = 0u;
_has_bits_[0] &= ~0x00000002u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 DetectionEvaluateParameter::_internal_num_classes() const {
return num_classes_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 DetectionEvaluateParameter::num_classes() const {
// @@protoc_insertion_point(field_get:caffe.DetectionEvaluateParameter.num_classes)
return _internal_num_classes();
}
inline void DetectionEvaluateParameter::_internal_set_num_classes(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000002u;
num_classes_ = value;
}
inline void DetectionEvaluateParameter::set_num_classes(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_num_classes(value);
// @@protoc_insertion_point(field_set:caffe.DetectionEvaluateParameter.num_classes)
}
// optional uint32 background_label_id = 2 [default = 0];
inline bool DetectionEvaluateParameter::_internal_has_background_label_id() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool DetectionEvaluateParameter::has_background_label_id() const {
return _internal_has_background_label_id();
}
inline void DetectionEvaluateParameter::clear_background_label_id() {
background_label_id_ = 0u;
_has_bits_[0] &= ~0x00000004u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 DetectionEvaluateParameter::_internal_background_label_id() const {
return background_label_id_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 DetectionEvaluateParameter::background_label_id() const {
// @@protoc_insertion_point(field_get:caffe.DetectionEvaluateParameter.background_label_id)
return _internal_background_label_id();
}
inline void DetectionEvaluateParameter::_internal_set_background_label_id(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000004u;
background_label_id_ = value;
}
inline void DetectionEvaluateParameter::set_background_label_id(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_background_label_id(value);
// @@protoc_insertion_point(field_set:caffe.DetectionEvaluateParameter.background_label_id)
}
// optional float overlap_threshold = 3 [default = 0.5];
inline bool DetectionEvaluateParameter::_internal_has_overlap_threshold() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool DetectionEvaluateParameter::has_overlap_threshold() const {
return _internal_has_overlap_threshold();
}
inline void DetectionEvaluateParameter::clear_overlap_threshold() {
overlap_threshold_ = 0.5f;
_has_bits_[0] &= ~0x00000008u;
}
inline float DetectionEvaluateParameter::_internal_overlap_threshold() const {
return overlap_threshold_;
}
inline float DetectionEvaluateParameter::overlap_threshold() const {
// @@protoc_insertion_point(field_get:caffe.DetectionEvaluateParameter.overlap_threshold)
return _internal_overlap_threshold();
}
inline void DetectionEvaluateParameter::_internal_set_overlap_threshold(float value) {
_has_bits_[0] |= 0x00000008u;
overlap_threshold_ = value;
}
inline void DetectionEvaluateParameter::set_overlap_threshold(float value) {
_internal_set_overlap_threshold(value);
// @@protoc_insertion_point(field_set:caffe.DetectionEvaluateParameter.overlap_threshold)
}
// optional bool evaluate_difficult_gt = 4 [default = true];
inline bool DetectionEvaluateParameter::_internal_has_evaluate_difficult_gt() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool DetectionEvaluateParameter::has_evaluate_difficult_gt() const {
return _internal_has_evaluate_difficult_gt();
}
inline void DetectionEvaluateParameter::clear_evaluate_difficult_gt() {
evaluate_difficult_gt_ = true;
_has_bits_[0] &= ~0x00000010u;
}
inline bool DetectionEvaluateParameter::_internal_evaluate_difficult_gt() const {
return evaluate_difficult_gt_;
}
inline bool DetectionEvaluateParameter::evaluate_difficult_gt() const {
// @@protoc_insertion_point(field_get:caffe.DetectionEvaluateParameter.evaluate_difficult_gt)
return _internal_evaluate_difficult_gt();
}
inline void DetectionEvaluateParameter::_internal_set_evaluate_difficult_gt(bool value) {
_has_bits_[0] |= 0x00000010u;
evaluate_difficult_gt_ = value;
}
inline void DetectionEvaluateParameter::set_evaluate_difficult_gt(bool value) {
_internal_set_evaluate_difficult_gt(value);
// @@protoc_insertion_point(field_set:caffe.DetectionEvaluateParameter.evaluate_difficult_gt)
}
// optional string name_size_file = 5;
inline bool DetectionEvaluateParameter::_internal_has_name_size_file() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool DetectionEvaluateParameter::has_name_size_file() const {
return _internal_has_name_size_file();
}
inline void DetectionEvaluateParameter::clear_name_size_file() {
name_size_file_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000001u;
}
inline const std::string& DetectionEvaluateParameter::name_size_file() const {
// @@protoc_insertion_point(field_get:caffe.DetectionEvaluateParameter.name_size_file)
return _internal_name_size_file();
}
inline void DetectionEvaluateParameter::set_name_size_file(const std::string& value) {
_internal_set_name_size_file(value);
// @@protoc_insertion_point(field_set:caffe.DetectionEvaluateParameter.name_size_file)
}
inline std::string* DetectionEvaluateParameter::mutable_name_size_file() {
// @@protoc_insertion_point(field_mutable:caffe.DetectionEvaluateParameter.name_size_file)
return _internal_mutable_name_size_file();
}
inline const std::string& DetectionEvaluateParameter::_internal_name_size_file() const {
return name_size_file_.Get();
}
inline void DetectionEvaluateParameter::_internal_set_name_size_file(const std::string& value) {
_has_bits_[0] |= 0x00000001u;
name_size_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void DetectionEvaluateParameter::set_name_size_file(std::string&& value) {
_has_bits_[0] |= 0x00000001u;
name_size_file_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.DetectionEvaluateParameter.name_size_file)
}
inline void DetectionEvaluateParameter::set_name_size_file(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000001u;
name_size_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.DetectionEvaluateParameter.name_size_file)
}
inline void DetectionEvaluateParameter::set_name_size_file(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000001u;
name_size_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.DetectionEvaluateParameter.name_size_file)
}
inline std::string* DetectionEvaluateParameter::_internal_mutable_name_size_file() {
_has_bits_[0] |= 0x00000001u;
return name_size_file_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* DetectionEvaluateParameter::release_name_size_file() {
// @@protoc_insertion_point(field_release:caffe.DetectionEvaluateParameter.name_size_file)
if (!_internal_has_name_size_file()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000001u;
return name_size_file_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void DetectionEvaluateParameter::set_allocated_name_size_file(std::string* name_size_file) {
if (name_size_file != nullptr) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
name_size_file_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), name_size_file,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.DetectionEvaluateParameter.name_size_file)
}
// -------------------------------------------------------------------
// NonMaximumSuppressionParameter
// optional float nms_threshold = 1 [default = 0.3];
inline bool NonMaximumSuppressionParameter::_internal_has_nms_threshold() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool NonMaximumSuppressionParameter::has_nms_threshold() const {
return _internal_has_nms_threshold();
}
inline void NonMaximumSuppressionParameter::clear_nms_threshold() {
nms_threshold_ = 0.3f;
_has_bits_[0] &= ~0x00000002u;
}
inline float NonMaximumSuppressionParameter::_internal_nms_threshold() const {
return nms_threshold_;
}
inline float NonMaximumSuppressionParameter::nms_threshold() const {
// @@protoc_insertion_point(field_get:caffe.NonMaximumSuppressionParameter.nms_threshold)
return _internal_nms_threshold();
}
inline void NonMaximumSuppressionParameter::_internal_set_nms_threshold(float value) {
_has_bits_[0] |= 0x00000002u;
nms_threshold_ = value;
}
inline void NonMaximumSuppressionParameter::set_nms_threshold(float value) {
_internal_set_nms_threshold(value);
// @@protoc_insertion_point(field_set:caffe.NonMaximumSuppressionParameter.nms_threshold)
}
// optional int32 top_k = 2;
inline bool NonMaximumSuppressionParameter::_internal_has_top_k() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool NonMaximumSuppressionParameter::has_top_k() const {
return _internal_has_top_k();
}
inline void NonMaximumSuppressionParameter::clear_top_k() {
top_k_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 NonMaximumSuppressionParameter::_internal_top_k() const {
return top_k_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 NonMaximumSuppressionParameter::top_k() const {
// @@protoc_insertion_point(field_get:caffe.NonMaximumSuppressionParameter.top_k)
return _internal_top_k();
}
inline void NonMaximumSuppressionParameter::_internal_set_top_k(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000001u;
top_k_ = value;
}
inline void NonMaximumSuppressionParameter::set_top_k(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_top_k(value);
// @@protoc_insertion_point(field_set:caffe.NonMaximumSuppressionParameter.top_k)
}
// -------------------------------------------------------------------
// SaveOutputParameter
// optional string output_directory = 1;
inline bool SaveOutputParameter::_internal_has_output_directory() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool SaveOutputParameter::has_output_directory() const {
return _internal_has_output_directory();
}
inline void SaveOutputParameter::clear_output_directory() {
output_directory_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000001u;
}
inline const std::string& SaveOutputParameter::output_directory() const {
// @@protoc_insertion_point(field_get:caffe.SaveOutputParameter.output_directory)
return _internal_output_directory();
}
inline void SaveOutputParameter::set_output_directory(const std::string& value) {
_internal_set_output_directory(value);
// @@protoc_insertion_point(field_set:caffe.SaveOutputParameter.output_directory)
}
inline std::string* SaveOutputParameter::mutable_output_directory() {
// @@protoc_insertion_point(field_mutable:caffe.SaveOutputParameter.output_directory)
return _internal_mutable_output_directory();
}
inline const std::string& SaveOutputParameter::_internal_output_directory() const {
return output_directory_.Get();
}
inline void SaveOutputParameter::_internal_set_output_directory(const std::string& value) {
_has_bits_[0] |= 0x00000001u;
output_directory_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void SaveOutputParameter::set_output_directory(std::string&& value) {
_has_bits_[0] |= 0x00000001u;
output_directory_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.SaveOutputParameter.output_directory)
}
inline void SaveOutputParameter::set_output_directory(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000001u;
output_directory_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.SaveOutputParameter.output_directory)
}
inline void SaveOutputParameter::set_output_directory(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000001u;
output_directory_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.SaveOutputParameter.output_directory)
}
inline std::string* SaveOutputParameter::_internal_mutable_output_directory() {
_has_bits_[0] |= 0x00000001u;
return output_directory_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* SaveOutputParameter::release_output_directory() {
// @@protoc_insertion_point(field_release:caffe.SaveOutputParameter.output_directory)
if (!_internal_has_output_directory()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000001u;
return output_directory_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void SaveOutputParameter::set_allocated_output_directory(std::string* output_directory) {
if (output_directory != nullptr) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
output_directory_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), output_directory,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.SaveOutputParameter.output_directory)
}
// optional string output_name_prefix = 2;
inline bool SaveOutputParameter::_internal_has_output_name_prefix() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool SaveOutputParameter::has_output_name_prefix() const {
return _internal_has_output_name_prefix();
}
inline void SaveOutputParameter::clear_output_name_prefix() {
output_name_prefix_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000002u;
}
inline const std::string& SaveOutputParameter::output_name_prefix() const {
// @@protoc_insertion_point(field_get:caffe.SaveOutputParameter.output_name_prefix)
return _internal_output_name_prefix();
}
inline void SaveOutputParameter::set_output_name_prefix(const std::string& value) {
_internal_set_output_name_prefix(value);
// @@protoc_insertion_point(field_set:caffe.SaveOutputParameter.output_name_prefix)
}
inline std::string* SaveOutputParameter::mutable_output_name_prefix() {
// @@protoc_insertion_point(field_mutable:caffe.SaveOutputParameter.output_name_prefix)
return _internal_mutable_output_name_prefix();
}
inline const std::string& SaveOutputParameter::_internal_output_name_prefix() const {
return output_name_prefix_.Get();
}
inline void SaveOutputParameter::_internal_set_output_name_prefix(const std::string& value) {
_has_bits_[0] |= 0x00000002u;
output_name_prefix_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void SaveOutputParameter::set_output_name_prefix(std::string&& value) {
_has_bits_[0] |= 0x00000002u;
output_name_prefix_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.SaveOutputParameter.output_name_prefix)
}
inline void SaveOutputParameter::set_output_name_prefix(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000002u;
output_name_prefix_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.SaveOutputParameter.output_name_prefix)
}
inline void SaveOutputParameter::set_output_name_prefix(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000002u;
output_name_prefix_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.SaveOutputParameter.output_name_prefix)
}
inline std::string* SaveOutputParameter::_internal_mutable_output_name_prefix() {
_has_bits_[0] |= 0x00000002u;
return output_name_prefix_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* SaveOutputParameter::release_output_name_prefix() {
// @@protoc_insertion_point(field_release:caffe.SaveOutputParameter.output_name_prefix)
if (!_internal_has_output_name_prefix()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000002u;
return output_name_prefix_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void SaveOutputParameter::set_allocated_output_name_prefix(std::string* output_name_prefix) {
if (output_name_prefix != nullptr) {
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
output_name_prefix_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), output_name_prefix,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.SaveOutputParameter.output_name_prefix)
}
// optional string output_format = 3;
inline bool SaveOutputParameter::_internal_has_output_format() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool SaveOutputParameter::has_output_format() const {
return _internal_has_output_format();
}
inline void SaveOutputParameter::clear_output_format() {
output_format_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000004u;
}
inline const std::string& SaveOutputParameter::output_format() const {
// @@protoc_insertion_point(field_get:caffe.SaveOutputParameter.output_format)
return _internal_output_format();
}
inline void SaveOutputParameter::set_output_format(const std::string& value) {
_internal_set_output_format(value);
// @@protoc_insertion_point(field_set:caffe.SaveOutputParameter.output_format)
}
inline std::string* SaveOutputParameter::mutable_output_format() {
// @@protoc_insertion_point(field_mutable:caffe.SaveOutputParameter.output_format)
return _internal_mutable_output_format();
}
inline const std::string& SaveOutputParameter::_internal_output_format() const {
return output_format_.Get();
}
inline void SaveOutputParameter::_internal_set_output_format(const std::string& value) {
_has_bits_[0] |= 0x00000004u;
output_format_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void SaveOutputParameter::set_output_format(std::string&& value) {
_has_bits_[0] |= 0x00000004u;
output_format_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.SaveOutputParameter.output_format)
}
inline void SaveOutputParameter::set_output_format(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000004u;
output_format_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.SaveOutputParameter.output_format)
}
inline void SaveOutputParameter::set_output_format(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000004u;
output_format_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.SaveOutputParameter.output_format)
}
inline std::string* SaveOutputParameter::_internal_mutable_output_format() {
_has_bits_[0] |= 0x00000004u;
return output_format_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* SaveOutputParameter::release_output_format() {
// @@protoc_insertion_point(field_release:caffe.SaveOutputParameter.output_format)
if (!_internal_has_output_format()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000004u;
return output_format_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void SaveOutputParameter::set_allocated_output_format(std::string* output_format) {
if (output_format != nullptr) {
_has_bits_[0] |= 0x00000004u;
} else {
_has_bits_[0] &= ~0x00000004u;
}
output_format_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), output_format,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.SaveOutputParameter.output_format)
}
// optional string label_map_file = 4;
inline bool SaveOutputParameter::_internal_has_label_map_file() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool SaveOutputParameter::has_label_map_file() const {
return _internal_has_label_map_file();
}
inline void SaveOutputParameter::clear_label_map_file() {
label_map_file_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000008u;
}
inline const std::string& SaveOutputParameter::label_map_file() const {
// @@protoc_insertion_point(field_get:caffe.SaveOutputParameter.label_map_file)
return _internal_label_map_file();
}
inline void SaveOutputParameter::set_label_map_file(const std::string& value) {
_internal_set_label_map_file(value);
// @@protoc_insertion_point(field_set:caffe.SaveOutputParameter.label_map_file)
}
inline std::string* SaveOutputParameter::mutable_label_map_file() {
// @@protoc_insertion_point(field_mutable:caffe.SaveOutputParameter.label_map_file)
return _internal_mutable_label_map_file();
}
inline const std::string& SaveOutputParameter::_internal_label_map_file() const {
return label_map_file_.Get();
}
inline void SaveOutputParameter::_internal_set_label_map_file(const std::string& value) {
_has_bits_[0] |= 0x00000008u;
label_map_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void SaveOutputParameter::set_label_map_file(std::string&& value) {
_has_bits_[0] |= 0x00000008u;
label_map_file_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.SaveOutputParameter.label_map_file)
}
inline void SaveOutputParameter::set_label_map_file(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000008u;
label_map_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.SaveOutputParameter.label_map_file)
}
inline void SaveOutputParameter::set_label_map_file(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000008u;
label_map_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.SaveOutputParameter.label_map_file)
}
inline std::string* SaveOutputParameter::_internal_mutable_label_map_file() {
_has_bits_[0] |= 0x00000008u;
return label_map_file_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* SaveOutputParameter::release_label_map_file() {
// @@protoc_insertion_point(field_release:caffe.SaveOutputParameter.label_map_file)
if (!_internal_has_label_map_file()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000008u;
return label_map_file_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void SaveOutputParameter::set_allocated_label_map_file(std::string* label_map_file) {
if (label_map_file != nullptr) {
_has_bits_[0] |= 0x00000008u;
} else {
_has_bits_[0] &= ~0x00000008u;
}
label_map_file_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), label_map_file,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.SaveOutputParameter.label_map_file)
}
// optional string name_size_file = 5;
inline bool SaveOutputParameter::_internal_has_name_size_file() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool SaveOutputParameter::has_name_size_file() const {
return _internal_has_name_size_file();
}
inline void SaveOutputParameter::clear_name_size_file() {
name_size_file_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000010u;
}
inline const std::string& SaveOutputParameter::name_size_file() const {
// @@protoc_insertion_point(field_get:caffe.SaveOutputParameter.name_size_file)
return _internal_name_size_file();
}
inline void SaveOutputParameter::set_name_size_file(const std::string& value) {
_internal_set_name_size_file(value);
// @@protoc_insertion_point(field_set:caffe.SaveOutputParameter.name_size_file)
}
inline std::string* SaveOutputParameter::mutable_name_size_file() {
// @@protoc_insertion_point(field_mutable:caffe.SaveOutputParameter.name_size_file)
return _internal_mutable_name_size_file();
}
inline const std::string& SaveOutputParameter::_internal_name_size_file() const {
return name_size_file_.Get();
}
inline void SaveOutputParameter::_internal_set_name_size_file(const std::string& value) {
_has_bits_[0] |= 0x00000010u;
name_size_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void SaveOutputParameter::set_name_size_file(std::string&& value) {
_has_bits_[0] |= 0x00000010u;
name_size_file_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.SaveOutputParameter.name_size_file)
}
inline void SaveOutputParameter::set_name_size_file(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000010u;
name_size_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.SaveOutputParameter.name_size_file)
}
inline void SaveOutputParameter::set_name_size_file(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000010u;
name_size_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.SaveOutputParameter.name_size_file)
}
inline std::string* SaveOutputParameter::_internal_mutable_name_size_file() {
_has_bits_[0] |= 0x00000010u;
return name_size_file_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* SaveOutputParameter::release_name_size_file() {
// @@protoc_insertion_point(field_release:caffe.SaveOutputParameter.name_size_file)
if (!_internal_has_name_size_file()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000010u;
return name_size_file_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void SaveOutputParameter::set_allocated_name_size_file(std::string* name_size_file) {
if (name_size_file != nullptr) {
_has_bits_[0] |= 0x00000010u;
} else {
_has_bits_[0] &= ~0x00000010u;
}
name_size_file_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), name_size_file,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.SaveOutputParameter.name_size_file)
}
// optional uint32 num_test_image = 6;
inline bool SaveOutputParameter::_internal_has_num_test_image() const {
bool value = (_has_bits_[0] & 0x00000020u) != 0;
return value;
}
inline bool SaveOutputParameter::has_num_test_image() const {
return _internal_has_num_test_image();
}
inline void SaveOutputParameter::clear_num_test_image() {
num_test_image_ = 0u;
_has_bits_[0] &= ~0x00000020u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 SaveOutputParameter::_internal_num_test_image() const {
return num_test_image_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 SaveOutputParameter::num_test_image() const {
// @@protoc_insertion_point(field_get:caffe.SaveOutputParameter.num_test_image)
return _internal_num_test_image();
}
inline void SaveOutputParameter::_internal_set_num_test_image(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000020u;
num_test_image_ = value;
}
inline void SaveOutputParameter::set_num_test_image(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_num_test_image(value);
// @@protoc_insertion_point(field_set:caffe.SaveOutputParameter.num_test_image)
}
// -------------------------------------------------------------------
// DetectionOutputParameter
// optional uint32 num_classes = 1;
inline bool DetectionOutputParameter::_internal_has_num_classes() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool DetectionOutputParameter::has_num_classes() const {
return _internal_has_num_classes();
}
inline void DetectionOutputParameter::clear_num_classes() {
num_classes_ = 0u;
_has_bits_[0] &= ~0x00000004u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 DetectionOutputParameter::_internal_num_classes() const {
return num_classes_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 DetectionOutputParameter::num_classes() const {
// @@protoc_insertion_point(field_get:caffe.DetectionOutputParameter.num_classes)
return _internal_num_classes();
}
inline void DetectionOutputParameter::_internal_set_num_classes(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000004u;
num_classes_ = value;
}
inline void DetectionOutputParameter::set_num_classes(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_num_classes(value);
// @@protoc_insertion_point(field_set:caffe.DetectionOutputParameter.num_classes)
}
// optional bool share_location = 2 [default = true];
inline bool DetectionOutputParameter::_internal_has_share_location() const {
bool value = (_has_bits_[0] & 0x00000200u) != 0;
return value;
}
inline bool DetectionOutputParameter::has_share_location() const {
return _internal_has_share_location();
}
inline void DetectionOutputParameter::clear_share_location() {
share_location_ = true;
_has_bits_[0] &= ~0x00000200u;
}
inline bool DetectionOutputParameter::_internal_share_location() const {
return share_location_;
}
inline bool DetectionOutputParameter::share_location() const {
// @@protoc_insertion_point(field_get:caffe.DetectionOutputParameter.share_location)
return _internal_share_location();
}
inline void DetectionOutputParameter::_internal_set_share_location(bool value) {
_has_bits_[0] |= 0x00000200u;
share_location_ = value;
}
inline void DetectionOutputParameter::set_share_location(bool value) {
_internal_set_share_location(value);
// @@protoc_insertion_point(field_set:caffe.DetectionOutputParameter.share_location)
}
// optional int32 background_label_id = 3 [default = 0];
inline bool DetectionOutputParameter::_internal_has_background_label_id() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool DetectionOutputParameter::has_background_label_id() const {
return _internal_has_background_label_id();
}
inline void DetectionOutputParameter::clear_background_label_id() {
background_label_id_ = 0;
_has_bits_[0] &= ~0x00000008u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 DetectionOutputParameter::_internal_background_label_id() const {
return background_label_id_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 DetectionOutputParameter::background_label_id() const {
// @@protoc_insertion_point(field_get:caffe.DetectionOutputParameter.background_label_id)
return _internal_background_label_id();
}
inline void DetectionOutputParameter::_internal_set_background_label_id(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000008u;
background_label_id_ = value;
}
inline void DetectionOutputParameter::set_background_label_id(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_background_label_id(value);
// @@protoc_insertion_point(field_set:caffe.DetectionOutputParameter.background_label_id)
}
// optional .caffe.NonMaximumSuppressionParameter nms_param = 4;
inline bool DetectionOutputParameter::_internal_has_nms_param() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
PROTOBUF_ASSUME(!value || nms_param_ != nullptr);
return value;
}
inline bool DetectionOutputParameter::has_nms_param() const {
return _internal_has_nms_param();
}
inline void DetectionOutputParameter::clear_nms_param() {
if (nms_param_ != nullptr) nms_param_->Clear();
_has_bits_[0] &= ~0x00000001u;
}
inline const ::caffe::NonMaximumSuppressionParameter& DetectionOutputParameter::_internal_nms_param() const {
const ::caffe::NonMaximumSuppressionParameter* p = nms_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::NonMaximumSuppressionParameter*>(
&::caffe::_NonMaximumSuppressionParameter_default_instance_);
}
inline const ::caffe::NonMaximumSuppressionParameter& DetectionOutputParameter::nms_param() const {
// @@protoc_insertion_point(field_get:caffe.DetectionOutputParameter.nms_param)
return _internal_nms_param();
}
inline void DetectionOutputParameter::unsafe_arena_set_allocated_nms_param(
::caffe::NonMaximumSuppressionParameter* nms_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(nms_param_);
}
nms_param_ = nms_param;
if (nms_param) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.DetectionOutputParameter.nms_param)
}
inline ::caffe::NonMaximumSuppressionParameter* DetectionOutputParameter::release_nms_param() {
_has_bits_[0] &= ~0x00000001u;
::caffe::NonMaximumSuppressionParameter* temp = nms_param_;
nms_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::NonMaximumSuppressionParameter* DetectionOutputParameter::unsafe_arena_release_nms_param() {
// @@protoc_insertion_point(field_release:caffe.DetectionOutputParameter.nms_param)
_has_bits_[0] &= ~0x00000001u;
::caffe::NonMaximumSuppressionParameter* temp = nms_param_;
nms_param_ = nullptr;
return temp;
}
inline ::caffe::NonMaximumSuppressionParameter* DetectionOutputParameter::_internal_mutable_nms_param() {
_has_bits_[0] |= 0x00000001u;
if (nms_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::NonMaximumSuppressionParameter>(GetArena());
nms_param_ = p;
}
return nms_param_;
}
inline ::caffe::NonMaximumSuppressionParameter* DetectionOutputParameter::mutable_nms_param() {
// @@protoc_insertion_point(field_mutable:caffe.DetectionOutputParameter.nms_param)
return _internal_mutable_nms_param();
}
inline void DetectionOutputParameter::set_allocated_nms_param(::caffe::NonMaximumSuppressionParameter* nms_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete nms_param_;
}
if (nms_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(nms_param);
if (message_arena != submessage_arena) {
nms_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, nms_param, submessage_arena);
}
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
nms_param_ = nms_param;
// @@protoc_insertion_point(field_set_allocated:caffe.DetectionOutputParameter.nms_param)
}
// optional .caffe.SaveOutputParameter save_output_param = 5;
inline bool DetectionOutputParameter::_internal_has_save_output_param() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
PROTOBUF_ASSUME(!value || save_output_param_ != nullptr);
return value;
}
inline bool DetectionOutputParameter::has_save_output_param() const {
return _internal_has_save_output_param();
}
inline void DetectionOutputParameter::clear_save_output_param() {
if (save_output_param_ != nullptr) save_output_param_->Clear();
_has_bits_[0] &= ~0x00000002u;
}
inline const ::caffe::SaveOutputParameter& DetectionOutputParameter::_internal_save_output_param() const {
const ::caffe::SaveOutputParameter* p = save_output_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::SaveOutputParameter*>(
&::caffe::_SaveOutputParameter_default_instance_);
}
inline const ::caffe::SaveOutputParameter& DetectionOutputParameter::save_output_param() const {
// @@protoc_insertion_point(field_get:caffe.DetectionOutputParameter.save_output_param)
return _internal_save_output_param();
}
inline void DetectionOutputParameter::unsafe_arena_set_allocated_save_output_param(
::caffe::SaveOutputParameter* save_output_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(save_output_param_);
}
save_output_param_ = save_output_param;
if (save_output_param) {
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.DetectionOutputParameter.save_output_param)
}
inline ::caffe::SaveOutputParameter* DetectionOutputParameter::release_save_output_param() {
_has_bits_[0] &= ~0x00000002u;
::caffe::SaveOutputParameter* temp = save_output_param_;
save_output_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::SaveOutputParameter* DetectionOutputParameter::unsafe_arena_release_save_output_param() {
// @@protoc_insertion_point(field_release:caffe.DetectionOutputParameter.save_output_param)
_has_bits_[0] &= ~0x00000002u;
::caffe::SaveOutputParameter* temp = save_output_param_;
save_output_param_ = nullptr;
return temp;
}
inline ::caffe::SaveOutputParameter* DetectionOutputParameter::_internal_mutable_save_output_param() {
_has_bits_[0] |= 0x00000002u;
if (save_output_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::SaveOutputParameter>(GetArena());
save_output_param_ = p;
}
return save_output_param_;
}
inline ::caffe::SaveOutputParameter* DetectionOutputParameter::mutable_save_output_param() {
// @@protoc_insertion_point(field_mutable:caffe.DetectionOutputParameter.save_output_param)
return _internal_mutable_save_output_param();
}
inline void DetectionOutputParameter::set_allocated_save_output_param(::caffe::SaveOutputParameter* save_output_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete save_output_param_;
}
if (save_output_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(save_output_param);
if (message_arena != submessage_arena) {
save_output_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, save_output_param, submessage_arena);
}
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
save_output_param_ = save_output_param;
// @@protoc_insertion_point(field_set_allocated:caffe.DetectionOutputParameter.save_output_param)
}
// optional .caffe.PriorBoxParameter.CodeType code_type = 6 [default = CORNER];
inline bool DetectionOutputParameter::_internal_has_code_type() const {
bool value = (_has_bits_[0] & 0x00000400u) != 0;
return value;
}
inline bool DetectionOutputParameter::has_code_type() const {
return _internal_has_code_type();
}
inline void DetectionOutputParameter::clear_code_type() {
code_type_ = 1;
_has_bits_[0] &= ~0x00000400u;
}
inline ::caffe::PriorBoxParameter_CodeType DetectionOutputParameter::_internal_code_type() const {
return static_cast< ::caffe::PriorBoxParameter_CodeType >(code_type_);
}
inline ::caffe::PriorBoxParameter_CodeType DetectionOutputParameter::code_type() const {
// @@protoc_insertion_point(field_get:caffe.DetectionOutputParameter.code_type)
return _internal_code_type();
}
inline void DetectionOutputParameter::_internal_set_code_type(::caffe::PriorBoxParameter_CodeType value) {
assert(::caffe::PriorBoxParameter_CodeType_IsValid(value));
_has_bits_[0] |= 0x00000400u;
code_type_ = value;
}
inline void DetectionOutputParameter::set_code_type(::caffe::PriorBoxParameter_CodeType value) {
_internal_set_code_type(value);
// @@protoc_insertion_point(field_set:caffe.DetectionOutputParameter.code_type)
}
// optional bool variance_encoded_in_target = 8 [default = false];
inline bool DetectionOutputParameter::_internal_has_variance_encoded_in_target() const {
bool value = (_has_bits_[0] & 0x00000020u) != 0;
return value;
}
inline bool DetectionOutputParameter::has_variance_encoded_in_target() const {
return _internal_has_variance_encoded_in_target();
}
inline void DetectionOutputParameter::clear_variance_encoded_in_target() {
variance_encoded_in_target_ = false;
_has_bits_[0] &= ~0x00000020u;
}
inline bool DetectionOutputParameter::_internal_variance_encoded_in_target() const {
return variance_encoded_in_target_;
}
inline bool DetectionOutputParameter::variance_encoded_in_target() const {
// @@protoc_insertion_point(field_get:caffe.DetectionOutputParameter.variance_encoded_in_target)
return _internal_variance_encoded_in_target();
}
inline void DetectionOutputParameter::_internal_set_variance_encoded_in_target(bool value) {
_has_bits_[0] |= 0x00000020u;
variance_encoded_in_target_ = value;
}
inline void DetectionOutputParameter::set_variance_encoded_in_target(bool value) {
_internal_set_variance_encoded_in_target(value);
// @@protoc_insertion_point(field_set:caffe.DetectionOutputParameter.variance_encoded_in_target)
}
// optional int32 keep_top_k = 7 [default = -1];
inline bool DetectionOutputParameter::_internal_has_keep_top_k() const {
bool value = (_has_bits_[0] & 0x00000100u) != 0;
return value;
}
inline bool DetectionOutputParameter::has_keep_top_k() const {
return _internal_has_keep_top_k();
}
inline void DetectionOutputParameter::clear_keep_top_k() {
keep_top_k_ = -1;
_has_bits_[0] &= ~0x00000100u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 DetectionOutputParameter::_internal_keep_top_k() const {
return keep_top_k_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 DetectionOutputParameter::keep_top_k() const {
// @@protoc_insertion_point(field_get:caffe.DetectionOutputParameter.keep_top_k)
return _internal_keep_top_k();
}
inline void DetectionOutputParameter::_internal_set_keep_top_k(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000100u;
keep_top_k_ = value;
}
inline void DetectionOutputParameter::set_keep_top_k(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_keep_top_k(value);
// @@protoc_insertion_point(field_set:caffe.DetectionOutputParameter.keep_top_k)
}
// optional float confidence_threshold = 9;
inline bool DetectionOutputParameter::_internal_has_confidence_threshold() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool DetectionOutputParameter::has_confidence_threshold() const {
return _internal_has_confidence_threshold();
}
inline void DetectionOutputParameter::clear_confidence_threshold() {
confidence_threshold_ = 0;
_has_bits_[0] &= ~0x00000010u;
}
inline float DetectionOutputParameter::_internal_confidence_threshold() const {
return confidence_threshold_;
}
inline float DetectionOutputParameter::confidence_threshold() const {
// @@protoc_insertion_point(field_get:caffe.DetectionOutputParameter.confidence_threshold)
return _internal_confidence_threshold();
}
inline void DetectionOutputParameter::_internal_set_confidence_threshold(float value) {
_has_bits_[0] |= 0x00000010u;
confidence_threshold_ = value;
}
inline void DetectionOutputParameter::set_confidence_threshold(float value) {
_internal_set_confidence_threshold(value);
// @@protoc_insertion_point(field_set:caffe.DetectionOutputParameter.confidence_threshold)
}
// optional bool visualize = 10 [default = false];
inline bool DetectionOutputParameter::_internal_has_visualize() const {
bool value = (_has_bits_[0] & 0x00000040u) != 0;
return value;
}
inline bool DetectionOutputParameter::has_visualize() const {
return _internal_has_visualize();
}
inline void DetectionOutputParameter::clear_visualize() {
visualize_ = false;
_has_bits_[0] &= ~0x00000040u;
}
inline bool DetectionOutputParameter::_internal_visualize() const {
return visualize_;
}
inline bool DetectionOutputParameter::visualize() const {
// @@protoc_insertion_point(field_get:caffe.DetectionOutputParameter.visualize)
return _internal_visualize();
}
inline void DetectionOutputParameter::_internal_set_visualize(bool value) {
_has_bits_[0] |= 0x00000040u;
visualize_ = value;
}
inline void DetectionOutputParameter::set_visualize(bool value) {
_internal_set_visualize(value);
// @@protoc_insertion_point(field_set:caffe.DetectionOutputParameter.visualize)
}
// optional float visualize_threshold = 11;
inline bool DetectionOutputParameter::_internal_has_visualize_threshold() const {
bool value = (_has_bits_[0] & 0x00000080u) != 0;
return value;
}
inline bool DetectionOutputParameter::has_visualize_threshold() const {
return _internal_has_visualize_threshold();
}
inline void DetectionOutputParameter::clear_visualize_threshold() {
visualize_threshold_ = 0;
_has_bits_[0] &= ~0x00000080u;
}
inline float DetectionOutputParameter::_internal_visualize_threshold() const {
return visualize_threshold_;
}
inline float DetectionOutputParameter::visualize_threshold() const {
// @@protoc_insertion_point(field_get:caffe.DetectionOutputParameter.visualize_threshold)
return _internal_visualize_threshold();
}
inline void DetectionOutputParameter::_internal_set_visualize_threshold(float value) {
_has_bits_[0] |= 0x00000080u;
visualize_threshold_ = value;
}
inline void DetectionOutputParameter::set_visualize_threshold(float value) {
_internal_set_visualize_threshold(value);
// @@protoc_insertion_point(field_set:caffe.DetectionOutputParameter.visualize_threshold)
}
// -------------------------------------------------------------------
// DropoutParameter
// optional float dropout_ratio = 1 [default = 0.5];
inline bool DropoutParameter::_internal_has_dropout_ratio() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool DropoutParameter::has_dropout_ratio() const {
return _internal_has_dropout_ratio();
}
inline void DropoutParameter::clear_dropout_ratio() {
dropout_ratio_ = 0.5f;
_has_bits_[0] &= ~0x00000001u;
}
inline float DropoutParameter::_internal_dropout_ratio() const {
return dropout_ratio_;
}
inline float DropoutParameter::dropout_ratio() const {
// @@protoc_insertion_point(field_get:caffe.DropoutParameter.dropout_ratio)
return _internal_dropout_ratio();
}
inline void DropoutParameter::_internal_set_dropout_ratio(float value) {
_has_bits_[0] |= 0x00000001u;
dropout_ratio_ = value;
}
inline void DropoutParameter::set_dropout_ratio(float value) {
_internal_set_dropout_ratio(value);
// @@protoc_insertion_point(field_set:caffe.DropoutParameter.dropout_ratio)
}
// optional bool scale_train = 2 [default = true];
inline bool DropoutParameter::_internal_has_scale_train() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool DropoutParameter::has_scale_train() const {
return _internal_has_scale_train();
}
inline void DropoutParameter::clear_scale_train() {
scale_train_ = true;
_has_bits_[0] &= ~0x00000002u;
}
inline bool DropoutParameter::_internal_scale_train() const {
return scale_train_;
}
inline bool DropoutParameter::scale_train() const {
// @@protoc_insertion_point(field_get:caffe.DropoutParameter.scale_train)
return _internal_scale_train();
}
inline void DropoutParameter::_internal_set_scale_train(bool value) {
_has_bits_[0] |= 0x00000002u;
scale_train_ = value;
}
inline void DropoutParameter::set_scale_train(bool value) {
_internal_set_scale_train(value);
// @@protoc_insertion_point(field_set:caffe.DropoutParameter.scale_train)
}
// -------------------------------------------------------------------
// DummyDataParameter
// repeated .caffe.FillerParameter data_filler = 1;
inline int DummyDataParameter::_internal_data_filler_size() const {
return data_filler_.size();
}
inline int DummyDataParameter::data_filler_size() const {
return _internal_data_filler_size();
}
inline void DummyDataParameter::clear_data_filler() {
data_filler_.Clear();
}
inline ::caffe::FillerParameter* DummyDataParameter::mutable_data_filler(int index) {
// @@protoc_insertion_point(field_mutable:caffe.DummyDataParameter.data_filler)
return data_filler_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::FillerParameter >*
DummyDataParameter::mutable_data_filler() {
// @@protoc_insertion_point(field_mutable_list:caffe.DummyDataParameter.data_filler)
return &data_filler_;
}
inline const ::caffe::FillerParameter& DummyDataParameter::_internal_data_filler(int index) const {
return data_filler_.Get(index);
}
inline const ::caffe::FillerParameter& DummyDataParameter::data_filler(int index) const {
// @@protoc_insertion_point(field_get:caffe.DummyDataParameter.data_filler)
return _internal_data_filler(index);
}
inline ::caffe::FillerParameter* DummyDataParameter::_internal_add_data_filler() {
return data_filler_.Add();
}
inline ::caffe::FillerParameter* DummyDataParameter::add_data_filler() {
// @@protoc_insertion_point(field_add:caffe.DummyDataParameter.data_filler)
return _internal_add_data_filler();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::FillerParameter >&
DummyDataParameter::data_filler() const {
// @@protoc_insertion_point(field_list:caffe.DummyDataParameter.data_filler)
return data_filler_;
}
// repeated .caffe.BlobShape shape = 6;
inline int DummyDataParameter::_internal_shape_size() const {
return shape_.size();
}
inline int DummyDataParameter::shape_size() const {
return _internal_shape_size();
}
inline void DummyDataParameter::clear_shape() {
shape_.Clear();
}
inline ::caffe::BlobShape* DummyDataParameter::mutable_shape(int index) {
// @@protoc_insertion_point(field_mutable:caffe.DummyDataParameter.shape)
return shape_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape >*
DummyDataParameter::mutable_shape() {
// @@protoc_insertion_point(field_mutable_list:caffe.DummyDataParameter.shape)
return &shape_;
}
inline const ::caffe::BlobShape& DummyDataParameter::_internal_shape(int index) const {
return shape_.Get(index);
}
inline const ::caffe::BlobShape& DummyDataParameter::shape(int index) const {
// @@protoc_insertion_point(field_get:caffe.DummyDataParameter.shape)
return _internal_shape(index);
}
inline ::caffe::BlobShape* DummyDataParameter::_internal_add_shape() {
return shape_.Add();
}
inline ::caffe::BlobShape* DummyDataParameter::add_shape() {
// @@protoc_insertion_point(field_add:caffe.DummyDataParameter.shape)
return _internal_add_shape();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape >&
DummyDataParameter::shape() const {
// @@protoc_insertion_point(field_list:caffe.DummyDataParameter.shape)
return shape_;
}
// repeated uint32 num = 2;
inline int DummyDataParameter::_internal_num_size() const {
return num_.size();
}
inline int DummyDataParameter::num_size() const {
return _internal_num_size();
}
inline void DummyDataParameter::clear_num() {
num_.Clear();
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 DummyDataParameter::_internal_num(int index) const {
return num_.Get(index);
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 DummyDataParameter::num(int index) const {
// @@protoc_insertion_point(field_get:caffe.DummyDataParameter.num)
return _internal_num(index);
}
inline void DummyDataParameter::set_num(int index, ::PROTOBUF_NAMESPACE_ID::uint32 value) {
num_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.DummyDataParameter.num)
}
inline void DummyDataParameter::_internal_add_num(::PROTOBUF_NAMESPACE_ID::uint32 value) {
num_.Add(value);
}
inline void DummyDataParameter::add_num(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_add_num(value);
// @@protoc_insertion_point(field_add:caffe.DummyDataParameter.num)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
DummyDataParameter::_internal_num() const {
return num_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
DummyDataParameter::num() const {
// @@protoc_insertion_point(field_list:caffe.DummyDataParameter.num)
return _internal_num();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
DummyDataParameter::_internal_mutable_num() {
return &num_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
DummyDataParameter::mutable_num() {
// @@protoc_insertion_point(field_mutable_list:caffe.DummyDataParameter.num)
return _internal_mutable_num();
}
// repeated uint32 channels = 3;
inline int DummyDataParameter::_internal_channels_size() const {
return channels_.size();
}
inline int DummyDataParameter::channels_size() const {
return _internal_channels_size();
}
inline void DummyDataParameter::clear_channels() {
channels_.Clear();
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 DummyDataParameter::_internal_channels(int index) const {
return channels_.Get(index);
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 DummyDataParameter::channels(int index) const {
// @@protoc_insertion_point(field_get:caffe.DummyDataParameter.channels)
return _internal_channels(index);
}
inline void DummyDataParameter::set_channels(int index, ::PROTOBUF_NAMESPACE_ID::uint32 value) {
channels_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.DummyDataParameter.channels)
}
inline void DummyDataParameter::_internal_add_channels(::PROTOBUF_NAMESPACE_ID::uint32 value) {
channels_.Add(value);
}
inline void DummyDataParameter::add_channels(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_add_channels(value);
// @@protoc_insertion_point(field_add:caffe.DummyDataParameter.channels)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
DummyDataParameter::_internal_channels() const {
return channels_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
DummyDataParameter::channels() const {
// @@protoc_insertion_point(field_list:caffe.DummyDataParameter.channels)
return _internal_channels();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
DummyDataParameter::_internal_mutable_channels() {
return &channels_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
DummyDataParameter::mutable_channels() {
// @@protoc_insertion_point(field_mutable_list:caffe.DummyDataParameter.channels)
return _internal_mutable_channels();
}
// repeated uint32 height = 4;
inline int DummyDataParameter::_internal_height_size() const {
return height_.size();
}
inline int DummyDataParameter::height_size() const {
return _internal_height_size();
}
inline void DummyDataParameter::clear_height() {
height_.Clear();
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 DummyDataParameter::_internal_height(int index) const {
return height_.Get(index);
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 DummyDataParameter::height(int index) const {
// @@protoc_insertion_point(field_get:caffe.DummyDataParameter.height)
return _internal_height(index);
}
inline void DummyDataParameter::set_height(int index, ::PROTOBUF_NAMESPACE_ID::uint32 value) {
height_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.DummyDataParameter.height)
}
inline void DummyDataParameter::_internal_add_height(::PROTOBUF_NAMESPACE_ID::uint32 value) {
height_.Add(value);
}
inline void DummyDataParameter::add_height(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_add_height(value);
// @@protoc_insertion_point(field_add:caffe.DummyDataParameter.height)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
DummyDataParameter::_internal_height() const {
return height_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
DummyDataParameter::height() const {
// @@protoc_insertion_point(field_list:caffe.DummyDataParameter.height)
return _internal_height();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
DummyDataParameter::_internal_mutable_height() {
return &height_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
DummyDataParameter::mutable_height() {
// @@protoc_insertion_point(field_mutable_list:caffe.DummyDataParameter.height)
return _internal_mutable_height();
}
// repeated uint32 width = 5;
inline int DummyDataParameter::_internal_width_size() const {
return width_.size();
}
inline int DummyDataParameter::width_size() const {
return _internal_width_size();
}
inline void DummyDataParameter::clear_width() {
width_.Clear();
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 DummyDataParameter::_internal_width(int index) const {
return width_.Get(index);
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 DummyDataParameter::width(int index) const {
// @@protoc_insertion_point(field_get:caffe.DummyDataParameter.width)
return _internal_width(index);
}
inline void DummyDataParameter::set_width(int index, ::PROTOBUF_NAMESPACE_ID::uint32 value) {
width_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.DummyDataParameter.width)
}
inline void DummyDataParameter::_internal_add_width(::PROTOBUF_NAMESPACE_ID::uint32 value) {
width_.Add(value);
}
inline void DummyDataParameter::add_width(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_add_width(value);
// @@protoc_insertion_point(field_add:caffe.DummyDataParameter.width)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
DummyDataParameter::_internal_width() const {
return width_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
DummyDataParameter::width() const {
// @@protoc_insertion_point(field_list:caffe.DummyDataParameter.width)
return _internal_width();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
DummyDataParameter::_internal_mutable_width() {
return &width_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
DummyDataParameter::mutable_width() {
// @@protoc_insertion_point(field_mutable_list:caffe.DummyDataParameter.width)
return _internal_mutable_width();
}
// -------------------------------------------------------------------
// EltwiseParameter
// optional .caffe.EltwiseParameter.EltwiseOp operation = 1 [default = SUM];
inline bool EltwiseParameter::_internal_has_operation() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool EltwiseParameter::has_operation() const {
return _internal_has_operation();
}
inline void EltwiseParameter::clear_operation() {
operation_ = 1;
_has_bits_[0] &= ~0x00000001u;
}
inline ::caffe::EltwiseParameter_EltwiseOp EltwiseParameter::_internal_operation() const {
return static_cast< ::caffe::EltwiseParameter_EltwiseOp >(operation_);
}
inline ::caffe::EltwiseParameter_EltwiseOp EltwiseParameter::operation() const {
// @@protoc_insertion_point(field_get:caffe.EltwiseParameter.operation)
return _internal_operation();
}
inline void EltwiseParameter::_internal_set_operation(::caffe::EltwiseParameter_EltwiseOp value) {
assert(::caffe::EltwiseParameter_EltwiseOp_IsValid(value));
_has_bits_[0] |= 0x00000001u;
operation_ = value;
}
inline void EltwiseParameter::set_operation(::caffe::EltwiseParameter_EltwiseOp value) {
_internal_set_operation(value);
// @@protoc_insertion_point(field_set:caffe.EltwiseParameter.operation)
}
// repeated float coeff = 2;
inline int EltwiseParameter::_internal_coeff_size() const {
return coeff_.size();
}
inline int EltwiseParameter::coeff_size() const {
return _internal_coeff_size();
}
inline void EltwiseParameter::clear_coeff() {
coeff_.Clear();
}
inline float EltwiseParameter::_internal_coeff(int index) const {
return coeff_.Get(index);
}
inline float EltwiseParameter::coeff(int index) const {
// @@protoc_insertion_point(field_get:caffe.EltwiseParameter.coeff)
return _internal_coeff(index);
}
inline void EltwiseParameter::set_coeff(int index, float value) {
coeff_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.EltwiseParameter.coeff)
}
inline void EltwiseParameter::_internal_add_coeff(float value) {
coeff_.Add(value);
}
inline void EltwiseParameter::add_coeff(float value) {
_internal_add_coeff(value);
// @@protoc_insertion_point(field_add:caffe.EltwiseParameter.coeff)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
EltwiseParameter::_internal_coeff() const {
return coeff_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
EltwiseParameter::coeff() const {
// @@protoc_insertion_point(field_list:caffe.EltwiseParameter.coeff)
return _internal_coeff();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
EltwiseParameter::_internal_mutable_coeff() {
return &coeff_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
EltwiseParameter::mutable_coeff() {
// @@protoc_insertion_point(field_mutable_list:caffe.EltwiseParameter.coeff)
return _internal_mutable_coeff();
}
// optional bool stable_prod_grad = 3 [default = true];
inline bool EltwiseParameter::_internal_has_stable_prod_grad() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool EltwiseParameter::has_stable_prod_grad() const {
return _internal_has_stable_prod_grad();
}
inline void EltwiseParameter::clear_stable_prod_grad() {
stable_prod_grad_ = true;
_has_bits_[0] &= ~0x00000002u;
}
inline bool EltwiseParameter::_internal_stable_prod_grad() const {
return stable_prod_grad_;
}
inline bool EltwiseParameter::stable_prod_grad() const {
// @@protoc_insertion_point(field_get:caffe.EltwiseParameter.stable_prod_grad)
return _internal_stable_prod_grad();
}
inline void EltwiseParameter::_internal_set_stable_prod_grad(bool value) {
_has_bits_[0] |= 0x00000002u;
stable_prod_grad_ = value;
}
inline void EltwiseParameter::set_stable_prod_grad(bool value) {
_internal_set_stable_prod_grad(value);
// @@protoc_insertion_point(field_set:caffe.EltwiseParameter.stable_prod_grad)
}
// -------------------------------------------------------------------
// ELUParameter
// optional float alpha = 1 [default = 1];
inline bool ELUParameter::_internal_has_alpha() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool ELUParameter::has_alpha() const {
return _internal_has_alpha();
}
inline void ELUParameter::clear_alpha() {
alpha_ = 1;
_has_bits_[0] &= ~0x00000001u;
}
inline float ELUParameter::_internal_alpha() const {
return alpha_;
}
inline float ELUParameter::alpha() const {
// @@protoc_insertion_point(field_get:caffe.ELUParameter.alpha)
return _internal_alpha();
}
inline void ELUParameter::_internal_set_alpha(float value) {
_has_bits_[0] |= 0x00000001u;
alpha_ = value;
}
inline void ELUParameter::set_alpha(float value) {
_internal_set_alpha(value);
// @@protoc_insertion_point(field_set:caffe.ELUParameter.alpha)
}
// -------------------------------------------------------------------
// EmbedParameter
// optional uint32 num_output = 1;
inline bool EmbedParameter::_internal_has_num_output() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool EmbedParameter::has_num_output() const {
return _internal_has_num_output();
}
inline void EmbedParameter::clear_num_output() {
num_output_ = 0u;
_has_bits_[0] &= ~0x00000004u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 EmbedParameter::_internal_num_output() const {
return num_output_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 EmbedParameter::num_output() const {
// @@protoc_insertion_point(field_get:caffe.EmbedParameter.num_output)
return _internal_num_output();
}
inline void EmbedParameter::_internal_set_num_output(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000004u;
num_output_ = value;
}
inline void EmbedParameter::set_num_output(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_num_output(value);
// @@protoc_insertion_point(field_set:caffe.EmbedParameter.num_output)
}
// optional uint32 input_dim = 2;
inline bool EmbedParameter::_internal_has_input_dim() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool EmbedParameter::has_input_dim() const {
return _internal_has_input_dim();
}
inline void EmbedParameter::clear_input_dim() {
input_dim_ = 0u;
_has_bits_[0] &= ~0x00000008u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 EmbedParameter::_internal_input_dim() const {
return input_dim_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 EmbedParameter::input_dim() const {
// @@protoc_insertion_point(field_get:caffe.EmbedParameter.input_dim)
return _internal_input_dim();
}
inline void EmbedParameter::_internal_set_input_dim(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000008u;
input_dim_ = value;
}
inline void EmbedParameter::set_input_dim(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_input_dim(value);
// @@protoc_insertion_point(field_set:caffe.EmbedParameter.input_dim)
}
// optional bool bias_term = 3 [default = true];
inline bool EmbedParameter::_internal_has_bias_term() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool EmbedParameter::has_bias_term() const {
return _internal_has_bias_term();
}
inline void EmbedParameter::clear_bias_term() {
bias_term_ = true;
_has_bits_[0] &= ~0x00000010u;
}
inline bool EmbedParameter::_internal_bias_term() const {
return bias_term_;
}
inline bool EmbedParameter::bias_term() const {
// @@protoc_insertion_point(field_get:caffe.EmbedParameter.bias_term)
return _internal_bias_term();
}
inline void EmbedParameter::_internal_set_bias_term(bool value) {
_has_bits_[0] |= 0x00000010u;
bias_term_ = value;
}
inline void EmbedParameter::set_bias_term(bool value) {
_internal_set_bias_term(value);
// @@protoc_insertion_point(field_set:caffe.EmbedParameter.bias_term)
}
// optional .caffe.FillerParameter weight_filler = 4;
inline bool EmbedParameter::_internal_has_weight_filler() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
PROTOBUF_ASSUME(!value || weight_filler_ != nullptr);
return value;
}
inline bool EmbedParameter::has_weight_filler() const {
return _internal_has_weight_filler();
}
inline void EmbedParameter::clear_weight_filler() {
if (weight_filler_ != nullptr) weight_filler_->Clear();
_has_bits_[0] &= ~0x00000001u;
}
inline const ::caffe::FillerParameter& EmbedParameter::_internal_weight_filler() const {
const ::caffe::FillerParameter* p = weight_filler_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::FillerParameter*>(
&::caffe::_FillerParameter_default_instance_);
}
inline const ::caffe::FillerParameter& EmbedParameter::weight_filler() const {
// @@protoc_insertion_point(field_get:caffe.EmbedParameter.weight_filler)
return _internal_weight_filler();
}
inline void EmbedParameter::unsafe_arena_set_allocated_weight_filler(
::caffe::FillerParameter* weight_filler) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(weight_filler_);
}
weight_filler_ = weight_filler;
if (weight_filler) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.EmbedParameter.weight_filler)
}
inline ::caffe::FillerParameter* EmbedParameter::release_weight_filler() {
_has_bits_[0] &= ~0x00000001u;
::caffe::FillerParameter* temp = weight_filler_;
weight_filler_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::FillerParameter* EmbedParameter::unsafe_arena_release_weight_filler() {
// @@protoc_insertion_point(field_release:caffe.EmbedParameter.weight_filler)
_has_bits_[0] &= ~0x00000001u;
::caffe::FillerParameter* temp = weight_filler_;
weight_filler_ = nullptr;
return temp;
}
inline ::caffe::FillerParameter* EmbedParameter::_internal_mutable_weight_filler() {
_has_bits_[0] |= 0x00000001u;
if (weight_filler_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::FillerParameter>(GetArena());
weight_filler_ = p;
}
return weight_filler_;
}
inline ::caffe::FillerParameter* EmbedParameter::mutable_weight_filler() {
// @@protoc_insertion_point(field_mutable:caffe.EmbedParameter.weight_filler)
return _internal_mutable_weight_filler();
}
inline void EmbedParameter::set_allocated_weight_filler(::caffe::FillerParameter* weight_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete weight_filler_;
}
if (weight_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(weight_filler);
if (message_arena != submessage_arena) {
weight_filler = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, weight_filler, submessage_arena);
}
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
weight_filler_ = weight_filler;
// @@protoc_insertion_point(field_set_allocated:caffe.EmbedParameter.weight_filler)
}
// optional .caffe.FillerParameter bias_filler = 5;
inline bool EmbedParameter::_internal_has_bias_filler() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
PROTOBUF_ASSUME(!value || bias_filler_ != nullptr);
return value;
}
inline bool EmbedParameter::has_bias_filler() const {
return _internal_has_bias_filler();
}
inline void EmbedParameter::clear_bias_filler() {
if (bias_filler_ != nullptr) bias_filler_->Clear();
_has_bits_[0] &= ~0x00000002u;
}
inline const ::caffe::FillerParameter& EmbedParameter::_internal_bias_filler() const {
const ::caffe::FillerParameter* p = bias_filler_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::FillerParameter*>(
&::caffe::_FillerParameter_default_instance_);
}
inline const ::caffe::FillerParameter& EmbedParameter::bias_filler() const {
// @@protoc_insertion_point(field_get:caffe.EmbedParameter.bias_filler)
return _internal_bias_filler();
}
inline void EmbedParameter::unsafe_arena_set_allocated_bias_filler(
::caffe::FillerParameter* bias_filler) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(bias_filler_);
}
bias_filler_ = bias_filler;
if (bias_filler) {
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.EmbedParameter.bias_filler)
}
inline ::caffe::FillerParameter* EmbedParameter::release_bias_filler() {
_has_bits_[0] &= ~0x00000002u;
::caffe::FillerParameter* temp = bias_filler_;
bias_filler_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::FillerParameter* EmbedParameter::unsafe_arena_release_bias_filler() {
// @@protoc_insertion_point(field_release:caffe.EmbedParameter.bias_filler)
_has_bits_[0] &= ~0x00000002u;
::caffe::FillerParameter* temp = bias_filler_;
bias_filler_ = nullptr;
return temp;
}
inline ::caffe::FillerParameter* EmbedParameter::_internal_mutable_bias_filler() {
_has_bits_[0] |= 0x00000002u;
if (bias_filler_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::FillerParameter>(GetArena());
bias_filler_ = p;
}
return bias_filler_;
}
inline ::caffe::FillerParameter* EmbedParameter::mutable_bias_filler() {
// @@protoc_insertion_point(field_mutable:caffe.EmbedParameter.bias_filler)
return _internal_mutable_bias_filler();
}
inline void EmbedParameter::set_allocated_bias_filler(::caffe::FillerParameter* bias_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete bias_filler_;
}
if (bias_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(bias_filler);
if (message_arena != submessage_arena) {
bias_filler = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, bias_filler, submessage_arena);
}
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
bias_filler_ = bias_filler;
// @@protoc_insertion_point(field_set_allocated:caffe.EmbedParameter.bias_filler)
}
// -------------------------------------------------------------------
// ExpParameter
// optional float base = 1 [default = -1];
inline bool ExpParameter::_internal_has_base() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool ExpParameter::has_base() const {
return _internal_has_base();
}
inline void ExpParameter::clear_base() {
base_ = -1;
_has_bits_[0] &= ~0x00000002u;
}
inline float ExpParameter::_internal_base() const {
return base_;
}
inline float ExpParameter::base() const {
// @@protoc_insertion_point(field_get:caffe.ExpParameter.base)
return _internal_base();
}
inline void ExpParameter::_internal_set_base(float value) {
_has_bits_[0] |= 0x00000002u;
base_ = value;
}
inline void ExpParameter::set_base(float value) {
_internal_set_base(value);
// @@protoc_insertion_point(field_set:caffe.ExpParameter.base)
}
// optional float scale = 2 [default = 1];
inline bool ExpParameter::_internal_has_scale() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool ExpParameter::has_scale() const {
return _internal_has_scale();
}
inline void ExpParameter::clear_scale() {
scale_ = 1;
_has_bits_[0] &= ~0x00000004u;
}
inline float ExpParameter::_internal_scale() const {
return scale_;
}
inline float ExpParameter::scale() const {
// @@protoc_insertion_point(field_get:caffe.ExpParameter.scale)
return _internal_scale();
}
inline void ExpParameter::_internal_set_scale(float value) {
_has_bits_[0] |= 0x00000004u;
scale_ = value;
}
inline void ExpParameter::set_scale(float value) {
_internal_set_scale(value);
// @@protoc_insertion_point(field_set:caffe.ExpParameter.scale)
}
// optional float shift = 3 [default = 0];
inline bool ExpParameter::_internal_has_shift() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool ExpParameter::has_shift() const {
return _internal_has_shift();
}
inline void ExpParameter::clear_shift() {
shift_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline float ExpParameter::_internal_shift() const {
return shift_;
}
inline float ExpParameter::shift() const {
// @@protoc_insertion_point(field_get:caffe.ExpParameter.shift)
return _internal_shift();
}
inline void ExpParameter::_internal_set_shift(float value) {
_has_bits_[0] |= 0x00000001u;
shift_ = value;
}
inline void ExpParameter::set_shift(float value) {
_internal_set_shift(value);
// @@protoc_insertion_point(field_set:caffe.ExpParameter.shift)
}
// -------------------------------------------------------------------
// FlattenParameter
// optional int32 axis = 1 [default = 1];
inline bool FlattenParameter::_internal_has_axis() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool FlattenParameter::has_axis() const {
return _internal_has_axis();
}
inline void FlattenParameter::clear_axis() {
axis_ = 1;
_has_bits_[0] &= ~0x00000001u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 FlattenParameter::_internal_axis() const {
return axis_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 FlattenParameter::axis() const {
// @@protoc_insertion_point(field_get:caffe.FlattenParameter.axis)
return _internal_axis();
}
inline void FlattenParameter::_internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000001u;
axis_ = value;
}
inline void FlattenParameter::set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_axis(value);
// @@protoc_insertion_point(field_set:caffe.FlattenParameter.axis)
}
// optional int32 end_axis = 2 [default = -1];
inline bool FlattenParameter::_internal_has_end_axis() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool FlattenParameter::has_end_axis() const {
return _internal_has_end_axis();
}
inline void FlattenParameter::clear_end_axis() {
end_axis_ = -1;
_has_bits_[0] &= ~0x00000002u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 FlattenParameter::_internal_end_axis() const {
return end_axis_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 FlattenParameter::end_axis() const {
// @@protoc_insertion_point(field_get:caffe.FlattenParameter.end_axis)
return _internal_end_axis();
}
inline void FlattenParameter::_internal_set_end_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000002u;
end_axis_ = value;
}
inline void FlattenParameter::set_end_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_end_axis(value);
// @@protoc_insertion_point(field_set:caffe.FlattenParameter.end_axis)
}
// -------------------------------------------------------------------
// HDF5DataParameter
// optional string source = 1;
inline bool HDF5DataParameter::_internal_has_source() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool HDF5DataParameter::has_source() const {
return _internal_has_source();
}
inline void HDF5DataParameter::clear_source() {
source_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000001u;
}
inline const std::string& HDF5DataParameter::source() const {
// @@protoc_insertion_point(field_get:caffe.HDF5DataParameter.source)
return _internal_source();
}
inline void HDF5DataParameter::set_source(const std::string& value) {
_internal_set_source(value);
// @@protoc_insertion_point(field_set:caffe.HDF5DataParameter.source)
}
inline std::string* HDF5DataParameter::mutable_source() {
// @@protoc_insertion_point(field_mutable:caffe.HDF5DataParameter.source)
return _internal_mutable_source();
}
inline const std::string& HDF5DataParameter::_internal_source() const {
return source_.Get();
}
inline void HDF5DataParameter::_internal_set_source(const std::string& value) {
_has_bits_[0] |= 0x00000001u;
source_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void HDF5DataParameter::set_source(std::string&& value) {
_has_bits_[0] |= 0x00000001u;
source_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.HDF5DataParameter.source)
}
inline void HDF5DataParameter::set_source(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000001u;
source_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.HDF5DataParameter.source)
}
inline void HDF5DataParameter::set_source(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000001u;
source_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.HDF5DataParameter.source)
}
inline std::string* HDF5DataParameter::_internal_mutable_source() {
_has_bits_[0] |= 0x00000001u;
return source_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* HDF5DataParameter::release_source() {
// @@protoc_insertion_point(field_release:caffe.HDF5DataParameter.source)
if (!_internal_has_source()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000001u;
return source_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void HDF5DataParameter::set_allocated_source(std::string* source) {
if (source != nullptr) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
source_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), source,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.HDF5DataParameter.source)
}
// optional uint32 batch_size = 2;
inline bool HDF5DataParameter::_internal_has_batch_size() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool HDF5DataParameter::has_batch_size() const {
return _internal_has_batch_size();
}
inline void HDF5DataParameter::clear_batch_size() {
batch_size_ = 0u;
_has_bits_[0] &= ~0x00000002u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 HDF5DataParameter::_internal_batch_size() const {
return batch_size_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 HDF5DataParameter::batch_size() const {
// @@protoc_insertion_point(field_get:caffe.HDF5DataParameter.batch_size)
return _internal_batch_size();
}
inline void HDF5DataParameter::_internal_set_batch_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000002u;
batch_size_ = value;
}
inline void HDF5DataParameter::set_batch_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_batch_size(value);
// @@protoc_insertion_point(field_set:caffe.HDF5DataParameter.batch_size)
}
// optional bool shuffle = 3 [default = false];
inline bool HDF5DataParameter::_internal_has_shuffle() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool HDF5DataParameter::has_shuffle() const {
return _internal_has_shuffle();
}
inline void HDF5DataParameter::clear_shuffle() {
shuffle_ = false;
_has_bits_[0] &= ~0x00000004u;
}
inline bool HDF5DataParameter::_internal_shuffle() const {
return shuffle_;
}
inline bool HDF5DataParameter::shuffle() const {
// @@protoc_insertion_point(field_get:caffe.HDF5DataParameter.shuffle)
return _internal_shuffle();
}
inline void HDF5DataParameter::_internal_set_shuffle(bool value) {
_has_bits_[0] |= 0x00000004u;
shuffle_ = value;
}
inline void HDF5DataParameter::set_shuffle(bool value) {
_internal_set_shuffle(value);
// @@protoc_insertion_point(field_set:caffe.HDF5DataParameter.shuffle)
}
// -------------------------------------------------------------------
// HDF5OutputParameter
// optional string file_name = 1;
inline bool HDF5OutputParameter::_internal_has_file_name() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool HDF5OutputParameter::has_file_name() const {
return _internal_has_file_name();
}
inline void HDF5OutputParameter::clear_file_name() {
file_name_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000001u;
}
inline const std::string& HDF5OutputParameter::file_name() const {
// @@protoc_insertion_point(field_get:caffe.HDF5OutputParameter.file_name)
return _internal_file_name();
}
inline void HDF5OutputParameter::set_file_name(const std::string& value) {
_internal_set_file_name(value);
// @@protoc_insertion_point(field_set:caffe.HDF5OutputParameter.file_name)
}
inline std::string* HDF5OutputParameter::mutable_file_name() {
// @@protoc_insertion_point(field_mutable:caffe.HDF5OutputParameter.file_name)
return _internal_mutable_file_name();
}
inline const std::string& HDF5OutputParameter::_internal_file_name() const {
return file_name_.Get();
}
inline void HDF5OutputParameter::_internal_set_file_name(const std::string& value) {
_has_bits_[0] |= 0x00000001u;
file_name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void HDF5OutputParameter::set_file_name(std::string&& value) {
_has_bits_[0] |= 0x00000001u;
file_name_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.HDF5OutputParameter.file_name)
}
inline void HDF5OutputParameter::set_file_name(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000001u;
file_name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.HDF5OutputParameter.file_name)
}
inline void HDF5OutputParameter::set_file_name(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000001u;
file_name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.HDF5OutputParameter.file_name)
}
inline std::string* HDF5OutputParameter::_internal_mutable_file_name() {
_has_bits_[0] |= 0x00000001u;
return file_name_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* HDF5OutputParameter::release_file_name() {
// @@protoc_insertion_point(field_release:caffe.HDF5OutputParameter.file_name)
if (!_internal_has_file_name()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000001u;
return file_name_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void HDF5OutputParameter::set_allocated_file_name(std::string* file_name) {
if (file_name != nullptr) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
file_name_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), file_name,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.HDF5OutputParameter.file_name)
}
// -------------------------------------------------------------------
// HingeLossParameter
// optional .caffe.HingeLossParameter.Norm norm = 1 [default = L1];
inline bool HingeLossParameter::_internal_has_norm() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool HingeLossParameter::has_norm() const {
return _internal_has_norm();
}
inline void HingeLossParameter::clear_norm() {
norm_ = 1;
_has_bits_[0] &= ~0x00000001u;
}
inline ::caffe::HingeLossParameter_Norm HingeLossParameter::_internal_norm() const {
return static_cast< ::caffe::HingeLossParameter_Norm >(norm_);
}
inline ::caffe::HingeLossParameter_Norm HingeLossParameter::norm() const {
// @@protoc_insertion_point(field_get:caffe.HingeLossParameter.norm)
return _internal_norm();
}
inline void HingeLossParameter::_internal_set_norm(::caffe::HingeLossParameter_Norm value) {
assert(::caffe::HingeLossParameter_Norm_IsValid(value));
_has_bits_[0] |= 0x00000001u;
norm_ = value;
}
inline void HingeLossParameter::set_norm(::caffe::HingeLossParameter_Norm value) {
_internal_set_norm(value);
// @@protoc_insertion_point(field_set:caffe.HingeLossParameter.norm)
}
// -------------------------------------------------------------------
// ImageDataParameter
// optional string source = 1;
inline bool ImageDataParameter::_internal_has_source() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool ImageDataParameter::has_source() const {
return _internal_has_source();
}
inline void ImageDataParameter::clear_source() {
source_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000001u;
}
inline const std::string& ImageDataParameter::source() const {
// @@protoc_insertion_point(field_get:caffe.ImageDataParameter.source)
return _internal_source();
}
inline void ImageDataParameter::set_source(const std::string& value) {
_internal_set_source(value);
// @@protoc_insertion_point(field_set:caffe.ImageDataParameter.source)
}
inline std::string* ImageDataParameter::mutable_source() {
// @@protoc_insertion_point(field_mutable:caffe.ImageDataParameter.source)
return _internal_mutable_source();
}
inline const std::string& ImageDataParameter::_internal_source() const {
return source_.Get();
}
inline void ImageDataParameter::_internal_set_source(const std::string& value) {
_has_bits_[0] |= 0x00000001u;
source_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void ImageDataParameter::set_source(std::string&& value) {
_has_bits_[0] |= 0x00000001u;
source_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.ImageDataParameter.source)
}
inline void ImageDataParameter::set_source(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000001u;
source_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.ImageDataParameter.source)
}
inline void ImageDataParameter::set_source(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000001u;
source_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.ImageDataParameter.source)
}
inline std::string* ImageDataParameter::_internal_mutable_source() {
_has_bits_[0] |= 0x00000001u;
return source_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* ImageDataParameter::release_source() {
// @@protoc_insertion_point(field_release:caffe.ImageDataParameter.source)
if (!_internal_has_source()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000001u;
return source_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void ImageDataParameter::set_allocated_source(std::string* source) {
if (source != nullptr) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
source_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), source,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.ImageDataParameter.source)
}
// optional uint32 batch_size = 4 [default = 1];
inline bool ImageDataParameter::_internal_has_batch_size() const {
bool value = (_has_bits_[0] & 0x00000800u) != 0;
return value;
}
inline bool ImageDataParameter::has_batch_size() const {
return _internal_has_batch_size();
}
inline void ImageDataParameter::clear_batch_size() {
batch_size_ = 1u;
_has_bits_[0] &= ~0x00000800u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ImageDataParameter::_internal_batch_size() const {
return batch_size_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ImageDataParameter::batch_size() const {
// @@protoc_insertion_point(field_get:caffe.ImageDataParameter.batch_size)
return _internal_batch_size();
}
inline void ImageDataParameter::_internal_set_batch_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000800u;
batch_size_ = value;
}
inline void ImageDataParameter::set_batch_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_batch_size(value);
// @@protoc_insertion_point(field_set:caffe.ImageDataParameter.batch_size)
}
// optional uint32 rand_skip = 7 [default = 0];
inline bool ImageDataParameter::_internal_has_rand_skip() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool ImageDataParameter::has_rand_skip() const {
return _internal_has_rand_skip();
}
inline void ImageDataParameter::clear_rand_skip() {
rand_skip_ = 0u;
_has_bits_[0] &= ~0x00000010u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ImageDataParameter::_internal_rand_skip() const {
return rand_skip_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ImageDataParameter::rand_skip() const {
// @@protoc_insertion_point(field_get:caffe.ImageDataParameter.rand_skip)
return _internal_rand_skip();
}
inline void ImageDataParameter::_internal_set_rand_skip(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000010u;
rand_skip_ = value;
}
inline void ImageDataParameter::set_rand_skip(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_rand_skip(value);
// @@protoc_insertion_point(field_set:caffe.ImageDataParameter.rand_skip)
}
// optional bool shuffle = 8 [default = false];
inline bool ImageDataParameter::_internal_has_shuffle() const {
bool value = (_has_bits_[0] & 0x00000020u) != 0;
return value;
}
inline bool ImageDataParameter::has_shuffle() const {
return _internal_has_shuffle();
}
inline void ImageDataParameter::clear_shuffle() {
shuffle_ = false;
_has_bits_[0] &= ~0x00000020u;
}
inline bool ImageDataParameter::_internal_shuffle() const {
return shuffle_;
}
inline bool ImageDataParameter::shuffle() const {
// @@protoc_insertion_point(field_get:caffe.ImageDataParameter.shuffle)
return _internal_shuffle();
}
inline void ImageDataParameter::_internal_set_shuffle(bool value) {
_has_bits_[0] |= 0x00000020u;
shuffle_ = value;
}
inline void ImageDataParameter::set_shuffle(bool value) {
_internal_set_shuffle(value);
// @@protoc_insertion_point(field_set:caffe.ImageDataParameter.shuffle)
}
// optional uint32 new_height = 9 [default = 0];
inline bool ImageDataParameter::_internal_has_new_height() const {
bool value = (_has_bits_[0] & 0x00000080u) != 0;
return value;
}
inline bool ImageDataParameter::has_new_height() const {
return _internal_has_new_height();
}
inline void ImageDataParameter::clear_new_height() {
new_height_ = 0u;
_has_bits_[0] &= ~0x00000080u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ImageDataParameter::_internal_new_height() const {
return new_height_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ImageDataParameter::new_height() const {
// @@protoc_insertion_point(field_get:caffe.ImageDataParameter.new_height)
return _internal_new_height();
}
inline void ImageDataParameter::_internal_set_new_height(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000080u;
new_height_ = value;
}
inline void ImageDataParameter::set_new_height(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_new_height(value);
// @@protoc_insertion_point(field_set:caffe.ImageDataParameter.new_height)
}
// optional uint32 new_width = 10 [default = 0];
inline bool ImageDataParameter::_internal_has_new_width() const {
bool value = (_has_bits_[0] & 0x00000100u) != 0;
return value;
}
inline bool ImageDataParameter::has_new_width() const {
return _internal_has_new_width();
}
inline void ImageDataParameter::clear_new_width() {
new_width_ = 0u;
_has_bits_[0] &= ~0x00000100u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ImageDataParameter::_internal_new_width() const {
return new_width_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ImageDataParameter::new_width() const {
// @@protoc_insertion_point(field_get:caffe.ImageDataParameter.new_width)
return _internal_new_width();
}
inline void ImageDataParameter::_internal_set_new_width(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000100u;
new_width_ = value;
}
inline void ImageDataParameter::set_new_width(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_new_width(value);
// @@protoc_insertion_point(field_set:caffe.ImageDataParameter.new_width)
}
// optional bool is_color = 11 [default = true];
inline bool ImageDataParameter::_internal_has_is_color() const {
bool value = (_has_bits_[0] & 0x00000200u) != 0;
return value;
}
inline bool ImageDataParameter::has_is_color() const {
return _internal_has_is_color();
}
inline void ImageDataParameter::clear_is_color() {
is_color_ = true;
_has_bits_[0] &= ~0x00000200u;
}
inline bool ImageDataParameter::_internal_is_color() const {
return is_color_;
}
inline bool ImageDataParameter::is_color() const {
// @@protoc_insertion_point(field_get:caffe.ImageDataParameter.is_color)
return _internal_is_color();
}
inline void ImageDataParameter::_internal_set_is_color(bool value) {
_has_bits_[0] |= 0x00000200u;
is_color_ = value;
}
inline void ImageDataParameter::set_is_color(bool value) {
_internal_set_is_color(value);
// @@protoc_insertion_point(field_set:caffe.ImageDataParameter.is_color)
}
// optional float scale = 2 [default = 1];
inline bool ImageDataParameter::_internal_has_scale() const {
bool value = (_has_bits_[0] & 0x00000400u) != 0;
return value;
}
inline bool ImageDataParameter::has_scale() const {
return _internal_has_scale();
}
inline void ImageDataParameter::clear_scale() {
scale_ = 1;
_has_bits_[0] &= ~0x00000400u;
}
inline float ImageDataParameter::_internal_scale() const {
return scale_;
}
inline float ImageDataParameter::scale() const {
// @@protoc_insertion_point(field_get:caffe.ImageDataParameter.scale)
return _internal_scale();
}
inline void ImageDataParameter::_internal_set_scale(float value) {
_has_bits_[0] |= 0x00000400u;
scale_ = value;
}
inline void ImageDataParameter::set_scale(float value) {
_internal_set_scale(value);
// @@protoc_insertion_point(field_set:caffe.ImageDataParameter.scale)
}
// optional string mean_file = 3;
inline bool ImageDataParameter::_internal_has_mean_file() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool ImageDataParameter::has_mean_file() const {
return _internal_has_mean_file();
}
inline void ImageDataParameter::clear_mean_file() {
mean_file_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000002u;
}
inline const std::string& ImageDataParameter::mean_file() const {
// @@protoc_insertion_point(field_get:caffe.ImageDataParameter.mean_file)
return _internal_mean_file();
}
inline void ImageDataParameter::set_mean_file(const std::string& value) {
_internal_set_mean_file(value);
// @@protoc_insertion_point(field_set:caffe.ImageDataParameter.mean_file)
}
inline std::string* ImageDataParameter::mutable_mean_file() {
// @@protoc_insertion_point(field_mutable:caffe.ImageDataParameter.mean_file)
return _internal_mutable_mean_file();
}
inline const std::string& ImageDataParameter::_internal_mean_file() const {
return mean_file_.Get();
}
inline void ImageDataParameter::_internal_set_mean_file(const std::string& value) {
_has_bits_[0] |= 0x00000002u;
mean_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void ImageDataParameter::set_mean_file(std::string&& value) {
_has_bits_[0] |= 0x00000002u;
mean_file_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.ImageDataParameter.mean_file)
}
inline void ImageDataParameter::set_mean_file(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000002u;
mean_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.ImageDataParameter.mean_file)
}
inline void ImageDataParameter::set_mean_file(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000002u;
mean_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.ImageDataParameter.mean_file)
}
inline std::string* ImageDataParameter::_internal_mutable_mean_file() {
_has_bits_[0] |= 0x00000002u;
return mean_file_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* ImageDataParameter::release_mean_file() {
// @@protoc_insertion_point(field_release:caffe.ImageDataParameter.mean_file)
if (!_internal_has_mean_file()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000002u;
return mean_file_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void ImageDataParameter::set_allocated_mean_file(std::string* mean_file) {
if (mean_file != nullptr) {
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
mean_file_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), mean_file,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.ImageDataParameter.mean_file)
}
// optional uint32 crop_size = 5 [default = 0];
inline bool ImageDataParameter::_internal_has_crop_size() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool ImageDataParameter::has_crop_size() const {
return _internal_has_crop_size();
}
inline void ImageDataParameter::clear_crop_size() {
crop_size_ = 0u;
_has_bits_[0] &= ~0x00000008u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ImageDataParameter::_internal_crop_size() const {
return crop_size_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ImageDataParameter::crop_size() const {
// @@protoc_insertion_point(field_get:caffe.ImageDataParameter.crop_size)
return _internal_crop_size();
}
inline void ImageDataParameter::_internal_set_crop_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000008u;
crop_size_ = value;
}
inline void ImageDataParameter::set_crop_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_crop_size(value);
// @@protoc_insertion_point(field_set:caffe.ImageDataParameter.crop_size)
}
// optional bool mirror = 6 [default = false];
inline bool ImageDataParameter::_internal_has_mirror() const {
bool value = (_has_bits_[0] & 0x00000040u) != 0;
return value;
}
inline bool ImageDataParameter::has_mirror() const {
return _internal_has_mirror();
}
inline void ImageDataParameter::clear_mirror() {
mirror_ = false;
_has_bits_[0] &= ~0x00000040u;
}
inline bool ImageDataParameter::_internal_mirror() const {
return mirror_;
}
inline bool ImageDataParameter::mirror() const {
// @@protoc_insertion_point(field_get:caffe.ImageDataParameter.mirror)
return _internal_mirror();
}
inline void ImageDataParameter::_internal_set_mirror(bool value) {
_has_bits_[0] |= 0x00000040u;
mirror_ = value;
}
inline void ImageDataParameter::set_mirror(bool value) {
_internal_set_mirror(value);
// @@protoc_insertion_point(field_set:caffe.ImageDataParameter.mirror)
}
// optional string root_folder = 12 [default = ""];
inline bool ImageDataParameter::_internal_has_root_folder() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool ImageDataParameter::has_root_folder() const {
return _internal_has_root_folder();
}
inline void ImageDataParameter::clear_root_folder() {
root_folder_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000004u;
}
inline const std::string& ImageDataParameter::root_folder() const {
// @@protoc_insertion_point(field_get:caffe.ImageDataParameter.root_folder)
return _internal_root_folder();
}
inline void ImageDataParameter::set_root_folder(const std::string& value) {
_internal_set_root_folder(value);
// @@protoc_insertion_point(field_set:caffe.ImageDataParameter.root_folder)
}
inline std::string* ImageDataParameter::mutable_root_folder() {
// @@protoc_insertion_point(field_mutable:caffe.ImageDataParameter.root_folder)
return _internal_mutable_root_folder();
}
inline const std::string& ImageDataParameter::_internal_root_folder() const {
return root_folder_.Get();
}
inline void ImageDataParameter::_internal_set_root_folder(const std::string& value) {
_has_bits_[0] |= 0x00000004u;
root_folder_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void ImageDataParameter::set_root_folder(std::string&& value) {
_has_bits_[0] |= 0x00000004u;
root_folder_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.ImageDataParameter.root_folder)
}
inline void ImageDataParameter::set_root_folder(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000004u;
root_folder_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.ImageDataParameter.root_folder)
}
inline void ImageDataParameter::set_root_folder(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000004u;
root_folder_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.ImageDataParameter.root_folder)
}
inline std::string* ImageDataParameter::_internal_mutable_root_folder() {
_has_bits_[0] |= 0x00000004u;
return root_folder_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* ImageDataParameter::release_root_folder() {
// @@protoc_insertion_point(field_release:caffe.ImageDataParameter.root_folder)
if (!_internal_has_root_folder()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000004u;
return root_folder_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void ImageDataParameter::set_allocated_root_folder(std::string* root_folder) {
if (root_folder != nullptr) {
_has_bits_[0] |= 0x00000004u;
} else {
_has_bits_[0] &= ~0x00000004u;
}
root_folder_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), root_folder,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.ImageDataParameter.root_folder)
}
// -------------------------------------------------------------------
// InfogainLossParameter
// optional string source = 1;
inline bool InfogainLossParameter::_internal_has_source() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool InfogainLossParameter::has_source() const {
return _internal_has_source();
}
inline void InfogainLossParameter::clear_source() {
source_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000001u;
}
inline const std::string& InfogainLossParameter::source() const {
// @@protoc_insertion_point(field_get:caffe.InfogainLossParameter.source)
return _internal_source();
}
inline void InfogainLossParameter::set_source(const std::string& value) {
_internal_set_source(value);
// @@protoc_insertion_point(field_set:caffe.InfogainLossParameter.source)
}
inline std::string* InfogainLossParameter::mutable_source() {
// @@protoc_insertion_point(field_mutable:caffe.InfogainLossParameter.source)
return _internal_mutable_source();
}
inline const std::string& InfogainLossParameter::_internal_source() const {
return source_.Get();
}
inline void InfogainLossParameter::_internal_set_source(const std::string& value) {
_has_bits_[0] |= 0x00000001u;
source_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void InfogainLossParameter::set_source(std::string&& value) {
_has_bits_[0] |= 0x00000001u;
source_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.InfogainLossParameter.source)
}
inline void InfogainLossParameter::set_source(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000001u;
source_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.InfogainLossParameter.source)
}
inline void InfogainLossParameter::set_source(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000001u;
source_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.InfogainLossParameter.source)
}
inline std::string* InfogainLossParameter::_internal_mutable_source() {
_has_bits_[0] |= 0x00000001u;
return source_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* InfogainLossParameter::release_source() {
// @@protoc_insertion_point(field_release:caffe.InfogainLossParameter.source)
if (!_internal_has_source()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000001u;
return source_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void InfogainLossParameter::set_allocated_source(std::string* source) {
if (source != nullptr) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
source_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), source,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.InfogainLossParameter.source)
}
// -------------------------------------------------------------------
// InnerProductParameter
// optional uint32 num_output = 1;
inline bool InnerProductParameter::_internal_has_num_output() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool InnerProductParameter::has_num_output() const {
return _internal_has_num_output();
}
inline void InnerProductParameter::clear_num_output() {
num_output_ = 0u;
_has_bits_[0] &= ~0x00000004u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 InnerProductParameter::_internal_num_output() const {
return num_output_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 InnerProductParameter::num_output() const {
// @@protoc_insertion_point(field_get:caffe.InnerProductParameter.num_output)
return _internal_num_output();
}
inline void InnerProductParameter::_internal_set_num_output(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000004u;
num_output_ = value;
}
inline void InnerProductParameter::set_num_output(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_num_output(value);
// @@protoc_insertion_point(field_set:caffe.InnerProductParameter.num_output)
}
// optional bool bias_term = 2 [default = true];
inline bool InnerProductParameter::_internal_has_bias_term() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool InnerProductParameter::has_bias_term() const {
return _internal_has_bias_term();
}
inline void InnerProductParameter::clear_bias_term() {
bias_term_ = true;
_has_bits_[0] &= ~0x00000010u;
}
inline bool InnerProductParameter::_internal_bias_term() const {
return bias_term_;
}
inline bool InnerProductParameter::bias_term() const {
// @@protoc_insertion_point(field_get:caffe.InnerProductParameter.bias_term)
return _internal_bias_term();
}
inline void InnerProductParameter::_internal_set_bias_term(bool value) {
_has_bits_[0] |= 0x00000010u;
bias_term_ = value;
}
inline void InnerProductParameter::set_bias_term(bool value) {
_internal_set_bias_term(value);
// @@protoc_insertion_point(field_set:caffe.InnerProductParameter.bias_term)
}
// optional .caffe.FillerParameter weight_filler = 3;
inline bool InnerProductParameter::_internal_has_weight_filler() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
PROTOBUF_ASSUME(!value || weight_filler_ != nullptr);
return value;
}
inline bool InnerProductParameter::has_weight_filler() const {
return _internal_has_weight_filler();
}
inline void InnerProductParameter::clear_weight_filler() {
if (weight_filler_ != nullptr) weight_filler_->Clear();
_has_bits_[0] &= ~0x00000001u;
}
inline const ::caffe::FillerParameter& InnerProductParameter::_internal_weight_filler() const {
const ::caffe::FillerParameter* p = weight_filler_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::FillerParameter*>(
&::caffe::_FillerParameter_default_instance_);
}
inline const ::caffe::FillerParameter& InnerProductParameter::weight_filler() const {
// @@protoc_insertion_point(field_get:caffe.InnerProductParameter.weight_filler)
return _internal_weight_filler();
}
inline void InnerProductParameter::unsafe_arena_set_allocated_weight_filler(
::caffe::FillerParameter* weight_filler) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(weight_filler_);
}
weight_filler_ = weight_filler;
if (weight_filler) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.InnerProductParameter.weight_filler)
}
inline ::caffe::FillerParameter* InnerProductParameter::release_weight_filler() {
_has_bits_[0] &= ~0x00000001u;
::caffe::FillerParameter* temp = weight_filler_;
weight_filler_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::FillerParameter* InnerProductParameter::unsafe_arena_release_weight_filler() {
// @@protoc_insertion_point(field_release:caffe.InnerProductParameter.weight_filler)
_has_bits_[0] &= ~0x00000001u;
::caffe::FillerParameter* temp = weight_filler_;
weight_filler_ = nullptr;
return temp;
}
inline ::caffe::FillerParameter* InnerProductParameter::_internal_mutable_weight_filler() {
_has_bits_[0] |= 0x00000001u;
if (weight_filler_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::FillerParameter>(GetArena());
weight_filler_ = p;
}
return weight_filler_;
}
inline ::caffe::FillerParameter* InnerProductParameter::mutable_weight_filler() {
// @@protoc_insertion_point(field_mutable:caffe.InnerProductParameter.weight_filler)
return _internal_mutable_weight_filler();
}
inline void InnerProductParameter::set_allocated_weight_filler(::caffe::FillerParameter* weight_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete weight_filler_;
}
if (weight_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(weight_filler);
if (message_arena != submessage_arena) {
weight_filler = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, weight_filler, submessage_arena);
}
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
weight_filler_ = weight_filler;
// @@protoc_insertion_point(field_set_allocated:caffe.InnerProductParameter.weight_filler)
}
// optional .caffe.FillerParameter bias_filler = 4;
inline bool InnerProductParameter::_internal_has_bias_filler() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
PROTOBUF_ASSUME(!value || bias_filler_ != nullptr);
return value;
}
inline bool InnerProductParameter::has_bias_filler() const {
return _internal_has_bias_filler();
}
inline void InnerProductParameter::clear_bias_filler() {
if (bias_filler_ != nullptr) bias_filler_->Clear();
_has_bits_[0] &= ~0x00000002u;
}
inline const ::caffe::FillerParameter& InnerProductParameter::_internal_bias_filler() const {
const ::caffe::FillerParameter* p = bias_filler_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::FillerParameter*>(
&::caffe::_FillerParameter_default_instance_);
}
inline const ::caffe::FillerParameter& InnerProductParameter::bias_filler() const {
// @@protoc_insertion_point(field_get:caffe.InnerProductParameter.bias_filler)
return _internal_bias_filler();
}
inline void InnerProductParameter::unsafe_arena_set_allocated_bias_filler(
::caffe::FillerParameter* bias_filler) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(bias_filler_);
}
bias_filler_ = bias_filler;
if (bias_filler) {
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.InnerProductParameter.bias_filler)
}
inline ::caffe::FillerParameter* InnerProductParameter::release_bias_filler() {
_has_bits_[0] &= ~0x00000002u;
::caffe::FillerParameter* temp = bias_filler_;
bias_filler_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::FillerParameter* InnerProductParameter::unsafe_arena_release_bias_filler() {
// @@protoc_insertion_point(field_release:caffe.InnerProductParameter.bias_filler)
_has_bits_[0] &= ~0x00000002u;
::caffe::FillerParameter* temp = bias_filler_;
bias_filler_ = nullptr;
return temp;
}
inline ::caffe::FillerParameter* InnerProductParameter::_internal_mutable_bias_filler() {
_has_bits_[0] |= 0x00000002u;
if (bias_filler_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::FillerParameter>(GetArena());
bias_filler_ = p;
}
return bias_filler_;
}
inline ::caffe::FillerParameter* InnerProductParameter::mutable_bias_filler() {
// @@protoc_insertion_point(field_mutable:caffe.InnerProductParameter.bias_filler)
return _internal_mutable_bias_filler();
}
inline void InnerProductParameter::set_allocated_bias_filler(::caffe::FillerParameter* bias_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete bias_filler_;
}
if (bias_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(bias_filler);
if (message_arena != submessage_arena) {
bias_filler = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, bias_filler, submessage_arena);
}
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
bias_filler_ = bias_filler;
// @@protoc_insertion_point(field_set_allocated:caffe.InnerProductParameter.bias_filler)
}
// optional int32 axis = 5 [default = 1];
inline bool InnerProductParameter::_internal_has_axis() const {
bool value = (_has_bits_[0] & 0x00000020u) != 0;
return value;
}
inline bool InnerProductParameter::has_axis() const {
return _internal_has_axis();
}
inline void InnerProductParameter::clear_axis() {
axis_ = 1;
_has_bits_[0] &= ~0x00000020u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 InnerProductParameter::_internal_axis() const {
return axis_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 InnerProductParameter::axis() const {
// @@protoc_insertion_point(field_get:caffe.InnerProductParameter.axis)
return _internal_axis();
}
inline void InnerProductParameter::_internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000020u;
axis_ = value;
}
inline void InnerProductParameter::set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_axis(value);
// @@protoc_insertion_point(field_set:caffe.InnerProductParameter.axis)
}
// optional bool transpose = 6 [default = false];
inline bool InnerProductParameter::_internal_has_transpose() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool InnerProductParameter::has_transpose() const {
return _internal_has_transpose();
}
inline void InnerProductParameter::clear_transpose() {
transpose_ = false;
_has_bits_[0] &= ~0x00000008u;
}
inline bool InnerProductParameter::_internal_transpose() const {
return transpose_;
}
inline bool InnerProductParameter::transpose() const {
// @@protoc_insertion_point(field_get:caffe.InnerProductParameter.transpose)
return _internal_transpose();
}
inline void InnerProductParameter::_internal_set_transpose(bool value) {
_has_bits_[0] |= 0x00000008u;
transpose_ = value;
}
inline void InnerProductParameter::set_transpose(bool value) {
_internal_set_transpose(value);
// @@protoc_insertion_point(field_set:caffe.InnerProductParameter.transpose)
}
// -------------------------------------------------------------------
// InputParameter
// repeated .caffe.BlobShape shape = 1;
inline int InputParameter::_internal_shape_size() const {
return shape_.size();
}
inline int InputParameter::shape_size() const {
return _internal_shape_size();
}
inline void InputParameter::clear_shape() {
shape_.Clear();
}
inline ::caffe::BlobShape* InputParameter::mutable_shape(int index) {
// @@protoc_insertion_point(field_mutable:caffe.InputParameter.shape)
return shape_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape >*
InputParameter::mutable_shape() {
// @@protoc_insertion_point(field_mutable_list:caffe.InputParameter.shape)
return &shape_;
}
inline const ::caffe::BlobShape& InputParameter::_internal_shape(int index) const {
return shape_.Get(index);
}
inline const ::caffe::BlobShape& InputParameter::shape(int index) const {
// @@protoc_insertion_point(field_get:caffe.InputParameter.shape)
return _internal_shape(index);
}
inline ::caffe::BlobShape* InputParameter::_internal_add_shape() {
return shape_.Add();
}
inline ::caffe::BlobShape* InputParameter::add_shape() {
// @@protoc_insertion_point(field_add:caffe.InputParameter.shape)
return _internal_add_shape();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape >&
InputParameter::shape() const {
// @@protoc_insertion_point(field_list:caffe.InputParameter.shape)
return shape_;
}
// -------------------------------------------------------------------
// LogParameter
// optional float base = 1 [default = -1];
inline bool LogParameter::_internal_has_base() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool LogParameter::has_base() const {
return _internal_has_base();
}
inline void LogParameter::clear_base() {
base_ = -1;
_has_bits_[0] &= ~0x00000002u;
}
inline float LogParameter::_internal_base() const {
return base_;
}
inline float LogParameter::base() const {
// @@protoc_insertion_point(field_get:caffe.LogParameter.base)
return _internal_base();
}
inline void LogParameter::_internal_set_base(float value) {
_has_bits_[0] |= 0x00000002u;
base_ = value;
}
inline void LogParameter::set_base(float value) {
_internal_set_base(value);
// @@protoc_insertion_point(field_set:caffe.LogParameter.base)
}
// optional float scale = 2 [default = 1];
inline bool LogParameter::_internal_has_scale() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool LogParameter::has_scale() const {
return _internal_has_scale();
}
inline void LogParameter::clear_scale() {
scale_ = 1;
_has_bits_[0] &= ~0x00000004u;
}
inline float LogParameter::_internal_scale() const {
return scale_;
}
inline float LogParameter::scale() const {
// @@protoc_insertion_point(field_get:caffe.LogParameter.scale)
return _internal_scale();
}
inline void LogParameter::_internal_set_scale(float value) {
_has_bits_[0] |= 0x00000004u;
scale_ = value;
}
inline void LogParameter::set_scale(float value) {
_internal_set_scale(value);
// @@protoc_insertion_point(field_set:caffe.LogParameter.scale)
}
// optional float shift = 3 [default = 0];
inline bool LogParameter::_internal_has_shift() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool LogParameter::has_shift() const {
return _internal_has_shift();
}
inline void LogParameter::clear_shift() {
shift_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline float LogParameter::_internal_shift() const {
return shift_;
}
inline float LogParameter::shift() const {
// @@protoc_insertion_point(field_get:caffe.LogParameter.shift)
return _internal_shift();
}
inline void LogParameter::_internal_set_shift(float value) {
_has_bits_[0] |= 0x00000001u;
shift_ = value;
}
inline void LogParameter::set_shift(float value) {
_internal_set_shift(value);
// @@protoc_insertion_point(field_set:caffe.LogParameter.shift)
}
// -------------------------------------------------------------------
// LRNParameter
// optional uint32 local_size = 1 [default = 5];
inline bool LRNParameter::_internal_has_local_size() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool LRNParameter::has_local_size() const {
return _internal_has_local_size();
}
inline void LRNParameter::clear_local_size() {
local_size_ = 5u;
_has_bits_[0] &= ~0x00000004u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 LRNParameter::_internal_local_size() const {
return local_size_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 LRNParameter::local_size() const {
// @@protoc_insertion_point(field_get:caffe.LRNParameter.local_size)
return _internal_local_size();
}
inline void LRNParameter::_internal_set_local_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000004u;
local_size_ = value;
}
inline void LRNParameter::set_local_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_local_size(value);
// @@protoc_insertion_point(field_set:caffe.LRNParameter.local_size)
}
// optional float alpha = 2 [default = 1];
inline bool LRNParameter::_internal_has_alpha() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool LRNParameter::has_alpha() const {
return _internal_has_alpha();
}
inline void LRNParameter::clear_alpha() {
alpha_ = 1;
_has_bits_[0] &= ~0x00000008u;
}
inline float LRNParameter::_internal_alpha() const {
return alpha_;
}
inline float LRNParameter::alpha() const {
// @@protoc_insertion_point(field_get:caffe.LRNParameter.alpha)
return _internal_alpha();
}
inline void LRNParameter::_internal_set_alpha(float value) {
_has_bits_[0] |= 0x00000008u;
alpha_ = value;
}
inline void LRNParameter::set_alpha(float value) {
_internal_set_alpha(value);
// @@protoc_insertion_point(field_set:caffe.LRNParameter.alpha)
}
// optional float beta = 3 [default = 0.75];
inline bool LRNParameter::_internal_has_beta() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool LRNParameter::has_beta() const {
return _internal_has_beta();
}
inline void LRNParameter::clear_beta() {
beta_ = 0.75f;
_has_bits_[0] &= ~0x00000010u;
}
inline float LRNParameter::_internal_beta() const {
return beta_;
}
inline float LRNParameter::beta() const {
// @@protoc_insertion_point(field_get:caffe.LRNParameter.beta)
return _internal_beta();
}
inline void LRNParameter::_internal_set_beta(float value) {
_has_bits_[0] |= 0x00000010u;
beta_ = value;
}
inline void LRNParameter::set_beta(float value) {
_internal_set_beta(value);
// @@protoc_insertion_point(field_set:caffe.LRNParameter.beta)
}
// optional .caffe.LRNParameter.NormRegion norm_region = 4 [default = ACROSS_CHANNELS];
inline bool LRNParameter::_internal_has_norm_region() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool LRNParameter::has_norm_region() const {
return _internal_has_norm_region();
}
inline void LRNParameter::clear_norm_region() {
norm_region_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline ::caffe::LRNParameter_NormRegion LRNParameter::_internal_norm_region() const {
return static_cast< ::caffe::LRNParameter_NormRegion >(norm_region_);
}
inline ::caffe::LRNParameter_NormRegion LRNParameter::norm_region() const {
// @@protoc_insertion_point(field_get:caffe.LRNParameter.norm_region)
return _internal_norm_region();
}
inline void LRNParameter::_internal_set_norm_region(::caffe::LRNParameter_NormRegion value) {
assert(::caffe::LRNParameter_NormRegion_IsValid(value));
_has_bits_[0] |= 0x00000001u;
norm_region_ = value;
}
inline void LRNParameter::set_norm_region(::caffe::LRNParameter_NormRegion value) {
_internal_set_norm_region(value);
// @@protoc_insertion_point(field_set:caffe.LRNParameter.norm_region)
}
// optional float k = 5 [default = 1];
inline bool LRNParameter::_internal_has_k() const {
bool value = (_has_bits_[0] & 0x00000020u) != 0;
return value;
}
inline bool LRNParameter::has_k() const {
return _internal_has_k();
}
inline void LRNParameter::clear_k() {
k_ = 1;
_has_bits_[0] &= ~0x00000020u;
}
inline float LRNParameter::_internal_k() const {
return k_;
}
inline float LRNParameter::k() const {
// @@protoc_insertion_point(field_get:caffe.LRNParameter.k)
return _internal_k();
}
inline void LRNParameter::_internal_set_k(float value) {
_has_bits_[0] |= 0x00000020u;
k_ = value;
}
inline void LRNParameter::set_k(float value) {
_internal_set_k(value);
// @@protoc_insertion_point(field_set:caffe.LRNParameter.k)
}
// optional .caffe.LRNParameter.Engine engine = 6 [default = DEFAULT];
inline bool LRNParameter::_internal_has_engine() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool LRNParameter::has_engine() const {
return _internal_has_engine();
}
inline void LRNParameter::clear_engine() {
engine_ = 0;
_has_bits_[0] &= ~0x00000002u;
}
inline ::caffe::LRNParameter_Engine LRNParameter::_internal_engine() const {
return static_cast< ::caffe::LRNParameter_Engine >(engine_);
}
inline ::caffe::LRNParameter_Engine LRNParameter::engine() const {
// @@protoc_insertion_point(field_get:caffe.LRNParameter.engine)
return _internal_engine();
}
inline void LRNParameter::_internal_set_engine(::caffe::LRNParameter_Engine value) {
assert(::caffe::LRNParameter_Engine_IsValid(value));
_has_bits_[0] |= 0x00000002u;
engine_ = value;
}
inline void LRNParameter::set_engine(::caffe::LRNParameter_Engine value) {
_internal_set_engine(value);
// @@protoc_insertion_point(field_set:caffe.LRNParameter.engine)
}
// -------------------------------------------------------------------
// MemoryDataParameter
// optional uint32 batch_size = 1;
inline bool MemoryDataParameter::_internal_has_batch_size() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool MemoryDataParameter::has_batch_size() const {
return _internal_has_batch_size();
}
inline void MemoryDataParameter::clear_batch_size() {
batch_size_ = 0u;
_has_bits_[0] &= ~0x00000001u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 MemoryDataParameter::_internal_batch_size() const {
return batch_size_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 MemoryDataParameter::batch_size() const {
// @@protoc_insertion_point(field_get:caffe.MemoryDataParameter.batch_size)
return _internal_batch_size();
}
inline void MemoryDataParameter::_internal_set_batch_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000001u;
batch_size_ = value;
}
inline void MemoryDataParameter::set_batch_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_batch_size(value);
// @@protoc_insertion_point(field_set:caffe.MemoryDataParameter.batch_size)
}
// optional uint32 channels = 2;
inline bool MemoryDataParameter::_internal_has_channels() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool MemoryDataParameter::has_channels() const {
return _internal_has_channels();
}
inline void MemoryDataParameter::clear_channels() {
channels_ = 0u;
_has_bits_[0] &= ~0x00000002u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 MemoryDataParameter::_internal_channels() const {
return channels_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 MemoryDataParameter::channels() const {
// @@protoc_insertion_point(field_get:caffe.MemoryDataParameter.channels)
return _internal_channels();
}
inline void MemoryDataParameter::_internal_set_channels(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000002u;
channels_ = value;
}
inline void MemoryDataParameter::set_channels(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_channels(value);
// @@protoc_insertion_point(field_set:caffe.MemoryDataParameter.channels)
}
// optional uint32 height = 3;
inline bool MemoryDataParameter::_internal_has_height() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool MemoryDataParameter::has_height() const {
return _internal_has_height();
}
inline void MemoryDataParameter::clear_height() {
height_ = 0u;
_has_bits_[0] &= ~0x00000004u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 MemoryDataParameter::_internal_height() const {
return height_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 MemoryDataParameter::height() const {
// @@protoc_insertion_point(field_get:caffe.MemoryDataParameter.height)
return _internal_height();
}
inline void MemoryDataParameter::_internal_set_height(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000004u;
height_ = value;
}
inline void MemoryDataParameter::set_height(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_height(value);
// @@protoc_insertion_point(field_set:caffe.MemoryDataParameter.height)
}
// optional uint32 width = 4;
inline bool MemoryDataParameter::_internal_has_width() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool MemoryDataParameter::has_width() const {
return _internal_has_width();
}
inline void MemoryDataParameter::clear_width() {
width_ = 0u;
_has_bits_[0] &= ~0x00000008u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 MemoryDataParameter::_internal_width() const {
return width_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 MemoryDataParameter::width() const {
// @@protoc_insertion_point(field_get:caffe.MemoryDataParameter.width)
return _internal_width();
}
inline void MemoryDataParameter::_internal_set_width(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000008u;
width_ = value;
}
inline void MemoryDataParameter::set_width(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_width(value);
// @@protoc_insertion_point(field_set:caffe.MemoryDataParameter.width)
}
// -------------------------------------------------------------------
// MultiBoxLossParameter
// optional .caffe.MultiBoxLossParameter.LocLossType loc_loss_type = 1 [default = SMOOTH_L1];
inline bool MultiBoxLossParameter::_internal_has_loc_loss_type() const {
bool value = (_has_bits_[0] & 0x00000020u) != 0;
return value;
}
inline bool MultiBoxLossParameter::has_loc_loss_type() const {
return _internal_has_loc_loss_type();
}
inline void MultiBoxLossParameter::clear_loc_loss_type() {
loc_loss_type_ = 1;
_has_bits_[0] &= ~0x00000020u;
}
inline ::caffe::MultiBoxLossParameter_LocLossType MultiBoxLossParameter::_internal_loc_loss_type() const {
return static_cast< ::caffe::MultiBoxLossParameter_LocLossType >(loc_loss_type_);
}
inline ::caffe::MultiBoxLossParameter_LocLossType MultiBoxLossParameter::loc_loss_type() const {
// @@protoc_insertion_point(field_get:caffe.MultiBoxLossParameter.loc_loss_type)
return _internal_loc_loss_type();
}
inline void MultiBoxLossParameter::_internal_set_loc_loss_type(::caffe::MultiBoxLossParameter_LocLossType value) {
assert(::caffe::MultiBoxLossParameter_LocLossType_IsValid(value));
_has_bits_[0] |= 0x00000020u;
loc_loss_type_ = value;
}
inline void MultiBoxLossParameter::set_loc_loss_type(::caffe::MultiBoxLossParameter_LocLossType value) {
_internal_set_loc_loss_type(value);
// @@protoc_insertion_point(field_set:caffe.MultiBoxLossParameter.loc_loss_type)
}
// optional .caffe.MultiBoxLossParameter.ConfLossType conf_loss_type = 2 [default = SOFTMAX];
inline bool MultiBoxLossParameter::_internal_has_conf_loss_type() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool MultiBoxLossParameter::has_conf_loss_type() const {
return _internal_has_conf_loss_type();
}
inline void MultiBoxLossParameter::clear_conf_loss_type() {
conf_loss_type_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline ::caffe::MultiBoxLossParameter_ConfLossType MultiBoxLossParameter::_internal_conf_loss_type() const {
return static_cast< ::caffe::MultiBoxLossParameter_ConfLossType >(conf_loss_type_);
}
inline ::caffe::MultiBoxLossParameter_ConfLossType MultiBoxLossParameter::conf_loss_type() const {
// @@protoc_insertion_point(field_get:caffe.MultiBoxLossParameter.conf_loss_type)
return _internal_conf_loss_type();
}
inline void MultiBoxLossParameter::_internal_set_conf_loss_type(::caffe::MultiBoxLossParameter_ConfLossType value) {
assert(::caffe::MultiBoxLossParameter_ConfLossType_IsValid(value));
_has_bits_[0] |= 0x00000001u;
conf_loss_type_ = value;
}
inline void MultiBoxLossParameter::set_conf_loss_type(::caffe::MultiBoxLossParameter_ConfLossType value) {
_internal_set_conf_loss_type(value);
// @@protoc_insertion_point(field_set:caffe.MultiBoxLossParameter.conf_loss_type)
}
// optional float loc_weight = 3 [default = 1];
inline bool MultiBoxLossParameter::_internal_has_loc_weight() const {
bool value = (_has_bits_[0] & 0x00000040u) != 0;
return value;
}
inline bool MultiBoxLossParameter::has_loc_weight() const {
return _internal_has_loc_weight();
}
inline void MultiBoxLossParameter::clear_loc_weight() {
loc_weight_ = 1;
_has_bits_[0] &= ~0x00000040u;
}
inline float MultiBoxLossParameter::_internal_loc_weight() const {
return loc_weight_;
}
inline float MultiBoxLossParameter::loc_weight() const {
// @@protoc_insertion_point(field_get:caffe.MultiBoxLossParameter.loc_weight)
return _internal_loc_weight();
}
inline void MultiBoxLossParameter::_internal_set_loc_weight(float value) {
_has_bits_[0] |= 0x00000040u;
loc_weight_ = value;
}
inline void MultiBoxLossParameter::set_loc_weight(float value) {
_internal_set_loc_weight(value);
// @@protoc_insertion_point(field_set:caffe.MultiBoxLossParameter.loc_weight)
}
// optional uint32 num_classes = 4;
inline bool MultiBoxLossParameter::_internal_has_num_classes() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool MultiBoxLossParameter::has_num_classes() const {
return _internal_has_num_classes();
}
inline void MultiBoxLossParameter::clear_num_classes() {
num_classes_ = 0u;
_has_bits_[0] &= ~0x00000002u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 MultiBoxLossParameter::_internal_num_classes() const {
return num_classes_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 MultiBoxLossParameter::num_classes() const {
// @@protoc_insertion_point(field_get:caffe.MultiBoxLossParameter.num_classes)
return _internal_num_classes();
}
inline void MultiBoxLossParameter::_internal_set_num_classes(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000002u;
num_classes_ = value;
}
inline void MultiBoxLossParameter::set_num_classes(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_num_classes(value);
// @@protoc_insertion_point(field_set:caffe.MultiBoxLossParameter.num_classes)
}
// optional bool share_location = 5 [default = true];
inline bool MultiBoxLossParameter::_internal_has_share_location() const {
bool value = (_has_bits_[0] & 0x00000200u) != 0;
return value;
}
inline bool MultiBoxLossParameter::has_share_location() const {
return _internal_has_share_location();
}
inline void MultiBoxLossParameter::clear_share_location() {
share_location_ = true;
_has_bits_[0] &= ~0x00000200u;
}
inline bool MultiBoxLossParameter::_internal_share_location() const {
return share_location_;
}
inline bool MultiBoxLossParameter::share_location() const {
// @@protoc_insertion_point(field_get:caffe.MultiBoxLossParameter.share_location)
return _internal_share_location();
}
inline void MultiBoxLossParameter::_internal_set_share_location(bool value) {
_has_bits_[0] |= 0x00000200u;
share_location_ = value;
}
inline void MultiBoxLossParameter::set_share_location(bool value) {
_internal_set_share_location(value);
// @@protoc_insertion_point(field_set:caffe.MultiBoxLossParameter.share_location)
}
// optional .caffe.MultiBoxLossParameter.MatchType match_type = 6 [default = PER_PREDICTION];
inline bool MultiBoxLossParameter::_internal_has_match_type() const {
bool value = (_has_bits_[0] & 0x00000080u) != 0;
return value;
}
inline bool MultiBoxLossParameter::has_match_type() const {
return _internal_has_match_type();
}
inline void MultiBoxLossParameter::clear_match_type() {
match_type_ = 1;
_has_bits_[0] &= ~0x00000080u;
}
inline ::caffe::MultiBoxLossParameter_MatchType MultiBoxLossParameter::_internal_match_type() const {
return static_cast< ::caffe::MultiBoxLossParameter_MatchType >(match_type_);
}
inline ::caffe::MultiBoxLossParameter_MatchType MultiBoxLossParameter::match_type() const {
// @@protoc_insertion_point(field_get:caffe.MultiBoxLossParameter.match_type)
return _internal_match_type();
}
inline void MultiBoxLossParameter::_internal_set_match_type(::caffe::MultiBoxLossParameter_MatchType value) {
assert(::caffe::MultiBoxLossParameter_MatchType_IsValid(value));
_has_bits_[0] |= 0x00000080u;
match_type_ = value;
}
inline void MultiBoxLossParameter::set_match_type(::caffe::MultiBoxLossParameter_MatchType value) {
_internal_set_match_type(value);
// @@protoc_insertion_point(field_set:caffe.MultiBoxLossParameter.match_type)
}
// optional float overlap_threshold = 7 [default = 0.5];
inline bool MultiBoxLossParameter::_internal_has_overlap_threshold() const {
bool value = (_has_bits_[0] & 0x00000100u) != 0;
return value;
}
inline bool MultiBoxLossParameter::has_overlap_threshold() const {
return _internal_has_overlap_threshold();
}
inline void MultiBoxLossParameter::clear_overlap_threshold() {
overlap_threshold_ = 0.5f;
_has_bits_[0] &= ~0x00000100u;
}
inline float MultiBoxLossParameter::_internal_overlap_threshold() const {
return overlap_threshold_;
}
inline float MultiBoxLossParameter::overlap_threshold() const {
// @@protoc_insertion_point(field_get:caffe.MultiBoxLossParameter.overlap_threshold)
return _internal_overlap_threshold();
}
inline void MultiBoxLossParameter::_internal_set_overlap_threshold(float value) {
_has_bits_[0] |= 0x00000100u;
overlap_threshold_ = value;
}
inline void MultiBoxLossParameter::set_overlap_threshold(float value) {
_internal_set_overlap_threshold(value);
// @@protoc_insertion_point(field_set:caffe.MultiBoxLossParameter.overlap_threshold)
}
// optional bool use_prior_for_matching = 8 [default = true];
inline bool MultiBoxLossParameter::_internal_has_use_prior_for_matching() const {
bool value = (_has_bits_[0] & 0x00000400u) != 0;
return value;
}
inline bool MultiBoxLossParameter::has_use_prior_for_matching() const {
return _internal_has_use_prior_for_matching();
}
inline void MultiBoxLossParameter::clear_use_prior_for_matching() {
use_prior_for_matching_ = true;
_has_bits_[0] &= ~0x00000400u;
}
inline bool MultiBoxLossParameter::_internal_use_prior_for_matching() const {
return use_prior_for_matching_;
}
inline bool MultiBoxLossParameter::use_prior_for_matching() const {
// @@protoc_insertion_point(field_get:caffe.MultiBoxLossParameter.use_prior_for_matching)
return _internal_use_prior_for_matching();
}
inline void MultiBoxLossParameter::_internal_set_use_prior_for_matching(bool value) {
_has_bits_[0] |= 0x00000400u;
use_prior_for_matching_ = value;
}
inline void MultiBoxLossParameter::set_use_prior_for_matching(bool value) {
_internal_set_use_prior_for_matching(value);
// @@protoc_insertion_point(field_set:caffe.MultiBoxLossParameter.use_prior_for_matching)
}
// optional uint32 background_label_id = 9 [default = 0];
inline bool MultiBoxLossParameter::_internal_has_background_label_id() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool MultiBoxLossParameter::has_background_label_id() const {
return _internal_has_background_label_id();
}
inline void MultiBoxLossParameter::clear_background_label_id() {
background_label_id_ = 0u;
_has_bits_[0] &= ~0x00000004u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 MultiBoxLossParameter::_internal_background_label_id() const {
return background_label_id_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 MultiBoxLossParameter::background_label_id() const {
// @@protoc_insertion_point(field_get:caffe.MultiBoxLossParameter.background_label_id)
return _internal_background_label_id();
}
inline void MultiBoxLossParameter::_internal_set_background_label_id(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000004u;
background_label_id_ = value;
}
inline void MultiBoxLossParameter::set_background_label_id(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_background_label_id(value);
// @@protoc_insertion_point(field_set:caffe.MultiBoxLossParameter.background_label_id)
}
// optional bool use_difficult_gt = 10 [default = true];
inline bool MultiBoxLossParameter::_internal_has_use_difficult_gt() const {
bool value = (_has_bits_[0] & 0x00000800u) != 0;
return value;
}
inline bool MultiBoxLossParameter::has_use_difficult_gt() const {
return _internal_has_use_difficult_gt();
}
inline void MultiBoxLossParameter::clear_use_difficult_gt() {
use_difficult_gt_ = true;
_has_bits_[0] &= ~0x00000800u;
}
inline bool MultiBoxLossParameter::_internal_use_difficult_gt() const {
return use_difficult_gt_;
}
inline bool MultiBoxLossParameter::use_difficult_gt() const {
// @@protoc_insertion_point(field_get:caffe.MultiBoxLossParameter.use_difficult_gt)
return _internal_use_difficult_gt();
}
inline void MultiBoxLossParameter::_internal_set_use_difficult_gt(bool value) {
_has_bits_[0] |= 0x00000800u;
use_difficult_gt_ = value;
}
inline void MultiBoxLossParameter::set_use_difficult_gt(bool value) {
_internal_set_use_difficult_gt(value);
// @@protoc_insertion_point(field_set:caffe.MultiBoxLossParameter.use_difficult_gt)
}
// optional bool do_neg_mining = 11 [default = true];
inline bool MultiBoxLossParameter::_internal_has_do_neg_mining() const {
bool value = (_has_bits_[0] & 0x00001000u) != 0;
return value;
}
inline bool MultiBoxLossParameter::has_do_neg_mining() const {
return _internal_has_do_neg_mining();
}
inline void MultiBoxLossParameter::clear_do_neg_mining() {
do_neg_mining_ = true;
_has_bits_[0] &= ~0x00001000u;
}
inline bool MultiBoxLossParameter::_internal_do_neg_mining() const {
return do_neg_mining_;
}
inline bool MultiBoxLossParameter::do_neg_mining() const {
// @@protoc_insertion_point(field_get:caffe.MultiBoxLossParameter.do_neg_mining)
return _internal_do_neg_mining();
}
inline void MultiBoxLossParameter::_internal_set_do_neg_mining(bool value) {
_has_bits_[0] |= 0x00001000u;
do_neg_mining_ = value;
}
inline void MultiBoxLossParameter::set_do_neg_mining(bool value) {
_internal_set_do_neg_mining(value);
// @@protoc_insertion_point(field_set:caffe.MultiBoxLossParameter.do_neg_mining)
}
// optional float neg_pos_ratio = 12 [default = 3];
inline bool MultiBoxLossParameter::_internal_has_neg_pos_ratio() const {
bool value = (_has_bits_[0] & 0x00002000u) != 0;
return value;
}
inline bool MultiBoxLossParameter::has_neg_pos_ratio() const {
return _internal_has_neg_pos_ratio();
}
inline void MultiBoxLossParameter::clear_neg_pos_ratio() {
neg_pos_ratio_ = 3;
_has_bits_[0] &= ~0x00002000u;
}
inline float MultiBoxLossParameter::_internal_neg_pos_ratio() const {
return neg_pos_ratio_;
}
inline float MultiBoxLossParameter::neg_pos_ratio() const {
// @@protoc_insertion_point(field_get:caffe.MultiBoxLossParameter.neg_pos_ratio)
return _internal_neg_pos_ratio();
}
inline void MultiBoxLossParameter::_internal_set_neg_pos_ratio(float value) {
_has_bits_[0] |= 0x00002000u;
neg_pos_ratio_ = value;
}
inline void MultiBoxLossParameter::set_neg_pos_ratio(float value) {
_internal_set_neg_pos_ratio(value);
// @@protoc_insertion_point(field_set:caffe.MultiBoxLossParameter.neg_pos_ratio)
}
// optional float neg_overlap = 13 [default = 0.5];
inline bool MultiBoxLossParameter::_internal_has_neg_overlap() const {
bool value = (_has_bits_[0] & 0x00004000u) != 0;
return value;
}
inline bool MultiBoxLossParameter::has_neg_overlap() const {
return _internal_has_neg_overlap();
}
inline void MultiBoxLossParameter::clear_neg_overlap() {
neg_overlap_ = 0.5f;
_has_bits_[0] &= ~0x00004000u;
}
inline float MultiBoxLossParameter::_internal_neg_overlap() const {
return neg_overlap_;
}
inline float MultiBoxLossParameter::neg_overlap() const {
// @@protoc_insertion_point(field_get:caffe.MultiBoxLossParameter.neg_overlap)
return _internal_neg_overlap();
}
inline void MultiBoxLossParameter::_internal_set_neg_overlap(float value) {
_has_bits_[0] |= 0x00004000u;
neg_overlap_ = value;
}
inline void MultiBoxLossParameter::set_neg_overlap(float value) {
_internal_set_neg_overlap(value);
// @@protoc_insertion_point(field_set:caffe.MultiBoxLossParameter.neg_overlap)
}
// optional .caffe.PriorBoxParameter.CodeType code_type = 14 [default = CORNER];
inline bool MultiBoxLossParameter::_internal_has_code_type() const {
bool value = (_has_bits_[0] & 0x00008000u) != 0;
return value;
}
inline bool MultiBoxLossParameter::has_code_type() const {
return _internal_has_code_type();
}
inline void MultiBoxLossParameter::clear_code_type() {
code_type_ = 1;
_has_bits_[0] &= ~0x00008000u;
}
inline ::caffe::PriorBoxParameter_CodeType MultiBoxLossParameter::_internal_code_type() const {
return static_cast< ::caffe::PriorBoxParameter_CodeType >(code_type_);
}
inline ::caffe::PriorBoxParameter_CodeType MultiBoxLossParameter::code_type() const {
// @@protoc_insertion_point(field_get:caffe.MultiBoxLossParameter.code_type)
return _internal_code_type();
}
inline void MultiBoxLossParameter::_internal_set_code_type(::caffe::PriorBoxParameter_CodeType value) {
assert(::caffe::PriorBoxParameter_CodeType_IsValid(value));
_has_bits_[0] |= 0x00008000u;
code_type_ = value;
}
inline void MultiBoxLossParameter::set_code_type(::caffe::PriorBoxParameter_CodeType value) {
_internal_set_code_type(value);
// @@protoc_insertion_point(field_set:caffe.MultiBoxLossParameter.code_type)
}
// optional bool encode_variance_in_target = 16 [default = false];
inline bool MultiBoxLossParameter::_internal_has_encode_variance_in_target() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool MultiBoxLossParameter::has_encode_variance_in_target() const {
return _internal_has_encode_variance_in_target();
}
inline void MultiBoxLossParameter::clear_encode_variance_in_target() {
encode_variance_in_target_ = false;
_has_bits_[0] &= ~0x00000008u;
}
inline bool MultiBoxLossParameter::_internal_encode_variance_in_target() const {
return encode_variance_in_target_;
}
inline bool MultiBoxLossParameter::encode_variance_in_target() const {
// @@protoc_insertion_point(field_get:caffe.MultiBoxLossParameter.encode_variance_in_target)
return _internal_encode_variance_in_target();
}
inline void MultiBoxLossParameter::_internal_set_encode_variance_in_target(bool value) {
_has_bits_[0] |= 0x00000008u;
encode_variance_in_target_ = value;
}
inline void MultiBoxLossParameter::set_encode_variance_in_target(bool value) {
_internal_set_encode_variance_in_target(value);
// @@protoc_insertion_point(field_set:caffe.MultiBoxLossParameter.encode_variance_in_target)
}
// optional bool map_object_to_agnostic = 17 [default = false];
inline bool MultiBoxLossParameter::_internal_has_map_object_to_agnostic() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool MultiBoxLossParameter::has_map_object_to_agnostic() const {
return _internal_has_map_object_to_agnostic();
}
inline void MultiBoxLossParameter::clear_map_object_to_agnostic() {
map_object_to_agnostic_ = false;
_has_bits_[0] &= ~0x00000010u;
}
inline bool MultiBoxLossParameter::_internal_map_object_to_agnostic() const {
return map_object_to_agnostic_;
}
inline bool MultiBoxLossParameter::map_object_to_agnostic() const {
// @@protoc_insertion_point(field_get:caffe.MultiBoxLossParameter.map_object_to_agnostic)
return _internal_map_object_to_agnostic();
}
inline void MultiBoxLossParameter::_internal_set_map_object_to_agnostic(bool value) {
_has_bits_[0] |= 0x00000010u;
map_object_to_agnostic_ = value;
}
inline void MultiBoxLossParameter::set_map_object_to_agnostic(bool value) {
_internal_set_map_object_to_agnostic(value);
// @@protoc_insertion_point(field_set:caffe.MultiBoxLossParameter.map_object_to_agnostic)
}
// -------------------------------------------------------------------
// MVNParameter
// optional bool normalize_variance = 1 [default = true];
inline bool MVNParameter::_internal_has_normalize_variance() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool MVNParameter::has_normalize_variance() const {
return _internal_has_normalize_variance();
}
inline void MVNParameter::clear_normalize_variance() {
normalize_variance_ = true;
_has_bits_[0] &= ~0x00000002u;
}
inline bool MVNParameter::_internal_normalize_variance() const {
return normalize_variance_;
}
inline bool MVNParameter::normalize_variance() const {
// @@protoc_insertion_point(field_get:caffe.MVNParameter.normalize_variance)
return _internal_normalize_variance();
}
inline void MVNParameter::_internal_set_normalize_variance(bool value) {
_has_bits_[0] |= 0x00000002u;
normalize_variance_ = value;
}
inline void MVNParameter::set_normalize_variance(bool value) {
_internal_set_normalize_variance(value);
// @@protoc_insertion_point(field_set:caffe.MVNParameter.normalize_variance)
}
// optional bool across_channels = 2 [default = false];
inline bool MVNParameter::_internal_has_across_channels() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool MVNParameter::has_across_channels() const {
return _internal_has_across_channels();
}
inline void MVNParameter::clear_across_channels() {
across_channels_ = false;
_has_bits_[0] &= ~0x00000001u;
}
inline bool MVNParameter::_internal_across_channels() const {
return across_channels_;
}
inline bool MVNParameter::across_channels() const {
// @@protoc_insertion_point(field_get:caffe.MVNParameter.across_channels)
return _internal_across_channels();
}
inline void MVNParameter::_internal_set_across_channels(bool value) {
_has_bits_[0] |= 0x00000001u;
across_channels_ = value;
}
inline void MVNParameter::set_across_channels(bool value) {
_internal_set_across_channels(value);
// @@protoc_insertion_point(field_set:caffe.MVNParameter.across_channels)
}
// optional float eps = 3 [default = 1e-09];
inline bool MVNParameter::_internal_has_eps() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool MVNParameter::has_eps() const {
return _internal_has_eps();
}
inline void MVNParameter::clear_eps() {
eps_ = 1e-09f;
_has_bits_[0] &= ~0x00000004u;
}
inline float MVNParameter::_internal_eps() const {
return eps_;
}
inline float MVNParameter::eps() const {
// @@protoc_insertion_point(field_get:caffe.MVNParameter.eps)
return _internal_eps();
}
inline void MVNParameter::_internal_set_eps(float value) {
_has_bits_[0] |= 0x00000004u;
eps_ = value;
}
inline void MVNParameter::set_eps(float value) {
_internal_set_eps(value);
// @@protoc_insertion_point(field_set:caffe.MVNParameter.eps)
}
// -------------------------------------------------------------------
// NormalizeParameter
// optional bool across_spatial = 1 [default = true];
inline bool NormalizeParameter::_internal_has_across_spatial() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool NormalizeParameter::has_across_spatial() const {
return _internal_has_across_spatial();
}
inline void NormalizeParameter::clear_across_spatial() {
across_spatial_ = true;
_has_bits_[0] &= ~0x00000002u;
}
inline bool NormalizeParameter::_internal_across_spatial() const {
return across_spatial_;
}
inline bool NormalizeParameter::across_spatial() const {
// @@protoc_insertion_point(field_get:caffe.NormalizeParameter.across_spatial)
return _internal_across_spatial();
}
inline void NormalizeParameter::_internal_set_across_spatial(bool value) {
_has_bits_[0] |= 0x00000002u;
across_spatial_ = value;
}
inline void NormalizeParameter::set_across_spatial(bool value) {
_internal_set_across_spatial(value);
// @@protoc_insertion_point(field_set:caffe.NormalizeParameter.across_spatial)
}
// optional .caffe.FillerParameter scale_filler = 2;
inline bool NormalizeParameter::_internal_has_scale_filler() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
PROTOBUF_ASSUME(!value || scale_filler_ != nullptr);
return value;
}
inline bool NormalizeParameter::has_scale_filler() const {
return _internal_has_scale_filler();
}
inline void NormalizeParameter::clear_scale_filler() {
if (scale_filler_ != nullptr) scale_filler_->Clear();
_has_bits_[0] &= ~0x00000001u;
}
inline const ::caffe::FillerParameter& NormalizeParameter::_internal_scale_filler() const {
const ::caffe::FillerParameter* p = scale_filler_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::FillerParameter*>(
&::caffe::_FillerParameter_default_instance_);
}
inline const ::caffe::FillerParameter& NormalizeParameter::scale_filler() const {
// @@protoc_insertion_point(field_get:caffe.NormalizeParameter.scale_filler)
return _internal_scale_filler();
}
inline void NormalizeParameter::unsafe_arena_set_allocated_scale_filler(
::caffe::FillerParameter* scale_filler) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(scale_filler_);
}
scale_filler_ = scale_filler;
if (scale_filler) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.NormalizeParameter.scale_filler)
}
inline ::caffe::FillerParameter* NormalizeParameter::release_scale_filler() {
_has_bits_[0] &= ~0x00000001u;
::caffe::FillerParameter* temp = scale_filler_;
scale_filler_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::FillerParameter* NormalizeParameter::unsafe_arena_release_scale_filler() {
// @@protoc_insertion_point(field_release:caffe.NormalizeParameter.scale_filler)
_has_bits_[0] &= ~0x00000001u;
::caffe::FillerParameter* temp = scale_filler_;
scale_filler_ = nullptr;
return temp;
}
inline ::caffe::FillerParameter* NormalizeParameter::_internal_mutable_scale_filler() {
_has_bits_[0] |= 0x00000001u;
if (scale_filler_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::FillerParameter>(GetArena());
scale_filler_ = p;
}
return scale_filler_;
}
inline ::caffe::FillerParameter* NormalizeParameter::mutable_scale_filler() {
// @@protoc_insertion_point(field_mutable:caffe.NormalizeParameter.scale_filler)
return _internal_mutable_scale_filler();
}
inline void NormalizeParameter::set_allocated_scale_filler(::caffe::FillerParameter* scale_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete scale_filler_;
}
if (scale_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(scale_filler);
if (message_arena != submessage_arena) {
scale_filler = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, scale_filler, submessage_arena);
}
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
scale_filler_ = scale_filler;
// @@protoc_insertion_point(field_set_allocated:caffe.NormalizeParameter.scale_filler)
}
// optional bool channel_shared = 3 [default = true];
inline bool NormalizeParameter::_internal_has_channel_shared() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool NormalizeParameter::has_channel_shared() const {
return _internal_has_channel_shared();
}
inline void NormalizeParameter::clear_channel_shared() {
channel_shared_ = true;
_has_bits_[0] &= ~0x00000004u;
}
inline bool NormalizeParameter::_internal_channel_shared() const {
return channel_shared_;
}
inline bool NormalizeParameter::channel_shared() const {
// @@protoc_insertion_point(field_get:caffe.NormalizeParameter.channel_shared)
return _internal_channel_shared();
}
inline void NormalizeParameter::_internal_set_channel_shared(bool value) {
_has_bits_[0] |= 0x00000004u;
channel_shared_ = value;
}
inline void NormalizeParameter::set_channel_shared(bool value) {
_internal_set_channel_shared(value);
// @@protoc_insertion_point(field_set:caffe.NormalizeParameter.channel_shared)
}
// optional float eps = 4 [default = 1e-10];
inline bool NormalizeParameter::_internal_has_eps() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool NormalizeParameter::has_eps() const {
return _internal_has_eps();
}
inline void NormalizeParameter::clear_eps() {
eps_ = 1e-10f;
_has_bits_[0] &= ~0x00000008u;
}
inline float NormalizeParameter::_internal_eps() const {
return eps_;
}
inline float NormalizeParameter::eps() const {
// @@protoc_insertion_point(field_get:caffe.NormalizeParameter.eps)
return _internal_eps();
}
inline void NormalizeParameter::_internal_set_eps(float value) {
_has_bits_[0] |= 0x00000008u;
eps_ = value;
}
inline void NormalizeParameter::set_eps(float value) {
_internal_set_eps(value);
// @@protoc_insertion_point(field_set:caffe.NormalizeParameter.eps)
}
// -------------------------------------------------------------------
// ParameterParameter
// optional .caffe.BlobShape shape = 1;
inline bool ParameterParameter::_internal_has_shape() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
PROTOBUF_ASSUME(!value || shape_ != nullptr);
return value;
}
inline bool ParameterParameter::has_shape() const {
return _internal_has_shape();
}
inline void ParameterParameter::clear_shape() {
if (shape_ != nullptr) shape_->Clear();
_has_bits_[0] &= ~0x00000001u;
}
inline const ::caffe::BlobShape& ParameterParameter::_internal_shape() const {
const ::caffe::BlobShape* p = shape_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::BlobShape*>(
&::caffe::_BlobShape_default_instance_);
}
inline const ::caffe::BlobShape& ParameterParameter::shape() const {
// @@protoc_insertion_point(field_get:caffe.ParameterParameter.shape)
return _internal_shape();
}
inline void ParameterParameter::unsafe_arena_set_allocated_shape(
::caffe::BlobShape* shape) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(shape_);
}
shape_ = shape;
if (shape) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.ParameterParameter.shape)
}
inline ::caffe::BlobShape* ParameterParameter::release_shape() {
_has_bits_[0] &= ~0x00000001u;
::caffe::BlobShape* temp = shape_;
shape_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::BlobShape* ParameterParameter::unsafe_arena_release_shape() {
// @@protoc_insertion_point(field_release:caffe.ParameterParameter.shape)
_has_bits_[0] &= ~0x00000001u;
::caffe::BlobShape* temp = shape_;
shape_ = nullptr;
return temp;
}
inline ::caffe::BlobShape* ParameterParameter::_internal_mutable_shape() {
_has_bits_[0] |= 0x00000001u;
if (shape_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::BlobShape>(GetArena());
shape_ = p;
}
return shape_;
}
inline ::caffe::BlobShape* ParameterParameter::mutable_shape() {
// @@protoc_insertion_point(field_mutable:caffe.ParameterParameter.shape)
return _internal_mutable_shape();
}
inline void ParameterParameter::set_allocated_shape(::caffe::BlobShape* shape) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete shape_;
}
if (shape) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(shape);
if (message_arena != submessage_arena) {
shape = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, shape, submessage_arena);
}
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
shape_ = shape;
// @@protoc_insertion_point(field_set_allocated:caffe.ParameterParameter.shape)
}
// -------------------------------------------------------------------
// PermuteParameter
// repeated uint32 order = 1;
inline int PermuteParameter::_internal_order_size() const {
return order_.size();
}
inline int PermuteParameter::order_size() const {
return _internal_order_size();
}
inline void PermuteParameter::clear_order() {
order_.Clear();
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 PermuteParameter::_internal_order(int index) const {
return order_.Get(index);
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 PermuteParameter::order(int index) const {
// @@protoc_insertion_point(field_get:caffe.PermuteParameter.order)
return _internal_order(index);
}
inline void PermuteParameter::set_order(int index, ::PROTOBUF_NAMESPACE_ID::uint32 value) {
order_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.PermuteParameter.order)
}
inline void PermuteParameter::_internal_add_order(::PROTOBUF_NAMESPACE_ID::uint32 value) {
order_.Add(value);
}
inline void PermuteParameter::add_order(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_add_order(value);
// @@protoc_insertion_point(field_add:caffe.PermuteParameter.order)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
PermuteParameter::_internal_order() const {
return order_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
PermuteParameter::order() const {
// @@protoc_insertion_point(field_list:caffe.PermuteParameter.order)
return _internal_order();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
PermuteParameter::_internal_mutable_order() {
return &order_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
PermuteParameter::mutable_order() {
// @@protoc_insertion_point(field_mutable_list:caffe.PermuteParameter.order)
return _internal_mutable_order();
}
// -------------------------------------------------------------------
// PoolingParameter
// optional .caffe.PoolingParameter.PoolMethod pool = 1 [default = MAX];
inline bool PoolingParameter::_internal_has_pool() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool PoolingParameter::has_pool() const {
return _internal_has_pool();
}
inline void PoolingParameter::clear_pool() {
pool_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline ::caffe::PoolingParameter_PoolMethod PoolingParameter::_internal_pool() const {
return static_cast< ::caffe::PoolingParameter_PoolMethod >(pool_);
}
inline ::caffe::PoolingParameter_PoolMethod PoolingParameter::pool() const {
// @@protoc_insertion_point(field_get:caffe.PoolingParameter.pool)
return _internal_pool();
}
inline void PoolingParameter::_internal_set_pool(::caffe::PoolingParameter_PoolMethod value) {
assert(::caffe::PoolingParameter_PoolMethod_IsValid(value));
_has_bits_[0] |= 0x00000001u;
pool_ = value;
}
inline void PoolingParameter::set_pool(::caffe::PoolingParameter_PoolMethod value) {
_internal_set_pool(value);
// @@protoc_insertion_point(field_set:caffe.PoolingParameter.pool)
}
// optional uint32 pad = 4 [default = 0];
inline bool PoolingParameter::_internal_has_pad() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool PoolingParameter::has_pad() const {
return _internal_has_pad();
}
inline void PoolingParameter::clear_pad() {
pad_ = 0u;
_has_bits_[0] &= ~0x00000004u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 PoolingParameter::_internal_pad() const {
return pad_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 PoolingParameter::pad() const {
// @@protoc_insertion_point(field_get:caffe.PoolingParameter.pad)
return _internal_pad();
}
inline void PoolingParameter::_internal_set_pad(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000004u;
pad_ = value;
}
inline void PoolingParameter::set_pad(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_pad(value);
// @@protoc_insertion_point(field_set:caffe.PoolingParameter.pad)
}
// optional uint32 pad_h = 9 [default = 0];
inline bool PoolingParameter::_internal_has_pad_h() const {
bool value = (_has_bits_[0] & 0x00000080u) != 0;
return value;
}
inline bool PoolingParameter::has_pad_h() const {
return _internal_has_pad_h();
}
inline void PoolingParameter::clear_pad_h() {
pad_h_ = 0u;
_has_bits_[0] &= ~0x00000080u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 PoolingParameter::_internal_pad_h() const {
return pad_h_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 PoolingParameter::pad_h() const {
// @@protoc_insertion_point(field_get:caffe.PoolingParameter.pad_h)
return _internal_pad_h();
}
inline void PoolingParameter::_internal_set_pad_h(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000080u;
pad_h_ = value;
}
inline void PoolingParameter::set_pad_h(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_pad_h(value);
// @@protoc_insertion_point(field_set:caffe.PoolingParameter.pad_h)
}
// optional uint32 pad_w = 10 [default = 0];
inline bool PoolingParameter::_internal_has_pad_w() const {
bool value = (_has_bits_[0] & 0x00000100u) != 0;
return value;
}
inline bool PoolingParameter::has_pad_w() const {
return _internal_has_pad_w();
}
inline void PoolingParameter::clear_pad_w() {
pad_w_ = 0u;
_has_bits_[0] &= ~0x00000100u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 PoolingParameter::_internal_pad_w() const {
return pad_w_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 PoolingParameter::pad_w() const {
// @@protoc_insertion_point(field_get:caffe.PoolingParameter.pad_w)
return _internal_pad_w();
}
inline void PoolingParameter::_internal_set_pad_w(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000100u;
pad_w_ = value;
}
inline void PoolingParameter::set_pad_w(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_pad_w(value);
// @@protoc_insertion_point(field_set:caffe.PoolingParameter.pad_w)
}
// optional uint32 kernel_size = 2;
inline bool PoolingParameter::_internal_has_kernel_size() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool PoolingParameter::has_kernel_size() const {
return _internal_has_kernel_size();
}
inline void PoolingParameter::clear_kernel_size() {
kernel_size_ = 0u;
_has_bits_[0] &= ~0x00000002u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 PoolingParameter::_internal_kernel_size() const {
return kernel_size_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 PoolingParameter::kernel_size() const {
// @@protoc_insertion_point(field_get:caffe.PoolingParameter.kernel_size)
return _internal_kernel_size();
}
inline void PoolingParameter::_internal_set_kernel_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000002u;
kernel_size_ = value;
}
inline void PoolingParameter::set_kernel_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_kernel_size(value);
// @@protoc_insertion_point(field_set:caffe.PoolingParameter.kernel_size)
}
// optional uint32 kernel_h = 5;
inline bool PoolingParameter::_internal_has_kernel_h() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool PoolingParameter::has_kernel_h() const {
return _internal_has_kernel_h();
}
inline void PoolingParameter::clear_kernel_h() {
kernel_h_ = 0u;
_has_bits_[0] &= ~0x00000008u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 PoolingParameter::_internal_kernel_h() const {
return kernel_h_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 PoolingParameter::kernel_h() const {
// @@protoc_insertion_point(field_get:caffe.PoolingParameter.kernel_h)
return _internal_kernel_h();
}
inline void PoolingParameter::_internal_set_kernel_h(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000008u;
kernel_h_ = value;
}
inline void PoolingParameter::set_kernel_h(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_kernel_h(value);
// @@protoc_insertion_point(field_set:caffe.PoolingParameter.kernel_h)
}
// optional uint32 kernel_w = 6;
inline bool PoolingParameter::_internal_has_kernel_w() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool PoolingParameter::has_kernel_w() const {
return _internal_has_kernel_w();
}
inline void PoolingParameter::clear_kernel_w() {
kernel_w_ = 0u;
_has_bits_[0] &= ~0x00000010u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 PoolingParameter::_internal_kernel_w() const {
return kernel_w_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 PoolingParameter::kernel_w() const {
// @@protoc_insertion_point(field_get:caffe.PoolingParameter.kernel_w)
return _internal_kernel_w();
}
inline void PoolingParameter::_internal_set_kernel_w(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000010u;
kernel_w_ = value;
}
inline void PoolingParameter::set_kernel_w(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_kernel_w(value);
// @@protoc_insertion_point(field_set:caffe.PoolingParameter.kernel_w)
}
// optional uint32 stride = 3 [default = 1];
inline bool PoolingParameter::_internal_has_stride() const {
bool value = (_has_bits_[0] & 0x00000800u) != 0;
return value;
}
inline bool PoolingParameter::has_stride() const {
return _internal_has_stride();
}
inline void PoolingParameter::clear_stride() {
stride_ = 1u;
_has_bits_[0] &= ~0x00000800u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 PoolingParameter::_internal_stride() const {
return stride_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 PoolingParameter::stride() const {
// @@protoc_insertion_point(field_get:caffe.PoolingParameter.stride)
return _internal_stride();
}
inline void PoolingParameter::_internal_set_stride(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000800u;
stride_ = value;
}
inline void PoolingParameter::set_stride(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_stride(value);
// @@protoc_insertion_point(field_set:caffe.PoolingParameter.stride)
}
// optional uint32 stride_h = 7;
inline bool PoolingParameter::_internal_has_stride_h() const {
bool value = (_has_bits_[0] & 0x00000020u) != 0;
return value;
}
inline bool PoolingParameter::has_stride_h() const {
return _internal_has_stride_h();
}
inline void PoolingParameter::clear_stride_h() {
stride_h_ = 0u;
_has_bits_[0] &= ~0x00000020u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 PoolingParameter::_internal_stride_h() const {
return stride_h_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 PoolingParameter::stride_h() const {
// @@protoc_insertion_point(field_get:caffe.PoolingParameter.stride_h)
return _internal_stride_h();
}
inline void PoolingParameter::_internal_set_stride_h(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000020u;
stride_h_ = value;
}
inline void PoolingParameter::set_stride_h(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_stride_h(value);
// @@protoc_insertion_point(field_set:caffe.PoolingParameter.stride_h)
}
// optional uint32 stride_w = 8;
inline bool PoolingParameter::_internal_has_stride_w() const {
bool value = (_has_bits_[0] & 0x00000040u) != 0;
return value;
}
inline bool PoolingParameter::has_stride_w() const {
return _internal_has_stride_w();
}
inline void PoolingParameter::clear_stride_w() {
stride_w_ = 0u;
_has_bits_[0] &= ~0x00000040u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 PoolingParameter::_internal_stride_w() const {
return stride_w_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 PoolingParameter::stride_w() const {
// @@protoc_insertion_point(field_get:caffe.PoolingParameter.stride_w)
return _internal_stride_w();
}
inline void PoolingParameter::_internal_set_stride_w(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000040u;
stride_w_ = value;
}
inline void PoolingParameter::set_stride_w(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_stride_w(value);
// @@protoc_insertion_point(field_set:caffe.PoolingParameter.stride_w)
}
// optional .caffe.PoolingParameter.Engine engine = 11 [default = DEFAULT];
inline bool PoolingParameter::_internal_has_engine() const {
bool value = (_has_bits_[0] & 0x00000200u) != 0;
return value;
}
inline bool PoolingParameter::has_engine() const {
return _internal_has_engine();
}
inline void PoolingParameter::clear_engine() {
engine_ = 0;
_has_bits_[0] &= ~0x00000200u;
}
inline ::caffe::PoolingParameter_Engine PoolingParameter::_internal_engine() const {
return static_cast< ::caffe::PoolingParameter_Engine >(engine_);
}
inline ::caffe::PoolingParameter_Engine PoolingParameter::engine() const {
// @@protoc_insertion_point(field_get:caffe.PoolingParameter.engine)
return _internal_engine();
}
inline void PoolingParameter::_internal_set_engine(::caffe::PoolingParameter_Engine value) {
assert(::caffe::PoolingParameter_Engine_IsValid(value));
_has_bits_[0] |= 0x00000200u;
engine_ = value;
}
inline void PoolingParameter::set_engine(::caffe::PoolingParameter_Engine value) {
_internal_set_engine(value);
// @@protoc_insertion_point(field_set:caffe.PoolingParameter.engine)
}
// optional bool global_pooling = 12 [default = false];
inline bool PoolingParameter::_internal_has_global_pooling() const {
bool value = (_has_bits_[0] & 0x00000400u) != 0;
return value;
}
inline bool PoolingParameter::has_global_pooling() const {
return _internal_has_global_pooling();
}
inline void PoolingParameter::clear_global_pooling() {
global_pooling_ = false;
_has_bits_[0] &= ~0x00000400u;
}
inline bool PoolingParameter::_internal_global_pooling() const {
return global_pooling_;
}
inline bool PoolingParameter::global_pooling() const {
// @@protoc_insertion_point(field_get:caffe.PoolingParameter.global_pooling)
return _internal_global_pooling();
}
inline void PoolingParameter::_internal_set_global_pooling(bool value) {
_has_bits_[0] |= 0x00000400u;
global_pooling_ = value;
}
inline void PoolingParameter::set_global_pooling(bool value) {
_internal_set_global_pooling(value);
// @@protoc_insertion_point(field_set:caffe.PoolingParameter.global_pooling)
}
// -------------------------------------------------------------------
// PowerParameter
// optional float power = 1 [default = 1];
inline bool PowerParameter::_internal_has_power() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool PowerParameter::has_power() const {
return _internal_has_power();
}
inline void PowerParameter::clear_power() {
power_ = 1;
_has_bits_[0] &= ~0x00000002u;
}
inline float PowerParameter::_internal_power() const {
return power_;
}
inline float PowerParameter::power() const {
// @@protoc_insertion_point(field_get:caffe.PowerParameter.power)
return _internal_power();
}
inline void PowerParameter::_internal_set_power(float value) {
_has_bits_[0] |= 0x00000002u;
power_ = value;
}
inline void PowerParameter::set_power(float value) {
_internal_set_power(value);
// @@protoc_insertion_point(field_set:caffe.PowerParameter.power)
}
// optional float scale = 2 [default = 1];
inline bool PowerParameter::_internal_has_scale() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool PowerParameter::has_scale() const {
return _internal_has_scale();
}
inline void PowerParameter::clear_scale() {
scale_ = 1;
_has_bits_[0] &= ~0x00000004u;
}
inline float PowerParameter::_internal_scale() const {
return scale_;
}
inline float PowerParameter::scale() const {
// @@protoc_insertion_point(field_get:caffe.PowerParameter.scale)
return _internal_scale();
}
inline void PowerParameter::_internal_set_scale(float value) {
_has_bits_[0] |= 0x00000004u;
scale_ = value;
}
inline void PowerParameter::set_scale(float value) {
_internal_set_scale(value);
// @@protoc_insertion_point(field_set:caffe.PowerParameter.scale)
}
// optional float shift = 3 [default = 0];
inline bool PowerParameter::_internal_has_shift() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool PowerParameter::has_shift() const {
return _internal_has_shift();
}
inline void PowerParameter::clear_shift() {
shift_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline float PowerParameter::_internal_shift() const {
return shift_;
}
inline float PowerParameter::shift() const {
// @@protoc_insertion_point(field_get:caffe.PowerParameter.shift)
return _internal_shift();
}
inline void PowerParameter::_internal_set_shift(float value) {
_has_bits_[0] |= 0x00000001u;
shift_ = value;
}
inline void PowerParameter::set_shift(float value) {
_internal_set_shift(value);
// @@protoc_insertion_point(field_set:caffe.PowerParameter.shift)
}
// -------------------------------------------------------------------
// PriorBoxParameter
// optional float min_size = 1;
inline bool PriorBoxParameter::_internal_has_min_size() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool PriorBoxParameter::has_min_size() const {
return _internal_has_min_size();
}
inline void PriorBoxParameter::clear_min_size() {
min_size_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline float PriorBoxParameter::_internal_min_size() const {
return min_size_;
}
inline float PriorBoxParameter::min_size() const {
// @@protoc_insertion_point(field_get:caffe.PriorBoxParameter.min_size)
return _internal_min_size();
}
inline void PriorBoxParameter::_internal_set_min_size(float value) {
_has_bits_[0] |= 0x00000001u;
min_size_ = value;
}
inline void PriorBoxParameter::set_min_size(float value) {
_internal_set_min_size(value);
// @@protoc_insertion_point(field_set:caffe.PriorBoxParameter.min_size)
}
// optional float max_size = 2;
inline bool PriorBoxParameter::_internal_has_max_size() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool PriorBoxParameter::has_max_size() const {
return _internal_has_max_size();
}
inline void PriorBoxParameter::clear_max_size() {
max_size_ = 0;
_has_bits_[0] &= ~0x00000002u;
}
inline float PriorBoxParameter::_internal_max_size() const {
return max_size_;
}
inline float PriorBoxParameter::max_size() const {
// @@protoc_insertion_point(field_get:caffe.PriorBoxParameter.max_size)
return _internal_max_size();
}
inline void PriorBoxParameter::_internal_set_max_size(float value) {
_has_bits_[0] |= 0x00000002u;
max_size_ = value;
}
inline void PriorBoxParameter::set_max_size(float value) {
_internal_set_max_size(value);
// @@protoc_insertion_point(field_set:caffe.PriorBoxParameter.max_size)
}
// repeated float aspect_ratio = 3;
inline int PriorBoxParameter::_internal_aspect_ratio_size() const {
return aspect_ratio_.size();
}
inline int PriorBoxParameter::aspect_ratio_size() const {
return _internal_aspect_ratio_size();
}
inline void PriorBoxParameter::clear_aspect_ratio() {
aspect_ratio_.Clear();
}
inline float PriorBoxParameter::_internal_aspect_ratio(int index) const {
return aspect_ratio_.Get(index);
}
inline float PriorBoxParameter::aspect_ratio(int index) const {
// @@protoc_insertion_point(field_get:caffe.PriorBoxParameter.aspect_ratio)
return _internal_aspect_ratio(index);
}
inline void PriorBoxParameter::set_aspect_ratio(int index, float value) {
aspect_ratio_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.PriorBoxParameter.aspect_ratio)
}
inline void PriorBoxParameter::_internal_add_aspect_ratio(float value) {
aspect_ratio_.Add(value);
}
inline void PriorBoxParameter::add_aspect_ratio(float value) {
_internal_add_aspect_ratio(value);
// @@protoc_insertion_point(field_add:caffe.PriorBoxParameter.aspect_ratio)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
PriorBoxParameter::_internal_aspect_ratio() const {
return aspect_ratio_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
PriorBoxParameter::aspect_ratio() const {
// @@protoc_insertion_point(field_list:caffe.PriorBoxParameter.aspect_ratio)
return _internal_aspect_ratio();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
PriorBoxParameter::_internal_mutable_aspect_ratio() {
return &aspect_ratio_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
PriorBoxParameter::mutable_aspect_ratio() {
// @@protoc_insertion_point(field_mutable_list:caffe.PriorBoxParameter.aspect_ratio)
return _internal_mutable_aspect_ratio();
}
// optional bool flip = 4 [default = true];
inline bool PriorBoxParameter::_internal_has_flip() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool PriorBoxParameter::has_flip() const {
return _internal_has_flip();
}
inline void PriorBoxParameter::clear_flip() {
flip_ = true;
_has_bits_[0] &= ~0x00000004u;
}
inline bool PriorBoxParameter::_internal_flip() const {
return flip_;
}
inline bool PriorBoxParameter::flip() const {
// @@protoc_insertion_point(field_get:caffe.PriorBoxParameter.flip)
return _internal_flip();
}
inline void PriorBoxParameter::_internal_set_flip(bool value) {
_has_bits_[0] |= 0x00000004u;
flip_ = value;
}
inline void PriorBoxParameter::set_flip(bool value) {
_internal_set_flip(value);
// @@protoc_insertion_point(field_set:caffe.PriorBoxParameter.flip)
}
// optional bool clip = 5 [default = true];
inline bool PriorBoxParameter::_internal_has_clip() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool PriorBoxParameter::has_clip() const {
return _internal_has_clip();
}
inline void PriorBoxParameter::clear_clip() {
clip_ = true;
_has_bits_[0] &= ~0x00000008u;
}
inline bool PriorBoxParameter::_internal_clip() const {
return clip_;
}
inline bool PriorBoxParameter::clip() const {
// @@protoc_insertion_point(field_get:caffe.PriorBoxParameter.clip)
return _internal_clip();
}
inline void PriorBoxParameter::_internal_set_clip(bool value) {
_has_bits_[0] |= 0x00000008u;
clip_ = value;
}
inline void PriorBoxParameter::set_clip(bool value) {
_internal_set_clip(value);
// @@protoc_insertion_point(field_set:caffe.PriorBoxParameter.clip)
}
// repeated float variance = 6;
inline int PriorBoxParameter::_internal_variance_size() const {
return variance_.size();
}
inline int PriorBoxParameter::variance_size() const {
return _internal_variance_size();
}
inline void PriorBoxParameter::clear_variance() {
variance_.Clear();
}
inline float PriorBoxParameter::_internal_variance(int index) const {
return variance_.Get(index);
}
inline float PriorBoxParameter::variance(int index) const {
// @@protoc_insertion_point(field_get:caffe.PriorBoxParameter.variance)
return _internal_variance(index);
}
inline void PriorBoxParameter::set_variance(int index, float value) {
variance_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.PriorBoxParameter.variance)
}
inline void PriorBoxParameter::_internal_add_variance(float value) {
variance_.Add(value);
}
inline void PriorBoxParameter::add_variance(float value) {
_internal_add_variance(value);
// @@protoc_insertion_point(field_add:caffe.PriorBoxParameter.variance)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
PriorBoxParameter::_internal_variance() const {
return variance_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
PriorBoxParameter::variance() const {
// @@protoc_insertion_point(field_list:caffe.PriorBoxParameter.variance)
return _internal_variance();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
PriorBoxParameter::_internal_mutable_variance() {
return &variance_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
PriorBoxParameter::mutable_variance() {
// @@protoc_insertion_point(field_mutable_list:caffe.PriorBoxParameter.variance)
return _internal_mutable_variance();
}
// -------------------------------------------------------------------
// PythonParameter
// optional string module = 1;
inline bool PythonParameter::_internal_has_module() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool PythonParameter::has_module() const {
return _internal_has_module();
}
inline void PythonParameter::clear_module() {
module_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000001u;
}
inline const std::string& PythonParameter::module() const {
// @@protoc_insertion_point(field_get:caffe.PythonParameter.module)
return _internal_module();
}
inline void PythonParameter::set_module(const std::string& value) {
_internal_set_module(value);
// @@protoc_insertion_point(field_set:caffe.PythonParameter.module)
}
inline std::string* PythonParameter::mutable_module() {
// @@protoc_insertion_point(field_mutable:caffe.PythonParameter.module)
return _internal_mutable_module();
}
inline const std::string& PythonParameter::_internal_module() const {
return module_.Get();
}
inline void PythonParameter::_internal_set_module(const std::string& value) {
_has_bits_[0] |= 0x00000001u;
module_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void PythonParameter::set_module(std::string&& value) {
_has_bits_[0] |= 0x00000001u;
module_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.PythonParameter.module)
}
inline void PythonParameter::set_module(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000001u;
module_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.PythonParameter.module)
}
inline void PythonParameter::set_module(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000001u;
module_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.PythonParameter.module)
}
inline std::string* PythonParameter::_internal_mutable_module() {
_has_bits_[0] |= 0x00000001u;
return module_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* PythonParameter::release_module() {
// @@protoc_insertion_point(field_release:caffe.PythonParameter.module)
if (!_internal_has_module()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000001u;
return module_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void PythonParameter::set_allocated_module(std::string* module) {
if (module != nullptr) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
module_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), module,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.PythonParameter.module)
}
// optional string layer = 2;
inline bool PythonParameter::_internal_has_layer() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool PythonParameter::has_layer() const {
return _internal_has_layer();
}
inline void PythonParameter::clear_layer() {
layer_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000002u;
}
inline const std::string& PythonParameter::layer() const {
// @@protoc_insertion_point(field_get:caffe.PythonParameter.layer)
return _internal_layer();
}
inline void PythonParameter::set_layer(const std::string& value) {
_internal_set_layer(value);
// @@protoc_insertion_point(field_set:caffe.PythonParameter.layer)
}
inline std::string* PythonParameter::mutable_layer() {
// @@protoc_insertion_point(field_mutable:caffe.PythonParameter.layer)
return _internal_mutable_layer();
}
inline const std::string& PythonParameter::_internal_layer() const {
return layer_.Get();
}
inline void PythonParameter::_internal_set_layer(const std::string& value) {
_has_bits_[0] |= 0x00000002u;
layer_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void PythonParameter::set_layer(std::string&& value) {
_has_bits_[0] |= 0x00000002u;
layer_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.PythonParameter.layer)
}
inline void PythonParameter::set_layer(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000002u;
layer_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.PythonParameter.layer)
}
inline void PythonParameter::set_layer(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000002u;
layer_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.PythonParameter.layer)
}
inline std::string* PythonParameter::_internal_mutable_layer() {
_has_bits_[0] |= 0x00000002u;
return layer_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* PythonParameter::release_layer() {
// @@protoc_insertion_point(field_release:caffe.PythonParameter.layer)
if (!_internal_has_layer()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000002u;
return layer_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void PythonParameter::set_allocated_layer(std::string* layer) {
if (layer != nullptr) {
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
layer_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), layer,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.PythonParameter.layer)
}
// optional string param_str = 3 [default = ""];
inline bool PythonParameter::_internal_has_param_str() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool PythonParameter::has_param_str() const {
return _internal_has_param_str();
}
inline void PythonParameter::clear_param_str() {
param_str_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000004u;
}
inline const std::string& PythonParameter::param_str() const {
// @@protoc_insertion_point(field_get:caffe.PythonParameter.param_str)
return _internal_param_str();
}
inline void PythonParameter::set_param_str(const std::string& value) {
_internal_set_param_str(value);
// @@protoc_insertion_point(field_set:caffe.PythonParameter.param_str)
}
inline std::string* PythonParameter::mutable_param_str() {
// @@protoc_insertion_point(field_mutable:caffe.PythonParameter.param_str)
return _internal_mutable_param_str();
}
inline const std::string& PythonParameter::_internal_param_str() const {
return param_str_.Get();
}
inline void PythonParameter::_internal_set_param_str(const std::string& value) {
_has_bits_[0] |= 0x00000004u;
param_str_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void PythonParameter::set_param_str(std::string&& value) {
_has_bits_[0] |= 0x00000004u;
param_str_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.PythonParameter.param_str)
}
inline void PythonParameter::set_param_str(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000004u;
param_str_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.PythonParameter.param_str)
}
inline void PythonParameter::set_param_str(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000004u;
param_str_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.PythonParameter.param_str)
}
inline std::string* PythonParameter::_internal_mutable_param_str() {
_has_bits_[0] |= 0x00000004u;
return param_str_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* PythonParameter::release_param_str() {
// @@protoc_insertion_point(field_release:caffe.PythonParameter.param_str)
if (!_internal_has_param_str()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000004u;
return param_str_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void PythonParameter::set_allocated_param_str(std::string* param_str) {
if (param_str != nullptr) {
_has_bits_[0] |= 0x00000004u;
} else {
_has_bits_[0] &= ~0x00000004u;
}
param_str_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), param_str,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.PythonParameter.param_str)
}
// optional bool share_in_parallel = 4 [default = false];
inline bool PythonParameter::_internal_has_share_in_parallel() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool PythonParameter::has_share_in_parallel() const {
return _internal_has_share_in_parallel();
}
inline void PythonParameter::clear_share_in_parallel() {
share_in_parallel_ = false;
_has_bits_[0] &= ~0x00000008u;
}
inline bool PythonParameter::_internal_share_in_parallel() const {
return share_in_parallel_;
}
inline bool PythonParameter::share_in_parallel() const {
// @@protoc_insertion_point(field_get:caffe.PythonParameter.share_in_parallel)
return _internal_share_in_parallel();
}
inline void PythonParameter::_internal_set_share_in_parallel(bool value) {
_has_bits_[0] |= 0x00000008u;
share_in_parallel_ = value;
}
inline void PythonParameter::set_share_in_parallel(bool value) {
_internal_set_share_in_parallel(value);
// @@protoc_insertion_point(field_set:caffe.PythonParameter.share_in_parallel)
}
// -------------------------------------------------------------------
// RecurrentParameter
// optional uint32 num_output = 1 [default = 0];
inline bool RecurrentParameter::_internal_has_num_output() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool RecurrentParameter::has_num_output() const {
return _internal_has_num_output();
}
inline void RecurrentParameter::clear_num_output() {
num_output_ = 0u;
_has_bits_[0] &= ~0x00000004u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 RecurrentParameter::_internal_num_output() const {
return num_output_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 RecurrentParameter::num_output() const {
// @@protoc_insertion_point(field_get:caffe.RecurrentParameter.num_output)
return _internal_num_output();
}
inline void RecurrentParameter::_internal_set_num_output(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000004u;
num_output_ = value;
}
inline void RecurrentParameter::set_num_output(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_num_output(value);
// @@protoc_insertion_point(field_set:caffe.RecurrentParameter.num_output)
}
// optional .caffe.FillerParameter weight_filler = 2;
inline bool RecurrentParameter::_internal_has_weight_filler() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
PROTOBUF_ASSUME(!value || weight_filler_ != nullptr);
return value;
}
inline bool RecurrentParameter::has_weight_filler() const {
return _internal_has_weight_filler();
}
inline void RecurrentParameter::clear_weight_filler() {
if (weight_filler_ != nullptr) weight_filler_->Clear();
_has_bits_[0] &= ~0x00000001u;
}
inline const ::caffe::FillerParameter& RecurrentParameter::_internal_weight_filler() const {
const ::caffe::FillerParameter* p = weight_filler_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::FillerParameter*>(
&::caffe::_FillerParameter_default_instance_);
}
inline const ::caffe::FillerParameter& RecurrentParameter::weight_filler() const {
// @@protoc_insertion_point(field_get:caffe.RecurrentParameter.weight_filler)
return _internal_weight_filler();
}
inline void RecurrentParameter::unsafe_arena_set_allocated_weight_filler(
::caffe::FillerParameter* weight_filler) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(weight_filler_);
}
weight_filler_ = weight_filler;
if (weight_filler) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.RecurrentParameter.weight_filler)
}
inline ::caffe::FillerParameter* RecurrentParameter::release_weight_filler() {
_has_bits_[0] &= ~0x00000001u;
::caffe::FillerParameter* temp = weight_filler_;
weight_filler_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::FillerParameter* RecurrentParameter::unsafe_arena_release_weight_filler() {
// @@protoc_insertion_point(field_release:caffe.RecurrentParameter.weight_filler)
_has_bits_[0] &= ~0x00000001u;
::caffe::FillerParameter* temp = weight_filler_;
weight_filler_ = nullptr;
return temp;
}
inline ::caffe::FillerParameter* RecurrentParameter::_internal_mutable_weight_filler() {
_has_bits_[0] |= 0x00000001u;
if (weight_filler_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::FillerParameter>(GetArena());
weight_filler_ = p;
}
return weight_filler_;
}
inline ::caffe::FillerParameter* RecurrentParameter::mutable_weight_filler() {
// @@protoc_insertion_point(field_mutable:caffe.RecurrentParameter.weight_filler)
return _internal_mutable_weight_filler();
}
inline void RecurrentParameter::set_allocated_weight_filler(::caffe::FillerParameter* weight_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete weight_filler_;
}
if (weight_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(weight_filler);
if (message_arena != submessage_arena) {
weight_filler = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, weight_filler, submessage_arena);
}
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
weight_filler_ = weight_filler;
// @@protoc_insertion_point(field_set_allocated:caffe.RecurrentParameter.weight_filler)
}
// optional .caffe.FillerParameter bias_filler = 3;
inline bool RecurrentParameter::_internal_has_bias_filler() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
PROTOBUF_ASSUME(!value || bias_filler_ != nullptr);
return value;
}
inline bool RecurrentParameter::has_bias_filler() const {
return _internal_has_bias_filler();
}
inline void RecurrentParameter::clear_bias_filler() {
if (bias_filler_ != nullptr) bias_filler_->Clear();
_has_bits_[0] &= ~0x00000002u;
}
inline const ::caffe::FillerParameter& RecurrentParameter::_internal_bias_filler() const {
const ::caffe::FillerParameter* p = bias_filler_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::FillerParameter*>(
&::caffe::_FillerParameter_default_instance_);
}
inline const ::caffe::FillerParameter& RecurrentParameter::bias_filler() const {
// @@protoc_insertion_point(field_get:caffe.RecurrentParameter.bias_filler)
return _internal_bias_filler();
}
inline void RecurrentParameter::unsafe_arena_set_allocated_bias_filler(
::caffe::FillerParameter* bias_filler) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(bias_filler_);
}
bias_filler_ = bias_filler;
if (bias_filler) {
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.RecurrentParameter.bias_filler)
}
inline ::caffe::FillerParameter* RecurrentParameter::release_bias_filler() {
_has_bits_[0] &= ~0x00000002u;
::caffe::FillerParameter* temp = bias_filler_;
bias_filler_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::FillerParameter* RecurrentParameter::unsafe_arena_release_bias_filler() {
// @@protoc_insertion_point(field_release:caffe.RecurrentParameter.bias_filler)
_has_bits_[0] &= ~0x00000002u;
::caffe::FillerParameter* temp = bias_filler_;
bias_filler_ = nullptr;
return temp;
}
inline ::caffe::FillerParameter* RecurrentParameter::_internal_mutable_bias_filler() {
_has_bits_[0] |= 0x00000002u;
if (bias_filler_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::FillerParameter>(GetArena());
bias_filler_ = p;
}
return bias_filler_;
}
inline ::caffe::FillerParameter* RecurrentParameter::mutable_bias_filler() {
// @@protoc_insertion_point(field_mutable:caffe.RecurrentParameter.bias_filler)
return _internal_mutable_bias_filler();
}
inline void RecurrentParameter::set_allocated_bias_filler(::caffe::FillerParameter* bias_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete bias_filler_;
}
if (bias_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(bias_filler);
if (message_arena != submessage_arena) {
bias_filler = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, bias_filler, submessage_arena);
}
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
bias_filler_ = bias_filler;
// @@protoc_insertion_point(field_set_allocated:caffe.RecurrentParameter.bias_filler)
}
// optional bool debug_info = 4 [default = false];
inline bool RecurrentParameter::_internal_has_debug_info() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool RecurrentParameter::has_debug_info() const {
return _internal_has_debug_info();
}
inline void RecurrentParameter::clear_debug_info() {
debug_info_ = false;
_has_bits_[0] &= ~0x00000008u;
}
inline bool RecurrentParameter::_internal_debug_info() const {
return debug_info_;
}
inline bool RecurrentParameter::debug_info() const {
// @@protoc_insertion_point(field_get:caffe.RecurrentParameter.debug_info)
return _internal_debug_info();
}
inline void RecurrentParameter::_internal_set_debug_info(bool value) {
_has_bits_[0] |= 0x00000008u;
debug_info_ = value;
}
inline void RecurrentParameter::set_debug_info(bool value) {
_internal_set_debug_info(value);
// @@protoc_insertion_point(field_set:caffe.RecurrentParameter.debug_info)
}
// optional bool expose_hidden = 5 [default = false];
inline bool RecurrentParameter::_internal_has_expose_hidden() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool RecurrentParameter::has_expose_hidden() const {
return _internal_has_expose_hidden();
}
inline void RecurrentParameter::clear_expose_hidden() {
expose_hidden_ = false;
_has_bits_[0] &= ~0x00000010u;
}
inline bool RecurrentParameter::_internal_expose_hidden() const {
return expose_hidden_;
}
inline bool RecurrentParameter::expose_hidden() const {
// @@protoc_insertion_point(field_get:caffe.RecurrentParameter.expose_hidden)
return _internal_expose_hidden();
}
inline void RecurrentParameter::_internal_set_expose_hidden(bool value) {
_has_bits_[0] |= 0x00000010u;
expose_hidden_ = value;
}
inline void RecurrentParameter::set_expose_hidden(bool value) {
_internal_set_expose_hidden(value);
// @@protoc_insertion_point(field_set:caffe.RecurrentParameter.expose_hidden)
}
// -------------------------------------------------------------------
// ReductionParameter
// optional .caffe.ReductionParameter.ReductionOp operation = 1 [default = SUM];
inline bool ReductionParameter::_internal_has_operation() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool ReductionParameter::has_operation() const {
return _internal_has_operation();
}
inline void ReductionParameter::clear_operation() {
operation_ = 1;
_has_bits_[0] &= ~0x00000002u;
}
inline ::caffe::ReductionParameter_ReductionOp ReductionParameter::_internal_operation() const {
return static_cast< ::caffe::ReductionParameter_ReductionOp >(operation_);
}
inline ::caffe::ReductionParameter_ReductionOp ReductionParameter::operation() const {
// @@protoc_insertion_point(field_get:caffe.ReductionParameter.operation)
return _internal_operation();
}
inline void ReductionParameter::_internal_set_operation(::caffe::ReductionParameter_ReductionOp value) {
assert(::caffe::ReductionParameter_ReductionOp_IsValid(value));
_has_bits_[0] |= 0x00000002u;
operation_ = value;
}
inline void ReductionParameter::set_operation(::caffe::ReductionParameter_ReductionOp value) {
_internal_set_operation(value);
// @@protoc_insertion_point(field_set:caffe.ReductionParameter.operation)
}
// optional int32 axis = 2 [default = 0];
inline bool ReductionParameter::_internal_has_axis() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool ReductionParameter::has_axis() const {
return _internal_has_axis();
}
inline void ReductionParameter::clear_axis() {
axis_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 ReductionParameter::_internal_axis() const {
return axis_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 ReductionParameter::axis() const {
// @@protoc_insertion_point(field_get:caffe.ReductionParameter.axis)
return _internal_axis();
}
inline void ReductionParameter::_internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000001u;
axis_ = value;
}
inline void ReductionParameter::set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_axis(value);
// @@protoc_insertion_point(field_set:caffe.ReductionParameter.axis)
}
// optional float coeff = 3 [default = 1];
inline bool ReductionParameter::_internal_has_coeff() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool ReductionParameter::has_coeff() const {
return _internal_has_coeff();
}
inline void ReductionParameter::clear_coeff() {
coeff_ = 1;
_has_bits_[0] &= ~0x00000004u;
}
inline float ReductionParameter::_internal_coeff() const {
return coeff_;
}
inline float ReductionParameter::coeff() const {
// @@protoc_insertion_point(field_get:caffe.ReductionParameter.coeff)
return _internal_coeff();
}
inline void ReductionParameter::_internal_set_coeff(float value) {
_has_bits_[0] |= 0x00000004u;
coeff_ = value;
}
inline void ReductionParameter::set_coeff(float value) {
_internal_set_coeff(value);
// @@protoc_insertion_point(field_set:caffe.ReductionParameter.coeff)
}
// -------------------------------------------------------------------
// ReLUParameter
// optional float negative_slope = 1 [default = 0];
inline bool ReLUParameter::_internal_has_negative_slope() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool ReLUParameter::has_negative_slope() const {
return _internal_has_negative_slope();
}
inline void ReLUParameter::clear_negative_slope() {
negative_slope_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline float ReLUParameter::_internal_negative_slope() const {
return negative_slope_;
}
inline float ReLUParameter::negative_slope() const {
// @@protoc_insertion_point(field_get:caffe.ReLUParameter.negative_slope)
return _internal_negative_slope();
}
inline void ReLUParameter::_internal_set_negative_slope(float value) {
_has_bits_[0] |= 0x00000001u;
negative_slope_ = value;
}
inline void ReLUParameter::set_negative_slope(float value) {
_internal_set_negative_slope(value);
// @@protoc_insertion_point(field_set:caffe.ReLUParameter.negative_slope)
}
// optional .caffe.ReLUParameter.Engine engine = 2 [default = DEFAULT];
inline bool ReLUParameter::_internal_has_engine() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool ReLUParameter::has_engine() const {
return _internal_has_engine();
}
inline void ReLUParameter::clear_engine() {
engine_ = 0;
_has_bits_[0] &= ~0x00000002u;
}
inline ::caffe::ReLUParameter_Engine ReLUParameter::_internal_engine() const {
return static_cast< ::caffe::ReLUParameter_Engine >(engine_);
}
inline ::caffe::ReLUParameter_Engine ReLUParameter::engine() const {
// @@protoc_insertion_point(field_get:caffe.ReLUParameter.engine)
return _internal_engine();
}
inline void ReLUParameter::_internal_set_engine(::caffe::ReLUParameter_Engine value) {
assert(::caffe::ReLUParameter_Engine_IsValid(value));
_has_bits_[0] |= 0x00000002u;
engine_ = value;
}
inline void ReLUParameter::set_engine(::caffe::ReLUParameter_Engine value) {
_internal_set_engine(value);
// @@protoc_insertion_point(field_set:caffe.ReLUParameter.engine)
}
// -------------------------------------------------------------------
// ReshapeParameter
// optional .caffe.BlobShape shape = 1;
inline bool ReshapeParameter::_internal_has_shape() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
PROTOBUF_ASSUME(!value || shape_ != nullptr);
return value;
}
inline bool ReshapeParameter::has_shape() const {
return _internal_has_shape();
}
inline void ReshapeParameter::clear_shape() {
if (shape_ != nullptr) shape_->Clear();
_has_bits_[0] &= ~0x00000001u;
}
inline const ::caffe::BlobShape& ReshapeParameter::_internal_shape() const {
const ::caffe::BlobShape* p = shape_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::BlobShape*>(
&::caffe::_BlobShape_default_instance_);
}
inline const ::caffe::BlobShape& ReshapeParameter::shape() const {
// @@protoc_insertion_point(field_get:caffe.ReshapeParameter.shape)
return _internal_shape();
}
inline void ReshapeParameter::unsafe_arena_set_allocated_shape(
::caffe::BlobShape* shape) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(shape_);
}
shape_ = shape;
if (shape) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.ReshapeParameter.shape)
}
inline ::caffe::BlobShape* ReshapeParameter::release_shape() {
_has_bits_[0] &= ~0x00000001u;
::caffe::BlobShape* temp = shape_;
shape_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::BlobShape* ReshapeParameter::unsafe_arena_release_shape() {
// @@protoc_insertion_point(field_release:caffe.ReshapeParameter.shape)
_has_bits_[0] &= ~0x00000001u;
::caffe::BlobShape* temp = shape_;
shape_ = nullptr;
return temp;
}
inline ::caffe::BlobShape* ReshapeParameter::_internal_mutable_shape() {
_has_bits_[0] |= 0x00000001u;
if (shape_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::BlobShape>(GetArena());
shape_ = p;
}
return shape_;
}
inline ::caffe::BlobShape* ReshapeParameter::mutable_shape() {
// @@protoc_insertion_point(field_mutable:caffe.ReshapeParameter.shape)
return _internal_mutable_shape();
}
inline void ReshapeParameter::set_allocated_shape(::caffe::BlobShape* shape) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete shape_;
}
if (shape) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(shape);
if (message_arena != submessage_arena) {
shape = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, shape, submessage_arena);
}
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
shape_ = shape;
// @@protoc_insertion_point(field_set_allocated:caffe.ReshapeParameter.shape)
}
// optional int32 axis = 2 [default = 0];
inline bool ReshapeParameter::_internal_has_axis() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool ReshapeParameter::has_axis() const {
return _internal_has_axis();
}
inline void ReshapeParameter::clear_axis() {
axis_ = 0;
_has_bits_[0] &= ~0x00000002u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 ReshapeParameter::_internal_axis() const {
return axis_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 ReshapeParameter::axis() const {
// @@protoc_insertion_point(field_get:caffe.ReshapeParameter.axis)
return _internal_axis();
}
inline void ReshapeParameter::_internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000002u;
axis_ = value;
}
inline void ReshapeParameter::set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_axis(value);
// @@protoc_insertion_point(field_set:caffe.ReshapeParameter.axis)
}
// optional int32 num_axes = 3 [default = -1];
inline bool ReshapeParameter::_internal_has_num_axes() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool ReshapeParameter::has_num_axes() const {
return _internal_has_num_axes();
}
inline void ReshapeParameter::clear_num_axes() {
num_axes_ = -1;
_has_bits_[0] &= ~0x00000004u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 ReshapeParameter::_internal_num_axes() const {
return num_axes_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 ReshapeParameter::num_axes() const {
// @@protoc_insertion_point(field_get:caffe.ReshapeParameter.num_axes)
return _internal_num_axes();
}
inline void ReshapeParameter::_internal_set_num_axes(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000004u;
num_axes_ = value;
}
inline void ReshapeParameter::set_num_axes(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_num_axes(value);
// @@protoc_insertion_point(field_set:caffe.ReshapeParameter.num_axes)
}
// -------------------------------------------------------------------
// ROIPoolingParameter
// optional uint32 pooled_h = 1 [default = 0];
inline bool ROIPoolingParameter::_internal_has_pooled_h() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool ROIPoolingParameter::has_pooled_h() const {
return _internal_has_pooled_h();
}
inline void ROIPoolingParameter::clear_pooled_h() {
pooled_h_ = 0u;
_has_bits_[0] &= ~0x00000001u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ROIPoolingParameter::_internal_pooled_h() const {
return pooled_h_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ROIPoolingParameter::pooled_h() const {
// @@protoc_insertion_point(field_get:caffe.ROIPoolingParameter.pooled_h)
return _internal_pooled_h();
}
inline void ROIPoolingParameter::_internal_set_pooled_h(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000001u;
pooled_h_ = value;
}
inline void ROIPoolingParameter::set_pooled_h(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_pooled_h(value);
// @@protoc_insertion_point(field_set:caffe.ROIPoolingParameter.pooled_h)
}
// optional uint32 pooled_w = 2 [default = 0];
inline bool ROIPoolingParameter::_internal_has_pooled_w() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool ROIPoolingParameter::has_pooled_w() const {
return _internal_has_pooled_w();
}
inline void ROIPoolingParameter::clear_pooled_w() {
pooled_w_ = 0u;
_has_bits_[0] &= ~0x00000002u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ROIPoolingParameter::_internal_pooled_w() const {
return pooled_w_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 ROIPoolingParameter::pooled_w() const {
// @@protoc_insertion_point(field_get:caffe.ROIPoolingParameter.pooled_w)
return _internal_pooled_w();
}
inline void ROIPoolingParameter::_internal_set_pooled_w(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000002u;
pooled_w_ = value;
}
inline void ROIPoolingParameter::set_pooled_w(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_pooled_w(value);
// @@protoc_insertion_point(field_set:caffe.ROIPoolingParameter.pooled_w)
}
// optional float spatial_scale = 3 [default = 1];
inline bool ROIPoolingParameter::_internal_has_spatial_scale() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool ROIPoolingParameter::has_spatial_scale() const {
return _internal_has_spatial_scale();
}
inline void ROIPoolingParameter::clear_spatial_scale() {
spatial_scale_ = 1;
_has_bits_[0] &= ~0x00000004u;
}
inline float ROIPoolingParameter::_internal_spatial_scale() const {
return spatial_scale_;
}
inline float ROIPoolingParameter::spatial_scale() const {
// @@protoc_insertion_point(field_get:caffe.ROIPoolingParameter.spatial_scale)
return _internal_spatial_scale();
}
inline void ROIPoolingParameter::_internal_set_spatial_scale(float value) {
_has_bits_[0] |= 0x00000004u;
spatial_scale_ = value;
}
inline void ROIPoolingParameter::set_spatial_scale(float value) {
_internal_set_spatial_scale(value);
// @@protoc_insertion_point(field_set:caffe.ROIPoolingParameter.spatial_scale)
}
// -------------------------------------------------------------------
// ScaleParameter
// optional int32 axis = 1 [default = 1];
inline bool ScaleParameter::_internal_has_axis() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool ScaleParameter::has_axis() const {
return _internal_has_axis();
}
inline void ScaleParameter::clear_axis() {
axis_ = 1;
_has_bits_[0] &= ~0x00000008u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 ScaleParameter::_internal_axis() const {
return axis_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 ScaleParameter::axis() const {
// @@protoc_insertion_point(field_get:caffe.ScaleParameter.axis)
return _internal_axis();
}
inline void ScaleParameter::_internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000008u;
axis_ = value;
}
inline void ScaleParameter::set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_axis(value);
// @@protoc_insertion_point(field_set:caffe.ScaleParameter.axis)
}
// optional int32 num_axes = 2 [default = 1];
inline bool ScaleParameter::_internal_has_num_axes() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool ScaleParameter::has_num_axes() const {
return _internal_has_num_axes();
}
inline void ScaleParameter::clear_num_axes() {
num_axes_ = 1;
_has_bits_[0] &= ~0x00000010u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 ScaleParameter::_internal_num_axes() const {
return num_axes_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 ScaleParameter::num_axes() const {
// @@protoc_insertion_point(field_get:caffe.ScaleParameter.num_axes)
return _internal_num_axes();
}
inline void ScaleParameter::_internal_set_num_axes(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000010u;
num_axes_ = value;
}
inline void ScaleParameter::set_num_axes(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_num_axes(value);
// @@protoc_insertion_point(field_set:caffe.ScaleParameter.num_axes)
}
// optional .caffe.FillerParameter filler = 3;
inline bool ScaleParameter::_internal_has_filler() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
PROTOBUF_ASSUME(!value || filler_ != nullptr);
return value;
}
inline bool ScaleParameter::has_filler() const {
return _internal_has_filler();
}
inline void ScaleParameter::clear_filler() {
if (filler_ != nullptr) filler_->Clear();
_has_bits_[0] &= ~0x00000001u;
}
inline const ::caffe::FillerParameter& ScaleParameter::_internal_filler() const {
const ::caffe::FillerParameter* p = filler_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::FillerParameter*>(
&::caffe::_FillerParameter_default_instance_);
}
inline const ::caffe::FillerParameter& ScaleParameter::filler() const {
// @@protoc_insertion_point(field_get:caffe.ScaleParameter.filler)
return _internal_filler();
}
inline void ScaleParameter::unsafe_arena_set_allocated_filler(
::caffe::FillerParameter* filler) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(filler_);
}
filler_ = filler;
if (filler) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.ScaleParameter.filler)
}
inline ::caffe::FillerParameter* ScaleParameter::release_filler() {
_has_bits_[0] &= ~0x00000001u;
::caffe::FillerParameter* temp = filler_;
filler_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::FillerParameter* ScaleParameter::unsafe_arena_release_filler() {
// @@protoc_insertion_point(field_release:caffe.ScaleParameter.filler)
_has_bits_[0] &= ~0x00000001u;
::caffe::FillerParameter* temp = filler_;
filler_ = nullptr;
return temp;
}
inline ::caffe::FillerParameter* ScaleParameter::_internal_mutable_filler() {
_has_bits_[0] |= 0x00000001u;
if (filler_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::FillerParameter>(GetArena());
filler_ = p;
}
return filler_;
}
inline ::caffe::FillerParameter* ScaleParameter::mutable_filler() {
// @@protoc_insertion_point(field_mutable:caffe.ScaleParameter.filler)
return _internal_mutable_filler();
}
inline void ScaleParameter::set_allocated_filler(::caffe::FillerParameter* filler) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete filler_;
}
if (filler) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(filler);
if (message_arena != submessage_arena) {
filler = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, filler, submessage_arena);
}
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
filler_ = filler;
// @@protoc_insertion_point(field_set_allocated:caffe.ScaleParameter.filler)
}
// optional bool bias_term = 4 [default = false];
inline bool ScaleParameter::_internal_has_bias_term() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool ScaleParameter::has_bias_term() const {
return _internal_has_bias_term();
}
inline void ScaleParameter::clear_bias_term() {
bias_term_ = false;
_has_bits_[0] &= ~0x00000004u;
}
inline bool ScaleParameter::_internal_bias_term() const {
return bias_term_;
}
inline bool ScaleParameter::bias_term() const {
// @@protoc_insertion_point(field_get:caffe.ScaleParameter.bias_term)
return _internal_bias_term();
}
inline void ScaleParameter::_internal_set_bias_term(bool value) {
_has_bits_[0] |= 0x00000004u;
bias_term_ = value;
}
inline void ScaleParameter::set_bias_term(bool value) {
_internal_set_bias_term(value);
// @@protoc_insertion_point(field_set:caffe.ScaleParameter.bias_term)
}
// optional .caffe.FillerParameter bias_filler = 5;
inline bool ScaleParameter::_internal_has_bias_filler() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
PROTOBUF_ASSUME(!value || bias_filler_ != nullptr);
return value;
}
inline bool ScaleParameter::has_bias_filler() const {
return _internal_has_bias_filler();
}
inline void ScaleParameter::clear_bias_filler() {
if (bias_filler_ != nullptr) bias_filler_->Clear();
_has_bits_[0] &= ~0x00000002u;
}
inline const ::caffe::FillerParameter& ScaleParameter::_internal_bias_filler() const {
const ::caffe::FillerParameter* p = bias_filler_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::FillerParameter*>(
&::caffe::_FillerParameter_default_instance_);
}
inline const ::caffe::FillerParameter& ScaleParameter::bias_filler() const {
// @@protoc_insertion_point(field_get:caffe.ScaleParameter.bias_filler)
return _internal_bias_filler();
}
inline void ScaleParameter::unsafe_arena_set_allocated_bias_filler(
::caffe::FillerParameter* bias_filler) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(bias_filler_);
}
bias_filler_ = bias_filler;
if (bias_filler) {
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.ScaleParameter.bias_filler)
}
inline ::caffe::FillerParameter* ScaleParameter::release_bias_filler() {
_has_bits_[0] &= ~0x00000002u;
::caffe::FillerParameter* temp = bias_filler_;
bias_filler_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::FillerParameter* ScaleParameter::unsafe_arena_release_bias_filler() {
// @@protoc_insertion_point(field_release:caffe.ScaleParameter.bias_filler)
_has_bits_[0] &= ~0x00000002u;
::caffe::FillerParameter* temp = bias_filler_;
bias_filler_ = nullptr;
return temp;
}
inline ::caffe::FillerParameter* ScaleParameter::_internal_mutable_bias_filler() {
_has_bits_[0] |= 0x00000002u;
if (bias_filler_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::FillerParameter>(GetArena());
bias_filler_ = p;
}
return bias_filler_;
}
inline ::caffe::FillerParameter* ScaleParameter::mutable_bias_filler() {
// @@protoc_insertion_point(field_mutable:caffe.ScaleParameter.bias_filler)
return _internal_mutable_bias_filler();
}
inline void ScaleParameter::set_allocated_bias_filler(::caffe::FillerParameter* bias_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete bias_filler_;
}
if (bias_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(bias_filler);
if (message_arena != submessage_arena) {
bias_filler = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, bias_filler, submessage_arena);
}
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
bias_filler_ = bias_filler;
// @@protoc_insertion_point(field_set_allocated:caffe.ScaleParameter.bias_filler)
}
// -------------------------------------------------------------------
// SigmoidParameter
// optional .caffe.SigmoidParameter.Engine engine = 1 [default = DEFAULT];
inline bool SigmoidParameter::_internal_has_engine() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool SigmoidParameter::has_engine() const {
return _internal_has_engine();
}
inline void SigmoidParameter::clear_engine() {
engine_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline ::caffe::SigmoidParameter_Engine SigmoidParameter::_internal_engine() const {
return static_cast< ::caffe::SigmoidParameter_Engine >(engine_);
}
inline ::caffe::SigmoidParameter_Engine SigmoidParameter::engine() const {
// @@protoc_insertion_point(field_get:caffe.SigmoidParameter.engine)
return _internal_engine();
}
inline void SigmoidParameter::_internal_set_engine(::caffe::SigmoidParameter_Engine value) {
assert(::caffe::SigmoidParameter_Engine_IsValid(value));
_has_bits_[0] |= 0x00000001u;
engine_ = value;
}
inline void SigmoidParameter::set_engine(::caffe::SigmoidParameter_Engine value) {
_internal_set_engine(value);
// @@protoc_insertion_point(field_set:caffe.SigmoidParameter.engine)
}
// -------------------------------------------------------------------
// SliceParameter
// optional int32 axis = 3 [default = 1];
inline bool SliceParameter::_internal_has_axis() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool SliceParameter::has_axis() const {
return _internal_has_axis();
}
inline void SliceParameter::clear_axis() {
axis_ = 1;
_has_bits_[0] &= ~0x00000002u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SliceParameter::_internal_axis() const {
return axis_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SliceParameter::axis() const {
// @@protoc_insertion_point(field_get:caffe.SliceParameter.axis)
return _internal_axis();
}
inline void SliceParameter::_internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000002u;
axis_ = value;
}
inline void SliceParameter::set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_axis(value);
// @@protoc_insertion_point(field_set:caffe.SliceParameter.axis)
}
// repeated uint32 slice_point = 2;
inline int SliceParameter::_internal_slice_point_size() const {
return slice_point_.size();
}
inline int SliceParameter::slice_point_size() const {
return _internal_slice_point_size();
}
inline void SliceParameter::clear_slice_point() {
slice_point_.Clear();
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 SliceParameter::_internal_slice_point(int index) const {
return slice_point_.Get(index);
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 SliceParameter::slice_point(int index) const {
// @@protoc_insertion_point(field_get:caffe.SliceParameter.slice_point)
return _internal_slice_point(index);
}
inline void SliceParameter::set_slice_point(int index, ::PROTOBUF_NAMESPACE_ID::uint32 value) {
slice_point_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.SliceParameter.slice_point)
}
inline void SliceParameter::_internal_add_slice_point(::PROTOBUF_NAMESPACE_ID::uint32 value) {
slice_point_.Add(value);
}
inline void SliceParameter::add_slice_point(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_add_slice_point(value);
// @@protoc_insertion_point(field_add:caffe.SliceParameter.slice_point)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
SliceParameter::_internal_slice_point() const {
return slice_point_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >&
SliceParameter::slice_point() const {
// @@protoc_insertion_point(field_list:caffe.SliceParameter.slice_point)
return _internal_slice_point();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
SliceParameter::_internal_mutable_slice_point() {
return &slice_point_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::PROTOBUF_NAMESPACE_ID::uint32 >*
SliceParameter::mutable_slice_point() {
// @@protoc_insertion_point(field_mutable_list:caffe.SliceParameter.slice_point)
return _internal_mutable_slice_point();
}
// optional uint32 slice_dim = 1 [default = 1];
inline bool SliceParameter::_internal_has_slice_dim() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool SliceParameter::has_slice_dim() const {
return _internal_has_slice_dim();
}
inline void SliceParameter::clear_slice_dim() {
slice_dim_ = 1u;
_has_bits_[0] &= ~0x00000001u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 SliceParameter::_internal_slice_dim() const {
return slice_dim_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 SliceParameter::slice_dim() const {
// @@protoc_insertion_point(field_get:caffe.SliceParameter.slice_dim)
return _internal_slice_dim();
}
inline void SliceParameter::_internal_set_slice_dim(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000001u;
slice_dim_ = value;
}
inline void SliceParameter::set_slice_dim(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_slice_dim(value);
// @@protoc_insertion_point(field_set:caffe.SliceParameter.slice_dim)
}
// -------------------------------------------------------------------
// SmoothL1LossParameter
// optional float sigma = 1 [default = 1];
inline bool SmoothL1LossParameter::_internal_has_sigma() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool SmoothL1LossParameter::has_sigma() const {
return _internal_has_sigma();
}
inline void SmoothL1LossParameter::clear_sigma() {
sigma_ = 1;
_has_bits_[0] &= ~0x00000001u;
}
inline float SmoothL1LossParameter::_internal_sigma() const {
return sigma_;
}
inline float SmoothL1LossParameter::sigma() const {
// @@protoc_insertion_point(field_get:caffe.SmoothL1LossParameter.sigma)
return _internal_sigma();
}
inline void SmoothL1LossParameter::_internal_set_sigma(float value) {
_has_bits_[0] |= 0x00000001u;
sigma_ = value;
}
inline void SmoothL1LossParameter::set_sigma(float value) {
_internal_set_sigma(value);
// @@protoc_insertion_point(field_set:caffe.SmoothL1LossParameter.sigma)
}
// -------------------------------------------------------------------
// SoftmaxParameter
// optional .caffe.SoftmaxParameter.Engine engine = 1 [default = DEFAULT];
inline bool SoftmaxParameter::_internal_has_engine() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool SoftmaxParameter::has_engine() const {
return _internal_has_engine();
}
inline void SoftmaxParameter::clear_engine() {
engine_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline ::caffe::SoftmaxParameter_Engine SoftmaxParameter::_internal_engine() const {
return static_cast< ::caffe::SoftmaxParameter_Engine >(engine_);
}
inline ::caffe::SoftmaxParameter_Engine SoftmaxParameter::engine() const {
// @@protoc_insertion_point(field_get:caffe.SoftmaxParameter.engine)
return _internal_engine();
}
inline void SoftmaxParameter::_internal_set_engine(::caffe::SoftmaxParameter_Engine value) {
assert(::caffe::SoftmaxParameter_Engine_IsValid(value));
_has_bits_[0] |= 0x00000001u;
engine_ = value;
}
inline void SoftmaxParameter::set_engine(::caffe::SoftmaxParameter_Engine value) {
_internal_set_engine(value);
// @@protoc_insertion_point(field_set:caffe.SoftmaxParameter.engine)
}
// optional int32 axis = 2 [default = 1];
inline bool SoftmaxParameter::_internal_has_axis() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool SoftmaxParameter::has_axis() const {
return _internal_has_axis();
}
inline void SoftmaxParameter::clear_axis() {
axis_ = 1;
_has_bits_[0] &= ~0x00000002u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SoftmaxParameter::_internal_axis() const {
return axis_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 SoftmaxParameter::axis() const {
// @@protoc_insertion_point(field_get:caffe.SoftmaxParameter.axis)
return _internal_axis();
}
inline void SoftmaxParameter::_internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000002u;
axis_ = value;
}
inline void SoftmaxParameter::set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_axis(value);
// @@protoc_insertion_point(field_set:caffe.SoftmaxParameter.axis)
}
// -------------------------------------------------------------------
// TanHParameter
// optional .caffe.TanHParameter.Engine engine = 1 [default = DEFAULT];
inline bool TanHParameter::_internal_has_engine() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool TanHParameter::has_engine() const {
return _internal_has_engine();
}
inline void TanHParameter::clear_engine() {
engine_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline ::caffe::TanHParameter_Engine TanHParameter::_internal_engine() const {
return static_cast< ::caffe::TanHParameter_Engine >(engine_);
}
inline ::caffe::TanHParameter_Engine TanHParameter::engine() const {
// @@protoc_insertion_point(field_get:caffe.TanHParameter.engine)
return _internal_engine();
}
inline void TanHParameter::_internal_set_engine(::caffe::TanHParameter_Engine value) {
assert(::caffe::TanHParameter_Engine_IsValid(value));
_has_bits_[0] |= 0x00000001u;
engine_ = value;
}
inline void TanHParameter::set_engine(::caffe::TanHParameter_Engine value) {
_internal_set_engine(value);
// @@protoc_insertion_point(field_set:caffe.TanHParameter.engine)
}
// -------------------------------------------------------------------
// TileParameter
// optional int32 axis = 1 [default = 1];
inline bool TileParameter::_internal_has_axis() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool TileParameter::has_axis() const {
return _internal_has_axis();
}
inline void TileParameter::clear_axis() {
axis_ = 1;
_has_bits_[0] &= ~0x00000002u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 TileParameter::_internal_axis() const {
return axis_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 TileParameter::axis() const {
// @@protoc_insertion_point(field_get:caffe.TileParameter.axis)
return _internal_axis();
}
inline void TileParameter::_internal_set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000002u;
axis_ = value;
}
inline void TileParameter::set_axis(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_axis(value);
// @@protoc_insertion_point(field_set:caffe.TileParameter.axis)
}
// optional int32 tiles = 2;
inline bool TileParameter::_internal_has_tiles() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool TileParameter::has_tiles() const {
return _internal_has_tiles();
}
inline void TileParameter::clear_tiles() {
tiles_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 TileParameter::_internal_tiles() const {
return tiles_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 TileParameter::tiles() const {
// @@protoc_insertion_point(field_get:caffe.TileParameter.tiles)
return _internal_tiles();
}
inline void TileParameter::_internal_set_tiles(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000001u;
tiles_ = value;
}
inline void TileParameter::set_tiles(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_tiles(value);
// @@protoc_insertion_point(field_set:caffe.TileParameter.tiles)
}
// -------------------------------------------------------------------
// ThresholdParameter
// optional float threshold = 1 [default = 0];
inline bool ThresholdParameter::_internal_has_threshold() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool ThresholdParameter::has_threshold() const {
return _internal_has_threshold();
}
inline void ThresholdParameter::clear_threshold() {
threshold_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline float ThresholdParameter::_internal_threshold() const {
return threshold_;
}
inline float ThresholdParameter::threshold() const {
// @@protoc_insertion_point(field_get:caffe.ThresholdParameter.threshold)
return _internal_threshold();
}
inline void ThresholdParameter::_internal_set_threshold(float value) {
_has_bits_[0] |= 0x00000001u;
threshold_ = value;
}
inline void ThresholdParameter::set_threshold(float value) {
_internal_set_threshold(value);
// @@protoc_insertion_point(field_set:caffe.ThresholdParameter.threshold)
}
// -------------------------------------------------------------------
// MILParameter
// optional .caffe.MILParameter.MILType type = 1 [default = MAX];
inline bool MILParameter::_internal_has_type() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool MILParameter::has_type() const {
return _internal_has_type();
}
inline void MILParameter::clear_type() {
type_ = 0;
_has_bits_[0] &= ~0x00000001u;
}
inline ::caffe::MILParameter_MILType MILParameter::_internal_type() const {
return static_cast< ::caffe::MILParameter_MILType >(type_);
}
inline ::caffe::MILParameter_MILType MILParameter::type() const {
// @@protoc_insertion_point(field_get:caffe.MILParameter.type)
return _internal_type();
}
inline void MILParameter::_internal_set_type(::caffe::MILParameter_MILType value) {
assert(::caffe::MILParameter_MILType_IsValid(value));
_has_bits_[0] |= 0x00000001u;
type_ = value;
}
inline void MILParameter::set_type(::caffe::MILParameter_MILType value) {
_internal_set_type(value);
// @@protoc_insertion_point(field_set:caffe.MILParameter.type)
}
// -------------------------------------------------------------------
// VideoDataParameter
// optional .caffe.VideoDataParameter.VideoType video_type = 1 [default = WEBCAM];
inline bool VideoDataParameter::_internal_has_video_type() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool VideoDataParameter::has_video_type() const {
return _internal_has_video_type();
}
inline void VideoDataParameter::clear_video_type() {
video_type_ = 0;
_has_bits_[0] &= ~0x00000002u;
}
inline ::caffe::VideoDataParameter_VideoType VideoDataParameter::_internal_video_type() const {
return static_cast< ::caffe::VideoDataParameter_VideoType >(video_type_);
}
inline ::caffe::VideoDataParameter_VideoType VideoDataParameter::video_type() const {
// @@protoc_insertion_point(field_get:caffe.VideoDataParameter.video_type)
return _internal_video_type();
}
inline void VideoDataParameter::_internal_set_video_type(::caffe::VideoDataParameter_VideoType value) {
assert(::caffe::VideoDataParameter_VideoType_IsValid(value));
_has_bits_[0] |= 0x00000002u;
video_type_ = value;
}
inline void VideoDataParameter::set_video_type(::caffe::VideoDataParameter_VideoType value) {
_internal_set_video_type(value);
// @@protoc_insertion_point(field_set:caffe.VideoDataParameter.video_type)
}
// optional int32 device_id = 2 [default = 0];
inline bool VideoDataParameter::_internal_has_device_id() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool VideoDataParameter::has_device_id() const {
return _internal_has_device_id();
}
inline void VideoDataParameter::clear_device_id() {
device_id_ = 0;
_has_bits_[0] &= ~0x00000004u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 VideoDataParameter::_internal_device_id() const {
return device_id_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 VideoDataParameter::device_id() const {
// @@protoc_insertion_point(field_get:caffe.VideoDataParameter.device_id)
return _internal_device_id();
}
inline void VideoDataParameter::_internal_set_device_id(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00000004u;
device_id_ = value;
}
inline void VideoDataParameter::set_device_id(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_device_id(value);
// @@protoc_insertion_point(field_set:caffe.VideoDataParameter.device_id)
}
// optional string video_file = 3;
inline bool VideoDataParameter::_internal_has_video_file() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool VideoDataParameter::has_video_file() const {
return _internal_has_video_file();
}
inline void VideoDataParameter::clear_video_file() {
video_file_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000001u;
}
inline const std::string& VideoDataParameter::video_file() const {
// @@protoc_insertion_point(field_get:caffe.VideoDataParameter.video_file)
return _internal_video_file();
}
inline void VideoDataParameter::set_video_file(const std::string& value) {
_internal_set_video_file(value);
// @@protoc_insertion_point(field_set:caffe.VideoDataParameter.video_file)
}
inline std::string* VideoDataParameter::mutable_video_file() {
// @@protoc_insertion_point(field_mutable:caffe.VideoDataParameter.video_file)
return _internal_mutable_video_file();
}
inline const std::string& VideoDataParameter::_internal_video_file() const {
return video_file_.Get();
}
inline void VideoDataParameter::_internal_set_video_file(const std::string& value) {
_has_bits_[0] |= 0x00000001u;
video_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void VideoDataParameter::set_video_file(std::string&& value) {
_has_bits_[0] |= 0x00000001u;
video_file_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.VideoDataParameter.video_file)
}
inline void VideoDataParameter::set_video_file(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000001u;
video_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.VideoDataParameter.video_file)
}
inline void VideoDataParameter::set_video_file(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000001u;
video_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.VideoDataParameter.video_file)
}
inline std::string* VideoDataParameter::_internal_mutable_video_file() {
_has_bits_[0] |= 0x00000001u;
return video_file_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* VideoDataParameter::release_video_file() {
// @@protoc_insertion_point(field_release:caffe.VideoDataParameter.video_file)
if (!_internal_has_video_file()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000001u;
return video_file_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void VideoDataParameter::set_allocated_video_file(std::string* video_file) {
if (video_file != nullptr) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
video_file_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), video_file,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.VideoDataParameter.video_file)
}
// -------------------------------------------------------------------
// WindowDataParameter
// optional string source = 1;
inline bool WindowDataParameter::_internal_has_source() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool WindowDataParameter::has_source() const {
return _internal_has_source();
}
inline void WindowDataParameter::clear_source() {
source_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000001u;
}
inline const std::string& WindowDataParameter::source() const {
// @@protoc_insertion_point(field_get:caffe.WindowDataParameter.source)
return _internal_source();
}
inline void WindowDataParameter::set_source(const std::string& value) {
_internal_set_source(value);
// @@protoc_insertion_point(field_set:caffe.WindowDataParameter.source)
}
inline std::string* WindowDataParameter::mutable_source() {
// @@protoc_insertion_point(field_mutable:caffe.WindowDataParameter.source)
return _internal_mutable_source();
}
inline const std::string& WindowDataParameter::_internal_source() const {
return source_.Get();
}
inline void WindowDataParameter::_internal_set_source(const std::string& value) {
_has_bits_[0] |= 0x00000001u;
source_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void WindowDataParameter::set_source(std::string&& value) {
_has_bits_[0] |= 0x00000001u;
source_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.WindowDataParameter.source)
}
inline void WindowDataParameter::set_source(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000001u;
source_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.WindowDataParameter.source)
}
inline void WindowDataParameter::set_source(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000001u;
source_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.WindowDataParameter.source)
}
inline std::string* WindowDataParameter::_internal_mutable_source() {
_has_bits_[0] |= 0x00000001u;
return source_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* WindowDataParameter::release_source() {
// @@protoc_insertion_point(field_release:caffe.WindowDataParameter.source)
if (!_internal_has_source()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000001u;
return source_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void WindowDataParameter::set_allocated_source(std::string* source) {
if (source != nullptr) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
source_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), source,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.WindowDataParameter.source)
}
// optional float scale = 2 [default = 1];
inline bool WindowDataParameter::_internal_has_scale() const {
bool value = (_has_bits_[0] & 0x00000200u) != 0;
return value;
}
inline bool WindowDataParameter::has_scale() const {
return _internal_has_scale();
}
inline void WindowDataParameter::clear_scale() {
scale_ = 1;
_has_bits_[0] &= ~0x00000200u;
}
inline float WindowDataParameter::_internal_scale() const {
return scale_;
}
inline float WindowDataParameter::scale() const {
// @@protoc_insertion_point(field_get:caffe.WindowDataParameter.scale)
return _internal_scale();
}
inline void WindowDataParameter::_internal_set_scale(float value) {
_has_bits_[0] |= 0x00000200u;
scale_ = value;
}
inline void WindowDataParameter::set_scale(float value) {
_internal_set_scale(value);
// @@protoc_insertion_point(field_set:caffe.WindowDataParameter.scale)
}
// optional string mean_file = 3;
inline bool WindowDataParameter::_internal_has_mean_file() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool WindowDataParameter::has_mean_file() const {
return _internal_has_mean_file();
}
inline void WindowDataParameter::clear_mean_file() {
mean_file_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000002u;
}
inline const std::string& WindowDataParameter::mean_file() const {
// @@protoc_insertion_point(field_get:caffe.WindowDataParameter.mean_file)
return _internal_mean_file();
}
inline void WindowDataParameter::set_mean_file(const std::string& value) {
_internal_set_mean_file(value);
// @@protoc_insertion_point(field_set:caffe.WindowDataParameter.mean_file)
}
inline std::string* WindowDataParameter::mutable_mean_file() {
// @@protoc_insertion_point(field_mutable:caffe.WindowDataParameter.mean_file)
return _internal_mutable_mean_file();
}
inline const std::string& WindowDataParameter::_internal_mean_file() const {
return mean_file_.Get();
}
inline void WindowDataParameter::_internal_set_mean_file(const std::string& value) {
_has_bits_[0] |= 0x00000002u;
mean_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void WindowDataParameter::set_mean_file(std::string&& value) {
_has_bits_[0] |= 0x00000002u;
mean_file_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.WindowDataParameter.mean_file)
}
inline void WindowDataParameter::set_mean_file(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000002u;
mean_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.WindowDataParameter.mean_file)
}
inline void WindowDataParameter::set_mean_file(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000002u;
mean_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.WindowDataParameter.mean_file)
}
inline std::string* WindowDataParameter::_internal_mutable_mean_file() {
_has_bits_[0] |= 0x00000002u;
return mean_file_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* WindowDataParameter::release_mean_file() {
// @@protoc_insertion_point(field_release:caffe.WindowDataParameter.mean_file)
if (!_internal_has_mean_file()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000002u;
return mean_file_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void WindowDataParameter::set_allocated_mean_file(std::string* mean_file) {
if (mean_file != nullptr) {
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
mean_file_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), mean_file,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.WindowDataParameter.mean_file)
}
// optional uint32 batch_size = 4;
inline bool WindowDataParameter::_internal_has_batch_size() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool WindowDataParameter::has_batch_size() const {
return _internal_has_batch_size();
}
inline void WindowDataParameter::clear_batch_size() {
batch_size_ = 0u;
_has_bits_[0] &= ~0x00000010u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 WindowDataParameter::_internal_batch_size() const {
return batch_size_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 WindowDataParameter::batch_size() const {
// @@protoc_insertion_point(field_get:caffe.WindowDataParameter.batch_size)
return _internal_batch_size();
}
inline void WindowDataParameter::_internal_set_batch_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000010u;
batch_size_ = value;
}
inline void WindowDataParameter::set_batch_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_batch_size(value);
// @@protoc_insertion_point(field_set:caffe.WindowDataParameter.batch_size)
}
// optional uint32 crop_size = 5 [default = 0];
inline bool WindowDataParameter::_internal_has_crop_size() const {
bool value = (_has_bits_[0] & 0x00000020u) != 0;
return value;
}
inline bool WindowDataParameter::has_crop_size() const {
return _internal_has_crop_size();
}
inline void WindowDataParameter::clear_crop_size() {
crop_size_ = 0u;
_has_bits_[0] &= ~0x00000020u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 WindowDataParameter::_internal_crop_size() const {
return crop_size_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 WindowDataParameter::crop_size() const {
// @@protoc_insertion_point(field_get:caffe.WindowDataParameter.crop_size)
return _internal_crop_size();
}
inline void WindowDataParameter::_internal_set_crop_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000020u;
crop_size_ = value;
}
inline void WindowDataParameter::set_crop_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_crop_size(value);
// @@protoc_insertion_point(field_set:caffe.WindowDataParameter.crop_size)
}
// optional bool mirror = 6 [default = false];
inline bool WindowDataParameter::_internal_has_mirror() const {
bool value = (_has_bits_[0] & 0x00000040u) != 0;
return value;
}
inline bool WindowDataParameter::has_mirror() const {
return _internal_has_mirror();
}
inline void WindowDataParameter::clear_mirror() {
mirror_ = false;
_has_bits_[0] &= ~0x00000040u;
}
inline bool WindowDataParameter::_internal_mirror() const {
return mirror_;
}
inline bool WindowDataParameter::mirror() const {
// @@protoc_insertion_point(field_get:caffe.WindowDataParameter.mirror)
return _internal_mirror();
}
inline void WindowDataParameter::_internal_set_mirror(bool value) {
_has_bits_[0] |= 0x00000040u;
mirror_ = value;
}
inline void WindowDataParameter::set_mirror(bool value) {
_internal_set_mirror(value);
// @@protoc_insertion_point(field_set:caffe.WindowDataParameter.mirror)
}
// optional float fg_threshold = 7 [default = 0.5];
inline bool WindowDataParameter::_internal_has_fg_threshold() const {
bool value = (_has_bits_[0] & 0x00000400u) != 0;
return value;
}
inline bool WindowDataParameter::has_fg_threshold() const {
return _internal_has_fg_threshold();
}
inline void WindowDataParameter::clear_fg_threshold() {
fg_threshold_ = 0.5f;
_has_bits_[0] &= ~0x00000400u;
}
inline float WindowDataParameter::_internal_fg_threshold() const {
return fg_threshold_;
}
inline float WindowDataParameter::fg_threshold() const {
// @@protoc_insertion_point(field_get:caffe.WindowDataParameter.fg_threshold)
return _internal_fg_threshold();
}
inline void WindowDataParameter::_internal_set_fg_threshold(float value) {
_has_bits_[0] |= 0x00000400u;
fg_threshold_ = value;
}
inline void WindowDataParameter::set_fg_threshold(float value) {
_internal_set_fg_threshold(value);
// @@protoc_insertion_point(field_set:caffe.WindowDataParameter.fg_threshold)
}
// optional float bg_threshold = 8 [default = 0.5];
inline bool WindowDataParameter::_internal_has_bg_threshold() const {
bool value = (_has_bits_[0] & 0x00000800u) != 0;
return value;
}
inline bool WindowDataParameter::has_bg_threshold() const {
return _internal_has_bg_threshold();
}
inline void WindowDataParameter::clear_bg_threshold() {
bg_threshold_ = 0.5f;
_has_bits_[0] &= ~0x00000800u;
}
inline float WindowDataParameter::_internal_bg_threshold() const {
return bg_threshold_;
}
inline float WindowDataParameter::bg_threshold() const {
// @@protoc_insertion_point(field_get:caffe.WindowDataParameter.bg_threshold)
return _internal_bg_threshold();
}
inline void WindowDataParameter::_internal_set_bg_threshold(float value) {
_has_bits_[0] |= 0x00000800u;
bg_threshold_ = value;
}
inline void WindowDataParameter::set_bg_threshold(float value) {
_internal_set_bg_threshold(value);
// @@protoc_insertion_point(field_set:caffe.WindowDataParameter.bg_threshold)
}
// optional float fg_fraction = 9 [default = 0.25];
inline bool WindowDataParameter::_internal_has_fg_fraction() const {
bool value = (_has_bits_[0] & 0x00001000u) != 0;
return value;
}
inline bool WindowDataParameter::has_fg_fraction() const {
return _internal_has_fg_fraction();
}
inline void WindowDataParameter::clear_fg_fraction() {
fg_fraction_ = 0.25f;
_has_bits_[0] &= ~0x00001000u;
}
inline float WindowDataParameter::_internal_fg_fraction() const {
return fg_fraction_;
}
inline float WindowDataParameter::fg_fraction() const {
// @@protoc_insertion_point(field_get:caffe.WindowDataParameter.fg_fraction)
return _internal_fg_fraction();
}
inline void WindowDataParameter::_internal_set_fg_fraction(float value) {
_has_bits_[0] |= 0x00001000u;
fg_fraction_ = value;
}
inline void WindowDataParameter::set_fg_fraction(float value) {
_internal_set_fg_fraction(value);
// @@protoc_insertion_point(field_set:caffe.WindowDataParameter.fg_fraction)
}
// optional uint32 context_pad = 10 [default = 0];
inline bool WindowDataParameter::_internal_has_context_pad() const {
bool value = (_has_bits_[0] & 0x00000100u) != 0;
return value;
}
inline bool WindowDataParameter::has_context_pad() const {
return _internal_has_context_pad();
}
inline void WindowDataParameter::clear_context_pad() {
context_pad_ = 0u;
_has_bits_[0] &= ~0x00000100u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 WindowDataParameter::_internal_context_pad() const {
return context_pad_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 WindowDataParameter::context_pad() const {
// @@protoc_insertion_point(field_get:caffe.WindowDataParameter.context_pad)
return _internal_context_pad();
}
inline void WindowDataParameter::_internal_set_context_pad(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000100u;
context_pad_ = value;
}
inline void WindowDataParameter::set_context_pad(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_context_pad(value);
// @@protoc_insertion_point(field_set:caffe.WindowDataParameter.context_pad)
}
// optional string crop_mode = 11 [default = "warp"];
inline bool WindowDataParameter::_internal_has_crop_mode() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool WindowDataParameter::has_crop_mode() const {
return _internal_has_crop_mode();
}
inline void WindowDataParameter::clear_crop_mode() {
crop_mode_.ClearToDefault(&::caffe::WindowDataParameter::_i_give_permission_to_break_this_code_default_crop_mode_.get(), GetArena());
_has_bits_[0] &= ~0x00000004u;
}
inline const std::string& WindowDataParameter::crop_mode() const {
// @@protoc_insertion_point(field_get:caffe.WindowDataParameter.crop_mode)
return _internal_crop_mode();
}
inline void WindowDataParameter::set_crop_mode(const std::string& value) {
_internal_set_crop_mode(value);
// @@protoc_insertion_point(field_set:caffe.WindowDataParameter.crop_mode)
}
inline std::string* WindowDataParameter::mutable_crop_mode() {
// @@protoc_insertion_point(field_mutable:caffe.WindowDataParameter.crop_mode)
return _internal_mutable_crop_mode();
}
inline const std::string& WindowDataParameter::_internal_crop_mode() const {
return crop_mode_.Get();
}
inline void WindowDataParameter::_internal_set_crop_mode(const std::string& value) {
_has_bits_[0] |= 0x00000004u;
crop_mode_.Set(&::caffe::WindowDataParameter::_i_give_permission_to_break_this_code_default_crop_mode_.get(), value, GetArena());
}
inline void WindowDataParameter::set_crop_mode(std::string&& value) {
_has_bits_[0] |= 0x00000004u;
crop_mode_.Set(
&::caffe::WindowDataParameter::_i_give_permission_to_break_this_code_default_crop_mode_.get(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.WindowDataParameter.crop_mode)
}
inline void WindowDataParameter::set_crop_mode(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000004u;
crop_mode_.Set(&::caffe::WindowDataParameter::_i_give_permission_to_break_this_code_default_crop_mode_.get(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.WindowDataParameter.crop_mode)
}
inline void WindowDataParameter::set_crop_mode(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000004u;
crop_mode_.Set(&::caffe::WindowDataParameter::_i_give_permission_to_break_this_code_default_crop_mode_.get(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.WindowDataParameter.crop_mode)
}
inline std::string* WindowDataParameter::_internal_mutable_crop_mode() {
_has_bits_[0] |= 0x00000004u;
return crop_mode_.Mutable(&::caffe::WindowDataParameter::_i_give_permission_to_break_this_code_default_crop_mode_.get(), GetArena());
}
inline std::string* WindowDataParameter::release_crop_mode() {
// @@protoc_insertion_point(field_release:caffe.WindowDataParameter.crop_mode)
if (!_internal_has_crop_mode()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000004u;
return crop_mode_.ReleaseNonDefault(&::caffe::WindowDataParameter::_i_give_permission_to_break_this_code_default_crop_mode_.get(), GetArena());
}
inline void WindowDataParameter::set_allocated_crop_mode(std::string* crop_mode) {
if (crop_mode != nullptr) {
_has_bits_[0] |= 0x00000004u;
} else {
_has_bits_[0] &= ~0x00000004u;
}
crop_mode_.SetAllocated(&::caffe::WindowDataParameter::_i_give_permission_to_break_this_code_default_crop_mode_.get(), crop_mode,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.WindowDataParameter.crop_mode)
}
// optional bool cache_images = 12 [default = false];
inline bool WindowDataParameter::_internal_has_cache_images() const {
bool value = (_has_bits_[0] & 0x00000080u) != 0;
return value;
}
inline bool WindowDataParameter::has_cache_images() const {
return _internal_has_cache_images();
}
inline void WindowDataParameter::clear_cache_images() {
cache_images_ = false;
_has_bits_[0] &= ~0x00000080u;
}
inline bool WindowDataParameter::_internal_cache_images() const {
return cache_images_;
}
inline bool WindowDataParameter::cache_images() const {
// @@protoc_insertion_point(field_get:caffe.WindowDataParameter.cache_images)
return _internal_cache_images();
}
inline void WindowDataParameter::_internal_set_cache_images(bool value) {
_has_bits_[0] |= 0x00000080u;
cache_images_ = value;
}
inline void WindowDataParameter::set_cache_images(bool value) {
_internal_set_cache_images(value);
// @@protoc_insertion_point(field_set:caffe.WindowDataParameter.cache_images)
}
// optional string root_folder = 13 [default = ""];
inline bool WindowDataParameter::_internal_has_root_folder() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool WindowDataParameter::has_root_folder() const {
return _internal_has_root_folder();
}
inline void WindowDataParameter::clear_root_folder() {
root_folder_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000008u;
}
inline const std::string& WindowDataParameter::root_folder() const {
// @@protoc_insertion_point(field_get:caffe.WindowDataParameter.root_folder)
return _internal_root_folder();
}
inline void WindowDataParameter::set_root_folder(const std::string& value) {
_internal_set_root_folder(value);
// @@protoc_insertion_point(field_set:caffe.WindowDataParameter.root_folder)
}
inline std::string* WindowDataParameter::mutable_root_folder() {
// @@protoc_insertion_point(field_mutable:caffe.WindowDataParameter.root_folder)
return _internal_mutable_root_folder();
}
inline const std::string& WindowDataParameter::_internal_root_folder() const {
return root_folder_.Get();
}
inline void WindowDataParameter::_internal_set_root_folder(const std::string& value) {
_has_bits_[0] |= 0x00000008u;
root_folder_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void WindowDataParameter::set_root_folder(std::string&& value) {
_has_bits_[0] |= 0x00000008u;
root_folder_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.WindowDataParameter.root_folder)
}
inline void WindowDataParameter::set_root_folder(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000008u;
root_folder_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.WindowDataParameter.root_folder)
}
inline void WindowDataParameter::set_root_folder(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000008u;
root_folder_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.WindowDataParameter.root_folder)
}
inline std::string* WindowDataParameter::_internal_mutable_root_folder() {
_has_bits_[0] |= 0x00000008u;
return root_folder_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* WindowDataParameter::release_root_folder() {
// @@protoc_insertion_point(field_release:caffe.WindowDataParameter.root_folder)
if (!_internal_has_root_folder()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000008u;
return root_folder_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void WindowDataParameter::set_allocated_root_folder(std::string* root_folder) {
if (root_folder != nullptr) {
_has_bits_[0] |= 0x00000008u;
} else {
_has_bits_[0] &= ~0x00000008u;
}
root_folder_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), root_folder,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.WindowDataParameter.root_folder)
}
// -------------------------------------------------------------------
// MILDataParameter
// optional string source = 1;
inline bool MILDataParameter::_internal_has_source() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool MILDataParameter::has_source() const {
return _internal_has_source();
}
inline void MILDataParameter::clear_source() {
source_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000001u;
}
inline const std::string& MILDataParameter::source() const {
// @@protoc_insertion_point(field_get:caffe.MILDataParameter.source)
return _internal_source();
}
inline void MILDataParameter::set_source(const std::string& value) {
_internal_set_source(value);
// @@protoc_insertion_point(field_set:caffe.MILDataParameter.source)
}
inline std::string* MILDataParameter::mutable_source() {
// @@protoc_insertion_point(field_mutable:caffe.MILDataParameter.source)
return _internal_mutable_source();
}
inline const std::string& MILDataParameter::_internal_source() const {
return source_.Get();
}
inline void MILDataParameter::_internal_set_source(const std::string& value) {
_has_bits_[0] |= 0x00000001u;
source_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void MILDataParameter::set_source(std::string&& value) {
_has_bits_[0] |= 0x00000001u;
source_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.MILDataParameter.source)
}
inline void MILDataParameter::set_source(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000001u;
source_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.MILDataParameter.source)
}
inline void MILDataParameter::set_source(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000001u;
source_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.MILDataParameter.source)
}
inline std::string* MILDataParameter::_internal_mutable_source() {
_has_bits_[0] |= 0x00000001u;
return source_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* MILDataParameter::release_source() {
// @@protoc_insertion_point(field_release:caffe.MILDataParameter.source)
if (!_internal_has_source()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000001u;
return source_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void MILDataParameter::set_allocated_source(std::string* source) {
if (source != nullptr) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
source_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), source,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.MILDataParameter.source)
}
// optional uint32 num_scales = 2 [default = 1];
inline bool MILDataParameter::_internal_has_num_scales() const {
bool value = (_has_bits_[0] & 0x00000040u) != 0;
return value;
}
inline bool MILDataParameter::has_num_scales() const {
return _internal_has_num_scales();
}
inline void MILDataParameter::clear_num_scales() {
num_scales_ = 1u;
_has_bits_[0] &= ~0x00000040u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 MILDataParameter::_internal_num_scales() const {
return num_scales_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 MILDataParameter::num_scales() const {
// @@protoc_insertion_point(field_get:caffe.MILDataParameter.num_scales)
return _internal_num_scales();
}
inline void MILDataParameter::_internal_set_num_scales(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000040u;
num_scales_ = value;
}
inline void MILDataParameter::set_num_scales(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_num_scales(value);
// @@protoc_insertion_point(field_set:caffe.MILDataParameter.num_scales)
}
// optional float scale_factor = 6 [default = 1];
inline bool MILDataParameter::_internal_has_scale_factor() const {
bool value = (_has_bits_[0] & 0x00000100u) != 0;
return value;
}
inline bool MILDataParameter::has_scale_factor() const {
return _internal_has_scale_factor();
}
inline void MILDataParameter::clear_scale_factor() {
scale_factor_ = 1;
_has_bits_[0] &= ~0x00000100u;
}
inline float MILDataParameter::_internal_scale_factor() const {
return scale_factor_;
}
inline float MILDataParameter::scale_factor() const {
// @@protoc_insertion_point(field_get:caffe.MILDataParameter.scale_factor)
return _internal_scale_factor();
}
inline void MILDataParameter::_internal_set_scale_factor(float value) {
_has_bits_[0] |= 0x00000100u;
scale_factor_ = value;
}
inline void MILDataParameter::set_scale_factor(float value) {
_internal_set_scale_factor(value);
// @@protoc_insertion_point(field_set:caffe.MILDataParameter.scale_factor)
}
// optional uint32 channels = 4 [default = 3];
inline bool MILDataParameter::_internal_has_channels() const {
bool value = (_has_bits_[0] & 0x00000080u) != 0;
return value;
}
inline bool MILDataParameter::has_channels() const {
return _internal_has_channels();
}
inline void MILDataParameter::clear_channels() {
channels_ = 3u;
_has_bits_[0] &= ~0x00000080u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 MILDataParameter::_internal_channels() const {
return channels_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 MILDataParameter::channels() const {
// @@protoc_insertion_point(field_get:caffe.MILDataParameter.channels)
return _internal_channels();
}
inline void MILDataParameter::_internal_set_channels(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000080u;
channels_ = value;
}
inline void MILDataParameter::set_channels(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_channels(value);
// @@protoc_insertion_point(field_set:caffe.MILDataParameter.channels)
}
// optional uint32 images_per_batch = 3;
inline bool MILDataParameter::_internal_has_images_per_batch() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool MILDataParameter::has_images_per_batch() const {
return _internal_has_images_per_batch();
}
inline void MILDataParameter::clear_images_per_batch() {
images_per_batch_ = 0u;
_has_bits_[0] &= ~0x00000010u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 MILDataParameter::_internal_images_per_batch() const {
return images_per_batch_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 MILDataParameter::images_per_batch() const {
// @@protoc_insertion_point(field_get:caffe.MILDataParameter.images_per_batch)
return _internal_images_per_batch();
}
inline void MILDataParameter::_internal_set_images_per_batch(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000010u;
images_per_batch_ = value;
}
inline void MILDataParameter::set_images_per_batch(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_images_per_batch(value);
// @@protoc_insertion_point(field_set:caffe.MILDataParameter.images_per_batch)
}
// optional uint32 n_classes = 5;
inline bool MILDataParameter::_internal_has_n_classes() const {
bool value = (_has_bits_[0] & 0x00000020u) != 0;
return value;
}
inline bool MILDataParameter::has_n_classes() const {
return _internal_has_n_classes();
}
inline void MILDataParameter::clear_n_classes() {
n_classes_ = 0u;
_has_bits_[0] &= ~0x00000020u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 MILDataParameter::_internal_n_classes() const {
return n_classes_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 MILDataParameter::n_classes() const {
// @@protoc_insertion_point(field_get:caffe.MILDataParameter.n_classes)
return _internal_n_classes();
}
inline void MILDataParameter::_internal_set_n_classes(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000020u;
n_classes_ = value;
}
inline void MILDataParameter::set_n_classes(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_n_classes(value);
// @@protoc_insertion_point(field_set:caffe.MILDataParameter.n_classes)
}
// optional string label_file = 7;
inline bool MILDataParameter::_internal_has_label_file() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool MILDataParameter::has_label_file() const {
return _internal_has_label_file();
}
inline void MILDataParameter::clear_label_file() {
label_file_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000002u;
}
inline const std::string& MILDataParameter::label_file() const {
// @@protoc_insertion_point(field_get:caffe.MILDataParameter.label_file)
return _internal_label_file();
}
inline void MILDataParameter::set_label_file(const std::string& value) {
_internal_set_label_file(value);
// @@protoc_insertion_point(field_set:caffe.MILDataParameter.label_file)
}
inline std::string* MILDataParameter::mutable_label_file() {
// @@protoc_insertion_point(field_mutable:caffe.MILDataParameter.label_file)
return _internal_mutable_label_file();
}
inline const std::string& MILDataParameter::_internal_label_file() const {
return label_file_.Get();
}
inline void MILDataParameter::_internal_set_label_file(const std::string& value) {
_has_bits_[0] |= 0x00000002u;
label_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void MILDataParameter::set_label_file(std::string&& value) {
_has_bits_[0] |= 0x00000002u;
label_file_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.MILDataParameter.label_file)
}
inline void MILDataParameter::set_label_file(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000002u;
label_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.MILDataParameter.label_file)
}
inline void MILDataParameter::set_label_file(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000002u;
label_file_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.MILDataParameter.label_file)
}
inline std::string* MILDataParameter::_internal_mutable_label_file() {
_has_bits_[0] |= 0x00000002u;
return label_file_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* MILDataParameter::release_label_file() {
// @@protoc_insertion_point(field_release:caffe.MILDataParameter.label_file)
if (!_internal_has_label_file()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000002u;
return label_file_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void MILDataParameter::set_allocated_label_file(std::string* label_file) {
if (label_file != nullptr) {
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
label_file_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), label_file,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.MILDataParameter.label_file)
}
// optional string root_dir = 11;
inline bool MILDataParameter::_internal_has_root_dir() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool MILDataParameter::has_root_dir() const {
return _internal_has_root_dir();
}
inline void MILDataParameter::clear_root_dir() {
root_dir_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000004u;
}
inline const std::string& MILDataParameter::root_dir() const {
// @@protoc_insertion_point(field_get:caffe.MILDataParameter.root_dir)
return _internal_root_dir();
}
inline void MILDataParameter::set_root_dir(const std::string& value) {
_internal_set_root_dir(value);
// @@protoc_insertion_point(field_set:caffe.MILDataParameter.root_dir)
}
inline std::string* MILDataParameter::mutable_root_dir() {
// @@protoc_insertion_point(field_mutable:caffe.MILDataParameter.root_dir)
return _internal_mutable_root_dir();
}
inline const std::string& MILDataParameter::_internal_root_dir() const {
return root_dir_.Get();
}
inline void MILDataParameter::_internal_set_root_dir(const std::string& value) {
_has_bits_[0] |= 0x00000004u;
root_dir_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void MILDataParameter::set_root_dir(std::string&& value) {
_has_bits_[0] |= 0x00000004u;
root_dir_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.MILDataParameter.root_dir)
}
inline void MILDataParameter::set_root_dir(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000004u;
root_dir_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.MILDataParameter.root_dir)
}
inline void MILDataParameter::set_root_dir(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000004u;
root_dir_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.MILDataParameter.root_dir)
}
inline std::string* MILDataParameter::_internal_mutable_root_dir() {
_has_bits_[0] |= 0x00000004u;
return root_dir_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* MILDataParameter::release_root_dir() {
// @@protoc_insertion_point(field_release:caffe.MILDataParameter.root_dir)
if (!_internal_has_root_dir()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000004u;
return root_dir_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void MILDataParameter::set_allocated_root_dir(std::string* root_dir) {
if (root_dir != nullptr) {
_has_bits_[0] |= 0x00000004u;
} else {
_has_bits_[0] &= ~0x00000004u;
}
root_dir_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), root_dir,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.MILDataParameter.root_dir)
}
// optional string ext = 12;
inline bool MILDataParameter::_internal_has_ext() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool MILDataParameter::has_ext() const {
return _internal_has_ext();
}
inline void MILDataParameter::clear_ext() {
ext_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000008u;
}
inline const std::string& MILDataParameter::ext() const {
// @@protoc_insertion_point(field_get:caffe.MILDataParameter.ext)
return _internal_ext();
}
inline void MILDataParameter::set_ext(const std::string& value) {
_internal_set_ext(value);
// @@protoc_insertion_point(field_set:caffe.MILDataParameter.ext)
}
inline std::string* MILDataParameter::mutable_ext() {
// @@protoc_insertion_point(field_mutable:caffe.MILDataParameter.ext)
return _internal_mutable_ext();
}
inline const std::string& MILDataParameter::_internal_ext() const {
return ext_.Get();
}
inline void MILDataParameter::_internal_set_ext(const std::string& value) {
_has_bits_[0] |= 0x00000008u;
ext_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void MILDataParameter::set_ext(std::string&& value) {
_has_bits_[0] |= 0x00000008u;
ext_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.MILDataParameter.ext)
}
inline void MILDataParameter::set_ext(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000008u;
ext_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.MILDataParameter.ext)
}
inline void MILDataParameter::set_ext(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000008u;
ext_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.MILDataParameter.ext)
}
inline std::string* MILDataParameter::_internal_mutable_ext() {
_has_bits_[0] |= 0x00000008u;
return ext_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* MILDataParameter::release_ext() {
// @@protoc_insertion_point(field_release:caffe.MILDataParameter.ext)
if (!_internal_has_ext()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000008u;
return ext_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void MILDataParameter::set_allocated_ext(std::string* ext) {
if (ext != nullptr) {
_has_bits_[0] |= 0x00000008u;
} else {
_has_bits_[0] &= ~0x00000008u;
}
ext_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ext,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.MILDataParameter.ext)
}
// optional bool randomize = 13 [default = true];
inline bool MILDataParameter::_internal_has_randomize() const {
bool value = (_has_bits_[0] & 0x00000200u) != 0;
return value;
}
inline bool MILDataParameter::has_randomize() const {
return _internal_has_randomize();
}
inline void MILDataParameter::clear_randomize() {
randomize_ = true;
_has_bits_[0] &= ~0x00000200u;
}
inline bool MILDataParameter::_internal_randomize() const {
return randomize_;
}
inline bool MILDataParameter::randomize() const {
// @@protoc_insertion_point(field_get:caffe.MILDataParameter.randomize)
return _internal_randomize();
}
inline void MILDataParameter::_internal_set_randomize(bool value) {
_has_bits_[0] |= 0x00000200u;
randomize_ = value;
}
inline void MILDataParameter::set_randomize(bool value) {
_internal_set_randomize(value);
// @@protoc_insertion_point(field_set:caffe.MILDataParameter.randomize)
}
// -------------------------------------------------------------------
// SPPParameter
// optional uint32 pyramid_height = 1;
inline bool SPPParameter::_internal_has_pyramid_height() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool SPPParameter::has_pyramid_height() const {
return _internal_has_pyramid_height();
}
inline void SPPParameter::clear_pyramid_height() {
pyramid_height_ = 0u;
_has_bits_[0] &= ~0x00000001u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 SPPParameter::_internal_pyramid_height() const {
return pyramid_height_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 SPPParameter::pyramid_height() const {
// @@protoc_insertion_point(field_get:caffe.SPPParameter.pyramid_height)
return _internal_pyramid_height();
}
inline void SPPParameter::_internal_set_pyramid_height(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000001u;
pyramid_height_ = value;
}
inline void SPPParameter::set_pyramid_height(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_pyramid_height(value);
// @@protoc_insertion_point(field_set:caffe.SPPParameter.pyramid_height)
}
// optional .caffe.SPPParameter.PoolMethod pool = 2 [default = MAX];
inline bool SPPParameter::_internal_has_pool() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool SPPParameter::has_pool() const {
return _internal_has_pool();
}
inline void SPPParameter::clear_pool() {
pool_ = 0;
_has_bits_[0] &= ~0x00000002u;
}
inline ::caffe::SPPParameter_PoolMethod SPPParameter::_internal_pool() const {
return static_cast< ::caffe::SPPParameter_PoolMethod >(pool_);
}
inline ::caffe::SPPParameter_PoolMethod SPPParameter::pool() const {
// @@protoc_insertion_point(field_get:caffe.SPPParameter.pool)
return _internal_pool();
}
inline void SPPParameter::_internal_set_pool(::caffe::SPPParameter_PoolMethod value) {
assert(::caffe::SPPParameter_PoolMethod_IsValid(value));
_has_bits_[0] |= 0x00000002u;
pool_ = value;
}
inline void SPPParameter::set_pool(::caffe::SPPParameter_PoolMethod value) {
_internal_set_pool(value);
// @@protoc_insertion_point(field_set:caffe.SPPParameter.pool)
}
// optional .caffe.SPPParameter.Engine engine = 6 [default = DEFAULT];
inline bool SPPParameter::_internal_has_engine() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool SPPParameter::has_engine() const {
return _internal_has_engine();
}
inline void SPPParameter::clear_engine() {
engine_ = 0;
_has_bits_[0] &= ~0x00000004u;
}
inline ::caffe::SPPParameter_Engine SPPParameter::_internal_engine() const {
return static_cast< ::caffe::SPPParameter_Engine >(engine_);
}
inline ::caffe::SPPParameter_Engine SPPParameter::engine() const {
// @@protoc_insertion_point(field_get:caffe.SPPParameter.engine)
return _internal_engine();
}
inline void SPPParameter::_internal_set_engine(::caffe::SPPParameter_Engine value) {
assert(::caffe::SPPParameter_Engine_IsValid(value));
_has_bits_[0] |= 0x00000004u;
engine_ = value;
}
inline void SPPParameter::set_engine(::caffe::SPPParameter_Engine value) {
_internal_set_engine(value);
// @@protoc_insertion_point(field_set:caffe.SPPParameter.engine)
}
// -------------------------------------------------------------------
// V1LayerParameter
// repeated string bottom = 2;
inline int V1LayerParameter::_internal_bottom_size() const {
return bottom_.size();
}
inline int V1LayerParameter::bottom_size() const {
return _internal_bottom_size();
}
inline void V1LayerParameter::clear_bottom() {
bottom_.Clear();
}
inline std::string* V1LayerParameter::add_bottom() {
// @@protoc_insertion_point(field_add_mutable:caffe.V1LayerParameter.bottom)
return _internal_add_bottom();
}
inline const std::string& V1LayerParameter::_internal_bottom(int index) const {
return bottom_.Get(index);
}
inline const std::string& V1LayerParameter::bottom(int index) const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.bottom)
return _internal_bottom(index);
}
inline std::string* V1LayerParameter::mutable_bottom(int index) {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.bottom)
return bottom_.Mutable(index);
}
inline void V1LayerParameter::set_bottom(int index, const std::string& value) {
// @@protoc_insertion_point(field_set:caffe.V1LayerParameter.bottom)
bottom_.Mutable(index)->assign(value);
}
inline void V1LayerParameter::set_bottom(int index, std::string&& value) {
// @@protoc_insertion_point(field_set:caffe.V1LayerParameter.bottom)
bottom_.Mutable(index)->assign(std::move(value));
}
inline void V1LayerParameter::set_bottom(int index, const char* value) {
GOOGLE_DCHECK(value != nullptr);
bottom_.Mutable(index)->assign(value);
// @@protoc_insertion_point(field_set_char:caffe.V1LayerParameter.bottom)
}
inline 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:caffe.V1LayerParameter.bottom)
}
inline std::string* V1LayerParameter::_internal_add_bottom() {
return bottom_.Add();
}
inline void V1LayerParameter::add_bottom(const std::string& value) {
bottom_.Add()->assign(value);
// @@protoc_insertion_point(field_add:caffe.V1LayerParameter.bottom)
}
inline void V1LayerParameter::add_bottom(std::string&& value) {
bottom_.Add(std::move(value));
// @@protoc_insertion_point(field_add:caffe.V1LayerParameter.bottom)
}
inline void V1LayerParameter::add_bottom(const char* value) {
GOOGLE_DCHECK(value != nullptr);
bottom_.Add()->assign(value);
// @@protoc_insertion_point(field_add_char:caffe.V1LayerParameter.bottom)
}
inline 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:caffe.V1LayerParameter.bottom)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>&
V1LayerParameter::bottom() const {
// @@protoc_insertion_point(field_list:caffe.V1LayerParameter.bottom)
return bottom_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>*
V1LayerParameter::mutable_bottom() {
// @@protoc_insertion_point(field_mutable_list:caffe.V1LayerParameter.bottom)
return &bottom_;
}
// repeated string top = 3;
inline int V1LayerParameter::_internal_top_size() const {
return top_.size();
}
inline int V1LayerParameter::top_size() const {
return _internal_top_size();
}
inline void V1LayerParameter::clear_top() {
top_.Clear();
}
inline std::string* V1LayerParameter::add_top() {
// @@protoc_insertion_point(field_add_mutable:caffe.V1LayerParameter.top)
return _internal_add_top();
}
inline const std::string& V1LayerParameter::_internal_top(int index) const {
return top_.Get(index);
}
inline const std::string& V1LayerParameter::top(int index) const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.top)
return _internal_top(index);
}
inline std::string* V1LayerParameter::mutable_top(int index) {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.top)
return top_.Mutable(index);
}
inline void V1LayerParameter::set_top(int index, const std::string& value) {
// @@protoc_insertion_point(field_set:caffe.V1LayerParameter.top)
top_.Mutable(index)->assign(value);
}
inline void V1LayerParameter::set_top(int index, std::string&& value) {
// @@protoc_insertion_point(field_set:caffe.V1LayerParameter.top)
top_.Mutable(index)->assign(std::move(value));
}
inline void V1LayerParameter::set_top(int index, const char* value) {
GOOGLE_DCHECK(value != nullptr);
top_.Mutable(index)->assign(value);
// @@protoc_insertion_point(field_set_char:caffe.V1LayerParameter.top)
}
inline 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:caffe.V1LayerParameter.top)
}
inline std::string* V1LayerParameter::_internal_add_top() {
return top_.Add();
}
inline void V1LayerParameter::add_top(const std::string& value) {
top_.Add()->assign(value);
// @@protoc_insertion_point(field_add:caffe.V1LayerParameter.top)
}
inline void V1LayerParameter::add_top(std::string&& value) {
top_.Add(std::move(value));
// @@protoc_insertion_point(field_add:caffe.V1LayerParameter.top)
}
inline void V1LayerParameter::add_top(const char* value) {
GOOGLE_DCHECK(value != nullptr);
top_.Add()->assign(value);
// @@protoc_insertion_point(field_add_char:caffe.V1LayerParameter.top)
}
inline 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:caffe.V1LayerParameter.top)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>&
V1LayerParameter::top() const {
// @@protoc_insertion_point(field_list:caffe.V1LayerParameter.top)
return top_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>*
V1LayerParameter::mutable_top() {
// @@protoc_insertion_point(field_mutable_list:caffe.V1LayerParameter.top)
return &top_;
}
// optional string name = 4;
inline bool V1LayerParameter::_internal_has_name() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool V1LayerParameter::has_name() const {
return _internal_has_name();
}
inline void V1LayerParameter::clear_name() {
name_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000001u;
}
inline const std::string& V1LayerParameter::name() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.name)
return _internal_name();
}
inline void V1LayerParameter::set_name(const std::string& value) {
_internal_set_name(value);
// @@protoc_insertion_point(field_set:caffe.V1LayerParameter.name)
}
inline std::string* V1LayerParameter::mutable_name() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.name)
return _internal_mutable_name();
}
inline const std::string& V1LayerParameter::_internal_name() const {
return name_.Get();
}
inline void V1LayerParameter::_internal_set_name(const std::string& value) {
_has_bits_[0] |= 0x00000001u;
name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void V1LayerParameter::set_name(std::string&& value) {
_has_bits_[0] |= 0x00000001u;
name_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.V1LayerParameter.name)
}
inline void V1LayerParameter::set_name(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000001u;
name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.V1LayerParameter.name)
}
inline void V1LayerParameter::set_name(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000001u;
name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.V1LayerParameter.name)
}
inline std::string* V1LayerParameter::_internal_mutable_name() {
_has_bits_[0] |= 0x00000001u;
return name_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* V1LayerParameter::release_name() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.name)
if (!_internal_has_name()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000001u;
return name_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void V1LayerParameter::set_allocated_name(std::string* name) {
if (name != nullptr) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
name_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), name,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.name)
}
// repeated .caffe.NetStateRule include = 32;
inline int V1LayerParameter::_internal_include_size() const {
return include_.size();
}
inline int V1LayerParameter::include_size() const {
return _internal_include_size();
}
inline void V1LayerParameter::clear_include() {
include_.Clear();
}
inline ::caffe::NetStateRule* V1LayerParameter::mutable_include(int index) {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.include)
return include_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetStateRule >*
V1LayerParameter::mutable_include() {
// @@protoc_insertion_point(field_mutable_list:caffe.V1LayerParameter.include)
return &include_;
}
inline const ::caffe::NetStateRule& V1LayerParameter::_internal_include(int index) const {
return include_.Get(index);
}
inline const ::caffe::NetStateRule& V1LayerParameter::include(int index) const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.include)
return _internal_include(index);
}
inline ::caffe::NetStateRule* V1LayerParameter::_internal_add_include() {
return include_.Add();
}
inline ::caffe::NetStateRule* V1LayerParameter::add_include() {
// @@protoc_insertion_point(field_add:caffe.V1LayerParameter.include)
return _internal_add_include();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetStateRule >&
V1LayerParameter::include() const {
// @@protoc_insertion_point(field_list:caffe.V1LayerParameter.include)
return include_;
}
// repeated .caffe.NetStateRule exclude = 33;
inline int V1LayerParameter::_internal_exclude_size() const {
return exclude_.size();
}
inline int V1LayerParameter::exclude_size() const {
return _internal_exclude_size();
}
inline void V1LayerParameter::clear_exclude() {
exclude_.Clear();
}
inline ::caffe::NetStateRule* V1LayerParameter::mutable_exclude(int index) {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.exclude)
return exclude_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetStateRule >*
V1LayerParameter::mutable_exclude() {
// @@protoc_insertion_point(field_mutable_list:caffe.V1LayerParameter.exclude)
return &exclude_;
}
inline const ::caffe::NetStateRule& V1LayerParameter::_internal_exclude(int index) const {
return exclude_.Get(index);
}
inline const ::caffe::NetStateRule& V1LayerParameter::exclude(int index) const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.exclude)
return _internal_exclude(index);
}
inline ::caffe::NetStateRule* V1LayerParameter::_internal_add_exclude() {
return exclude_.Add();
}
inline ::caffe::NetStateRule* V1LayerParameter::add_exclude() {
// @@protoc_insertion_point(field_add:caffe.V1LayerParameter.exclude)
return _internal_add_exclude();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::NetStateRule >&
V1LayerParameter::exclude() const {
// @@protoc_insertion_point(field_list:caffe.V1LayerParameter.exclude)
return exclude_;
}
// optional .caffe.V1LayerParameter.LayerType type = 5;
inline bool V1LayerParameter::_internal_has_type() const {
bool value = (_has_bits_[1] & 0x00000001u) != 0;
return value;
}
inline bool V1LayerParameter::has_type() const {
return _internal_has_type();
}
inline void V1LayerParameter::clear_type() {
type_ = 0;
_has_bits_[1] &= ~0x00000001u;
}
inline ::caffe::V1LayerParameter_LayerType V1LayerParameter::_internal_type() const {
return static_cast< ::caffe::V1LayerParameter_LayerType >(type_);
}
inline ::caffe::V1LayerParameter_LayerType V1LayerParameter::type() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.type)
return _internal_type();
}
inline void V1LayerParameter::_internal_set_type(::caffe::V1LayerParameter_LayerType value) {
assert(::caffe::V1LayerParameter_LayerType_IsValid(value));
_has_bits_[1] |= 0x00000001u;
type_ = value;
}
inline void V1LayerParameter::set_type(::caffe::V1LayerParameter_LayerType value) {
_internal_set_type(value);
// @@protoc_insertion_point(field_set:caffe.V1LayerParameter.type)
}
// repeated .caffe.BlobProto blobs = 6;
inline int V1LayerParameter::_internal_blobs_size() const {
return blobs_.size();
}
inline int V1LayerParameter::blobs_size() const {
return _internal_blobs_size();
}
inline void V1LayerParameter::clear_blobs() {
blobs_.Clear();
}
inline ::caffe::BlobProto* V1LayerParameter::mutable_blobs(int index) {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.blobs)
return blobs_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto >*
V1LayerParameter::mutable_blobs() {
// @@protoc_insertion_point(field_mutable_list:caffe.V1LayerParameter.blobs)
return &blobs_;
}
inline const ::caffe::BlobProto& V1LayerParameter::_internal_blobs(int index) const {
return blobs_.Get(index);
}
inline const ::caffe::BlobProto& V1LayerParameter::blobs(int index) const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.blobs)
return _internal_blobs(index);
}
inline ::caffe::BlobProto* V1LayerParameter::_internal_add_blobs() {
return blobs_.Add();
}
inline ::caffe::BlobProto* V1LayerParameter::add_blobs() {
// @@protoc_insertion_point(field_add:caffe.V1LayerParameter.blobs)
return _internal_add_blobs();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto >&
V1LayerParameter::blobs() const {
// @@protoc_insertion_point(field_list:caffe.V1LayerParameter.blobs)
return blobs_;
}
// repeated string param = 1001;
inline int V1LayerParameter::_internal_param_size() const {
return param_.size();
}
inline int V1LayerParameter::param_size() const {
return _internal_param_size();
}
inline void V1LayerParameter::clear_param() {
param_.Clear();
}
inline std::string* V1LayerParameter::add_param() {
// @@protoc_insertion_point(field_add_mutable:caffe.V1LayerParameter.param)
return _internal_add_param();
}
inline const std::string& V1LayerParameter::_internal_param(int index) const {
return param_.Get(index);
}
inline const std::string& V1LayerParameter::param(int index) const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.param)
return _internal_param(index);
}
inline std::string* V1LayerParameter::mutable_param(int index) {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.param)
return param_.Mutable(index);
}
inline void V1LayerParameter::set_param(int index, const std::string& value) {
// @@protoc_insertion_point(field_set:caffe.V1LayerParameter.param)
param_.Mutable(index)->assign(value);
}
inline void V1LayerParameter::set_param(int index, std::string&& value) {
// @@protoc_insertion_point(field_set:caffe.V1LayerParameter.param)
param_.Mutable(index)->assign(std::move(value));
}
inline void V1LayerParameter::set_param(int index, const char* value) {
GOOGLE_DCHECK(value != nullptr);
param_.Mutable(index)->assign(value);
// @@protoc_insertion_point(field_set_char:caffe.V1LayerParameter.param)
}
inline 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:caffe.V1LayerParameter.param)
}
inline std::string* V1LayerParameter::_internal_add_param() {
return param_.Add();
}
inline void V1LayerParameter::add_param(const std::string& value) {
param_.Add()->assign(value);
// @@protoc_insertion_point(field_add:caffe.V1LayerParameter.param)
}
inline void V1LayerParameter::add_param(std::string&& value) {
param_.Add(std::move(value));
// @@protoc_insertion_point(field_add:caffe.V1LayerParameter.param)
}
inline void V1LayerParameter::add_param(const char* value) {
GOOGLE_DCHECK(value != nullptr);
param_.Add()->assign(value);
// @@protoc_insertion_point(field_add_char:caffe.V1LayerParameter.param)
}
inline 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:caffe.V1LayerParameter.param)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>&
V1LayerParameter::param() const {
// @@protoc_insertion_point(field_list:caffe.V1LayerParameter.param)
return param_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField<std::string>*
V1LayerParameter::mutable_param() {
// @@protoc_insertion_point(field_mutable_list:caffe.V1LayerParameter.param)
return ¶m_;
}
// repeated .caffe.V1LayerParameter.DimCheckMode blob_share_mode = 1002;
inline int V1LayerParameter::_internal_blob_share_mode_size() const {
return blob_share_mode_.size();
}
inline int V1LayerParameter::blob_share_mode_size() const {
return _internal_blob_share_mode_size();
}
inline void V1LayerParameter::clear_blob_share_mode() {
blob_share_mode_.Clear();
}
inline ::caffe::V1LayerParameter_DimCheckMode V1LayerParameter::_internal_blob_share_mode(int index) const {
return static_cast< ::caffe::V1LayerParameter_DimCheckMode >(blob_share_mode_.Get(index));
}
inline ::caffe::V1LayerParameter_DimCheckMode V1LayerParameter::blob_share_mode(int index) const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.blob_share_mode)
return _internal_blob_share_mode(index);
}
inline void V1LayerParameter::set_blob_share_mode(int index, ::caffe::V1LayerParameter_DimCheckMode value) {
assert(::caffe::V1LayerParameter_DimCheckMode_IsValid(value));
blob_share_mode_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.V1LayerParameter.blob_share_mode)
}
inline void V1LayerParameter::_internal_add_blob_share_mode(::caffe::V1LayerParameter_DimCheckMode value) {
assert(::caffe::V1LayerParameter_DimCheckMode_IsValid(value));
blob_share_mode_.Add(value);
}
inline void V1LayerParameter::add_blob_share_mode(::caffe::V1LayerParameter_DimCheckMode value) {
// @@protoc_insertion_point(field_add:caffe.V1LayerParameter.blob_share_mode)
_internal_add_blob_share_mode(value);
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField<int>&
V1LayerParameter::blob_share_mode() const {
// @@protoc_insertion_point(field_list:caffe.V1LayerParameter.blob_share_mode)
return blob_share_mode_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField<int>*
V1LayerParameter::_internal_mutable_blob_share_mode() {
return &blob_share_mode_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField<int>*
V1LayerParameter::mutable_blob_share_mode() {
// @@protoc_insertion_point(field_mutable_list:caffe.V1LayerParameter.blob_share_mode)
return _internal_mutable_blob_share_mode();
}
// repeated float blobs_lr = 7;
inline int V1LayerParameter::_internal_blobs_lr_size() const {
return blobs_lr_.size();
}
inline int V1LayerParameter::blobs_lr_size() const {
return _internal_blobs_lr_size();
}
inline void V1LayerParameter::clear_blobs_lr() {
blobs_lr_.Clear();
}
inline float V1LayerParameter::_internal_blobs_lr(int index) const {
return blobs_lr_.Get(index);
}
inline float V1LayerParameter::blobs_lr(int index) const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.blobs_lr)
return _internal_blobs_lr(index);
}
inline void V1LayerParameter::set_blobs_lr(int index, float value) {
blobs_lr_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.V1LayerParameter.blobs_lr)
}
inline void V1LayerParameter::_internal_add_blobs_lr(float value) {
blobs_lr_.Add(value);
}
inline void V1LayerParameter::add_blobs_lr(float value) {
_internal_add_blobs_lr(value);
// @@protoc_insertion_point(field_add:caffe.V1LayerParameter.blobs_lr)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
V1LayerParameter::_internal_blobs_lr() const {
return blobs_lr_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
V1LayerParameter::blobs_lr() const {
// @@protoc_insertion_point(field_list:caffe.V1LayerParameter.blobs_lr)
return _internal_blobs_lr();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
V1LayerParameter::_internal_mutable_blobs_lr() {
return &blobs_lr_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
V1LayerParameter::mutable_blobs_lr() {
// @@protoc_insertion_point(field_mutable_list:caffe.V1LayerParameter.blobs_lr)
return _internal_mutable_blobs_lr();
}
// repeated float weight_decay = 8;
inline int V1LayerParameter::_internal_weight_decay_size() const {
return weight_decay_.size();
}
inline int V1LayerParameter::weight_decay_size() const {
return _internal_weight_decay_size();
}
inline void V1LayerParameter::clear_weight_decay() {
weight_decay_.Clear();
}
inline float V1LayerParameter::_internal_weight_decay(int index) const {
return weight_decay_.Get(index);
}
inline float V1LayerParameter::weight_decay(int index) const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.weight_decay)
return _internal_weight_decay(index);
}
inline void V1LayerParameter::set_weight_decay(int index, float value) {
weight_decay_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.V1LayerParameter.weight_decay)
}
inline void V1LayerParameter::_internal_add_weight_decay(float value) {
weight_decay_.Add(value);
}
inline void V1LayerParameter::add_weight_decay(float value) {
_internal_add_weight_decay(value);
// @@protoc_insertion_point(field_add:caffe.V1LayerParameter.weight_decay)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
V1LayerParameter::_internal_weight_decay() const {
return weight_decay_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
V1LayerParameter::weight_decay() const {
// @@protoc_insertion_point(field_list:caffe.V1LayerParameter.weight_decay)
return _internal_weight_decay();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
V1LayerParameter::_internal_mutable_weight_decay() {
return &weight_decay_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
V1LayerParameter::mutable_weight_decay() {
// @@protoc_insertion_point(field_mutable_list:caffe.V1LayerParameter.weight_decay)
return _internal_mutable_weight_decay();
}
// repeated float loss_weight = 35;
inline int V1LayerParameter::_internal_loss_weight_size() const {
return loss_weight_.size();
}
inline int V1LayerParameter::loss_weight_size() const {
return _internal_loss_weight_size();
}
inline void V1LayerParameter::clear_loss_weight() {
loss_weight_.Clear();
}
inline float V1LayerParameter::_internal_loss_weight(int index) const {
return loss_weight_.Get(index);
}
inline float V1LayerParameter::loss_weight(int index) const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.loss_weight)
return _internal_loss_weight(index);
}
inline void V1LayerParameter::set_loss_weight(int index, float value) {
loss_weight_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.V1LayerParameter.loss_weight)
}
inline void V1LayerParameter::_internal_add_loss_weight(float value) {
loss_weight_.Add(value);
}
inline void V1LayerParameter::add_loss_weight(float value) {
_internal_add_loss_weight(value);
// @@protoc_insertion_point(field_add:caffe.V1LayerParameter.loss_weight)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
V1LayerParameter::_internal_loss_weight() const {
return loss_weight_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
V1LayerParameter::loss_weight() const {
// @@protoc_insertion_point(field_list:caffe.V1LayerParameter.loss_weight)
return _internal_loss_weight();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
V1LayerParameter::_internal_mutable_loss_weight() {
return &loss_weight_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
V1LayerParameter::mutable_loss_weight() {
// @@protoc_insertion_point(field_mutable_list:caffe.V1LayerParameter.loss_weight)
return _internal_mutable_loss_weight();
}
// optional .caffe.AccuracyParameter accuracy_param = 27;
inline bool V1LayerParameter::_internal_has_accuracy_param() const {
bool value = (_has_bits_[0] & 0x00100000u) != 0;
PROTOBUF_ASSUME(!value || accuracy_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_accuracy_param() const {
return _internal_has_accuracy_param();
}
inline void V1LayerParameter::clear_accuracy_param() {
if (accuracy_param_ != nullptr) accuracy_param_->Clear();
_has_bits_[0] &= ~0x00100000u;
}
inline const ::caffe::AccuracyParameter& V1LayerParameter::_internal_accuracy_param() const {
const ::caffe::AccuracyParameter* p = accuracy_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::AccuracyParameter*>(
&::caffe::_AccuracyParameter_default_instance_);
}
inline const ::caffe::AccuracyParameter& V1LayerParameter::accuracy_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.accuracy_param)
return _internal_accuracy_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_accuracy_param(
::caffe::AccuracyParameter* accuracy_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(accuracy_param_);
}
accuracy_param_ = accuracy_param;
if (accuracy_param) {
_has_bits_[0] |= 0x00100000u;
} else {
_has_bits_[0] &= ~0x00100000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.accuracy_param)
}
inline ::caffe::AccuracyParameter* V1LayerParameter::release_accuracy_param() {
_has_bits_[0] &= ~0x00100000u;
::caffe::AccuracyParameter* temp = accuracy_param_;
accuracy_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::AccuracyParameter* V1LayerParameter::unsafe_arena_release_accuracy_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.accuracy_param)
_has_bits_[0] &= ~0x00100000u;
::caffe::AccuracyParameter* temp = accuracy_param_;
accuracy_param_ = nullptr;
return temp;
}
inline ::caffe::AccuracyParameter* V1LayerParameter::_internal_mutable_accuracy_param() {
_has_bits_[0] |= 0x00100000u;
if (accuracy_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::AccuracyParameter>(GetArena());
accuracy_param_ = p;
}
return accuracy_param_;
}
inline ::caffe::AccuracyParameter* V1LayerParameter::mutable_accuracy_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.accuracy_param)
return _internal_mutable_accuracy_param();
}
inline void V1LayerParameter::set_allocated_accuracy_param(::caffe::AccuracyParameter* accuracy_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete accuracy_param_;
}
if (accuracy_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(accuracy_param);
if (message_arena != submessage_arena) {
accuracy_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, accuracy_param, submessage_arena);
}
_has_bits_[0] |= 0x00100000u;
} else {
_has_bits_[0] &= ~0x00100000u;
}
accuracy_param_ = accuracy_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.accuracy_param)
}
// optional .caffe.ArgMaxParameter argmax_param = 23;
inline bool V1LayerParameter::_internal_has_argmax_param() const {
bool value = (_has_bits_[0] & 0x00010000u) != 0;
PROTOBUF_ASSUME(!value || argmax_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_argmax_param() const {
return _internal_has_argmax_param();
}
inline void V1LayerParameter::clear_argmax_param() {
if (argmax_param_ != nullptr) argmax_param_->Clear();
_has_bits_[0] &= ~0x00010000u;
}
inline const ::caffe::ArgMaxParameter& V1LayerParameter::_internal_argmax_param() const {
const ::caffe::ArgMaxParameter* p = argmax_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ArgMaxParameter*>(
&::caffe::_ArgMaxParameter_default_instance_);
}
inline const ::caffe::ArgMaxParameter& V1LayerParameter::argmax_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.argmax_param)
return _internal_argmax_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_argmax_param(
::caffe::ArgMaxParameter* argmax_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(argmax_param_);
}
argmax_param_ = argmax_param;
if (argmax_param) {
_has_bits_[0] |= 0x00010000u;
} else {
_has_bits_[0] &= ~0x00010000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.argmax_param)
}
inline ::caffe::ArgMaxParameter* V1LayerParameter::release_argmax_param() {
_has_bits_[0] &= ~0x00010000u;
::caffe::ArgMaxParameter* temp = argmax_param_;
argmax_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ArgMaxParameter* V1LayerParameter::unsafe_arena_release_argmax_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.argmax_param)
_has_bits_[0] &= ~0x00010000u;
::caffe::ArgMaxParameter* temp = argmax_param_;
argmax_param_ = nullptr;
return temp;
}
inline ::caffe::ArgMaxParameter* V1LayerParameter::_internal_mutable_argmax_param() {
_has_bits_[0] |= 0x00010000u;
if (argmax_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ArgMaxParameter>(GetArena());
argmax_param_ = p;
}
return argmax_param_;
}
inline ::caffe::ArgMaxParameter* V1LayerParameter::mutable_argmax_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.argmax_param)
return _internal_mutable_argmax_param();
}
inline void V1LayerParameter::set_allocated_argmax_param(::caffe::ArgMaxParameter* argmax_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete argmax_param_;
}
if (argmax_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(argmax_param);
if (message_arena != submessage_arena) {
argmax_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, argmax_param, submessage_arena);
}
_has_bits_[0] |= 0x00010000u;
} else {
_has_bits_[0] &= ~0x00010000u;
}
argmax_param_ = argmax_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.argmax_param)
}
// optional .caffe.ConcatParameter concat_param = 9;
inline bool V1LayerParameter::_internal_has_concat_param() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
PROTOBUF_ASSUME(!value || concat_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_concat_param() const {
return _internal_has_concat_param();
}
inline void V1LayerParameter::clear_concat_param() {
if (concat_param_ != nullptr) concat_param_->Clear();
_has_bits_[0] &= ~0x00000004u;
}
inline const ::caffe::ConcatParameter& V1LayerParameter::_internal_concat_param() const {
const ::caffe::ConcatParameter* p = concat_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ConcatParameter*>(
&::caffe::_ConcatParameter_default_instance_);
}
inline const ::caffe::ConcatParameter& V1LayerParameter::concat_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.concat_param)
return _internal_concat_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_concat_param(
::caffe::ConcatParameter* concat_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(concat_param_);
}
concat_param_ = concat_param;
if (concat_param) {
_has_bits_[0] |= 0x00000004u;
} else {
_has_bits_[0] &= ~0x00000004u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.concat_param)
}
inline ::caffe::ConcatParameter* V1LayerParameter::release_concat_param() {
_has_bits_[0] &= ~0x00000004u;
::caffe::ConcatParameter* temp = concat_param_;
concat_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ConcatParameter* V1LayerParameter::unsafe_arena_release_concat_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.concat_param)
_has_bits_[0] &= ~0x00000004u;
::caffe::ConcatParameter* temp = concat_param_;
concat_param_ = nullptr;
return temp;
}
inline ::caffe::ConcatParameter* V1LayerParameter::_internal_mutable_concat_param() {
_has_bits_[0] |= 0x00000004u;
if (concat_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ConcatParameter>(GetArena());
concat_param_ = p;
}
return concat_param_;
}
inline ::caffe::ConcatParameter* V1LayerParameter::mutable_concat_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.concat_param)
return _internal_mutable_concat_param();
}
inline void V1LayerParameter::set_allocated_concat_param(::caffe::ConcatParameter* concat_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete concat_param_;
}
if (concat_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(concat_param);
if (message_arena != submessage_arena) {
concat_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, concat_param, submessage_arena);
}
_has_bits_[0] |= 0x00000004u;
} else {
_has_bits_[0] &= ~0x00000004u;
}
concat_param_ = concat_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.concat_param)
}
// optional .caffe.ContrastiveLossParameter contrastive_loss_param = 40;
inline bool V1LayerParameter::_internal_has_contrastive_loss_param() const {
bool value = (_has_bits_[0] & 0x20000000u) != 0;
PROTOBUF_ASSUME(!value || contrastive_loss_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_contrastive_loss_param() const {
return _internal_has_contrastive_loss_param();
}
inline void V1LayerParameter::clear_contrastive_loss_param() {
if (contrastive_loss_param_ != nullptr) contrastive_loss_param_->Clear();
_has_bits_[0] &= ~0x20000000u;
}
inline const ::caffe::ContrastiveLossParameter& V1LayerParameter::_internal_contrastive_loss_param() const {
const ::caffe::ContrastiveLossParameter* p = contrastive_loss_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ContrastiveLossParameter*>(
&::caffe::_ContrastiveLossParameter_default_instance_);
}
inline const ::caffe::ContrastiveLossParameter& V1LayerParameter::contrastive_loss_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.contrastive_loss_param)
return _internal_contrastive_loss_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_contrastive_loss_param(
::caffe::ContrastiveLossParameter* contrastive_loss_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(contrastive_loss_param_);
}
contrastive_loss_param_ = contrastive_loss_param;
if (contrastive_loss_param) {
_has_bits_[0] |= 0x20000000u;
} else {
_has_bits_[0] &= ~0x20000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.contrastive_loss_param)
}
inline ::caffe::ContrastiveLossParameter* V1LayerParameter::release_contrastive_loss_param() {
_has_bits_[0] &= ~0x20000000u;
::caffe::ContrastiveLossParameter* temp = contrastive_loss_param_;
contrastive_loss_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ContrastiveLossParameter* V1LayerParameter::unsafe_arena_release_contrastive_loss_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.contrastive_loss_param)
_has_bits_[0] &= ~0x20000000u;
::caffe::ContrastiveLossParameter* temp = contrastive_loss_param_;
contrastive_loss_param_ = nullptr;
return temp;
}
inline ::caffe::ContrastiveLossParameter* V1LayerParameter::_internal_mutable_contrastive_loss_param() {
_has_bits_[0] |= 0x20000000u;
if (contrastive_loss_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ContrastiveLossParameter>(GetArena());
contrastive_loss_param_ = p;
}
return contrastive_loss_param_;
}
inline ::caffe::ContrastiveLossParameter* V1LayerParameter::mutable_contrastive_loss_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.contrastive_loss_param)
return _internal_mutable_contrastive_loss_param();
}
inline void V1LayerParameter::set_allocated_contrastive_loss_param(::caffe::ContrastiveLossParameter* contrastive_loss_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete contrastive_loss_param_;
}
if (contrastive_loss_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(contrastive_loss_param);
if (message_arena != submessage_arena) {
contrastive_loss_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, contrastive_loss_param, submessage_arena);
}
_has_bits_[0] |= 0x20000000u;
} else {
_has_bits_[0] &= ~0x20000000u;
}
contrastive_loss_param_ = contrastive_loss_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.contrastive_loss_param)
}
// optional .caffe.ConvolutionParameter convolution_param = 10;
inline bool V1LayerParameter::_internal_has_convolution_param() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
PROTOBUF_ASSUME(!value || convolution_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_convolution_param() const {
return _internal_has_convolution_param();
}
inline void V1LayerParameter::clear_convolution_param() {
if (convolution_param_ != nullptr) convolution_param_->Clear();
_has_bits_[0] &= ~0x00000008u;
}
inline const ::caffe::ConvolutionParameter& V1LayerParameter::_internal_convolution_param() const {
const ::caffe::ConvolutionParameter* p = convolution_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ConvolutionParameter*>(
&::caffe::_ConvolutionParameter_default_instance_);
}
inline const ::caffe::ConvolutionParameter& V1LayerParameter::convolution_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.convolution_param)
return _internal_convolution_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_convolution_param(
::caffe::ConvolutionParameter* convolution_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(convolution_param_);
}
convolution_param_ = convolution_param;
if (convolution_param) {
_has_bits_[0] |= 0x00000008u;
} else {
_has_bits_[0] &= ~0x00000008u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.convolution_param)
}
inline ::caffe::ConvolutionParameter* V1LayerParameter::release_convolution_param() {
_has_bits_[0] &= ~0x00000008u;
::caffe::ConvolutionParameter* temp = convolution_param_;
convolution_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ConvolutionParameter* V1LayerParameter::unsafe_arena_release_convolution_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.convolution_param)
_has_bits_[0] &= ~0x00000008u;
::caffe::ConvolutionParameter* temp = convolution_param_;
convolution_param_ = nullptr;
return temp;
}
inline ::caffe::ConvolutionParameter* V1LayerParameter::_internal_mutable_convolution_param() {
_has_bits_[0] |= 0x00000008u;
if (convolution_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ConvolutionParameter>(GetArena());
convolution_param_ = p;
}
return convolution_param_;
}
inline ::caffe::ConvolutionParameter* V1LayerParameter::mutable_convolution_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.convolution_param)
return _internal_mutable_convolution_param();
}
inline void V1LayerParameter::set_allocated_convolution_param(::caffe::ConvolutionParameter* convolution_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete convolution_param_;
}
if (convolution_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(convolution_param);
if (message_arena != submessage_arena) {
convolution_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, convolution_param, submessage_arena);
}
_has_bits_[0] |= 0x00000008u;
} else {
_has_bits_[0] &= ~0x00000008u;
}
convolution_param_ = convolution_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.convolution_param)
}
// optional .caffe.DataParameter data_param = 11;
inline bool V1LayerParameter::_internal_has_data_param() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
PROTOBUF_ASSUME(!value || data_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_data_param() const {
return _internal_has_data_param();
}
inline void V1LayerParameter::clear_data_param() {
if (data_param_ != nullptr) data_param_->Clear();
_has_bits_[0] &= ~0x00000010u;
}
inline const ::caffe::DataParameter& V1LayerParameter::_internal_data_param() const {
const ::caffe::DataParameter* p = data_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::DataParameter*>(
&::caffe::_DataParameter_default_instance_);
}
inline const ::caffe::DataParameter& V1LayerParameter::data_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.data_param)
return _internal_data_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_data_param(
::caffe::DataParameter* data_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(data_param_);
}
data_param_ = data_param;
if (data_param) {
_has_bits_[0] |= 0x00000010u;
} else {
_has_bits_[0] &= ~0x00000010u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.data_param)
}
inline ::caffe::DataParameter* V1LayerParameter::release_data_param() {
_has_bits_[0] &= ~0x00000010u;
::caffe::DataParameter* temp = data_param_;
data_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::DataParameter* V1LayerParameter::unsafe_arena_release_data_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.data_param)
_has_bits_[0] &= ~0x00000010u;
::caffe::DataParameter* temp = data_param_;
data_param_ = nullptr;
return temp;
}
inline ::caffe::DataParameter* V1LayerParameter::_internal_mutable_data_param() {
_has_bits_[0] |= 0x00000010u;
if (data_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::DataParameter>(GetArena());
data_param_ = p;
}
return data_param_;
}
inline ::caffe::DataParameter* V1LayerParameter::mutable_data_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.data_param)
return _internal_mutable_data_param();
}
inline void V1LayerParameter::set_allocated_data_param(::caffe::DataParameter* data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete data_param_;
}
if (data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(data_param);
if (message_arena != submessage_arena) {
data_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, data_param, submessage_arena);
}
_has_bits_[0] |= 0x00000010u;
} else {
_has_bits_[0] &= ~0x00000010u;
}
data_param_ = data_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.data_param)
}
// optional .caffe.DropoutParameter dropout_param = 12;
inline bool V1LayerParameter::_internal_has_dropout_param() const {
bool value = (_has_bits_[0] & 0x00000020u) != 0;
PROTOBUF_ASSUME(!value || dropout_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_dropout_param() const {
return _internal_has_dropout_param();
}
inline void V1LayerParameter::clear_dropout_param() {
if (dropout_param_ != nullptr) dropout_param_->Clear();
_has_bits_[0] &= ~0x00000020u;
}
inline const ::caffe::DropoutParameter& V1LayerParameter::_internal_dropout_param() const {
const ::caffe::DropoutParameter* p = dropout_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::DropoutParameter*>(
&::caffe::_DropoutParameter_default_instance_);
}
inline const ::caffe::DropoutParameter& V1LayerParameter::dropout_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.dropout_param)
return _internal_dropout_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_dropout_param(
::caffe::DropoutParameter* dropout_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(dropout_param_);
}
dropout_param_ = dropout_param;
if (dropout_param) {
_has_bits_[0] |= 0x00000020u;
} else {
_has_bits_[0] &= ~0x00000020u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.dropout_param)
}
inline ::caffe::DropoutParameter* V1LayerParameter::release_dropout_param() {
_has_bits_[0] &= ~0x00000020u;
::caffe::DropoutParameter* temp = dropout_param_;
dropout_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::DropoutParameter* V1LayerParameter::unsafe_arena_release_dropout_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.dropout_param)
_has_bits_[0] &= ~0x00000020u;
::caffe::DropoutParameter* temp = dropout_param_;
dropout_param_ = nullptr;
return temp;
}
inline ::caffe::DropoutParameter* V1LayerParameter::_internal_mutable_dropout_param() {
_has_bits_[0] |= 0x00000020u;
if (dropout_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::DropoutParameter>(GetArena());
dropout_param_ = p;
}
return dropout_param_;
}
inline ::caffe::DropoutParameter* V1LayerParameter::mutable_dropout_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.dropout_param)
return _internal_mutable_dropout_param();
}
inline void V1LayerParameter::set_allocated_dropout_param(::caffe::DropoutParameter* dropout_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete dropout_param_;
}
if (dropout_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(dropout_param);
if (message_arena != submessage_arena) {
dropout_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, dropout_param, submessage_arena);
}
_has_bits_[0] |= 0x00000020u;
} else {
_has_bits_[0] &= ~0x00000020u;
}
dropout_param_ = dropout_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.dropout_param)
}
// optional .caffe.DummyDataParameter dummy_data_param = 26;
inline bool V1LayerParameter::_internal_has_dummy_data_param() const {
bool value = (_has_bits_[0] & 0x00080000u) != 0;
PROTOBUF_ASSUME(!value || dummy_data_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_dummy_data_param() const {
return _internal_has_dummy_data_param();
}
inline void V1LayerParameter::clear_dummy_data_param() {
if (dummy_data_param_ != nullptr) dummy_data_param_->Clear();
_has_bits_[0] &= ~0x00080000u;
}
inline const ::caffe::DummyDataParameter& V1LayerParameter::_internal_dummy_data_param() const {
const ::caffe::DummyDataParameter* p = dummy_data_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::DummyDataParameter*>(
&::caffe::_DummyDataParameter_default_instance_);
}
inline const ::caffe::DummyDataParameter& V1LayerParameter::dummy_data_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.dummy_data_param)
return _internal_dummy_data_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_dummy_data_param(
::caffe::DummyDataParameter* dummy_data_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(dummy_data_param_);
}
dummy_data_param_ = dummy_data_param;
if (dummy_data_param) {
_has_bits_[0] |= 0x00080000u;
} else {
_has_bits_[0] &= ~0x00080000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.dummy_data_param)
}
inline ::caffe::DummyDataParameter* V1LayerParameter::release_dummy_data_param() {
_has_bits_[0] &= ~0x00080000u;
::caffe::DummyDataParameter* temp = dummy_data_param_;
dummy_data_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::DummyDataParameter* V1LayerParameter::unsafe_arena_release_dummy_data_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.dummy_data_param)
_has_bits_[0] &= ~0x00080000u;
::caffe::DummyDataParameter* temp = dummy_data_param_;
dummy_data_param_ = nullptr;
return temp;
}
inline ::caffe::DummyDataParameter* V1LayerParameter::_internal_mutable_dummy_data_param() {
_has_bits_[0] |= 0x00080000u;
if (dummy_data_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::DummyDataParameter>(GetArena());
dummy_data_param_ = p;
}
return dummy_data_param_;
}
inline ::caffe::DummyDataParameter* V1LayerParameter::mutable_dummy_data_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.dummy_data_param)
return _internal_mutable_dummy_data_param();
}
inline void V1LayerParameter::set_allocated_dummy_data_param(::caffe::DummyDataParameter* dummy_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete dummy_data_param_;
}
if (dummy_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(dummy_data_param);
if (message_arena != submessage_arena) {
dummy_data_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, dummy_data_param, submessage_arena);
}
_has_bits_[0] |= 0x00080000u;
} else {
_has_bits_[0] &= ~0x00080000u;
}
dummy_data_param_ = dummy_data_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.dummy_data_param)
}
// optional .caffe.EltwiseParameter eltwise_param = 24;
inline bool V1LayerParameter::_internal_has_eltwise_param() const {
bool value = (_has_bits_[0] & 0x00020000u) != 0;
PROTOBUF_ASSUME(!value || eltwise_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_eltwise_param() const {
return _internal_has_eltwise_param();
}
inline void V1LayerParameter::clear_eltwise_param() {
if (eltwise_param_ != nullptr) eltwise_param_->Clear();
_has_bits_[0] &= ~0x00020000u;
}
inline const ::caffe::EltwiseParameter& V1LayerParameter::_internal_eltwise_param() const {
const ::caffe::EltwiseParameter* p = eltwise_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::EltwiseParameter*>(
&::caffe::_EltwiseParameter_default_instance_);
}
inline const ::caffe::EltwiseParameter& V1LayerParameter::eltwise_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.eltwise_param)
return _internal_eltwise_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_eltwise_param(
::caffe::EltwiseParameter* eltwise_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(eltwise_param_);
}
eltwise_param_ = eltwise_param;
if (eltwise_param) {
_has_bits_[0] |= 0x00020000u;
} else {
_has_bits_[0] &= ~0x00020000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.eltwise_param)
}
inline ::caffe::EltwiseParameter* V1LayerParameter::release_eltwise_param() {
_has_bits_[0] &= ~0x00020000u;
::caffe::EltwiseParameter* temp = eltwise_param_;
eltwise_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::EltwiseParameter* V1LayerParameter::unsafe_arena_release_eltwise_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.eltwise_param)
_has_bits_[0] &= ~0x00020000u;
::caffe::EltwiseParameter* temp = eltwise_param_;
eltwise_param_ = nullptr;
return temp;
}
inline ::caffe::EltwiseParameter* V1LayerParameter::_internal_mutable_eltwise_param() {
_has_bits_[0] |= 0x00020000u;
if (eltwise_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::EltwiseParameter>(GetArena());
eltwise_param_ = p;
}
return eltwise_param_;
}
inline ::caffe::EltwiseParameter* V1LayerParameter::mutable_eltwise_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.eltwise_param)
return _internal_mutable_eltwise_param();
}
inline void V1LayerParameter::set_allocated_eltwise_param(::caffe::EltwiseParameter* eltwise_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete eltwise_param_;
}
if (eltwise_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(eltwise_param);
if (message_arena != submessage_arena) {
eltwise_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, eltwise_param, submessage_arena);
}
_has_bits_[0] |= 0x00020000u;
} else {
_has_bits_[0] &= ~0x00020000u;
}
eltwise_param_ = eltwise_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.eltwise_param)
}
// optional .caffe.ExpParameter exp_param = 41;
inline bool V1LayerParameter::_internal_has_exp_param() const {
bool value = (_has_bits_[0] & 0x40000000u) != 0;
PROTOBUF_ASSUME(!value || exp_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_exp_param() const {
return _internal_has_exp_param();
}
inline void V1LayerParameter::clear_exp_param() {
if (exp_param_ != nullptr) exp_param_->Clear();
_has_bits_[0] &= ~0x40000000u;
}
inline const ::caffe::ExpParameter& V1LayerParameter::_internal_exp_param() const {
const ::caffe::ExpParameter* p = exp_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ExpParameter*>(
&::caffe::_ExpParameter_default_instance_);
}
inline const ::caffe::ExpParameter& V1LayerParameter::exp_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.exp_param)
return _internal_exp_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_exp_param(
::caffe::ExpParameter* exp_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(exp_param_);
}
exp_param_ = exp_param;
if (exp_param) {
_has_bits_[0] |= 0x40000000u;
} else {
_has_bits_[0] &= ~0x40000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.exp_param)
}
inline ::caffe::ExpParameter* V1LayerParameter::release_exp_param() {
_has_bits_[0] &= ~0x40000000u;
::caffe::ExpParameter* temp = exp_param_;
exp_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ExpParameter* V1LayerParameter::unsafe_arena_release_exp_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.exp_param)
_has_bits_[0] &= ~0x40000000u;
::caffe::ExpParameter* temp = exp_param_;
exp_param_ = nullptr;
return temp;
}
inline ::caffe::ExpParameter* V1LayerParameter::_internal_mutable_exp_param() {
_has_bits_[0] |= 0x40000000u;
if (exp_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ExpParameter>(GetArena());
exp_param_ = p;
}
return exp_param_;
}
inline ::caffe::ExpParameter* V1LayerParameter::mutable_exp_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.exp_param)
return _internal_mutable_exp_param();
}
inline void V1LayerParameter::set_allocated_exp_param(::caffe::ExpParameter* exp_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete exp_param_;
}
if (exp_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(exp_param);
if (message_arena != submessage_arena) {
exp_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, exp_param, submessage_arena);
}
_has_bits_[0] |= 0x40000000u;
} else {
_has_bits_[0] &= ~0x40000000u;
}
exp_param_ = exp_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.exp_param)
}
// optional .caffe.HDF5DataParameter hdf5_data_param = 13;
inline bool V1LayerParameter::_internal_has_hdf5_data_param() const {
bool value = (_has_bits_[0] & 0x00000040u) != 0;
PROTOBUF_ASSUME(!value || hdf5_data_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_hdf5_data_param() const {
return _internal_has_hdf5_data_param();
}
inline void V1LayerParameter::clear_hdf5_data_param() {
if (hdf5_data_param_ != nullptr) hdf5_data_param_->Clear();
_has_bits_[0] &= ~0x00000040u;
}
inline const ::caffe::HDF5DataParameter& V1LayerParameter::_internal_hdf5_data_param() const {
const ::caffe::HDF5DataParameter* p = hdf5_data_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::HDF5DataParameter*>(
&::caffe::_HDF5DataParameter_default_instance_);
}
inline const ::caffe::HDF5DataParameter& V1LayerParameter::hdf5_data_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.hdf5_data_param)
return _internal_hdf5_data_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_hdf5_data_param(
::caffe::HDF5DataParameter* hdf5_data_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(hdf5_data_param_);
}
hdf5_data_param_ = hdf5_data_param;
if (hdf5_data_param) {
_has_bits_[0] |= 0x00000040u;
} else {
_has_bits_[0] &= ~0x00000040u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.hdf5_data_param)
}
inline ::caffe::HDF5DataParameter* V1LayerParameter::release_hdf5_data_param() {
_has_bits_[0] &= ~0x00000040u;
::caffe::HDF5DataParameter* temp = hdf5_data_param_;
hdf5_data_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::HDF5DataParameter* V1LayerParameter::unsafe_arena_release_hdf5_data_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.hdf5_data_param)
_has_bits_[0] &= ~0x00000040u;
::caffe::HDF5DataParameter* temp = hdf5_data_param_;
hdf5_data_param_ = nullptr;
return temp;
}
inline ::caffe::HDF5DataParameter* V1LayerParameter::_internal_mutable_hdf5_data_param() {
_has_bits_[0] |= 0x00000040u;
if (hdf5_data_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::HDF5DataParameter>(GetArena());
hdf5_data_param_ = p;
}
return hdf5_data_param_;
}
inline ::caffe::HDF5DataParameter* V1LayerParameter::mutable_hdf5_data_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.hdf5_data_param)
return _internal_mutable_hdf5_data_param();
}
inline void V1LayerParameter::set_allocated_hdf5_data_param(::caffe::HDF5DataParameter* hdf5_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete hdf5_data_param_;
}
if (hdf5_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(hdf5_data_param);
if (message_arena != submessage_arena) {
hdf5_data_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, hdf5_data_param, submessage_arena);
}
_has_bits_[0] |= 0x00000040u;
} else {
_has_bits_[0] &= ~0x00000040u;
}
hdf5_data_param_ = hdf5_data_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.hdf5_data_param)
}
// optional .caffe.HDF5OutputParameter hdf5_output_param = 14;
inline bool V1LayerParameter::_internal_has_hdf5_output_param() const {
bool value = (_has_bits_[0] & 0x00000080u) != 0;
PROTOBUF_ASSUME(!value || hdf5_output_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_hdf5_output_param() const {
return _internal_has_hdf5_output_param();
}
inline void V1LayerParameter::clear_hdf5_output_param() {
if (hdf5_output_param_ != nullptr) hdf5_output_param_->Clear();
_has_bits_[0] &= ~0x00000080u;
}
inline const ::caffe::HDF5OutputParameter& V1LayerParameter::_internal_hdf5_output_param() const {
const ::caffe::HDF5OutputParameter* p = hdf5_output_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::HDF5OutputParameter*>(
&::caffe::_HDF5OutputParameter_default_instance_);
}
inline const ::caffe::HDF5OutputParameter& V1LayerParameter::hdf5_output_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.hdf5_output_param)
return _internal_hdf5_output_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_hdf5_output_param(
::caffe::HDF5OutputParameter* hdf5_output_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(hdf5_output_param_);
}
hdf5_output_param_ = hdf5_output_param;
if (hdf5_output_param) {
_has_bits_[0] |= 0x00000080u;
} else {
_has_bits_[0] &= ~0x00000080u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.hdf5_output_param)
}
inline ::caffe::HDF5OutputParameter* V1LayerParameter::release_hdf5_output_param() {
_has_bits_[0] &= ~0x00000080u;
::caffe::HDF5OutputParameter* temp = hdf5_output_param_;
hdf5_output_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::HDF5OutputParameter* V1LayerParameter::unsafe_arena_release_hdf5_output_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.hdf5_output_param)
_has_bits_[0] &= ~0x00000080u;
::caffe::HDF5OutputParameter* temp = hdf5_output_param_;
hdf5_output_param_ = nullptr;
return temp;
}
inline ::caffe::HDF5OutputParameter* V1LayerParameter::_internal_mutable_hdf5_output_param() {
_has_bits_[0] |= 0x00000080u;
if (hdf5_output_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::HDF5OutputParameter>(GetArena());
hdf5_output_param_ = p;
}
return hdf5_output_param_;
}
inline ::caffe::HDF5OutputParameter* V1LayerParameter::mutable_hdf5_output_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.hdf5_output_param)
return _internal_mutable_hdf5_output_param();
}
inline void V1LayerParameter::set_allocated_hdf5_output_param(::caffe::HDF5OutputParameter* hdf5_output_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete hdf5_output_param_;
}
if (hdf5_output_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(hdf5_output_param);
if (message_arena != submessage_arena) {
hdf5_output_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, hdf5_output_param, submessage_arena);
}
_has_bits_[0] |= 0x00000080u;
} else {
_has_bits_[0] &= ~0x00000080u;
}
hdf5_output_param_ = hdf5_output_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.hdf5_output_param)
}
// optional .caffe.HingeLossParameter hinge_loss_param = 29;
inline bool V1LayerParameter::_internal_has_hinge_loss_param() const {
bool value = (_has_bits_[0] & 0x00200000u) != 0;
PROTOBUF_ASSUME(!value || hinge_loss_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_hinge_loss_param() const {
return _internal_has_hinge_loss_param();
}
inline void V1LayerParameter::clear_hinge_loss_param() {
if (hinge_loss_param_ != nullptr) hinge_loss_param_->Clear();
_has_bits_[0] &= ~0x00200000u;
}
inline const ::caffe::HingeLossParameter& V1LayerParameter::_internal_hinge_loss_param() const {
const ::caffe::HingeLossParameter* p = hinge_loss_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::HingeLossParameter*>(
&::caffe::_HingeLossParameter_default_instance_);
}
inline const ::caffe::HingeLossParameter& V1LayerParameter::hinge_loss_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.hinge_loss_param)
return _internal_hinge_loss_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_hinge_loss_param(
::caffe::HingeLossParameter* hinge_loss_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(hinge_loss_param_);
}
hinge_loss_param_ = hinge_loss_param;
if (hinge_loss_param) {
_has_bits_[0] |= 0x00200000u;
} else {
_has_bits_[0] &= ~0x00200000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.hinge_loss_param)
}
inline ::caffe::HingeLossParameter* V1LayerParameter::release_hinge_loss_param() {
_has_bits_[0] &= ~0x00200000u;
::caffe::HingeLossParameter* temp = hinge_loss_param_;
hinge_loss_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::HingeLossParameter* V1LayerParameter::unsafe_arena_release_hinge_loss_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.hinge_loss_param)
_has_bits_[0] &= ~0x00200000u;
::caffe::HingeLossParameter* temp = hinge_loss_param_;
hinge_loss_param_ = nullptr;
return temp;
}
inline ::caffe::HingeLossParameter* V1LayerParameter::_internal_mutable_hinge_loss_param() {
_has_bits_[0] |= 0x00200000u;
if (hinge_loss_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::HingeLossParameter>(GetArena());
hinge_loss_param_ = p;
}
return hinge_loss_param_;
}
inline ::caffe::HingeLossParameter* V1LayerParameter::mutable_hinge_loss_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.hinge_loss_param)
return _internal_mutable_hinge_loss_param();
}
inline void V1LayerParameter::set_allocated_hinge_loss_param(::caffe::HingeLossParameter* hinge_loss_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete hinge_loss_param_;
}
if (hinge_loss_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(hinge_loss_param);
if (message_arena != submessage_arena) {
hinge_loss_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, hinge_loss_param, submessage_arena);
}
_has_bits_[0] |= 0x00200000u;
} else {
_has_bits_[0] &= ~0x00200000u;
}
hinge_loss_param_ = hinge_loss_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.hinge_loss_param)
}
// optional .caffe.ImageDataParameter image_data_param = 15;
inline bool V1LayerParameter::_internal_has_image_data_param() const {
bool value = (_has_bits_[0] & 0x00000100u) != 0;
PROTOBUF_ASSUME(!value || image_data_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_image_data_param() const {
return _internal_has_image_data_param();
}
inline void V1LayerParameter::clear_image_data_param() {
if (image_data_param_ != nullptr) image_data_param_->Clear();
_has_bits_[0] &= ~0x00000100u;
}
inline const ::caffe::ImageDataParameter& V1LayerParameter::_internal_image_data_param() const {
const ::caffe::ImageDataParameter* p = image_data_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ImageDataParameter*>(
&::caffe::_ImageDataParameter_default_instance_);
}
inline const ::caffe::ImageDataParameter& V1LayerParameter::image_data_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.image_data_param)
return _internal_image_data_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_image_data_param(
::caffe::ImageDataParameter* image_data_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(image_data_param_);
}
image_data_param_ = image_data_param;
if (image_data_param) {
_has_bits_[0] |= 0x00000100u;
} else {
_has_bits_[0] &= ~0x00000100u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.image_data_param)
}
inline ::caffe::ImageDataParameter* V1LayerParameter::release_image_data_param() {
_has_bits_[0] &= ~0x00000100u;
::caffe::ImageDataParameter* temp = image_data_param_;
image_data_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ImageDataParameter* V1LayerParameter::unsafe_arena_release_image_data_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.image_data_param)
_has_bits_[0] &= ~0x00000100u;
::caffe::ImageDataParameter* temp = image_data_param_;
image_data_param_ = nullptr;
return temp;
}
inline ::caffe::ImageDataParameter* V1LayerParameter::_internal_mutable_image_data_param() {
_has_bits_[0] |= 0x00000100u;
if (image_data_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ImageDataParameter>(GetArena());
image_data_param_ = p;
}
return image_data_param_;
}
inline ::caffe::ImageDataParameter* V1LayerParameter::mutable_image_data_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.image_data_param)
return _internal_mutable_image_data_param();
}
inline void V1LayerParameter::set_allocated_image_data_param(::caffe::ImageDataParameter* image_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete image_data_param_;
}
if (image_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(image_data_param);
if (message_arena != submessage_arena) {
image_data_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, image_data_param, submessage_arena);
}
_has_bits_[0] |= 0x00000100u;
} else {
_has_bits_[0] &= ~0x00000100u;
}
image_data_param_ = image_data_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.image_data_param)
}
// optional .caffe.InfogainLossParameter infogain_loss_param = 16;
inline bool V1LayerParameter::_internal_has_infogain_loss_param() const {
bool value = (_has_bits_[0] & 0x00000200u) != 0;
PROTOBUF_ASSUME(!value || infogain_loss_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_infogain_loss_param() const {
return _internal_has_infogain_loss_param();
}
inline void V1LayerParameter::clear_infogain_loss_param() {
if (infogain_loss_param_ != nullptr) infogain_loss_param_->Clear();
_has_bits_[0] &= ~0x00000200u;
}
inline const ::caffe::InfogainLossParameter& V1LayerParameter::_internal_infogain_loss_param() const {
const ::caffe::InfogainLossParameter* p = infogain_loss_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::InfogainLossParameter*>(
&::caffe::_InfogainLossParameter_default_instance_);
}
inline const ::caffe::InfogainLossParameter& V1LayerParameter::infogain_loss_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.infogain_loss_param)
return _internal_infogain_loss_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_infogain_loss_param(
::caffe::InfogainLossParameter* infogain_loss_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(infogain_loss_param_);
}
infogain_loss_param_ = infogain_loss_param;
if (infogain_loss_param) {
_has_bits_[0] |= 0x00000200u;
} else {
_has_bits_[0] &= ~0x00000200u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.infogain_loss_param)
}
inline ::caffe::InfogainLossParameter* V1LayerParameter::release_infogain_loss_param() {
_has_bits_[0] &= ~0x00000200u;
::caffe::InfogainLossParameter* temp = infogain_loss_param_;
infogain_loss_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::InfogainLossParameter* V1LayerParameter::unsafe_arena_release_infogain_loss_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.infogain_loss_param)
_has_bits_[0] &= ~0x00000200u;
::caffe::InfogainLossParameter* temp = infogain_loss_param_;
infogain_loss_param_ = nullptr;
return temp;
}
inline ::caffe::InfogainLossParameter* V1LayerParameter::_internal_mutable_infogain_loss_param() {
_has_bits_[0] |= 0x00000200u;
if (infogain_loss_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::InfogainLossParameter>(GetArena());
infogain_loss_param_ = p;
}
return infogain_loss_param_;
}
inline ::caffe::InfogainLossParameter* V1LayerParameter::mutable_infogain_loss_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.infogain_loss_param)
return _internal_mutable_infogain_loss_param();
}
inline void V1LayerParameter::set_allocated_infogain_loss_param(::caffe::InfogainLossParameter* infogain_loss_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete infogain_loss_param_;
}
if (infogain_loss_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(infogain_loss_param);
if (message_arena != submessage_arena) {
infogain_loss_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, infogain_loss_param, submessage_arena);
}
_has_bits_[0] |= 0x00000200u;
} else {
_has_bits_[0] &= ~0x00000200u;
}
infogain_loss_param_ = infogain_loss_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.infogain_loss_param)
}
// optional .caffe.InnerProductParameter inner_product_param = 17;
inline bool V1LayerParameter::_internal_has_inner_product_param() const {
bool value = (_has_bits_[0] & 0x00000400u) != 0;
PROTOBUF_ASSUME(!value || inner_product_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_inner_product_param() const {
return _internal_has_inner_product_param();
}
inline void V1LayerParameter::clear_inner_product_param() {
if (inner_product_param_ != nullptr) inner_product_param_->Clear();
_has_bits_[0] &= ~0x00000400u;
}
inline const ::caffe::InnerProductParameter& V1LayerParameter::_internal_inner_product_param() const {
const ::caffe::InnerProductParameter* p = inner_product_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::InnerProductParameter*>(
&::caffe::_InnerProductParameter_default_instance_);
}
inline const ::caffe::InnerProductParameter& V1LayerParameter::inner_product_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.inner_product_param)
return _internal_inner_product_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_inner_product_param(
::caffe::InnerProductParameter* inner_product_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(inner_product_param_);
}
inner_product_param_ = inner_product_param;
if (inner_product_param) {
_has_bits_[0] |= 0x00000400u;
} else {
_has_bits_[0] &= ~0x00000400u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.inner_product_param)
}
inline ::caffe::InnerProductParameter* V1LayerParameter::release_inner_product_param() {
_has_bits_[0] &= ~0x00000400u;
::caffe::InnerProductParameter* temp = inner_product_param_;
inner_product_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::InnerProductParameter* V1LayerParameter::unsafe_arena_release_inner_product_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.inner_product_param)
_has_bits_[0] &= ~0x00000400u;
::caffe::InnerProductParameter* temp = inner_product_param_;
inner_product_param_ = nullptr;
return temp;
}
inline ::caffe::InnerProductParameter* V1LayerParameter::_internal_mutable_inner_product_param() {
_has_bits_[0] |= 0x00000400u;
if (inner_product_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::InnerProductParameter>(GetArena());
inner_product_param_ = p;
}
return inner_product_param_;
}
inline ::caffe::InnerProductParameter* V1LayerParameter::mutable_inner_product_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.inner_product_param)
return _internal_mutable_inner_product_param();
}
inline void V1LayerParameter::set_allocated_inner_product_param(::caffe::InnerProductParameter* inner_product_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete inner_product_param_;
}
if (inner_product_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(inner_product_param);
if (message_arena != submessage_arena) {
inner_product_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, inner_product_param, submessage_arena);
}
_has_bits_[0] |= 0x00000400u;
} else {
_has_bits_[0] &= ~0x00000400u;
}
inner_product_param_ = inner_product_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.inner_product_param)
}
// optional .caffe.LRNParameter lrn_param = 18;
inline bool V1LayerParameter::_internal_has_lrn_param() const {
bool value = (_has_bits_[0] & 0x00000800u) != 0;
PROTOBUF_ASSUME(!value || lrn_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_lrn_param() const {
return _internal_has_lrn_param();
}
inline void V1LayerParameter::clear_lrn_param() {
if (lrn_param_ != nullptr) lrn_param_->Clear();
_has_bits_[0] &= ~0x00000800u;
}
inline const ::caffe::LRNParameter& V1LayerParameter::_internal_lrn_param() const {
const ::caffe::LRNParameter* p = lrn_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::LRNParameter*>(
&::caffe::_LRNParameter_default_instance_);
}
inline const ::caffe::LRNParameter& V1LayerParameter::lrn_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.lrn_param)
return _internal_lrn_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_lrn_param(
::caffe::LRNParameter* lrn_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(lrn_param_);
}
lrn_param_ = lrn_param;
if (lrn_param) {
_has_bits_[0] |= 0x00000800u;
} else {
_has_bits_[0] &= ~0x00000800u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.lrn_param)
}
inline ::caffe::LRNParameter* V1LayerParameter::release_lrn_param() {
_has_bits_[0] &= ~0x00000800u;
::caffe::LRNParameter* temp = lrn_param_;
lrn_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::LRNParameter* V1LayerParameter::unsafe_arena_release_lrn_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.lrn_param)
_has_bits_[0] &= ~0x00000800u;
::caffe::LRNParameter* temp = lrn_param_;
lrn_param_ = nullptr;
return temp;
}
inline ::caffe::LRNParameter* V1LayerParameter::_internal_mutable_lrn_param() {
_has_bits_[0] |= 0x00000800u;
if (lrn_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::LRNParameter>(GetArena());
lrn_param_ = p;
}
return lrn_param_;
}
inline ::caffe::LRNParameter* V1LayerParameter::mutable_lrn_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.lrn_param)
return _internal_mutable_lrn_param();
}
inline void V1LayerParameter::set_allocated_lrn_param(::caffe::LRNParameter* lrn_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete lrn_param_;
}
if (lrn_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(lrn_param);
if (message_arena != submessage_arena) {
lrn_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, lrn_param, submessage_arena);
}
_has_bits_[0] |= 0x00000800u;
} else {
_has_bits_[0] &= ~0x00000800u;
}
lrn_param_ = lrn_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.lrn_param)
}
// optional .caffe.MemoryDataParameter memory_data_param = 22;
inline bool V1LayerParameter::_internal_has_memory_data_param() const {
bool value = (_has_bits_[0] & 0x00008000u) != 0;
PROTOBUF_ASSUME(!value || memory_data_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_memory_data_param() const {
return _internal_has_memory_data_param();
}
inline void V1LayerParameter::clear_memory_data_param() {
if (memory_data_param_ != nullptr) memory_data_param_->Clear();
_has_bits_[0] &= ~0x00008000u;
}
inline const ::caffe::MemoryDataParameter& V1LayerParameter::_internal_memory_data_param() const {
const ::caffe::MemoryDataParameter* p = memory_data_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::MemoryDataParameter*>(
&::caffe::_MemoryDataParameter_default_instance_);
}
inline const ::caffe::MemoryDataParameter& V1LayerParameter::memory_data_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.memory_data_param)
return _internal_memory_data_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_memory_data_param(
::caffe::MemoryDataParameter* memory_data_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(memory_data_param_);
}
memory_data_param_ = memory_data_param;
if (memory_data_param) {
_has_bits_[0] |= 0x00008000u;
} else {
_has_bits_[0] &= ~0x00008000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.memory_data_param)
}
inline ::caffe::MemoryDataParameter* V1LayerParameter::release_memory_data_param() {
_has_bits_[0] &= ~0x00008000u;
::caffe::MemoryDataParameter* temp = memory_data_param_;
memory_data_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::MemoryDataParameter* V1LayerParameter::unsafe_arena_release_memory_data_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.memory_data_param)
_has_bits_[0] &= ~0x00008000u;
::caffe::MemoryDataParameter* temp = memory_data_param_;
memory_data_param_ = nullptr;
return temp;
}
inline ::caffe::MemoryDataParameter* V1LayerParameter::_internal_mutable_memory_data_param() {
_has_bits_[0] |= 0x00008000u;
if (memory_data_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::MemoryDataParameter>(GetArena());
memory_data_param_ = p;
}
return memory_data_param_;
}
inline ::caffe::MemoryDataParameter* V1LayerParameter::mutable_memory_data_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.memory_data_param)
return _internal_mutable_memory_data_param();
}
inline void V1LayerParameter::set_allocated_memory_data_param(::caffe::MemoryDataParameter* memory_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete memory_data_param_;
}
if (memory_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(memory_data_param);
if (message_arena != submessage_arena) {
memory_data_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, memory_data_param, submessage_arena);
}
_has_bits_[0] |= 0x00008000u;
} else {
_has_bits_[0] &= ~0x00008000u;
}
memory_data_param_ = memory_data_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.memory_data_param)
}
// optional .caffe.MVNParameter mvn_param = 34;
inline bool V1LayerParameter::_internal_has_mvn_param() const {
bool value = (_has_bits_[0] & 0x01000000u) != 0;
PROTOBUF_ASSUME(!value || mvn_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_mvn_param() const {
return _internal_has_mvn_param();
}
inline void V1LayerParameter::clear_mvn_param() {
if (mvn_param_ != nullptr) mvn_param_->Clear();
_has_bits_[0] &= ~0x01000000u;
}
inline const ::caffe::MVNParameter& V1LayerParameter::_internal_mvn_param() const {
const ::caffe::MVNParameter* p = mvn_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::MVNParameter*>(
&::caffe::_MVNParameter_default_instance_);
}
inline const ::caffe::MVNParameter& V1LayerParameter::mvn_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.mvn_param)
return _internal_mvn_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_mvn_param(
::caffe::MVNParameter* mvn_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(mvn_param_);
}
mvn_param_ = mvn_param;
if (mvn_param) {
_has_bits_[0] |= 0x01000000u;
} else {
_has_bits_[0] &= ~0x01000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.mvn_param)
}
inline ::caffe::MVNParameter* V1LayerParameter::release_mvn_param() {
_has_bits_[0] &= ~0x01000000u;
::caffe::MVNParameter* temp = mvn_param_;
mvn_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::MVNParameter* V1LayerParameter::unsafe_arena_release_mvn_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.mvn_param)
_has_bits_[0] &= ~0x01000000u;
::caffe::MVNParameter* temp = mvn_param_;
mvn_param_ = nullptr;
return temp;
}
inline ::caffe::MVNParameter* V1LayerParameter::_internal_mutable_mvn_param() {
_has_bits_[0] |= 0x01000000u;
if (mvn_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::MVNParameter>(GetArena());
mvn_param_ = p;
}
return mvn_param_;
}
inline ::caffe::MVNParameter* V1LayerParameter::mutable_mvn_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.mvn_param)
return _internal_mutable_mvn_param();
}
inline void V1LayerParameter::set_allocated_mvn_param(::caffe::MVNParameter* mvn_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete mvn_param_;
}
if (mvn_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(mvn_param);
if (message_arena != submessage_arena) {
mvn_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, mvn_param, submessage_arena);
}
_has_bits_[0] |= 0x01000000u;
} else {
_has_bits_[0] &= ~0x01000000u;
}
mvn_param_ = mvn_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.mvn_param)
}
// optional .caffe.PoolingParameter pooling_param = 19;
inline bool V1LayerParameter::_internal_has_pooling_param() const {
bool value = (_has_bits_[0] & 0x00001000u) != 0;
PROTOBUF_ASSUME(!value || pooling_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_pooling_param() const {
return _internal_has_pooling_param();
}
inline void V1LayerParameter::clear_pooling_param() {
if (pooling_param_ != nullptr) pooling_param_->Clear();
_has_bits_[0] &= ~0x00001000u;
}
inline const ::caffe::PoolingParameter& V1LayerParameter::_internal_pooling_param() const {
const ::caffe::PoolingParameter* p = pooling_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::PoolingParameter*>(
&::caffe::_PoolingParameter_default_instance_);
}
inline const ::caffe::PoolingParameter& V1LayerParameter::pooling_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.pooling_param)
return _internal_pooling_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_pooling_param(
::caffe::PoolingParameter* pooling_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(pooling_param_);
}
pooling_param_ = pooling_param;
if (pooling_param) {
_has_bits_[0] |= 0x00001000u;
} else {
_has_bits_[0] &= ~0x00001000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.pooling_param)
}
inline ::caffe::PoolingParameter* V1LayerParameter::release_pooling_param() {
_has_bits_[0] &= ~0x00001000u;
::caffe::PoolingParameter* temp = pooling_param_;
pooling_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::PoolingParameter* V1LayerParameter::unsafe_arena_release_pooling_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.pooling_param)
_has_bits_[0] &= ~0x00001000u;
::caffe::PoolingParameter* temp = pooling_param_;
pooling_param_ = nullptr;
return temp;
}
inline ::caffe::PoolingParameter* V1LayerParameter::_internal_mutable_pooling_param() {
_has_bits_[0] |= 0x00001000u;
if (pooling_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::PoolingParameter>(GetArena());
pooling_param_ = p;
}
return pooling_param_;
}
inline ::caffe::PoolingParameter* V1LayerParameter::mutable_pooling_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.pooling_param)
return _internal_mutable_pooling_param();
}
inline void V1LayerParameter::set_allocated_pooling_param(::caffe::PoolingParameter* pooling_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete pooling_param_;
}
if (pooling_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(pooling_param);
if (message_arena != submessage_arena) {
pooling_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, pooling_param, submessage_arena);
}
_has_bits_[0] |= 0x00001000u;
} else {
_has_bits_[0] &= ~0x00001000u;
}
pooling_param_ = pooling_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.pooling_param)
}
// optional .caffe.PowerParameter power_param = 21;
inline bool V1LayerParameter::_internal_has_power_param() const {
bool value = (_has_bits_[0] & 0x00004000u) != 0;
PROTOBUF_ASSUME(!value || power_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_power_param() const {
return _internal_has_power_param();
}
inline void V1LayerParameter::clear_power_param() {
if (power_param_ != nullptr) power_param_->Clear();
_has_bits_[0] &= ~0x00004000u;
}
inline const ::caffe::PowerParameter& V1LayerParameter::_internal_power_param() const {
const ::caffe::PowerParameter* p = power_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::PowerParameter*>(
&::caffe::_PowerParameter_default_instance_);
}
inline const ::caffe::PowerParameter& V1LayerParameter::power_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.power_param)
return _internal_power_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_power_param(
::caffe::PowerParameter* power_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(power_param_);
}
power_param_ = power_param;
if (power_param) {
_has_bits_[0] |= 0x00004000u;
} else {
_has_bits_[0] &= ~0x00004000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.power_param)
}
inline ::caffe::PowerParameter* V1LayerParameter::release_power_param() {
_has_bits_[0] &= ~0x00004000u;
::caffe::PowerParameter* temp = power_param_;
power_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::PowerParameter* V1LayerParameter::unsafe_arena_release_power_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.power_param)
_has_bits_[0] &= ~0x00004000u;
::caffe::PowerParameter* temp = power_param_;
power_param_ = nullptr;
return temp;
}
inline ::caffe::PowerParameter* V1LayerParameter::_internal_mutable_power_param() {
_has_bits_[0] |= 0x00004000u;
if (power_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::PowerParameter>(GetArena());
power_param_ = p;
}
return power_param_;
}
inline ::caffe::PowerParameter* V1LayerParameter::mutable_power_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.power_param)
return _internal_mutable_power_param();
}
inline void V1LayerParameter::set_allocated_power_param(::caffe::PowerParameter* power_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete power_param_;
}
if (power_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(power_param);
if (message_arena != submessage_arena) {
power_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, power_param, submessage_arena);
}
_has_bits_[0] |= 0x00004000u;
} else {
_has_bits_[0] &= ~0x00004000u;
}
power_param_ = power_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.power_param)
}
// optional .caffe.ReLUParameter relu_param = 30;
inline bool V1LayerParameter::_internal_has_relu_param() const {
bool value = (_has_bits_[0] & 0x00400000u) != 0;
PROTOBUF_ASSUME(!value || relu_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_relu_param() const {
return _internal_has_relu_param();
}
inline void V1LayerParameter::clear_relu_param() {
if (relu_param_ != nullptr) relu_param_->Clear();
_has_bits_[0] &= ~0x00400000u;
}
inline const ::caffe::ReLUParameter& V1LayerParameter::_internal_relu_param() const {
const ::caffe::ReLUParameter* p = relu_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ReLUParameter*>(
&::caffe::_ReLUParameter_default_instance_);
}
inline const ::caffe::ReLUParameter& V1LayerParameter::relu_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.relu_param)
return _internal_relu_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_relu_param(
::caffe::ReLUParameter* relu_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(relu_param_);
}
relu_param_ = relu_param;
if (relu_param) {
_has_bits_[0] |= 0x00400000u;
} else {
_has_bits_[0] &= ~0x00400000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.relu_param)
}
inline ::caffe::ReLUParameter* V1LayerParameter::release_relu_param() {
_has_bits_[0] &= ~0x00400000u;
::caffe::ReLUParameter* temp = relu_param_;
relu_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ReLUParameter* V1LayerParameter::unsafe_arena_release_relu_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.relu_param)
_has_bits_[0] &= ~0x00400000u;
::caffe::ReLUParameter* temp = relu_param_;
relu_param_ = nullptr;
return temp;
}
inline ::caffe::ReLUParameter* V1LayerParameter::_internal_mutable_relu_param() {
_has_bits_[0] |= 0x00400000u;
if (relu_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ReLUParameter>(GetArena());
relu_param_ = p;
}
return relu_param_;
}
inline ::caffe::ReLUParameter* V1LayerParameter::mutable_relu_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.relu_param)
return _internal_mutable_relu_param();
}
inline void V1LayerParameter::set_allocated_relu_param(::caffe::ReLUParameter* relu_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete relu_param_;
}
if (relu_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(relu_param);
if (message_arena != submessage_arena) {
relu_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, relu_param, submessage_arena);
}
_has_bits_[0] |= 0x00400000u;
} else {
_has_bits_[0] &= ~0x00400000u;
}
relu_param_ = relu_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.relu_param)
}
// optional .caffe.SigmoidParameter sigmoid_param = 38;
inline bool V1LayerParameter::_internal_has_sigmoid_param() const {
bool value = (_has_bits_[0] & 0x08000000u) != 0;
PROTOBUF_ASSUME(!value || sigmoid_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_sigmoid_param() const {
return _internal_has_sigmoid_param();
}
inline void V1LayerParameter::clear_sigmoid_param() {
if (sigmoid_param_ != nullptr) sigmoid_param_->Clear();
_has_bits_[0] &= ~0x08000000u;
}
inline const ::caffe::SigmoidParameter& V1LayerParameter::_internal_sigmoid_param() const {
const ::caffe::SigmoidParameter* p = sigmoid_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::SigmoidParameter*>(
&::caffe::_SigmoidParameter_default_instance_);
}
inline const ::caffe::SigmoidParameter& V1LayerParameter::sigmoid_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.sigmoid_param)
return _internal_sigmoid_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_sigmoid_param(
::caffe::SigmoidParameter* sigmoid_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(sigmoid_param_);
}
sigmoid_param_ = sigmoid_param;
if (sigmoid_param) {
_has_bits_[0] |= 0x08000000u;
} else {
_has_bits_[0] &= ~0x08000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.sigmoid_param)
}
inline ::caffe::SigmoidParameter* V1LayerParameter::release_sigmoid_param() {
_has_bits_[0] &= ~0x08000000u;
::caffe::SigmoidParameter* temp = sigmoid_param_;
sigmoid_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::SigmoidParameter* V1LayerParameter::unsafe_arena_release_sigmoid_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.sigmoid_param)
_has_bits_[0] &= ~0x08000000u;
::caffe::SigmoidParameter* temp = sigmoid_param_;
sigmoid_param_ = nullptr;
return temp;
}
inline ::caffe::SigmoidParameter* V1LayerParameter::_internal_mutable_sigmoid_param() {
_has_bits_[0] |= 0x08000000u;
if (sigmoid_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::SigmoidParameter>(GetArena());
sigmoid_param_ = p;
}
return sigmoid_param_;
}
inline ::caffe::SigmoidParameter* V1LayerParameter::mutable_sigmoid_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.sigmoid_param)
return _internal_mutable_sigmoid_param();
}
inline void V1LayerParameter::set_allocated_sigmoid_param(::caffe::SigmoidParameter* sigmoid_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete sigmoid_param_;
}
if (sigmoid_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(sigmoid_param);
if (message_arena != submessage_arena) {
sigmoid_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, sigmoid_param, submessage_arena);
}
_has_bits_[0] |= 0x08000000u;
} else {
_has_bits_[0] &= ~0x08000000u;
}
sigmoid_param_ = sigmoid_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.sigmoid_param)
}
// optional .caffe.SoftmaxParameter softmax_param = 39;
inline bool V1LayerParameter::_internal_has_softmax_param() const {
bool value = (_has_bits_[0] & 0x10000000u) != 0;
PROTOBUF_ASSUME(!value || softmax_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_softmax_param() const {
return _internal_has_softmax_param();
}
inline void V1LayerParameter::clear_softmax_param() {
if (softmax_param_ != nullptr) softmax_param_->Clear();
_has_bits_[0] &= ~0x10000000u;
}
inline const ::caffe::SoftmaxParameter& V1LayerParameter::_internal_softmax_param() const {
const ::caffe::SoftmaxParameter* p = softmax_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::SoftmaxParameter*>(
&::caffe::_SoftmaxParameter_default_instance_);
}
inline const ::caffe::SoftmaxParameter& V1LayerParameter::softmax_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.softmax_param)
return _internal_softmax_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_softmax_param(
::caffe::SoftmaxParameter* softmax_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(softmax_param_);
}
softmax_param_ = softmax_param;
if (softmax_param) {
_has_bits_[0] |= 0x10000000u;
} else {
_has_bits_[0] &= ~0x10000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.softmax_param)
}
inline ::caffe::SoftmaxParameter* V1LayerParameter::release_softmax_param() {
_has_bits_[0] &= ~0x10000000u;
::caffe::SoftmaxParameter* temp = softmax_param_;
softmax_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::SoftmaxParameter* V1LayerParameter::unsafe_arena_release_softmax_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.softmax_param)
_has_bits_[0] &= ~0x10000000u;
::caffe::SoftmaxParameter* temp = softmax_param_;
softmax_param_ = nullptr;
return temp;
}
inline ::caffe::SoftmaxParameter* V1LayerParameter::_internal_mutable_softmax_param() {
_has_bits_[0] |= 0x10000000u;
if (softmax_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::SoftmaxParameter>(GetArena());
softmax_param_ = p;
}
return softmax_param_;
}
inline ::caffe::SoftmaxParameter* V1LayerParameter::mutable_softmax_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.softmax_param)
return _internal_mutable_softmax_param();
}
inline void V1LayerParameter::set_allocated_softmax_param(::caffe::SoftmaxParameter* softmax_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete softmax_param_;
}
if (softmax_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(softmax_param);
if (message_arena != submessage_arena) {
softmax_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, softmax_param, submessage_arena);
}
_has_bits_[0] |= 0x10000000u;
} else {
_has_bits_[0] &= ~0x10000000u;
}
softmax_param_ = softmax_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.softmax_param)
}
// optional .caffe.SliceParameter slice_param = 31;
inline bool V1LayerParameter::_internal_has_slice_param() const {
bool value = (_has_bits_[0] & 0x00800000u) != 0;
PROTOBUF_ASSUME(!value || slice_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_slice_param() const {
return _internal_has_slice_param();
}
inline void V1LayerParameter::clear_slice_param() {
if (slice_param_ != nullptr) slice_param_->Clear();
_has_bits_[0] &= ~0x00800000u;
}
inline const ::caffe::SliceParameter& V1LayerParameter::_internal_slice_param() const {
const ::caffe::SliceParameter* p = slice_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::SliceParameter*>(
&::caffe::_SliceParameter_default_instance_);
}
inline const ::caffe::SliceParameter& V1LayerParameter::slice_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.slice_param)
return _internal_slice_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_slice_param(
::caffe::SliceParameter* slice_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(slice_param_);
}
slice_param_ = slice_param;
if (slice_param) {
_has_bits_[0] |= 0x00800000u;
} else {
_has_bits_[0] &= ~0x00800000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.slice_param)
}
inline ::caffe::SliceParameter* V1LayerParameter::release_slice_param() {
_has_bits_[0] &= ~0x00800000u;
::caffe::SliceParameter* temp = slice_param_;
slice_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::SliceParameter* V1LayerParameter::unsafe_arena_release_slice_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.slice_param)
_has_bits_[0] &= ~0x00800000u;
::caffe::SliceParameter* temp = slice_param_;
slice_param_ = nullptr;
return temp;
}
inline ::caffe::SliceParameter* V1LayerParameter::_internal_mutable_slice_param() {
_has_bits_[0] |= 0x00800000u;
if (slice_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::SliceParameter>(GetArena());
slice_param_ = p;
}
return slice_param_;
}
inline ::caffe::SliceParameter* V1LayerParameter::mutable_slice_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.slice_param)
return _internal_mutable_slice_param();
}
inline void V1LayerParameter::set_allocated_slice_param(::caffe::SliceParameter* slice_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete slice_param_;
}
if (slice_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(slice_param);
if (message_arena != submessage_arena) {
slice_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, slice_param, submessage_arena);
}
_has_bits_[0] |= 0x00800000u;
} else {
_has_bits_[0] &= ~0x00800000u;
}
slice_param_ = slice_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.slice_param)
}
// optional .caffe.TanHParameter tanh_param = 37;
inline bool V1LayerParameter::_internal_has_tanh_param() const {
bool value = (_has_bits_[0] & 0x04000000u) != 0;
PROTOBUF_ASSUME(!value || tanh_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_tanh_param() const {
return _internal_has_tanh_param();
}
inline void V1LayerParameter::clear_tanh_param() {
if (tanh_param_ != nullptr) tanh_param_->Clear();
_has_bits_[0] &= ~0x04000000u;
}
inline const ::caffe::TanHParameter& V1LayerParameter::_internal_tanh_param() const {
const ::caffe::TanHParameter* p = tanh_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::TanHParameter*>(
&::caffe::_TanHParameter_default_instance_);
}
inline const ::caffe::TanHParameter& V1LayerParameter::tanh_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.tanh_param)
return _internal_tanh_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_tanh_param(
::caffe::TanHParameter* tanh_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(tanh_param_);
}
tanh_param_ = tanh_param;
if (tanh_param) {
_has_bits_[0] |= 0x04000000u;
} else {
_has_bits_[0] &= ~0x04000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.tanh_param)
}
inline ::caffe::TanHParameter* V1LayerParameter::release_tanh_param() {
_has_bits_[0] &= ~0x04000000u;
::caffe::TanHParameter* temp = tanh_param_;
tanh_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::TanHParameter* V1LayerParameter::unsafe_arena_release_tanh_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.tanh_param)
_has_bits_[0] &= ~0x04000000u;
::caffe::TanHParameter* temp = tanh_param_;
tanh_param_ = nullptr;
return temp;
}
inline ::caffe::TanHParameter* V1LayerParameter::_internal_mutable_tanh_param() {
_has_bits_[0] |= 0x04000000u;
if (tanh_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::TanHParameter>(GetArena());
tanh_param_ = p;
}
return tanh_param_;
}
inline ::caffe::TanHParameter* V1LayerParameter::mutable_tanh_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.tanh_param)
return _internal_mutable_tanh_param();
}
inline void V1LayerParameter::set_allocated_tanh_param(::caffe::TanHParameter* tanh_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete tanh_param_;
}
if (tanh_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(tanh_param);
if (message_arena != submessage_arena) {
tanh_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, tanh_param, submessage_arena);
}
_has_bits_[0] |= 0x04000000u;
} else {
_has_bits_[0] &= ~0x04000000u;
}
tanh_param_ = tanh_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.tanh_param)
}
// optional .caffe.ThresholdParameter threshold_param = 25;
inline bool V1LayerParameter::_internal_has_threshold_param() const {
bool value = (_has_bits_[0] & 0x00040000u) != 0;
PROTOBUF_ASSUME(!value || threshold_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_threshold_param() const {
return _internal_has_threshold_param();
}
inline void V1LayerParameter::clear_threshold_param() {
if (threshold_param_ != nullptr) threshold_param_->Clear();
_has_bits_[0] &= ~0x00040000u;
}
inline const ::caffe::ThresholdParameter& V1LayerParameter::_internal_threshold_param() const {
const ::caffe::ThresholdParameter* p = threshold_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::ThresholdParameter*>(
&::caffe::_ThresholdParameter_default_instance_);
}
inline const ::caffe::ThresholdParameter& V1LayerParameter::threshold_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.threshold_param)
return _internal_threshold_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_threshold_param(
::caffe::ThresholdParameter* threshold_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(threshold_param_);
}
threshold_param_ = threshold_param;
if (threshold_param) {
_has_bits_[0] |= 0x00040000u;
} else {
_has_bits_[0] &= ~0x00040000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.threshold_param)
}
inline ::caffe::ThresholdParameter* V1LayerParameter::release_threshold_param() {
_has_bits_[0] &= ~0x00040000u;
::caffe::ThresholdParameter* temp = threshold_param_;
threshold_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::ThresholdParameter* V1LayerParameter::unsafe_arena_release_threshold_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.threshold_param)
_has_bits_[0] &= ~0x00040000u;
::caffe::ThresholdParameter* temp = threshold_param_;
threshold_param_ = nullptr;
return temp;
}
inline ::caffe::ThresholdParameter* V1LayerParameter::_internal_mutable_threshold_param() {
_has_bits_[0] |= 0x00040000u;
if (threshold_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::ThresholdParameter>(GetArena());
threshold_param_ = p;
}
return threshold_param_;
}
inline ::caffe::ThresholdParameter* V1LayerParameter::mutable_threshold_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.threshold_param)
return _internal_mutable_threshold_param();
}
inline void V1LayerParameter::set_allocated_threshold_param(::caffe::ThresholdParameter* threshold_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete threshold_param_;
}
if (threshold_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(threshold_param);
if (message_arena != submessage_arena) {
threshold_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, threshold_param, submessage_arena);
}
_has_bits_[0] |= 0x00040000u;
} else {
_has_bits_[0] &= ~0x00040000u;
}
threshold_param_ = threshold_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.threshold_param)
}
// optional .caffe.WindowDataParameter window_data_param = 20;
inline bool V1LayerParameter::_internal_has_window_data_param() const {
bool value = (_has_bits_[0] & 0x00002000u) != 0;
PROTOBUF_ASSUME(!value || window_data_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_window_data_param() const {
return _internal_has_window_data_param();
}
inline void V1LayerParameter::clear_window_data_param() {
if (window_data_param_ != nullptr) window_data_param_->Clear();
_has_bits_[0] &= ~0x00002000u;
}
inline const ::caffe::WindowDataParameter& V1LayerParameter::_internal_window_data_param() const {
const ::caffe::WindowDataParameter* p = window_data_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::WindowDataParameter*>(
&::caffe::_WindowDataParameter_default_instance_);
}
inline const ::caffe::WindowDataParameter& V1LayerParameter::window_data_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.window_data_param)
return _internal_window_data_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_window_data_param(
::caffe::WindowDataParameter* window_data_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(window_data_param_);
}
window_data_param_ = window_data_param;
if (window_data_param) {
_has_bits_[0] |= 0x00002000u;
} else {
_has_bits_[0] &= ~0x00002000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.window_data_param)
}
inline ::caffe::WindowDataParameter* V1LayerParameter::release_window_data_param() {
_has_bits_[0] &= ~0x00002000u;
::caffe::WindowDataParameter* temp = window_data_param_;
window_data_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::WindowDataParameter* V1LayerParameter::unsafe_arena_release_window_data_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.window_data_param)
_has_bits_[0] &= ~0x00002000u;
::caffe::WindowDataParameter* temp = window_data_param_;
window_data_param_ = nullptr;
return temp;
}
inline ::caffe::WindowDataParameter* V1LayerParameter::_internal_mutable_window_data_param() {
_has_bits_[0] |= 0x00002000u;
if (window_data_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::WindowDataParameter>(GetArena());
window_data_param_ = p;
}
return window_data_param_;
}
inline ::caffe::WindowDataParameter* V1LayerParameter::mutable_window_data_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.window_data_param)
return _internal_mutable_window_data_param();
}
inline void V1LayerParameter::set_allocated_window_data_param(::caffe::WindowDataParameter* window_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete window_data_param_;
}
if (window_data_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(window_data_param);
if (message_arena != submessage_arena) {
window_data_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, window_data_param, submessage_arena);
}
_has_bits_[0] |= 0x00002000u;
} else {
_has_bits_[0] &= ~0x00002000u;
}
window_data_param_ = window_data_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.window_data_param)
}
// optional .caffe.TransformationParameter transform_param = 36;
inline bool V1LayerParameter::_internal_has_transform_param() const {
bool value = (_has_bits_[0] & 0x02000000u) != 0;
PROTOBUF_ASSUME(!value || transform_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_transform_param() const {
return _internal_has_transform_param();
}
inline void V1LayerParameter::clear_transform_param() {
if (transform_param_ != nullptr) transform_param_->Clear();
_has_bits_[0] &= ~0x02000000u;
}
inline const ::caffe::TransformationParameter& V1LayerParameter::_internal_transform_param() const {
const ::caffe::TransformationParameter* p = transform_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::TransformationParameter*>(
&::caffe::_TransformationParameter_default_instance_);
}
inline const ::caffe::TransformationParameter& V1LayerParameter::transform_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.transform_param)
return _internal_transform_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_transform_param(
::caffe::TransformationParameter* transform_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(transform_param_);
}
transform_param_ = transform_param;
if (transform_param) {
_has_bits_[0] |= 0x02000000u;
} else {
_has_bits_[0] &= ~0x02000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.transform_param)
}
inline ::caffe::TransformationParameter* V1LayerParameter::release_transform_param() {
_has_bits_[0] &= ~0x02000000u;
::caffe::TransformationParameter* temp = transform_param_;
transform_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::TransformationParameter* V1LayerParameter::unsafe_arena_release_transform_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.transform_param)
_has_bits_[0] &= ~0x02000000u;
::caffe::TransformationParameter* temp = transform_param_;
transform_param_ = nullptr;
return temp;
}
inline ::caffe::TransformationParameter* V1LayerParameter::_internal_mutable_transform_param() {
_has_bits_[0] |= 0x02000000u;
if (transform_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::TransformationParameter>(GetArena());
transform_param_ = p;
}
return transform_param_;
}
inline ::caffe::TransformationParameter* V1LayerParameter::mutable_transform_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.transform_param)
return _internal_mutable_transform_param();
}
inline void V1LayerParameter::set_allocated_transform_param(::caffe::TransformationParameter* transform_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete transform_param_;
}
if (transform_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(transform_param);
if (message_arena != submessage_arena) {
transform_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, transform_param, submessage_arena);
}
_has_bits_[0] |= 0x02000000u;
} else {
_has_bits_[0] &= ~0x02000000u;
}
transform_param_ = transform_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.transform_param)
}
// optional .caffe.LossParameter loss_param = 42;
inline bool V1LayerParameter::_internal_has_loss_param() const {
bool value = (_has_bits_[0] & 0x80000000u) != 0;
PROTOBUF_ASSUME(!value || loss_param_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_loss_param() const {
return _internal_has_loss_param();
}
inline void V1LayerParameter::clear_loss_param() {
if (loss_param_ != nullptr) loss_param_->Clear();
_has_bits_[0] &= ~0x80000000u;
}
inline const ::caffe::LossParameter& V1LayerParameter::_internal_loss_param() const {
const ::caffe::LossParameter* p = loss_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::LossParameter*>(
&::caffe::_LossParameter_default_instance_);
}
inline const ::caffe::LossParameter& V1LayerParameter::loss_param() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.loss_param)
return _internal_loss_param();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_loss_param(
::caffe::LossParameter* loss_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(loss_param_);
}
loss_param_ = loss_param;
if (loss_param) {
_has_bits_[0] |= 0x80000000u;
} else {
_has_bits_[0] &= ~0x80000000u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.loss_param)
}
inline ::caffe::LossParameter* V1LayerParameter::release_loss_param() {
_has_bits_[0] &= ~0x80000000u;
::caffe::LossParameter* temp = loss_param_;
loss_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::LossParameter* V1LayerParameter::unsafe_arena_release_loss_param() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.loss_param)
_has_bits_[0] &= ~0x80000000u;
::caffe::LossParameter* temp = loss_param_;
loss_param_ = nullptr;
return temp;
}
inline ::caffe::LossParameter* V1LayerParameter::_internal_mutable_loss_param() {
_has_bits_[0] |= 0x80000000u;
if (loss_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::LossParameter>(GetArena());
loss_param_ = p;
}
return loss_param_;
}
inline ::caffe::LossParameter* V1LayerParameter::mutable_loss_param() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.loss_param)
return _internal_mutable_loss_param();
}
inline void V1LayerParameter::set_allocated_loss_param(::caffe::LossParameter* loss_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete loss_param_;
}
if (loss_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(loss_param);
if (message_arena != submessage_arena) {
loss_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, loss_param, submessage_arena);
}
_has_bits_[0] |= 0x80000000u;
} else {
_has_bits_[0] &= ~0x80000000u;
}
loss_param_ = loss_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.loss_param)
}
// optional .caffe.V0LayerParameter layer = 1;
inline bool V1LayerParameter::_internal_has_layer() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
PROTOBUF_ASSUME(!value || layer_ != nullptr);
return value;
}
inline bool V1LayerParameter::has_layer() const {
return _internal_has_layer();
}
inline void V1LayerParameter::clear_layer() {
if (layer_ != nullptr) layer_->Clear();
_has_bits_[0] &= ~0x00000002u;
}
inline const ::caffe::V0LayerParameter& V1LayerParameter::_internal_layer() const {
const ::caffe::V0LayerParameter* p = layer_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::V0LayerParameter*>(
&::caffe::_V0LayerParameter_default_instance_);
}
inline const ::caffe::V0LayerParameter& V1LayerParameter::layer() const {
// @@protoc_insertion_point(field_get:caffe.V1LayerParameter.layer)
return _internal_layer();
}
inline void V1LayerParameter::unsafe_arena_set_allocated_layer(
::caffe::V0LayerParameter* layer) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(layer_);
}
layer_ = layer;
if (layer) {
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V1LayerParameter.layer)
}
inline ::caffe::V0LayerParameter* V1LayerParameter::release_layer() {
_has_bits_[0] &= ~0x00000002u;
::caffe::V0LayerParameter* temp = layer_;
layer_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::V0LayerParameter* V1LayerParameter::unsafe_arena_release_layer() {
// @@protoc_insertion_point(field_release:caffe.V1LayerParameter.layer)
_has_bits_[0] &= ~0x00000002u;
::caffe::V0LayerParameter* temp = layer_;
layer_ = nullptr;
return temp;
}
inline ::caffe::V0LayerParameter* V1LayerParameter::_internal_mutable_layer() {
_has_bits_[0] |= 0x00000002u;
if (layer_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::V0LayerParameter>(GetArena());
layer_ = p;
}
return layer_;
}
inline ::caffe::V0LayerParameter* V1LayerParameter::mutable_layer() {
// @@protoc_insertion_point(field_mutable:caffe.V1LayerParameter.layer)
return _internal_mutable_layer();
}
inline void V1LayerParameter::set_allocated_layer(::caffe::V0LayerParameter* layer) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete layer_;
}
if (layer) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(layer);
if (message_arena != submessage_arena) {
layer = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, layer, submessage_arena);
}
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
layer_ = layer;
// @@protoc_insertion_point(field_set_allocated:caffe.V1LayerParameter.layer)
}
// -------------------------------------------------------------------
// V0LayerParameter
// optional string name = 1;
inline bool V0LayerParameter::_internal_has_name() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool V0LayerParameter::has_name() const {
return _internal_has_name();
}
inline void V0LayerParameter::clear_name() {
name_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000001u;
}
inline const std::string& V0LayerParameter::name() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.name)
return _internal_name();
}
inline void V0LayerParameter::set_name(const std::string& value) {
_internal_set_name(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.name)
}
inline std::string* V0LayerParameter::mutable_name() {
// @@protoc_insertion_point(field_mutable:caffe.V0LayerParameter.name)
return _internal_mutable_name();
}
inline const std::string& V0LayerParameter::_internal_name() const {
return name_.Get();
}
inline void V0LayerParameter::_internal_set_name(const std::string& value) {
_has_bits_[0] |= 0x00000001u;
name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void V0LayerParameter::set_name(std::string&& value) {
_has_bits_[0] |= 0x00000001u;
name_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.V0LayerParameter.name)
}
inline void V0LayerParameter::set_name(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000001u;
name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.V0LayerParameter.name)
}
inline void V0LayerParameter::set_name(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000001u;
name_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.V0LayerParameter.name)
}
inline std::string* V0LayerParameter::_internal_mutable_name() {
_has_bits_[0] |= 0x00000001u;
return name_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* V0LayerParameter::release_name() {
// @@protoc_insertion_point(field_release:caffe.V0LayerParameter.name)
if (!_internal_has_name()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000001u;
return name_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void V0LayerParameter::set_allocated_name(std::string* name) {
if (name != nullptr) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
name_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), name,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.V0LayerParameter.name)
}
// optional string type = 2;
inline bool V0LayerParameter::_internal_has_type() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool V0LayerParameter::has_type() const {
return _internal_has_type();
}
inline void V0LayerParameter::clear_type() {
type_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000002u;
}
inline const std::string& V0LayerParameter::type() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.type)
return _internal_type();
}
inline void V0LayerParameter::set_type(const std::string& value) {
_internal_set_type(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.type)
}
inline std::string* V0LayerParameter::mutable_type() {
// @@protoc_insertion_point(field_mutable:caffe.V0LayerParameter.type)
return _internal_mutable_type();
}
inline const std::string& V0LayerParameter::_internal_type() const {
return type_.Get();
}
inline void V0LayerParameter::_internal_set_type(const std::string& value) {
_has_bits_[0] |= 0x00000002u;
type_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void V0LayerParameter::set_type(std::string&& value) {
_has_bits_[0] |= 0x00000002u;
type_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.V0LayerParameter.type)
}
inline void V0LayerParameter::set_type(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000002u;
type_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.V0LayerParameter.type)
}
inline void V0LayerParameter::set_type(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000002u;
type_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.V0LayerParameter.type)
}
inline std::string* V0LayerParameter::_internal_mutable_type() {
_has_bits_[0] |= 0x00000002u;
return type_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* V0LayerParameter::release_type() {
// @@protoc_insertion_point(field_release:caffe.V0LayerParameter.type)
if (!_internal_has_type()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000002u;
return type_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void V0LayerParameter::set_allocated_type(std::string* type) {
if (type != nullptr) {
_has_bits_[0] |= 0x00000002u;
} else {
_has_bits_[0] &= ~0x00000002u;
}
type_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), type,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.V0LayerParameter.type)
}
// optional uint32 num_output = 3;
inline bool V0LayerParameter::_internal_has_num_output() const {
bool value = (_has_bits_[0] & 0x00000100u) != 0;
return value;
}
inline bool V0LayerParameter::has_num_output() const {
return _internal_has_num_output();
}
inline void V0LayerParameter::clear_num_output() {
num_output_ = 0u;
_has_bits_[0] &= ~0x00000100u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 V0LayerParameter::_internal_num_output() const {
return num_output_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 V0LayerParameter::num_output() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.num_output)
return _internal_num_output();
}
inline void V0LayerParameter::_internal_set_num_output(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000100u;
num_output_ = value;
}
inline void V0LayerParameter::set_num_output(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_num_output(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.num_output)
}
// optional bool biasterm = 4 [default = true];
inline bool V0LayerParameter::_internal_has_biasterm() const {
bool value = (_has_bits_[0] & 0x00800000u) != 0;
return value;
}
inline bool V0LayerParameter::has_biasterm() const {
return _internal_has_biasterm();
}
inline void V0LayerParameter::clear_biasterm() {
biasterm_ = true;
_has_bits_[0] &= ~0x00800000u;
}
inline bool V0LayerParameter::_internal_biasterm() const {
return biasterm_;
}
inline bool V0LayerParameter::biasterm() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.biasterm)
return _internal_biasterm();
}
inline void V0LayerParameter::_internal_set_biasterm(bool value) {
_has_bits_[0] |= 0x00800000u;
biasterm_ = value;
}
inline void V0LayerParameter::set_biasterm(bool value) {
_internal_set_biasterm(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.biasterm)
}
// optional .caffe.FillerParameter weight_filler = 5;
inline bool V0LayerParameter::_internal_has_weight_filler() const {
bool value = (_has_bits_[0] & 0x00000020u) != 0;
PROTOBUF_ASSUME(!value || weight_filler_ != nullptr);
return value;
}
inline bool V0LayerParameter::has_weight_filler() const {
return _internal_has_weight_filler();
}
inline void V0LayerParameter::clear_weight_filler() {
if (weight_filler_ != nullptr) weight_filler_->Clear();
_has_bits_[0] &= ~0x00000020u;
}
inline const ::caffe::FillerParameter& V0LayerParameter::_internal_weight_filler() const {
const ::caffe::FillerParameter* p = weight_filler_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::FillerParameter*>(
&::caffe::_FillerParameter_default_instance_);
}
inline const ::caffe::FillerParameter& V0LayerParameter::weight_filler() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.weight_filler)
return _internal_weight_filler();
}
inline void V0LayerParameter::unsafe_arena_set_allocated_weight_filler(
::caffe::FillerParameter* weight_filler) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(weight_filler_);
}
weight_filler_ = weight_filler;
if (weight_filler) {
_has_bits_[0] |= 0x00000020u;
} else {
_has_bits_[0] &= ~0x00000020u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V0LayerParameter.weight_filler)
}
inline ::caffe::FillerParameter* V0LayerParameter::release_weight_filler() {
_has_bits_[0] &= ~0x00000020u;
::caffe::FillerParameter* temp = weight_filler_;
weight_filler_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::FillerParameter* V0LayerParameter::unsafe_arena_release_weight_filler() {
// @@protoc_insertion_point(field_release:caffe.V0LayerParameter.weight_filler)
_has_bits_[0] &= ~0x00000020u;
::caffe::FillerParameter* temp = weight_filler_;
weight_filler_ = nullptr;
return temp;
}
inline ::caffe::FillerParameter* V0LayerParameter::_internal_mutable_weight_filler() {
_has_bits_[0] |= 0x00000020u;
if (weight_filler_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::FillerParameter>(GetArena());
weight_filler_ = p;
}
return weight_filler_;
}
inline ::caffe::FillerParameter* V0LayerParameter::mutable_weight_filler() {
// @@protoc_insertion_point(field_mutable:caffe.V0LayerParameter.weight_filler)
return _internal_mutable_weight_filler();
}
inline void V0LayerParameter::set_allocated_weight_filler(::caffe::FillerParameter* weight_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete weight_filler_;
}
if (weight_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(weight_filler);
if (message_arena != submessage_arena) {
weight_filler = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, weight_filler, submessage_arena);
}
_has_bits_[0] |= 0x00000020u;
} else {
_has_bits_[0] &= ~0x00000020u;
}
weight_filler_ = weight_filler;
// @@protoc_insertion_point(field_set_allocated:caffe.V0LayerParameter.weight_filler)
}
// optional .caffe.FillerParameter bias_filler = 6;
inline bool V0LayerParameter::_internal_has_bias_filler() const {
bool value = (_has_bits_[0] & 0x00000040u) != 0;
PROTOBUF_ASSUME(!value || bias_filler_ != nullptr);
return value;
}
inline bool V0LayerParameter::has_bias_filler() const {
return _internal_has_bias_filler();
}
inline void V0LayerParameter::clear_bias_filler() {
if (bias_filler_ != nullptr) bias_filler_->Clear();
_has_bits_[0] &= ~0x00000040u;
}
inline const ::caffe::FillerParameter& V0LayerParameter::_internal_bias_filler() const {
const ::caffe::FillerParameter* p = bias_filler_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::FillerParameter*>(
&::caffe::_FillerParameter_default_instance_);
}
inline const ::caffe::FillerParameter& V0LayerParameter::bias_filler() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.bias_filler)
return _internal_bias_filler();
}
inline void V0LayerParameter::unsafe_arena_set_allocated_bias_filler(
::caffe::FillerParameter* bias_filler) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(bias_filler_);
}
bias_filler_ = bias_filler;
if (bias_filler) {
_has_bits_[0] |= 0x00000040u;
} else {
_has_bits_[0] &= ~0x00000040u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V0LayerParameter.bias_filler)
}
inline ::caffe::FillerParameter* V0LayerParameter::release_bias_filler() {
_has_bits_[0] &= ~0x00000040u;
::caffe::FillerParameter* temp = bias_filler_;
bias_filler_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::FillerParameter* V0LayerParameter::unsafe_arena_release_bias_filler() {
// @@protoc_insertion_point(field_release:caffe.V0LayerParameter.bias_filler)
_has_bits_[0] &= ~0x00000040u;
::caffe::FillerParameter* temp = bias_filler_;
bias_filler_ = nullptr;
return temp;
}
inline ::caffe::FillerParameter* V0LayerParameter::_internal_mutable_bias_filler() {
_has_bits_[0] |= 0x00000040u;
if (bias_filler_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::FillerParameter>(GetArena());
bias_filler_ = p;
}
return bias_filler_;
}
inline ::caffe::FillerParameter* V0LayerParameter::mutable_bias_filler() {
// @@protoc_insertion_point(field_mutable:caffe.V0LayerParameter.bias_filler)
return _internal_mutable_bias_filler();
}
inline void V0LayerParameter::set_allocated_bias_filler(::caffe::FillerParameter* bias_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete bias_filler_;
}
if (bias_filler) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(bias_filler);
if (message_arena != submessage_arena) {
bias_filler = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, bias_filler, submessage_arena);
}
_has_bits_[0] |= 0x00000040u;
} else {
_has_bits_[0] &= ~0x00000040u;
}
bias_filler_ = bias_filler;
// @@protoc_insertion_point(field_set_allocated:caffe.V0LayerParameter.bias_filler)
}
// optional uint32 pad = 7 [default = 0];
inline bool V0LayerParameter::_internal_has_pad() const {
bool value = (_has_bits_[0] & 0x00000200u) != 0;
return value;
}
inline bool V0LayerParameter::has_pad() const {
return _internal_has_pad();
}
inline void V0LayerParameter::clear_pad() {
pad_ = 0u;
_has_bits_[0] &= ~0x00000200u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 V0LayerParameter::_internal_pad() const {
return pad_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 V0LayerParameter::pad() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.pad)
return _internal_pad();
}
inline void V0LayerParameter::_internal_set_pad(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000200u;
pad_ = value;
}
inline void V0LayerParameter::set_pad(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_pad(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.pad)
}
// optional uint32 kernelsize = 8;
inline bool V0LayerParameter::_internal_has_kernelsize() const {
bool value = (_has_bits_[0] & 0x00000400u) != 0;
return value;
}
inline bool V0LayerParameter::has_kernelsize() const {
return _internal_has_kernelsize();
}
inline void V0LayerParameter::clear_kernelsize() {
kernelsize_ = 0u;
_has_bits_[0] &= ~0x00000400u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 V0LayerParameter::_internal_kernelsize() const {
return kernelsize_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 V0LayerParameter::kernelsize() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.kernelsize)
return _internal_kernelsize();
}
inline void V0LayerParameter::_internal_set_kernelsize(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000400u;
kernelsize_ = value;
}
inline void V0LayerParameter::set_kernelsize(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_kernelsize(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.kernelsize)
}
// optional uint32 group = 9 [default = 1];
inline bool V0LayerParameter::_internal_has_group() const {
bool value = (_has_bits_[0] & 0x01000000u) != 0;
return value;
}
inline bool V0LayerParameter::has_group() const {
return _internal_has_group();
}
inline void V0LayerParameter::clear_group() {
group_ = 1u;
_has_bits_[0] &= ~0x01000000u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 V0LayerParameter::_internal_group() const {
return group_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 V0LayerParameter::group() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.group)
return _internal_group();
}
inline void V0LayerParameter::_internal_set_group(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x01000000u;
group_ = value;
}
inline void V0LayerParameter::set_group(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_group(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.group)
}
// optional uint32 stride = 10 [default = 1];
inline bool V0LayerParameter::_internal_has_stride() const {
bool value = (_has_bits_[0] & 0x02000000u) != 0;
return value;
}
inline bool V0LayerParameter::has_stride() const {
return _internal_has_stride();
}
inline void V0LayerParameter::clear_stride() {
stride_ = 1u;
_has_bits_[0] &= ~0x02000000u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 V0LayerParameter::_internal_stride() const {
return stride_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 V0LayerParameter::stride() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.stride)
return _internal_stride();
}
inline void V0LayerParameter::_internal_set_stride(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x02000000u;
stride_ = value;
}
inline void V0LayerParameter::set_stride(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_stride(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.stride)
}
// optional .caffe.V0LayerParameter.PoolMethod pool = 11 [default = MAX];
inline bool V0LayerParameter::_internal_has_pool() const {
bool value = (_has_bits_[0] & 0x00000800u) != 0;
return value;
}
inline bool V0LayerParameter::has_pool() const {
return _internal_has_pool();
}
inline void V0LayerParameter::clear_pool() {
pool_ = 0;
_has_bits_[0] &= ~0x00000800u;
}
inline ::caffe::V0LayerParameter_PoolMethod V0LayerParameter::_internal_pool() const {
return static_cast< ::caffe::V0LayerParameter_PoolMethod >(pool_);
}
inline ::caffe::V0LayerParameter_PoolMethod V0LayerParameter::pool() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.pool)
return _internal_pool();
}
inline void V0LayerParameter::_internal_set_pool(::caffe::V0LayerParameter_PoolMethod value) {
assert(::caffe::V0LayerParameter_PoolMethod_IsValid(value));
_has_bits_[0] |= 0x00000800u;
pool_ = value;
}
inline void V0LayerParameter::set_pool(::caffe::V0LayerParameter_PoolMethod value) {
_internal_set_pool(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.pool)
}
// optional float dropout_ratio = 12 [default = 0.5];
inline bool V0LayerParameter::_internal_has_dropout_ratio() const {
bool value = (_has_bits_[0] & 0x04000000u) != 0;
return value;
}
inline bool V0LayerParameter::has_dropout_ratio() const {
return _internal_has_dropout_ratio();
}
inline void V0LayerParameter::clear_dropout_ratio() {
dropout_ratio_ = 0.5f;
_has_bits_[0] &= ~0x04000000u;
}
inline float V0LayerParameter::_internal_dropout_ratio() const {
return dropout_ratio_;
}
inline float V0LayerParameter::dropout_ratio() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.dropout_ratio)
return _internal_dropout_ratio();
}
inline void V0LayerParameter::_internal_set_dropout_ratio(float value) {
_has_bits_[0] |= 0x04000000u;
dropout_ratio_ = value;
}
inline void V0LayerParameter::set_dropout_ratio(float value) {
_internal_set_dropout_ratio(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.dropout_ratio)
}
// optional uint32 local_size = 13 [default = 5];
inline bool V0LayerParameter::_internal_has_local_size() const {
bool value = (_has_bits_[0] & 0x08000000u) != 0;
return value;
}
inline bool V0LayerParameter::has_local_size() const {
return _internal_has_local_size();
}
inline void V0LayerParameter::clear_local_size() {
local_size_ = 5u;
_has_bits_[0] &= ~0x08000000u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 V0LayerParameter::_internal_local_size() const {
return local_size_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 V0LayerParameter::local_size() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.local_size)
return _internal_local_size();
}
inline void V0LayerParameter::_internal_set_local_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x08000000u;
local_size_ = value;
}
inline void V0LayerParameter::set_local_size(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_local_size(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.local_size)
}
// optional float alpha = 14 [default = 1];
inline bool V0LayerParameter::_internal_has_alpha() const {
bool value = (_has_bits_[0] & 0x10000000u) != 0;
return value;
}
inline bool V0LayerParameter::has_alpha() const {
return _internal_has_alpha();
}
inline void V0LayerParameter::clear_alpha() {
alpha_ = 1;
_has_bits_[0] &= ~0x10000000u;
}
inline float V0LayerParameter::_internal_alpha() const {
return alpha_;
}
inline float V0LayerParameter::alpha() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.alpha)
return _internal_alpha();
}
inline void V0LayerParameter::_internal_set_alpha(float value) {
_has_bits_[0] |= 0x10000000u;
alpha_ = value;
}
inline void V0LayerParameter::set_alpha(float value) {
_internal_set_alpha(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.alpha)
}
// optional float beta = 15 [default = 0.75];
inline bool V0LayerParameter::_internal_has_beta() const {
bool value = (_has_bits_[0] & 0x20000000u) != 0;
return value;
}
inline bool V0LayerParameter::has_beta() const {
return _internal_has_beta();
}
inline void V0LayerParameter::clear_beta() {
beta_ = 0.75f;
_has_bits_[0] &= ~0x20000000u;
}
inline float V0LayerParameter::_internal_beta() const {
return beta_;
}
inline float V0LayerParameter::beta() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.beta)
return _internal_beta();
}
inline void V0LayerParameter::_internal_set_beta(float value) {
_has_bits_[0] |= 0x20000000u;
beta_ = value;
}
inline void V0LayerParameter::set_beta(float value) {
_internal_set_beta(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.beta)
}
// optional float k = 22 [default = 1];
inline bool V0LayerParameter::_internal_has_k() const {
bool value = (_has_bits_[0] & 0x80000000u) != 0;
return value;
}
inline bool V0LayerParameter::has_k() const {
return _internal_has_k();
}
inline void V0LayerParameter::clear_k() {
k_ = 1;
_has_bits_[0] &= ~0x80000000u;
}
inline float V0LayerParameter::_internal_k() const {
return k_;
}
inline float V0LayerParameter::k() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.k)
return _internal_k();
}
inline void V0LayerParameter::_internal_set_k(float value) {
_has_bits_[0] |= 0x80000000u;
k_ = value;
}
inline void V0LayerParameter::set_k(float value) {
_internal_set_k(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.k)
}
// optional string source = 16;
inline bool V0LayerParameter::_internal_has_source() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool V0LayerParameter::has_source() const {
return _internal_has_source();
}
inline void V0LayerParameter::clear_source() {
source_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000004u;
}
inline const std::string& V0LayerParameter::source() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.source)
return _internal_source();
}
inline void V0LayerParameter::set_source(const std::string& value) {
_internal_set_source(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.source)
}
inline std::string* V0LayerParameter::mutable_source() {
// @@protoc_insertion_point(field_mutable:caffe.V0LayerParameter.source)
return _internal_mutable_source();
}
inline const std::string& V0LayerParameter::_internal_source() const {
return source_.Get();
}
inline void V0LayerParameter::_internal_set_source(const std::string& value) {
_has_bits_[0] |= 0x00000004u;
source_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void V0LayerParameter::set_source(std::string&& value) {
_has_bits_[0] |= 0x00000004u;
source_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.V0LayerParameter.source)
}
inline void V0LayerParameter::set_source(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000004u;
source_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.V0LayerParameter.source)
}
inline void V0LayerParameter::set_source(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000004u;
source_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.V0LayerParameter.source)
}
inline std::string* V0LayerParameter::_internal_mutable_source() {
_has_bits_[0] |= 0x00000004u;
return source_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* V0LayerParameter::release_source() {
// @@protoc_insertion_point(field_release:caffe.V0LayerParameter.source)
if (!_internal_has_source()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000004u;
return source_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void V0LayerParameter::set_allocated_source(std::string* source) {
if (source != nullptr) {
_has_bits_[0] |= 0x00000004u;
} else {
_has_bits_[0] &= ~0x00000004u;
}
source_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), source,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.V0LayerParameter.source)
}
// optional float scale = 17 [default = 1];
inline bool V0LayerParameter::_internal_has_scale() const {
bool value = (_has_bits_[0] & 0x40000000u) != 0;
return value;
}
inline bool V0LayerParameter::has_scale() const {
return _internal_has_scale();
}
inline void V0LayerParameter::clear_scale() {
scale_ = 1;
_has_bits_[0] &= ~0x40000000u;
}
inline float V0LayerParameter::_internal_scale() const {
return scale_;
}
inline float V0LayerParameter::scale() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.scale)
return _internal_scale();
}
inline void V0LayerParameter::_internal_set_scale(float value) {
_has_bits_[0] |= 0x40000000u;
scale_ = value;
}
inline void V0LayerParameter::set_scale(float value) {
_internal_set_scale(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.scale)
}
// optional string meanfile = 18;
inline bool V0LayerParameter::_internal_has_meanfile() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool V0LayerParameter::has_meanfile() const {
return _internal_has_meanfile();
}
inline void V0LayerParameter::clear_meanfile() {
meanfile_.ClearToEmpty(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
_has_bits_[0] &= ~0x00000008u;
}
inline const std::string& V0LayerParameter::meanfile() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.meanfile)
return _internal_meanfile();
}
inline void V0LayerParameter::set_meanfile(const std::string& value) {
_internal_set_meanfile(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.meanfile)
}
inline std::string* V0LayerParameter::mutable_meanfile() {
// @@protoc_insertion_point(field_mutable:caffe.V0LayerParameter.meanfile)
return _internal_mutable_meanfile();
}
inline const std::string& V0LayerParameter::_internal_meanfile() const {
return meanfile_.Get();
}
inline void V0LayerParameter::_internal_set_meanfile(const std::string& value) {
_has_bits_[0] |= 0x00000008u;
meanfile_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value, GetArena());
}
inline void V0LayerParameter::set_meanfile(std::string&& value) {
_has_bits_[0] |= 0x00000008u;
meanfile_.Set(
&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.V0LayerParameter.meanfile)
}
inline void V0LayerParameter::set_meanfile(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000008u;
meanfile_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.V0LayerParameter.meanfile)
}
inline void V0LayerParameter::set_meanfile(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000008u;
meanfile_.Set(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.V0LayerParameter.meanfile)
}
inline std::string* V0LayerParameter::_internal_mutable_meanfile() {
_has_bits_[0] |= 0x00000008u;
return meanfile_.Mutable(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline std::string* V0LayerParameter::release_meanfile() {
// @@protoc_insertion_point(field_release:caffe.V0LayerParameter.meanfile)
if (!_internal_has_meanfile()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000008u;
return meanfile_.ReleaseNonDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena());
}
inline void V0LayerParameter::set_allocated_meanfile(std::string* meanfile) {
if (meanfile != nullptr) {
_has_bits_[0] |= 0x00000008u;
} else {
_has_bits_[0] &= ~0x00000008u;
}
meanfile_.SetAllocated(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), meanfile,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.V0LayerParameter.meanfile)
}
// optional uint32 batchsize = 19;
inline bool V0LayerParameter::_internal_has_batchsize() const {
bool value = (_has_bits_[0] & 0x00001000u) != 0;
return value;
}
inline bool V0LayerParameter::has_batchsize() const {
return _internal_has_batchsize();
}
inline void V0LayerParameter::clear_batchsize() {
batchsize_ = 0u;
_has_bits_[0] &= ~0x00001000u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 V0LayerParameter::_internal_batchsize() const {
return batchsize_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 V0LayerParameter::batchsize() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.batchsize)
return _internal_batchsize();
}
inline void V0LayerParameter::_internal_set_batchsize(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00001000u;
batchsize_ = value;
}
inline void V0LayerParameter::set_batchsize(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_batchsize(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.batchsize)
}
// optional uint32 cropsize = 20 [default = 0];
inline bool V0LayerParameter::_internal_has_cropsize() const {
bool value = (_has_bits_[0] & 0x00002000u) != 0;
return value;
}
inline bool V0LayerParameter::has_cropsize() const {
return _internal_has_cropsize();
}
inline void V0LayerParameter::clear_cropsize() {
cropsize_ = 0u;
_has_bits_[0] &= ~0x00002000u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 V0LayerParameter::_internal_cropsize() const {
return cropsize_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 V0LayerParameter::cropsize() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.cropsize)
return _internal_cropsize();
}
inline void V0LayerParameter::_internal_set_cropsize(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00002000u;
cropsize_ = value;
}
inline void V0LayerParameter::set_cropsize(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_cropsize(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.cropsize)
}
// optional bool mirror = 21 [default = false];
inline bool V0LayerParameter::_internal_has_mirror() const {
bool value = (_has_bits_[0] & 0x00008000u) != 0;
return value;
}
inline bool V0LayerParameter::has_mirror() const {
return _internal_has_mirror();
}
inline void V0LayerParameter::clear_mirror() {
mirror_ = false;
_has_bits_[0] &= ~0x00008000u;
}
inline bool V0LayerParameter::_internal_mirror() const {
return mirror_;
}
inline bool V0LayerParameter::mirror() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.mirror)
return _internal_mirror();
}
inline void V0LayerParameter::_internal_set_mirror(bool value) {
_has_bits_[0] |= 0x00008000u;
mirror_ = value;
}
inline void V0LayerParameter::set_mirror(bool value) {
_internal_set_mirror(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.mirror)
}
// repeated .caffe.BlobProto blobs = 50;
inline int V0LayerParameter::_internal_blobs_size() const {
return blobs_.size();
}
inline int V0LayerParameter::blobs_size() const {
return _internal_blobs_size();
}
inline void V0LayerParameter::clear_blobs() {
blobs_.Clear();
}
inline ::caffe::BlobProto* V0LayerParameter::mutable_blobs(int index) {
// @@protoc_insertion_point(field_mutable:caffe.V0LayerParameter.blobs)
return blobs_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto >*
V0LayerParameter::mutable_blobs() {
// @@protoc_insertion_point(field_mutable_list:caffe.V0LayerParameter.blobs)
return &blobs_;
}
inline const ::caffe::BlobProto& V0LayerParameter::_internal_blobs(int index) const {
return blobs_.Get(index);
}
inline const ::caffe::BlobProto& V0LayerParameter::blobs(int index) const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.blobs)
return _internal_blobs(index);
}
inline ::caffe::BlobProto* V0LayerParameter::_internal_add_blobs() {
return blobs_.Add();
}
inline ::caffe::BlobProto* V0LayerParameter::add_blobs() {
// @@protoc_insertion_point(field_add:caffe.V0LayerParameter.blobs)
return _internal_add_blobs();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobProto >&
V0LayerParameter::blobs() const {
// @@protoc_insertion_point(field_list:caffe.V0LayerParameter.blobs)
return blobs_;
}
// repeated float blobs_lr = 51;
inline int V0LayerParameter::_internal_blobs_lr_size() const {
return blobs_lr_.size();
}
inline int V0LayerParameter::blobs_lr_size() const {
return _internal_blobs_lr_size();
}
inline void V0LayerParameter::clear_blobs_lr() {
blobs_lr_.Clear();
}
inline float V0LayerParameter::_internal_blobs_lr(int index) const {
return blobs_lr_.Get(index);
}
inline float V0LayerParameter::blobs_lr(int index) const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.blobs_lr)
return _internal_blobs_lr(index);
}
inline void V0LayerParameter::set_blobs_lr(int index, float value) {
blobs_lr_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.blobs_lr)
}
inline void V0LayerParameter::_internal_add_blobs_lr(float value) {
blobs_lr_.Add(value);
}
inline void V0LayerParameter::add_blobs_lr(float value) {
_internal_add_blobs_lr(value);
// @@protoc_insertion_point(field_add:caffe.V0LayerParameter.blobs_lr)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
V0LayerParameter::_internal_blobs_lr() const {
return blobs_lr_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
V0LayerParameter::blobs_lr() const {
// @@protoc_insertion_point(field_list:caffe.V0LayerParameter.blobs_lr)
return _internal_blobs_lr();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
V0LayerParameter::_internal_mutable_blobs_lr() {
return &blobs_lr_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
V0LayerParameter::mutable_blobs_lr() {
// @@protoc_insertion_point(field_mutable_list:caffe.V0LayerParameter.blobs_lr)
return _internal_mutable_blobs_lr();
}
// repeated float weight_decay = 52;
inline int V0LayerParameter::_internal_weight_decay_size() const {
return weight_decay_.size();
}
inline int V0LayerParameter::weight_decay_size() const {
return _internal_weight_decay_size();
}
inline void V0LayerParameter::clear_weight_decay() {
weight_decay_.Clear();
}
inline float V0LayerParameter::_internal_weight_decay(int index) const {
return weight_decay_.Get(index);
}
inline float V0LayerParameter::weight_decay(int index) const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.weight_decay)
return _internal_weight_decay(index);
}
inline void V0LayerParameter::set_weight_decay(int index, float value) {
weight_decay_.Set(index, value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.weight_decay)
}
inline void V0LayerParameter::_internal_add_weight_decay(float value) {
weight_decay_.Add(value);
}
inline void V0LayerParameter::add_weight_decay(float value) {
_internal_add_weight_decay(value);
// @@protoc_insertion_point(field_add:caffe.V0LayerParameter.weight_decay)
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
V0LayerParameter::_internal_weight_decay() const {
return weight_decay_;
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >&
V0LayerParameter::weight_decay() const {
// @@protoc_insertion_point(field_list:caffe.V0LayerParameter.weight_decay)
return _internal_weight_decay();
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
V0LayerParameter::_internal_mutable_weight_decay() {
return &weight_decay_;
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< float >*
V0LayerParameter::mutable_weight_decay() {
// @@protoc_insertion_point(field_mutable_list:caffe.V0LayerParameter.weight_decay)
return _internal_mutable_weight_decay();
}
// optional uint32 rand_skip = 53 [default = 0];
inline bool V0LayerParameter::_internal_has_rand_skip() const {
bool value = (_has_bits_[0] & 0x00020000u) != 0;
return value;
}
inline bool V0LayerParameter::has_rand_skip() const {
return _internal_has_rand_skip();
}
inline void V0LayerParameter::clear_rand_skip() {
rand_skip_ = 0u;
_has_bits_[0] &= ~0x00020000u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 V0LayerParameter::_internal_rand_skip() const {
return rand_skip_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 V0LayerParameter::rand_skip() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.rand_skip)
return _internal_rand_skip();
}
inline void V0LayerParameter::_internal_set_rand_skip(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00020000u;
rand_skip_ = value;
}
inline void V0LayerParameter::set_rand_skip(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_rand_skip(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.rand_skip)
}
// optional float det_fg_threshold = 54 [default = 0.5];
inline bool V0LayerParameter::_internal_has_det_fg_threshold() const {
bool value = (_has_bits_[1] & 0x00000001u) != 0;
return value;
}
inline bool V0LayerParameter::has_det_fg_threshold() const {
return _internal_has_det_fg_threshold();
}
inline void V0LayerParameter::clear_det_fg_threshold() {
det_fg_threshold_ = 0.5f;
_has_bits_[1] &= ~0x00000001u;
}
inline float V0LayerParameter::_internal_det_fg_threshold() const {
return det_fg_threshold_;
}
inline float V0LayerParameter::det_fg_threshold() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.det_fg_threshold)
return _internal_det_fg_threshold();
}
inline void V0LayerParameter::_internal_set_det_fg_threshold(float value) {
_has_bits_[1] |= 0x00000001u;
det_fg_threshold_ = value;
}
inline void V0LayerParameter::set_det_fg_threshold(float value) {
_internal_set_det_fg_threshold(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.det_fg_threshold)
}
// optional float det_bg_threshold = 55 [default = 0.5];
inline bool V0LayerParameter::_internal_has_det_bg_threshold() const {
bool value = (_has_bits_[1] & 0x00000002u) != 0;
return value;
}
inline bool V0LayerParameter::has_det_bg_threshold() const {
return _internal_has_det_bg_threshold();
}
inline void V0LayerParameter::clear_det_bg_threshold() {
det_bg_threshold_ = 0.5f;
_has_bits_[1] &= ~0x00000002u;
}
inline float V0LayerParameter::_internal_det_bg_threshold() const {
return det_bg_threshold_;
}
inline float V0LayerParameter::det_bg_threshold() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.det_bg_threshold)
return _internal_det_bg_threshold();
}
inline void V0LayerParameter::_internal_set_det_bg_threshold(float value) {
_has_bits_[1] |= 0x00000002u;
det_bg_threshold_ = value;
}
inline void V0LayerParameter::set_det_bg_threshold(float value) {
_internal_set_det_bg_threshold(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.det_bg_threshold)
}
// optional float det_fg_fraction = 56 [default = 0.25];
inline bool V0LayerParameter::_internal_has_det_fg_fraction() const {
bool value = (_has_bits_[1] & 0x00000004u) != 0;
return value;
}
inline bool V0LayerParameter::has_det_fg_fraction() const {
return _internal_has_det_fg_fraction();
}
inline void V0LayerParameter::clear_det_fg_fraction() {
det_fg_fraction_ = 0.25f;
_has_bits_[1] &= ~0x00000004u;
}
inline float V0LayerParameter::_internal_det_fg_fraction() const {
return det_fg_fraction_;
}
inline float V0LayerParameter::det_fg_fraction() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.det_fg_fraction)
return _internal_det_fg_fraction();
}
inline void V0LayerParameter::_internal_set_det_fg_fraction(float value) {
_has_bits_[1] |= 0x00000004u;
det_fg_fraction_ = value;
}
inline void V0LayerParameter::set_det_fg_fraction(float value) {
_internal_set_det_fg_fraction(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.det_fg_fraction)
}
// optional uint32 det_context_pad = 58 [default = 0];
inline bool V0LayerParameter::_internal_has_det_context_pad() const {
bool value = (_has_bits_[0] & 0x00040000u) != 0;
return value;
}
inline bool V0LayerParameter::has_det_context_pad() const {
return _internal_has_det_context_pad();
}
inline void V0LayerParameter::clear_det_context_pad() {
det_context_pad_ = 0u;
_has_bits_[0] &= ~0x00040000u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 V0LayerParameter::_internal_det_context_pad() const {
return det_context_pad_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 V0LayerParameter::det_context_pad() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.det_context_pad)
return _internal_det_context_pad();
}
inline void V0LayerParameter::_internal_set_det_context_pad(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00040000u;
det_context_pad_ = value;
}
inline void V0LayerParameter::set_det_context_pad(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_det_context_pad(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.det_context_pad)
}
// optional string det_crop_mode = 59 [default = "warp"];
inline bool V0LayerParameter::_internal_has_det_crop_mode() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool V0LayerParameter::has_det_crop_mode() const {
return _internal_has_det_crop_mode();
}
inline void V0LayerParameter::clear_det_crop_mode() {
det_crop_mode_.ClearToDefault(&::caffe::V0LayerParameter::_i_give_permission_to_break_this_code_default_det_crop_mode_.get(), GetArena());
_has_bits_[0] &= ~0x00000010u;
}
inline const std::string& V0LayerParameter::det_crop_mode() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.det_crop_mode)
return _internal_det_crop_mode();
}
inline void V0LayerParameter::set_det_crop_mode(const std::string& value) {
_internal_set_det_crop_mode(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.det_crop_mode)
}
inline std::string* V0LayerParameter::mutable_det_crop_mode() {
// @@protoc_insertion_point(field_mutable:caffe.V0LayerParameter.det_crop_mode)
return _internal_mutable_det_crop_mode();
}
inline const std::string& V0LayerParameter::_internal_det_crop_mode() const {
return det_crop_mode_.Get();
}
inline void V0LayerParameter::_internal_set_det_crop_mode(const std::string& value) {
_has_bits_[0] |= 0x00000010u;
det_crop_mode_.Set(&::caffe::V0LayerParameter::_i_give_permission_to_break_this_code_default_det_crop_mode_.get(), value, GetArena());
}
inline void V0LayerParameter::set_det_crop_mode(std::string&& value) {
_has_bits_[0] |= 0x00000010u;
det_crop_mode_.Set(
&::caffe::V0LayerParameter::_i_give_permission_to_break_this_code_default_det_crop_mode_.get(), ::std::move(value), GetArena());
// @@protoc_insertion_point(field_set_rvalue:caffe.V0LayerParameter.det_crop_mode)
}
inline void V0LayerParameter::set_det_crop_mode(const char* value) {
GOOGLE_DCHECK(value != nullptr);
_has_bits_[0] |= 0x00000010u;
det_crop_mode_.Set(&::caffe::V0LayerParameter::_i_give_permission_to_break_this_code_default_det_crop_mode_.get(), ::std::string(value),
GetArena());
// @@protoc_insertion_point(field_set_char:caffe.V0LayerParameter.det_crop_mode)
}
inline void V0LayerParameter::set_det_crop_mode(const char* value,
size_t size) {
_has_bits_[0] |= 0x00000010u;
det_crop_mode_.Set(&::caffe::V0LayerParameter::_i_give_permission_to_break_this_code_default_det_crop_mode_.get(), ::std::string(
reinterpret_cast<const char*>(value), size), GetArena());
// @@protoc_insertion_point(field_set_pointer:caffe.V0LayerParameter.det_crop_mode)
}
inline std::string* V0LayerParameter::_internal_mutable_det_crop_mode() {
_has_bits_[0] |= 0x00000010u;
return det_crop_mode_.Mutable(&::caffe::V0LayerParameter::_i_give_permission_to_break_this_code_default_det_crop_mode_.get(), GetArena());
}
inline std::string* V0LayerParameter::release_det_crop_mode() {
// @@protoc_insertion_point(field_release:caffe.V0LayerParameter.det_crop_mode)
if (!_internal_has_det_crop_mode()) {
return nullptr;
}
_has_bits_[0] &= ~0x00000010u;
return det_crop_mode_.ReleaseNonDefault(&::caffe::V0LayerParameter::_i_give_permission_to_break_this_code_default_det_crop_mode_.get(), GetArena());
}
inline void V0LayerParameter::set_allocated_det_crop_mode(std::string* det_crop_mode) {
if (det_crop_mode != nullptr) {
_has_bits_[0] |= 0x00000010u;
} else {
_has_bits_[0] &= ~0x00000010u;
}
det_crop_mode_.SetAllocated(&::caffe::V0LayerParameter::_i_give_permission_to_break_this_code_default_det_crop_mode_.get(), det_crop_mode,
GetArena());
// @@protoc_insertion_point(field_set_allocated:caffe.V0LayerParameter.det_crop_mode)
}
// optional int32 new_num = 60 [default = 0];
inline bool V0LayerParameter::_internal_has_new_num() const {
bool value = (_has_bits_[0] & 0x00080000u) != 0;
return value;
}
inline bool V0LayerParameter::has_new_num() const {
return _internal_has_new_num();
}
inline void V0LayerParameter::clear_new_num() {
new_num_ = 0;
_has_bits_[0] &= ~0x00080000u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 V0LayerParameter::_internal_new_num() const {
return new_num_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 V0LayerParameter::new_num() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.new_num)
return _internal_new_num();
}
inline void V0LayerParameter::_internal_set_new_num(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00080000u;
new_num_ = value;
}
inline void V0LayerParameter::set_new_num(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_new_num(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.new_num)
}
// optional int32 new_channels = 61 [default = 0];
inline bool V0LayerParameter::_internal_has_new_channels() const {
bool value = (_has_bits_[0] & 0x00100000u) != 0;
return value;
}
inline bool V0LayerParameter::has_new_channels() const {
return _internal_has_new_channels();
}
inline void V0LayerParameter::clear_new_channels() {
new_channels_ = 0;
_has_bits_[0] &= ~0x00100000u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 V0LayerParameter::_internal_new_channels() const {
return new_channels_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 V0LayerParameter::new_channels() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.new_channels)
return _internal_new_channels();
}
inline void V0LayerParameter::_internal_set_new_channels(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00100000u;
new_channels_ = value;
}
inline void V0LayerParameter::set_new_channels(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_new_channels(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.new_channels)
}
// optional int32 new_height = 62 [default = 0];
inline bool V0LayerParameter::_internal_has_new_height() const {
bool value = (_has_bits_[0] & 0x00200000u) != 0;
return value;
}
inline bool V0LayerParameter::has_new_height() const {
return _internal_has_new_height();
}
inline void V0LayerParameter::clear_new_height() {
new_height_ = 0;
_has_bits_[0] &= ~0x00200000u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 V0LayerParameter::_internal_new_height() const {
return new_height_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 V0LayerParameter::new_height() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.new_height)
return _internal_new_height();
}
inline void V0LayerParameter::_internal_set_new_height(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00200000u;
new_height_ = value;
}
inline void V0LayerParameter::set_new_height(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_new_height(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.new_height)
}
// optional int32 new_width = 63 [default = 0];
inline bool V0LayerParameter::_internal_has_new_width() const {
bool value = (_has_bits_[0] & 0x00004000u) != 0;
return value;
}
inline bool V0LayerParameter::has_new_width() const {
return _internal_has_new_width();
}
inline void V0LayerParameter::clear_new_width() {
new_width_ = 0;
_has_bits_[0] &= ~0x00004000u;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 V0LayerParameter::_internal_new_width() const {
return new_width_;
}
inline ::PROTOBUF_NAMESPACE_ID::int32 V0LayerParameter::new_width() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.new_width)
return _internal_new_width();
}
inline void V0LayerParameter::_internal_set_new_width(::PROTOBUF_NAMESPACE_ID::int32 value) {
_has_bits_[0] |= 0x00004000u;
new_width_ = value;
}
inline void V0LayerParameter::set_new_width(::PROTOBUF_NAMESPACE_ID::int32 value) {
_internal_set_new_width(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.new_width)
}
// optional bool shuffle_images = 64 [default = false];
inline bool V0LayerParameter::_internal_has_shuffle_images() const {
bool value = (_has_bits_[0] & 0x00010000u) != 0;
return value;
}
inline bool V0LayerParameter::has_shuffle_images() const {
return _internal_has_shuffle_images();
}
inline void V0LayerParameter::clear_shuffle_images() {
shuffle_images_ = false;
_has_bits_[0] &= ~0x00010000u;
}
inline bool V0LayerParameter::_internal_shuffle_images() const {
return shuffle_images_;
}
inline bool V0LayerParameter::shuffle_images() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.shuffle_images)
return _internal_shuffle_images();
}
inline void V0LayerParameter::_internal_set_shuffle_images(bool value) {
_has_bits_[0] |= 0x00010000u;
shuffle_images_ = value;
}
inline void V0LayerParameter::set_shuffle_images(bool value) {
_internal_set_shuffle_images(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.shuffle_images)
}
// optional uint32 concat_dim = 65 [default = 1];
inline bool V0LayerParameter::_internal_has_concat_dim() const {
bool value = (_has_bits_[0] & 0x00400000u) != 0;
return value;
}
inline bool V0LayerParameter::has_concat_dim() const {
return _internal_has_concat_dim();
}
inline void V0LayerParameter::clear_concat_dim() {
concat_dim_ = 1u;
_has_bits_[0] &= ~0x00400000u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 V0LayerParameter::_internal_concat_dim() const {
return concat_dim_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 V0LayerParameter::concat_dim() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.concat_dim)
return _internal_concat_dim();
}
inline void V0LayerParameter::_internal_set_concat_dim(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00400000u;
concat_dim_ = value;
}
inline void V0LayerParameter::set_concat_dim(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_concat_dim(value);
// @@protoc_insertion_point(field_set:caffe.V0LayerParameter.concat_dim)
}
// optional .caffe.HDF5OutputParameter hdf5_output_param = 1001;
inline bool V0LayerParameter::_internal_has_hdf5_output_param() const {
bool value = (_has_bits_[0] & 0x00000080u) != 0;
PROTOBUF_ASSUME(!value || hdf5_output_param_ != nullptr);
return value;
}
inline bool V0LayerParameter::has_hdf5_output_param() const {
return _internal_has_hdf5_output_param();
}
inline void V0LayerParameter::clear_hdf5_output_param() {
if (hdf5_output_param_ != nullptr) hdf5_output_param_->Clear();
_has_bits_[0] &= ~0x00000080u;
}
inline const ::caffe::HDF5OutputParameter& V0LayerParameter::_internal_hdf5_output_param() const {
const ::caffe::HDF5OutputParameter* p = hdf5_output_param_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::HDF5OutputParameter*>(
&::caffe::_HDF5OutputParameter_default_instance_);
}
inline const ::caffe::HDF5OutputParameter& V0LayerParameter::hdf5_output_param() const {
// @@protoc_insertion_point(field_get:caffe.V0LayerParameter.hdf5_output_param)
return _internal_hdf5_output_param();
}
inline void V0LayerParameter::unsafe_arena_set_allocated_hdf5_output_param(
::caffe::HDF5OutputParameter* hdf5_output_param) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(hdf5_output_param_);
}
hdf5_output_param_ = hdf5_output_param;
if (hdf5_output_param) {
_has_bits_[0] |= 0x00000080u;
} else {
_has_bits_[0] &= ~0x00000080u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.V0LayerParameter.hdf5_output_param)
}
inline ::caffe::HDF5OutputParameter* V0LayerParameter::release_hdf5_output_param() {
_has_bits_[0] &= ~0x00000080u;
::caffe::HDF5OutputParameter* temp = hdf5_output_param_;
hdf5_output_param_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::HDF5OutputParameter* V0LayerParameter::unsafe_arena_release_hdf5_output_param() {
// @@protoc_insertion_point(field_release:caffe.V0LayerParameter.hdf5_output_param)
_has_bits_[0] &= ~0x00000080u;
::caffe::HDF5OutputParameter* temp = hdf5_output_param_;
hdf5_output_param_ = nullptr;
return temp;
}
inline ::caffe::HDF5OutputParameter* V0LayerParameter::_internal_mutable_hdf5_output_param() {
_has_bits_[0] |= 0x00000080u;
if (hdf5_output_param_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::HDF5OutputParameter>(GetArena());
hdf5_output_param_ = p;
}
return hdf5_output_param_;
}
inline ::caffe::HDF5OutputParameter* V0LayerParameter::mutable_hdf5_output_param() {
// @@protoc_insertion_point(field_mutable:caffe.V0LayerParameter.hdf5_output_param)
return _internal_mutable_hdf5_output_param();
}
inline void V0LayerParameter::set_allocated_hdf5_output_param(::caffe::HDF5OutputParameter* hdf5_output_param) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete hdf5_output_param_;
}
if (hdf5_output_param) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(hdf5_output_param);
if (message_arena != submessage_arena) {
hdf5_output_param = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, hdf5_output_param, submessage_arena);
}
_has_bits_[0] |= 0x00000080u;
} else {
_has_bits_[0] &= ~0x00000080u;
}
hdf5_output_param_ = hdf5_output_param;
// @@protoc_insertion_point(field_set_allocated:caffe.V0LayerParameter.hdf5_output_param)
}
// -------------------------------------------------------------------
// PReLUParameter
// optional .caffe.FillerParameter filler = 1;
inline bool PReLUParameter::_internal_has_filler() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
PROTOBUF_ASSUME(!value || filler_ != nullptr);
return value;
}
inline bool PReLUParameter::has_filler() const {
return _internal_has_filler();
}
inline void PReLUParameter::clear_filler() {
if (filler_ != nullptr) filler_->Clear();
_has_bits_[0] &= ~0x00000001u;
}
inline const ::caffe::FillerParameter& PReLUParameter::_internal_filler() const {
const ::caffe::FillerParameter* p = filler_;
return p != nullptr ? *p : *reinterpret_cast<const ::caffe::FillerParameter*>(
&::caffe::_FillerParameter_default_instance_);
}
inline const ::caffe::FillerParameter& PReLUParameter::filler() const {
// @@protoc_insertion_point(field_get:caffe.PReLUParameter.filler)
return _internal_filler();
}
inline void PReLUParameter::unsafe_arena_set_allocated_filler(
::caffe::FillerParameter* filler) {
if (GetArena() == nullptr) {
delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(filler_);
}
filler_ = filler;
if (filler) {
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
// @@protoc_insertion_point(field_unsafe_arena_set_allocated:caffe.PReLUParameter.filler)
}
inline ::caffe::FillerParameter* PReLUParameter::release_filler() {
_has_bits_[0] &= ~0x00000001u;
::caffe::FillerParameter* temp = filler_;
filler_ = nullptr;
if (GetArena() != nullptr) {
temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp);
}
return temp;
}
inline ::caffe::FillerParameter* PReLUParameter::unsafe_arena_release_filler() {
// @@protoc_insertion_point(field_release:caffe.PReLUParameter.filler)
_has_bits_[0] &= ~0x00000001u;
::caffe::FillerParameter* temp = filler_;
filler_ = nullptr;
return temp;
}
inline ::caffe::FillerParameter* PReLUParameter::_internal_mutable_filler() {
_has_bits_[0] |= 0x00000001u;
if (filler_ == nullptr) {
auto* p = CreateMaybeMessage<::caffe::FillerParameter>(GetArena());
filler_ = p;
}
return filler_;
}
inline ::caffe::FillerParameter* PReLUParameter::mutable_filler() {
// @@protoc_insertion_point(field_mutable:caffe.PReLUParameter.filler)
return _internal_mutable_filler();
}
inline void PReLUParameter::set_allocated_filler(::caffe::FillerParameter* filler) {
::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArena();
if (message_arena == nullptr) {
delete filler_;
}
if (filler) {
::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
::PROTOBUF_NAMESPACE_ID::Arena::GetArena(filler);
if (message_arena != submessage_arena) {
filler = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
message_arena, filler, submessage_arena);
}
_has_bits_[0] |= 0x00000001u;
} else {
_has_bits_[0] &= ~0x00000001u;
}
filler_ = filler;
// @@protoc_insertion_point(field_set_allocated:caffe.PReLUParameter.filler)
}
// optional bool channel_shared = 2 [default = false];
inline bool PReLUParameter::_internal_has_channel_shared() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool PReLUParameter::has_channel_shared() const {
return _internal_has_channel_shared();
}
inline void PReLUParameter::clear_channel_shared() {
channel_shared_ = false;
_has_bits_[0] &= ~0x00000002u;
}
inline bool PReLUParameter::_internal_channel_shared() const {
return channel_shared_;
}
inline bool PReLUParameter::channel_shared() const {
// @@protoc_insertion_point(field_get:caffe.PReLUParameter.channel_shared)
return _internal_channel_shared();
}
inline void PReLUParameter::_internal_set_channel_shared(bool value) {
_has_bits_[0] |= 0x00000002u;
channel_shared_ = value;
}
inline void PReLUParameter::set_channel_shared(bool value) {
_internal_set_channel_shared(value);
// @@protoc_insertion_point(field_set:caffe.PReLUParameter.channel_shared)
}
// -------------------------------------------------------------------
// FaceDataParameter
// optional bool fullface = 1 [default = false];
inline bool FaceDataParameter::_internal_has_fullface() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool FaceDataParameter::has_fullface() const {
return _internal_has_fullface();
}
inline void FaceDataParameter::clear_fullface() {
fullface_ = false;
_has_bits_[0] &= ~0x00000001u;
}
inline bool FaceDataParameter::_internal_fullface() const {
return fullface_;
}
inline bool FaceDataParameter::fullface() const {
// @@protoc_insertion_point(field_get:caffe.FaceDataParameter.fullface)
return _internal_fullface();
}
inline void FaceDataParameter::_internal_set_fullface(bool value) {
_has_bits_[0] |= 0x00000001u;
fullface_ = value;
}
inline void FaceDataParameter::set_fullface(bool value) {
_internal_set_fullface(value);
// @@protoc_insertion_point(field_set:caffe.FaceDataParameter.fullface)
}
// optional bool croppedface = 2 [default = true];
inline bool FaceDataParameter::_internal_has_croppedface() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool FaceDataParameter::has_croppedface() const {
return _internal_has_croppedface();
}
inline void FaceDataParameter::clear_croppedface() {
croppedface_ = true;
_has_bits_[0] &= ~0x00000010u;
}
inline bool FaceDataParameter::_internal_croppedface() const {
return croppedface_;
}
inline bool FaceDataParameter::croppedface() const {
// @@protoc_insertion_point(field_get:caffe.FaceDataParameter.croppedface)
return _internal_croppedface();
}
inline void FaceDataParameter::_internal_set_croppedface(bool value) {
_has_bits_[0] |= 0x00000010u;
croppedface_ = value;
}
inline void FaceDataParameter::set_croppedface(bool value) {
_internal_set_croppedface(value);
// @@protoc_insertion_point(field_set:caffe.FaceDataParameter.croppedface)
}
// optional bool eye = 3 [default = false];
inline bool FaceDataParameter::_internal_has_eye() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool FaceDataParameter::has_eye() const {
return _internal_has_eye();
}
inline void FaceDataParameter::clear_eye() {
eye_ = false;
_has_bits_[0] &= ~0x00000002u;
}
inline bool FaceDataParameter::_internal_eye() const {
return eye_;
}
inline bool FaceDataParameter::eye() const {
// @@protoc_insertion_point(field_get:caffe.FaceDataParameter.eye)
return _internal_eye();
}
inline void FaceDataParameter::_internal_set_eye(bool value) {
_has_bits_[0] |= 0x00000002u;
eye_ = value;
}
inline void FaceDataParameter::set_eye(bool value) {
_internal_set_eye(value);
// @@protoc_insertion_point(field_set:caffe.FaceDataParameter.eye)
}
// optional bool nose = 4 [default = false];
inline bool FaceDataParameter::_internal_has_nose() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool FaceDataParameter::has_nose() const {
return _internal_has_nose();
}
inline void FaceDataParameter::clear_nose() {
nose_ = false;
_has_bits_[0] &= ~0x00000004u;
}
inline bool FaceDataParameter::_internal_nose() const {
return nose_;
}
inline bool FaceDataParameter::nose() const {
// @@protoc_insertion_point(field_get:caffe.FaceDataParameter.nose)
return _internal_nose();
}
inline void FaceDataParameter::_internal_set_nose(bool value) {
_has_bits_[0] |= 0x00000004u;
nose_ = value;
}
inline void FaceDataParameter::set_nose(bool value) {
_internal_set_nose(value);
// @@protoc_insertion_point(field_set:caffe.FaceDataParameter.nose)
}
// optional bool mouth = 5 [default = false];
inline bool FaceDataParameter::_internal_has_mouth() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool FaceDataParameter::has_mouth() const {
return _internal_has_mouth();
}
inline void FaceDataParameter::clear_mouth() {
mouth_ = false;
_has_bits_[0] &= ~0x00000008u;
}
inline bool FaceDataParameter::_internal_mouth() const {
return mouth_;
}
inline bool FaceDataParameter::mouth() const {
// @@protoc_insertion_point(field_get:caffe.FaceDataParameter.mouth)
return _internal_mouth();
}
inline void FaceDataParameter::_internal_set_mouth(bool value) {
_has_bits_[0] |= 0x00000008u;
mouth_ = value;
}
inline void FaceDataParameter::set_mouth(bool value) {
_internal_set_mouth(value);
// @@protoc_insertion_point(field_set:caffe.FaceDataParameter.mouth)
}
// repeated .caffe.BlobShape shape = 6;
inline int FaceDataParameter::_internal_shape_size() const {
return shape_.size();
}
inline int FaceDataParameter::shape_size() const {
return _internal_shape_size();
}
inline void FaceDataParameter::clear_shape() {
shape_.Clear();
}
inline ::caffe::BlobShape* FaceDataParameter::mutable_shape(int index) {
// @@protoc_insertion_point(field_mutable:caffe.FaceDataParameter.shape)
return shape_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape >*
FaceDataParameter::mutable_shape() {
// @@protoc_insertion_point(field_mutable_list:caffe.FaceDataParameter.shape)
return &shape_;
}
inline const ::caffe::BlobShape& FaceDataParameter::_internal_shape(int index) const {
return shape_.Get(index);
}
inline const ::caffe::BlobShape& FaceDataParameter::shape(int index) const {
// @@protoc_insertion_point(field_get:caffe.FaceDataParameter.shape)
return _internal_shape(index);
}
inline ::caffe::BlobShape* FaceDataParameter::_internal_add_shape() {
return shape_.Add();
}
inline ::caffe::BlobShape* FaceDataParameter::add_shape() {
// @@protoc_insertion_point(field_add:caffe.FaceDataParameter.shape)
return _internal_add_shape();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape >&
FaceDataParameter::shape() const {
// @@protoc_insertion_point(field_list:caffe.FaceDataParameter.shape)
return shape_;
}
// -------------------------------------------------------------------
// UpsampleParameter
// optional uint32 scale = 1 [default = 2];
inline bool UpsampleParameter::_internal_has_scale() const {
bool value = (_has_bits_[0] & 0x00000040u) != 0;
return value;
}
inline bool UpsampleParameter::has_scale() const {
return _internal_has_scale();
}
inline void UpsampleParameter::clear_scale() {
scale_ = 2u;
_has_bits_[0] &= ~0x00000040u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 UpsampleParameter::_internal_scale() const {
return scale_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 UpsampleParameter::scale() const {
// @@protoc_insertion_point(field_get:caffe.UpsampleParameter.scale)
return _internal_scale();
}
inline void UpsampleParameter::_internal_set_scale(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000040u;
scale_ = value;
}
inline void UpsampleParameter::set_scale(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_scale(value);
// @@protoc_insertion_point(field_set:caffe.UpsampleParameter.scale)
}
// optional uint32 scale_h = 2;
inline bool UpsampleParameter::_internal_has_scale_h() const {
bool value = (_has_bits_[0] & 0x00000001u) != 0;
return value;
}
inline bool UpsampleParameter::has_scale_h() const {
return _internal_has_scale_h();
}
inline void UpsampleParameter::clear_scale_h() {
scale_h_ = 0u;
_has_bits_[0] &= ~0x00000001u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 UpsampleParameter::_internal_scale_h() const {
return scale_h_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 UpsampleParameter::scale_h() const {
// @@protoc_insertion_point(field_get:caffe.UpsampleParameter.scale_h)
return _internal_scale_h();
}
inline void UpsampleParameter::_internal_set_scale_h(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000001u;
scale_h_ = value;
}
inline void UpsampleParameter::set_scale_h(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_scale_h(value);
// @@protoc_insertion_point(field_set:caffe.UpsampleParameter.scale_h)
}
// optional uint32 scale_w = 3;
inline bool UpsampleParameter::_internal_has_scale_w() const {
bool value = (_has_bits_[0] & 0x00000002u) != 0;
return value;
}
inline bool UpsampleParameter::has_scale_w() const {
return _internal_has_scale_w();
}
inline void UpsampleParameter::clear_scale_w() {
scale_w_ = 0u;
_has_bits_[0] &= ~0x00000002u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 UpsampleParameter::_internal_scale_w() const {
return scale_w_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 UpsampleParameter::scale_w() const {
// @@protoc_insertion_point(field_get:caffe.UpsampleParameter.scale_w)
return _internal_scale_w();
}
inline void UpsampleParameter::_internal_set_scale_w(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000002u;
scale_w_ = value;
}
inline void UpsampleParameter::set_scale_w(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_scale_w(value);
// @@protoc_insertion_point(field_set:caffe.UpsampleParameter.scale_w)
}
// optional bool pad_out_h = 4 [default = false];
inline bool UpsampleParameter::_internal_has_pad_out_h() const {
bool value = (_has_bits_[0] & 0x00000004u) != 0;
return value;
}
inline bool UpsampleParameter::has_pad_out_h() const {
return _internal_has_pad_out_h();
}
inline void UpsampleParameter::clear_pad_out_h() {
pad_out_h_ = false;
_has_bits_[0] &= ~0x00000004u;
}
inline bool UpsampleParameter::_internal_pad_out_h() const {
return pad_out_h_;
}
inline bool UpsampleParameter::pad_out_h() const {
// @@protoc_insertion_point(field_get:caffe.UpsampleParameter.pad_out_h)
return _internal_pad_out_h();
}
inline void UpsampleParameter::_internal_set_pad_out_h(bool value) {
_has_bits_[0] |= 0x00000004u;
pad_out_h_ = value;
}
inline void UpsampleParameter::set_pad_out_h(bool value) {
_internal_set_pad_out_h(value);
// @@protoc_insertion_point(field_set:caffe.UpsampleParameter.pad_out_h)
}
// optional bool pad_out_w = 5 [default = false];
inline bool UpsampleParameter::_internal_has_pad_out_w() const {
bool value = (_has_bits_[0] & 0x00000008u) != 0;
return value;
}
inline bool UpsampleParameter::has_pad_out_w() const {
return _internal_has_pad_out_w();
}
inline void UpsampleParameter::clear_pad_out_w() {
pad_out_w_ = false;
_has_bits_[0] &= ~0x00000008u;
}
inline bool UpsampleParameter::_internal_pad_out_w() const {
return pad_out_w_;
}
inline bool UpsampleParameter::pad_out_w() const {
// @@protoc_insertion_point(field_get:caffe.UpsampleParameter.pad_out_w)
return _internal_pad_out_w();
}
inline void UpsampleParameter::_internal_set_pad_out_w(bool value) {
_has_bits_[0] |= 0x00000008u;
pad_out_w_ = value;
}
inline void UpsampleParameter::set_pad_out_w(bool value) {
_internal_set_pad_out_w(value);
// @@protoc_insertion_point(field_set:caffe.UpsampleParameter.pad_out_w)
}
// optional uint32 upsample_h = 6;
inline bool UpsampleParameter::_internal_has_upsample_h() const {
bool value = (_has_bits_[0] & 0x00000010u) != 0;
return value;
}
inline bool UpsampleParameter::has_upsample_h() const {
return _internal_has_upsample_h();
}
inline void UpsampleParameter::clear_upsample_h() {
upsample_h_ = 0u;
_has_bits_[0] &= ~0x00000010u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 UpsampleParameter::_internal_upsample_h() const {
return upsample_h_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 UpsampleParameter::upsample_h() const {
// @@protoc_insertion_point(field_get:caffe.UpsampleParameter.upsample_h)
return _internal_upsample_h();
}
inline void UpsampleParameter::_internal_set_upsample_h(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000010u;
upsample_h_ = value;
}
inline void UpsampleParameter::set_upsample_h(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_upsample_h(value);
// @@protoc_insertion_point(field_set:caffe.UpsampleParameter.upsample_h)
}
// optional uint32 upsample_w = 7;
inline bool UpsampleParameter::_internal_has_upsample_w() const {
bool value = (_has_bits_[0] & 0x00000020u) != 0;
return value;
}
inline bool UpsampleParameter::has_upsample_w() const {
return _internal_has_upsample_w();
}
inline void UpsampleParameter::clear_upsample_w() {
upsample_w_ = 0u;
_has_bits_[0] &= ~0x00000020u;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 UpsampleParameter::_internal_upsample_w() const {
return upsample_w_;
}
inline ::PROTOBUF_NAMESPACE_ID::uint32 UpsampleParameter::upsample_w() const {
// @@protoc_insertion_point(field_get:caffe.UpsampleParameter.upsample_w)
return _internal_upsample_w();
}
inline void UpsampleParameter::_internal_set_upsample_w(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_has_bits_[0] |= 0x00000020u;
upsample_w_ = value;
}
inline void UpsampleParameter::set_upsample_w(::PROTOBUF_NAMESPACE_ID::uint32 value) {
_internal_set_upsample_w(value);
// @@protoc_insertion_point(field_set:caffe.UpsampleParameter.upsample_w)
}
// -------------------------------------------------------------------
// ConnectParameter
// repeated .caffe.BlobShape shape = 1;
inline int ConnectParameter::_internal_shape_size() const {
return shape_.size();
}
inline int ConnectParameter::shape_size() const {
return _internal_shape_size();
}
inline void ConnectParameter::clear_shape() {
shape_.Clear();
}
inline ::caffe::BlobShape* ConnectParameter::mutable_shape(int index) {
// @@protoc_insertion_point(field_mutable:caffe.ConnectParameter.shape)
return shape_.Mutable(index);
}
inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape >*
ConnectParameter::mutable_shape() {
// @@protoc_insertion_point(field_mutable_list:caffe.ConnectParameter.shape)
return &shape_;
}
inline const ::caffe::BlobShape& ConnectParameter::_internal_shape(int index) const {
return shape_.Get(index);
}
inline const ::caffe::BlobShape& ConnectParameter::shape(int index) const {
// @@protoc_insertion_point(field_get:caffe.ConnectParameter.shape)
return _internal_shape(index);
}
inline ::caffe::BlobShape* ConnectParameter::_internal_add_shape() {
return shape_.Add();
}
inline ::caffe::BlobShape* ConnectParameter::add_shape() {
// @@protoc_insertion_point(field_add:caffe.ConnectParameter.shape)
return _internal_add_shape();
}
inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::caffe::BlobShape >&
ConnectParameter::shape() const {
// @@protoc_insertion_point(field_list:caffe.ConnectParameter.shape)
return shape_;
}
#ifdef __GNUC__
#pragma GCC diagnostic pop
#endif // __GNUC__
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// @@protoc_insertion_point(namespace_scope)
} // namespace caffe
PROTOBUF_NAMESPACE_OPEN
template <> struct is_proto_enum< ::caffe::EmitConstraint_EmitType> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::EmitConstraint_EmitType>() {
return ::caffe::EmitConstraint_EmitType_descriptor();
}
template <> struct is_proto_enum< ::caffe::AnnotatedDatum_AnnotationType> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::AnnotatedDatum_AnnotationType>() {
return ::caffe::AnnotatedDatum_AnnotationType_descriptor();
}
template <> struct is_proto_enum< ::caffe::FillerParameter_VarianceNorm> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::FillerParameter_VarianceNorm>() {
return ::caffe::FillerParameter_VarianceNorm_descriptor();
}
template <> struct is_proto_enum< ::caffe::SolverParameter_SnapshotFormat> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::SolverParameter_SnapshotFormat>() {
return ::caffe::SolverParameter_SnapshotFormat_descriptor();
}
template <> struct is_proto_enum< ::caffe::SolverParameter_SolverMode> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::SolverParameter_SolverMode>() {
return ::caffe::SolverParameter_SolverMode_descriptor();
}
template <> struct is_proto_enum< ::caffe::SolverParameter_SolverType> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::SolverParameter_SolverType>() {
return ::caffe::SolverParameter_SolverType_descriptor();
}
template <> struct is_proto_enum< ::caffe::ParamSpec_DimCheckMode> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::ParamSpec_DimCheckMode>() {
return ::caffe::ParamSpec_DimCheckMode_descriptor();
}
template <> struct is_proto_enum< ::caffe::ResizeParameter_Resize_mode> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::ResizeParameter_Resize_mode>() {
return ::caffe::ResizeParameter_Resize_mode_descriptor();
}
template <> struct is_proto_enum< ::caffe::ResizeParameter_Pad_mode> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::ResizeParameter_Pad_mode>() {
return ::caffe::ResizeParameter_Pad_mode_descriptor();
}
template <> struct is_proto_enum< ::caffe::ResizeParameter_Interp_mode> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::ResizeParameter_Interp_mode>() {
return ::caffe::ResizeParameter_Interp_mode_descriptor();
}
template <> struct is_proto_enum< ::caffe::LossParameter_NormalizationMode> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::LossParameter_NormalizationMode>() {
return ::caffe::LossParameter_NormalizationMode_descriptor();
}
template <> struct is_proto_enum< ::caffe::ConvolutionParameter_Engine> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::ConvolutionParameter_Engine>() {
return ::caffe::ConvolutionParameter_Engine_descriptor();
}
template <> struct is_proto_enum< ::caffe::DataParameter_DB> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::DataParameter_DB>() {
return ::caffe::DataParameter_DB_descriptor();
}
template <> struct is_proto_enum< ::caffe::EltwiseParameter_EltwiseOp> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::EltwiseParameter_EltwiseOp>() {
return ::caffe::EltwiseParameter_EltwiseOp_descriptor();
}
template <> struct is_proto_enum< ::caffe::HingeLossParameter_Norm> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::HingeLossParameter_Norm>() {
return ::caffe::HingeLossParameter_Norm_descriptor();
}
template <> struct is_proto_enum< ::caffe::LRNParameter_NormRegion> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::LRNParameter_NormRegion>() {
return ::caffe::LRNParameter_NormRegion_descriptor();
}
template <> struct is_proto_enum< ::caffe::LRNParameter_Engine> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::LRNParameter_Engine>() {
return ::caffe::LRNParameter_Engine_descriptor();
}
template <> struct is_proto_enum< ::caffe::MultiBoxLossParameter_LocLossType> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::MultiBoxLossParameter_LocLossType>() {
return ::caffe::MultiBoxLossParameter_LocLossType_descriptor();
}
template <> struct is_proto_enum< ::caffe::MultiBoxLossParameter_ConfLossType> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::MultiBoxLossParameter_ConfLossType>() {
return ::caffe::MultiBoxLossParameter_ConfLossType_descriptor();
}
template <> struct is_proto_enum< ::caffe::MultiBoxLossParameter_MatchType> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::MultiBoxLossParameter_MatchType>() {
return ::caffe::MultiBoxLossParameter_MatchType_descriptor();
}
template <> struct is_proto_enum< ::caffe::PoolingParameter_PoolMethod> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::PoolingParameter_PoolMethod>() {
return ::caffe::PoolingParameter_PoolMethod_descriptor();
}
template <> struct is_proto_enum< ::caffe::PoolingParameter_Engine> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::PoolingParameter_Engine>() {
return ::caffe::PoolingParameter_Engine_descriptor();
}
template <> struct is_proto_enum< ::caffe::PriorBoxParameter_CodeType> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::PriorBoxParameter_CodeType>() {
return ::caffe::PriorBoxParameter_CodeType_descriptor();
}
template <> struct is_proto_enum< ::caffe::ReductionParameter_ReductionOp> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::ReductionParameter_ReductionOp>() {
return ::caffe::ReductionParameter_ReductionOp_descriptor();
}
template <> struct is_proto_enum< ::caffe::ReLUParameter_Engine> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::ReLUParameter_Engine>() {
return ::caffe::ReLUParameter_Engine_descriptor();
}
template <> struct is_proto_enum< ::caffe::SigmoidParameter_Engine> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::SigmoidParameter_Engine>() {
return ::caffe::SigmoidParameter_Engine_descriptor();
}
template <> struct is_proto_enum< ::caffe::SoftmaxParameter_Engine> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::SoftmaxParameter_Engine>() {
return ::caffe::SoftmaxParameter_Engine_descriptor();
}
template <> struct is_proto_enum< ::caffe::TanHParameter_Engine> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::TanHParameter_Engine>() {
return ::caffe::TanHParameter_Engine_descriptor();
}
template <> struct is_proto_enum< ::caffe::MILParameter_MILType> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::MILParameter_MILType>() {
return ::caffe::MILParameter_MILType_descriptor();
}
template <> struct is_proto_enum< ::caffe::VideoDataParameter_VideoType> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::VideoDataParameter_VideoType>() {
return ::caffe::VideoDataParameter_VideoType_descriptor();
}
template <> struct is_proto_enum< ::caffe::SPPParameter_PoolMethod> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::SPPParameter_PoolMethod>() {
return ::caffe::SPPParameter_PoolMethod_descriptor();
}
template <> struct is_proto_enum< ::caffe::SPPParameter_Engine> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::SPPParameter_Engine>() {
return ::caffe::SPPParameter_Engine_descriptor();
}
template <> struct is_proto_enum< ::caffe::V1LayerParameter_LayerType> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::V1LayerParameter_LayerType>() {
return ::caffe::V1LayerParameter_LayerType_descriptor();
}
template <> struct is_proto_enum< ::caffe::V1LayerParameter_DimCheckMode> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::V1LayerParameter_DimCheckMode>() {
return ::caffe::V1LayerParameter_DimCheckMode_descriptor();
}
template <> struct is_proto_enum< ::caffe::V0LayerParameter_PoolMethod> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::V0LayerParameter_PoolMethod>() {
return ::caffe::V0LayerParameter_PoolMethod_descriptor();
}
template <> struct is_proto_enum< ::caffe::Phase> : ::std::true_type {};
template <>
inline const EnumDescriptor* GetEnumDescriptor< ::caffe::Phase>() {
return ::caffe::Phase_descriptor();
}
PROTOBUF_NAMESPACE_CLOSE
// @@protoc_insertion_point(global_scope)
#include <google/protobuf/port_undef.inc>
#endif // GOOGLE_PROTOBUF_INCLUDED_GOOGLE_PROTOBUF_INCLUDED_caffe_2eproto
| [
"39266922@qq.com"
] | 39266922@qq.com |
4cf998ca353455d74c92bc7238a4191b34cd1363 | 36b9decf14d266d6babaf1c44085c2ba869c03ce | /Remnant-main/Remnant/SDK/Widget_QuestNotification_ObjectiveSuccess_parameters.h | 3917579aef34323dcb3e8f637fc19ddb9ab1e9a1 | [] | no_license | RoryGlenn/RemnantLootSwitcher | 6e309a7b2b7bac88a166b552b640c830b863eb2d | 85c4cb6839b7c0f60cf8143c571d64ca12439a63 | refs/heads/master | 2022-12-29T08:47:15.713546 | 2020-10-23T22:01:45 | 2020-10-23T22:01:45 | 305,910,400 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,605 | h | #pragma once
// Name: Remnant, Version: 6
#include "../SDK.h"
#ifdef _MSC_VER
#pragma pack(push, 0x01)
#endif
/*!!HELPER_DEF!!*/
/*!!DEFINE!!*/
namespace UFT
{
//---------------------------------------------------------------------------
// Parameters
//---------------------------------------------------------------------------
// Function Widget_QuestNotification_ObjectiveSuccess.Widget_QuestNotification_ObjectiveSuccess_C.BuildRewardList
struct UWidget_QuestNotification_ObjectiveSuccess_C_BuildRewardList_Params
{
};
// Function Widget_QuestNotification_ObjectiveSuccess.Widget_QuestNotification_ObjectiveSuccess_C.FadeOut
struct UWidget_QuestNotification_ObjectiveSuccess_C_FadeOut_Params
{
float Delay; // (BlueprintVisible, BlueprintReadOnly, Parm, ZeroConstructor, IsPlainOldData, NoDestructor, HasGetValueTypeHash)
};
// Function Widget_QuestNotification_ObjectiveSuccess.Widget_QuestNotification_ObjectiveSuccess_C.Get_QuestName_Text_1
struct UWidget_QuestNotification_ObjectiveSuccess_C_Get_QuestName_Text_1_Params
{
struct FText ReturnValue; // (Parm, OutParm, ReturnParm)
};
// Function Widget_QuestNotification_ObjectiveSuccess.Widget_QuestNotification_ObjectiveSuccess_C.Construct
struct UWidget_QuestNotification_ObjectiveSuccess_C_Construct_Params
{
};
// Function Widget_QuestNotification_ObjectiveSuccess.Widget_QuestNotification_ObjectiveSuccess_C.OnFadeOut
struct UWidget_QuestNotification_ObjectiveSuccess_C_OnFadeOut_Params
{
};
// Function Widget_QuestNotification_ObjectiveSuccess.Widget_QuestNotification_ObjectiveSuccess_C.OnRemoveFromParent
struct UWidget_QuestNotification_ObjectiveSuccess_C_OnRemoveFromParent_Params
{
};
// Function Widget_QuestNotification_ObjectiveSuccess.Widget_QuestNotification_ObjectiveSuccess_C.BuildListWithDelay
struct UWidget_QuestNotification_ObjectiveSuccess_C_BuildListWithDelay_Params
{
};
// Function Widget_QuestNotification_ObjectiveSuccess.Widget_QuestNotification_ObjectiveSuccess_C.ExecuteUbergraph_Widget_QuestNotification_ObjectiveSuccess
struct UWidget_QuestNotification_ObjectiveSuccess_C_ExecuteUbergraph_Widget_QuestNotification_ObjectiveSuccess_Params
{
int EntryPoint; // (BlueprintVisible, BlueprintReadOnly, Parm, ZeroConstructor, IsPlainOldData, NoDestructor, HasGetValueTypeHash)
};
}
#ifdef _MSC_VER
#pragma pack(pop)
#endif
| [
"romglenn@ucsc.edu"
] | romglenn@ucsc.edu |
935f4aef6d3cabb1d50488ba6c2e5a031b9cf677 | 4a3120997e23cee3cbf7b634c1e887f5cce47b8c | /main.cpp | 862718df9de0dc45151c2c7e2ced131e57e84b59 | [] | no_license | sarahklock/manipulando_arquivos-tarefas.cpp | e2c69b5e50193d0fad7f39a8c8bc018d8b6b0c17 | a56b34530bb541064e379ea1697f99053c439969 | refs/heads/master | 2020-09-15T00:40:18.396723 | 2019-12-09T20:42:00 | 2019-12-09T20:42:00 | 223,307,874 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,497 | cpp | #include <iostream>
#include <iomanip>
#include <fstream>
#include <stdlib.h>
#include <vector>
#include <algorithm>
using namespace std;
int main(){
ofstream arquivo;
string tarefas;
vector <string> tasks;
int sn;
cout << "Digite 1 para criar uma lista de tarefas, 2 para acrescentar mais tarefas a lista anterior.\n";
cin >> sn;
cin.ignore();
if (sn == 1){
tasks.push_back("Tarefas:");
}
if (sn == 2){
ifstream arquivo_antigo;
arquivo_antigo.open("teste.txt", ios :: app );
while(!arquivo_antigo.eof()){
getline(arquivo_antigo, tarefas);
tasks.push_back(tarefas);
cout << tarefas << endl;
}
arquivo_antigo.close();
}
arquivo.open("teste.txt");
do{
cout << "Acrescente uma tarefa: \n";
getline(cin, tarefas);
tasks.push_back("-> " + tarefas);
cout << "Deseja acrescentar mais tarefas? Digite 1 para 'sim', 0 para 'nao'. \n";
cin >> sn;
cin.ignore();
} while(sn != 0);
sort(tasks.begin() + 1, tasks.end());
system("cls");
cout << "Esta eh a sua lista de tarefas em ordem alfabetica: ";
for(string task: tasks){
cout << endl << task;
}
cout << endl << "Deseja deletar alguma tarefas? Se sim, digite 1 e, em seguida, em qual linha, \n";
cout << "a partir da primeira tarefa, esta a que deseja deletar. Se não, digite 2.\n";
cin >> sn;
if (sn == 1){
int linha_deletar;
cin >> linha_deletar;
tasks.erase(tasks.begin() + linha_deletar);
}
while(sn == 1){
cout << "Esta eh a sua lista de tarefas atualizada: ";
for(string task: tasks){
cout << endl << task;
}
cout << endl << endl << "Deseja deletar mais alguma tarefas? Se sim, digite 1 e, em seguida, em qual linha, \n";
cout << "a partir da primeira tarefa, esta a que deseja deletar. Se nao, digite 2.\n";
cin >> sn;
if (sn == 1){
int linha_deletar;
cin >> linha_deletar;
tasks.erase(tasks.begin() + linha_deletar);
}
}
arquivo << tasks[0];
for(int i = 1; i < tasks.size(); i++){
arquivo << endl << tasks[i];
}
arquivo.close();
cout << "Sua lista esta pronta!\n";
return 0;
}
| [
"noreply@github.com"
] | noreply@github.com |
b504d94a71eba5c6d6ade36997a103df451c6a50 | cb142e98b043e7088f0fe009f5159928877acf1b | /D1mini/WiFi_ofo_test/B2_GSM_GPRS_GPS.ino | 46ab985a03101c4bbfd54e7ba98a3ebe77e73333 | [] | no_license | wetnt/Arduino_public | ef30502b4a30e099a09e2617fd58fd3a9801cf13 | 4cc331e2f43dda0df8f78d9cfe924da130ca5df3 | refs/heads/master | 2021-01-23T09:38:43.302783 | 2019-09-12T00:29:43 | 2019-09-12T00:29:43 | 33,909,041 | 2 | 2 | null | null | null | null | UTF-8 | C++ | false | false | 3,011 | ino | //#include "SIM900.h"
//#include "gps.h"
//
//GPSGSM gps;
//
//char lon[15];
//char lat[15];
//char alt[15];
//char time[20];
//char vel[15];
//char msg1[5];
//char msg2[5];
//
//char stat;
//char inSerial[20];
//int i=0;
//boolean started=false;
//
//void gsm_setup(){
// if (gsm.begin(9600)) {
// lg("\nstatus=READY");
// gsm.forceON(); //To ensure that SIM908 is not only in charge mode
// started=true;
// } else lg("\nstatus=IDLE");
//
// if(started) {
// //GPS attach
// if (gps.attachGPS())
// lgln("status=GPSREADY");
// else lgln("status=ERROR");
//
// delay(20000); //Time for fixing
// stat=gps.getStat();
// if(stat==1)
// lgln("NOT FIXED");
// else if(stat==0)
// lgln("GPS OFF");
// else if(stat==2)
// lgln("2D FIXED");
// else if(stat==3)
// lgln("3D FIXED");
// delay(5000);
// //Get data from GPS
// gps.getPar(lon,lat,alt,time,vel);
// Serial.println(lon);
// Serial.println(lat);
// Serial.println(alt);
// Serial.println(time);
// Serial.println(vel);
// }
//};
//
//void loop()
//{
// //Read for new byte on serial hardware,
// //and write them on NewSoftSerial.
// serialhwread();
// //Read for new byte on NewSoftSerial.
// serialswread();
//};
//
//void serialhwread()
//{
// i=0;
// if (Serial.available() > 0) {
// while (Serial.available() > 0) {
// inSerial[i]=(Serial.read());
// delay(10);
// i++;
// }
//
// inSerial[i]='\0';
// if(!strcmp(inSerial,"/END")) {
// Serial.println("_");
// inSerial[0]=0x1a;
// inSerial[1]='\0';
// gsm.SimpleWriteln(inSerial);
// }
// //Send a saved AT command using serial port.
// if(!strcmp(inSerial,"TEST")) {
//// Serial.println("BATTERY TEST 1");
//// gps.getBattInf(msg1,msg2);
//// Serial.println(msg1);
//// Serial.println(msg2);
//// Serial.println("BATTERY TEST 2");
//// gps.getBattTVol(msg1);
//// Serial.println(msg1);
// stat=gps.getStat();
// if(stat==1)
// Serial.println("NOT FIXED");
// else if(stat==0)
// Serial.println("GPS OFF");
// else if(stat==2)
// Serial.println("2D FIXED");
// else if(stat==3)
// Serial.println("3D FIXED");
// }
// //Read last message saved.
// if(!strcmp(inSerial,"MSG")) {
// Serial.println(msg1);
// } else {
// Serial.println(inSerial);
// gsm.SimpleWriteln(inSerial);
// }
// inSerial[0]='\0';
// }
//}
//
//void serialswread(){
// gsm.SimpleRead();
//}
| [
"wetnt@sina.com"
] | wetnt@sina.com |
c0e8a872db8697a351ce57d3feae593ab1b92d3c | 3531dd9f52b11ae26d0c5f624a815538bf4c1964 | /examples/ITVDN_CPP/other/makefile/Github/_advanced/makefile-tutorial2/clientB.cc | 0213c47a017c6e843e652122df52bc56657b6f38 | [] | no_license | syurskyi/CPP_Topics | b9a481fa828fb763fe4e21388cd04b4e90c2cd96 | c9851ab9e254e2fc01ab1bb819ca1d642f623fae | refs/heads/master | 2022-12-11T16:12:49.219989 | 2020-09-01T22:36:08 | 2020-09-01T22:36:08 | 277,678,709 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 174 | cc | #include "libfib.h"
#include <iostream>
int main() {
printf("%d\n", fib_slow(10));
printf("%d\n", fib_fast(40));
printf("%d\n", fib_wrong(2147483647));
return 0;
}
| [
"sergejyurskyj@yahoo.com"
] | sergejyurskyj@yahoo.com |
38f07117b6bc5885a22161d5777df0b50bd3e565 | 28124b6f9a1c1c4e1f8873f23ab9ea6a1bca28a3 | /gameviewstate.cpp | 6e37911c51ea496d8ab88709c8f80003096329b8 | [] | no_license | Konstilio/Tower_Defence | 07297646cc2274d9fada06bb560366dd7cffb0b5 | 21e7884a2d612e7cf2377639a13fff1713c053db | refs/heads/master | 2021-01-14T05:02:38.248983 | 2017-02-23T15:48:45 | 2017-02-23T15:48:45 | 81,852,847 | 0 | 1 | null | null | null | null | UTF-8 | C++ | false | false | 4,663 | cpp | #include "gameviewstate.h"
#include "gameview.h"
#include "gamescene.h"
#include "tower.h"
#include "enemy.h"
#include <QCursor>
#include <QDebug>
GameViewState::GameViewState(GameView *View, GameScene *Scene, QObject *Parent)
: QObject(Parent)
, mp_View(View)
, mp_Scene(Scene)
{
}
void GameViewState::SetScene(GameScene *Scene)
{
mp_Scene = Scene;
}
// NormalViewState
NormalViewState::NormalViewState(GameView *View, GameScene *Scene, QObject *Parent)
: GameViewState(View, Scene, Parent)
{
}
void NormalViewState::mouseMoveEvent(QMouseEvent *event)
{
(void)event;
}
void NormalViewState::leaveEvent()
{
}
void NormalViewState::mousePressEvent(QMouseEvent *event)
{
if (event->button() == Qt::RightButton)
{
ClearSelected();
emit SelectionCleared();
return;
}
if (event->button() != Qt::LeftButton)
return;
ClearSelected();
auto Items = mp_Scene->items(event->pos());
for (auto *Item : Items)
{
auto *TowerItem = qgraphicsitem_cast<Tower *>(Item);
if (TowerItem)
{
mp_SelectedTower = TowerItem;
mp_SelectedTower->Indicate(Tower::EIndicator_Select);
emit TowerSelected(mp_Scene->CanUpgradeTower(mp_SelectedTower));
emit TowerSelected(mp_SelectedTower);
return;
}
auto *EnemyItem = qgraphicsitem_cast<Enemy *>(Item);
if (EnemyItem)
{
mp_SelectedEnemy = EnemyItem;
emit EnemySelected(mp_SelectedEnemy);
return;
}
}
emit SelectionCleared();
}
void NormalViewState::onEnter()
{
}
void NormalViewState::onExit()
{
ClearSelected();
emit SelectionCleared();
}
void NormalViewState::UpgradeRequested()
{
if (!mp_SelectedTower)
return;
mp_Scene->UpgradeTower(mp_SelectedTower);
}
void NormalViewState::SellRequested()
{
if (!mp_SelectedTower)
return;
mp_Scene->SellTower(mp_SelectedTower);
ClearSelected();
emit SelectionCleared();
}
void NormalViewState::onLevelChanged()
{
if (mp_SelectedTower)
emit TowerSelected(mp_Scene->CanUpgradeTower(mp_SelectedTower));
}
void NormalViewState::onSceneUpdated()
{
if (!mp_SelectedTower)
emit EnemySelected(mp_SelectedEnemy);
}
void NormalViewState::ClearSelected()
{
if (mp_SelectedTower)
{
mp_SelectedTower->ClearIndicator();
mp_SelectedTower.clear();
}
mp_SelectedEnemy.clear();
}
// BuildViewState
BuildViewState::BuildViewState(GameView *View, GameScene *Scene, QObject *Parent)
: GameViewState(View, Scene, Parent)
, mp_PrevTilePos({-1,-1})
{
}
void BuildViewState::mouseMoveEvent(QMouseEvent *event)
{
QPoint CurrentTilePos = mp_Scene->mapGlobalToTile(event->pos());
if (mp_PrevTilePos == CurrentTilePos)
return;
Q_ASSERT(mp_Tower);
if (mp_Tower->scene() != mp_Scene)
{
mp_Scene->RemoveTempItem(mp_Tower);
mp_Scene->AddTempGameItem(mp_Tower, CurrentTilePos);
}
else
mp_Scene->MoveTempItem(mp_Tower, CurrentTilePos);
mp_CanBuild = mp_Scene->CanBuildTower(mp_Tower);
mp_Tower->Indicate(mp_CanBuild ? Tower::EIndicator_CanBuild : Tower::EIndicator_CanNotBuild);
mp_PrevTilePos = CurrentTilePos;
}
void BuildViewState::leaveEvent()
{
mp_Scene->RemoveTempItem(mp_Tower);
}
void BuildViewState::mousePressEvent(QMouseEvent *event)
{
mp_WantBuild = event->button() == Qt::LeftButton;
if (mp_WantBuild)
mp_CanBuild = mp_Scene->CanBuildTower(mp_Tower);
if ((mp_WantBuild && mp_CanBuild) || !mp_WantBuild)
emit WantLeave();
else
mp_WantBuild = false;
}
void BuildViewState::onEnter()
{
Q_ASSERT(mp_Tower);
mp_Tower->Indicate(Tower::EIndicator_CanBuild);
mp_View->setCursor(Qt::PointingHandCursor);
emit TowerAttached(mp_Tower);
}
void BuildViewState::onExit()
{
if (!mp_WantBuild)
{
mp_Scene->RemoveTempItem(mp_Tower);
delete mp_Tower;
}
else
{
mp_Scene->BuildTower(mp_Tower);
mp_Tower->ClearIndicator();
}
emit AttachedTowerCleared();
mp_Tower = nullptr;
mp_View->setCursor(Qt::ArrowCursor);
mp_PrevTilePos = {-1, -1};
}
void BuildViewState::AttachTower(Tower *TowerItem)
{
Q_ASSERT(TowerItem);
delete mp_Tower;
mp_Tower = TowerItem;
emit TowerAttached(mp_Tower);
}
void BuildViewState::onSceneUpdated()
{
if (!mp_Tower)
return;
mp_CanBuild = mp_Scene->CanBuildTower(mp_Tower);
mp_Tower->Indicate(mp_CanBuild ? Tower::EIndicator_CanBuild : Tower::EIndicator_CanNotBuild);
}
| [
"acmilan1"
] | acmilan1 |
8502af8420f40706061404ddb115447581e669d6 | ab261c6ef92b3af072aac4d4edce669e652b7987 | /thrift/lib/cpp2/transport/http2/common/MultiRpcChannel.h | f5ad6c9a8fa54c8c778e48ffabb8e45af81fb45f | [
"Apache-2.0"
] | permissive | ambikabohra/fbthrift | 747c41e775b72a2b0da7692f1e04d6cc3b7e4fe5 | 2f0c98fc33d5a466ec3eebf49e25558e559f94c2 | refs/heads/master | 2021-08-17T01:48:34.471448 | 2017-11-20T16:34:52 | 2017-11-20T16:40:38 | 111,459,658 | 1 | 0 | null | 2017-11-20T20:30:46 | 2017-11-20T20:30:46 | null | UTF-8 | C++ | false | false | 4,761 | h | /*
* Copyright 2017-present Facebook, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#pragma once
#include <thrift/lib/cpp2/transport/http2/common/H2Channel.h>
#include <proxygen/lib/http/session/HTTPTransaction.h>
#include <thrift/lib/cpp/protocol/TProtocolTypes.h>
#include <chrono>
#include <string>
#include <vector>
namespace apache {
namespace thrift {
class MultiRpcChannel : public H2Channel {
public:
MultiRpcChannel(
proxygen::ResponseHandler* toHttp2,
ThriftProcessor* processor);
explicit MultiRpcChannel(H2ClientConnection* toHttp2);
virtual ~MultiRpcChannel() override;
// Initializes the client side channel by creating a transaction and
// calling sendHeaders(). Cannot be performed in the constructor.
void initialize(std::chrono::milliseconds timeout);
void sendThriftResponse(
std::unique_ptr<ResponseRpcMetadata> metadata,
std::unique_ptr<folly::IOBuf> payload) noexcept override;
virtual void sendThriftRequest(
std::unique_ptr<RequestRpcMetadata> metadata,
std::unique_ptr<folly::IOBuf> payload,
std::unique_ptr<ThriftClientCallback> callback) noexcept override;
folly::EventBase* getEventBase() noexcept override;
void setInput(int32_t seqId, SubscriberRef sink) noexcept override;
SubscriberRef getOutput(int32_t seqId) noexcept override;
void onH2StreamBegin(
std::unique_ptr<proxygen::HTTPMessage> headers) noexcept override;
void onH2BodyFrame(std::unique_ptr<folly::IOBuf> contents) noexcept override;
void onH2StreamEnd() noexcept override;
void onH2StreamClosed(proxygen::ProxygenError) noexcept override;
// Returns true if this channel can process more RPCs.
bool canDoRpcs() noexcept;
// Closes the outgoing stream on the client side by calling sendEOM().
void closeClientSide() noexcept;
private:
// TODO: This is hardwired for now. We should negotiate this value
// between client and server.
static constexpr uint32_t kMaxRpcs = 1024;
// Server side handling when we have a complete Thrift request.
virtual void onThriftRequest() noexcept;
// Client side handling when we have a complete Thrift response.
void onThriftResponse() noexcept;
// Combines the three arguments into a single IOBuf chain.
std::unique_ptr<folly::IOBuf> combine(
uint32_t size,
std::unique_ptr<folly::IOBuf>&& metadata,
std::unique_ptr<folly::IOBuf>&& payload) noexcept;
// Add the IOBuf object to payload_.
void addToPayload(std::unique_ptr<folly::IOBuf> buf) noexcept;
void performErrorCallbacks(proxygen::ProxygenError error) noexcept;
// Called from onThriftRequest() to send an error response.
void sendThriftErrorResponse(
const std::string& message,
ProtocolId protoId = ProtocolId::COMPACT) noexcept;
// The thrift processor used to execute RPCs (server side only).
// Owned by H2ThriftServer.
ThriftProcessor* processor_{nullptr};
// Event base on which all methods in this object must be invoked.
folly::EventBase* evb_;
// Transaction object for use on client side to communicate with the
// Proxygen layer.
proxygen::HTTPTransaction* httpTransaction_;
// Callbacks for client side indexed by sequence id.
std::vector<std::unique_ptr<ThriftClientCallback>> callbacks_;
// The data from Proxygen for each RPC may arrive via multiple calls
// to onH2BodyFrame(), and also the same call to onH2BodyFrame() may
// contain data for multiple RPCs. Therefore, we need to maintain
// the current state of the data in the fields below.
// The payload for each RPC starts with a 4 byte size field. This
// specifies how many size bytes are yet to be read for the current
// RPC.
uint32_t sizeBytesRemaining_{4};
// Once the size bytes have been read, we need to read an additional
// number of bytes as specified in the size bytes. This specifies
// how many bytes remain to be read.
uint32_t payloadBytesRemaining_{0};
// The part of the RPC payload that has been read so far.
std::unique_ptr<folly::IOBuf> payload_;
// If true, no more rpcs may be initiated.
bool isClosed_{false};
uint32_t rpcsInitiated_{0};
uint32_t rpcsCompleted_{0};
};
} // namespace thrift
} // namespace apache
| [
"facebook-github-bot@users.noreply.github.com"
] | facebook-github-bot@users.noreply.github.com |
0adec576f685f8cfa102f903798617242d08675e | 88f963a4c549b429977b9b793d8c2a988cbba1c9 | /hy-ideal/routers/LowerNRC.cc | 9cb19b881aee41cc9bfef70bd74e3ddda7ffa468 | [] | no_license | konigsberg/tianhe_network | 3fee004b4d6150288654c411b396914c4004652a | fd3aa983b75dc6b47578f39f768ca58b564098b8 | refs/heads/master | 2021-07-26T01:34:13.547047 | 2018-07-20T01:12:53 | 2018-07-20T01:12:53 | 133,828,943 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 27,948 | cc | #include <algorithm>
#include <cassert>
#include <cstring>
#include "LowerNRC.h"
using buf = std::deque<flit *>;
LowerNRC::LowerNRC() {}
LowerNRC::~LowerNRC() {
cancelAndDelete(self_timer_);
// clear inbuf
auto inbuf_flits = 0;
for (auto i = 0; i < P; i++) {
for (auto j = 0; j < V; j++) {
while (!inbuf_[i][j].empty()) {
delete inbuf_[i][j].front();
inbuf_[i][j].pop_front();
inbuf_flits++;
}
}
}
recordScalar("inbuf_flits_left", inbuf_flits);
// clear swtbuf
auto swtbuf_flits = 0;
for (auto i = 0; i < H; i++)
for (auto j = 0; j < W; j++)
for (auto k = 0; k < W; k++)
for (auto b = 0; b < H; b++)
for (auto v = 0; v < V; v++)
while (!swtbuf_[i][j][k][b][v].empty()) {
delete swtbuf_[i][j][k][b][v].front();
swtbuf_[i][j][k][b][v].pop_front();
swtbuf_flits++;
}
recordScalar("swtbuf_flits_left", swtbuf_flits);
// clearing free_msg_queue and forward_queue is unnecessary.
// pipeline is removed. free_msg is integrated into flit.
// clear colbuf
auto colbuf_flits = 0;
for (auto i = 0; i < H; i++)
for (auto j = 0; j < W; j++)
for (auto k = 0; k < H; k++)
for (auto v = 0; v < V; v++)
while (!colbuf_[i][j][k][v].empty()) {
delete colbuf_[i][j][k][v].front();
colbuf_[i][j][k][v].pop_front();
colbuf_flits++;
}
recordScalar("colbuf_flits_left", colbuf_flits);
// clear credit_queue
auto credits = 0;
for (auto p = 0; p < P; p++) {
while (!credit_queue_[p].empty()) {
delete credit_queue_[p].front();
credit_queue_[p].pop_front();
++credits;
}
}
recordScalar("credits_unsent", credits);
}
void LowerNRC::initialize() {
clock_ = 0;
self_timer_ = new omnetpp::cMessage("self_timer");
scheduleAt(sim_start_time, self_timer_);
std::fill(routing_result_[0],
routing_result_[0] + sizeof(routing_result_) / sizeof(int32_t), -1);
std::fill(next_routing_result_[0],
next_routing_result_[0] +
sizeof(next_routing_result_) / sizeof(int32_t),
-1);
std::fill(credit_[0], credit_[0] + sizeof(credit_) / sizeof(int32_t),
inbuf_capacity);
memset(vca1_state_[0][0][0][0], 0, sizeof(vca1_state_));
std::fill(vca1_result_[0][0][0],
vca1_result_[0][0][0] + sizeof(vca1_result_) / sizeof(int32_t), -1);
std::fill(vca1_result_prev_[0][0][0],
vca1_result_prev_[0][0][0] +
sizeof(vca1_result_prev_) / sizeof(int32_t),
-1);
std::fill(sa1_result_[0][0],
sa1_result_[0][0] + sizeof(sa1_result_) / sizeof(int32_t), -1);
std::fill(vca2_port_[0][0],
vca2_port_[0][0] + sizeof(vca2_port_) / sizeof(int32_t), -1);
std::fill(vca2_port_prev_[0][0],
vca2_port_prev_[0][0] + sizeof(vca2_port_prev_) / sizeof(int32_t),
-1);
std::fill(sa2_vcid_, sa2_vcid_ + sizeof(sa2_vcid_) / sizeof(int32_t), -1);
std::fill(cabinet_remote_credit_counter_[0][0],
cabinet_remote_credit_counter_[0][0] +
sizeof(cabinet_remote_credit_counter_) / sizeof(int32_t),
inbuf_capacity);
std::fill(cabinet_local_credit_counter_[0][0],
cabinet_local_credit_counter_[0][0] +
sizeof(cabinet_local_credit_counter_) / sizeof(int32_t),
inbuf_capacity);
}
void LowerNRC::handleMessage(omnetpp::cMessage *msg) {
if (msg->isSelfMessage()) {
timer_cb();
} else if (strcmp(msg->getName(), "credit") == 0 ||
strcmp(msg->getName(), "credit_lower") == 0 ||
strcmp(msg->getName(), "credit_upper") == 0) {
credit_cb(msg);
} else if (strcmp(msg->getName(), "exchange") == 0) {
exchange_cb(msg);
} else {
flit_cb(msg);
}
}
void LowerNRC::timer_cb() {
++clock_;
// std::cerr << "in lowerNRC, clock is " << clock_ << std::endl;
scheduleAt(omnetpp::simTime() + clk_cycle, self_timer_);
route_compute();
row_move();
send_credit();
first_virtual_channel_allocation();
switch_allocation();
switch_traversal();
lower_port_second_virtual_channel_allocation();
lower_port_allocation();
lower_port_forward_flit();
upper_port_select_packet();
}
#define ROUTE_COMPUTE_FOR_FLIT(pi, vi) \
{ \
if (inbuf_[pi][vi].empty()) \
continue; \
\
flit *f = inbuf_[pi][vi].front(); \
\
if (f->getIs_head() && routing_result_[pi][vi] == -1) { \
auto po = get_routing_port(f); \
auto vo = rand() % V; \
\
if (po >= P / 2) { \
auto next_po = get_next_routing_port(f); \
f->setNext_port(next_po); \
next_routing_result_[pi][vi] = next_po; \
if (next_po < P / 2) \
vo = rand() % (V / 2) + V / 2; \
else \
vo = rand() % V; \
} else \
next_routing_result_[pi][vi] = -1; \
\
f->setPort(po); \
f->setVcid(vo); \
routing_result_[pi][vi] = po * V + vo; \
} else { \
auto po = routing_result_[pi][vi] / V; \
auto vo = routing_result_[pi][vi] % V; \
f->setPort(po); \
f->setVcid(vo); \
f->setNext_port(next_routing_result_[pi][vi]); \
} \
}
void LowerNRC::route_compute() {
for (auto pi = 0; pi < P; pi++)
for (auto vi = 0; vi < V; vi++)
ROUTE_COMPUTE_FOR_FLIT(pi, vi);
}
#define ROW_MOVE_FOR_BUF(pi, vi) \
{ \
if (inbuf_[pi][vi].empty()) \
continue; \
\
buf &source = inbuf_[pi][vi]; \
flit *f = source.front(); \
auto po = f->getPort(); \
auto ti = pi / W; \
auto tj = po % W; \
auto si = pi % W; \
auto sj = po % H; \
buf &target = swtbuf_[ti][tj][si][sj][vi]; \
\
if (target.size() == swtbuf_capacity) \
continue; \
\
if (f->getIs_tail()) { \
routing_result_[pi][vi] = -1; \
next_routing_result_[pi][vi] = -1; \
} \
target.push_back(f); \
source.pop_front(); \
\
{ \
auto cdt = new credit("credit_lower"); \
\
if (pi < P / 2) { \
cdt->setOs(-1); \
cdt->setPort(get_next_port(pi)); \
cdt->setVc(vi); \
credit_queue_[pi].push_back(cdt); \
} else if (vi < V / 2) { \
cdt->setOs(get_cabinet_id()); \
cdt->setPort(get_nrm_id()); \
cdt->setVc(vi); \
credit_queue_[pi].push_back(cdt); \
} else { \
/* which upper port in NRM */ \
auto os = getIndex() * P / 2 + (po - P / 2); \
auto port = get_nrm_id(); \
cabinet_local_credit_counter_[os][port][vi] += 1; \
update_credit(local, os, port, vi, 1); \
} \
} \
}
void LowerNRC::row_move() {
for (auto pi = 0; pi < P; pi++) {
for (auto vi = 0; vi < V; vi++) {
ROW_MOVE_FOR_BUF(pi, vi);
}
}
}
void LowerNRC::send_credit() {
for (auto pi = 0; pi < P; pi++) {
if (channel_is_available(pi) && !credit_queue_[pi].empty()) {
auto cdt = credit_queue_[pi].front();
char pi_cstr[20];
sprintf(pi_cstr, "port_%d$o", pi);
send(cdt, pi_cstr);
credit_queue_[pi].pop_front();
std::cerr << get_log(log_levels::info,
"sending credit message " + credit_string(cdt) +
" at port " + std::to_string(pi));
}
}
}
#define FIRST_VCA_FOR_FLIT(ti, tj, po, vo) \
{ \
if (vca1_result_[ti][tj][po][vo] != -1) \
continue; \
\
auto r = vca1_result_prev_[ti][tj][po][vo] + 1; \
auto count = 0; \
\
for (; count < W * V; r++, count++) { \
auto result = r % (W * V); \
auto pi = result / V, vi = result % V; \
buf &buffer = swtbuf_[ti][tj][pi][po][vi]; \
if (buffer.empty()) \
continue; \
\
flit *f = buffer.front(); \
auto sub_vo = f->getVcid(); \
if (sub_vo == vo) { \
vca1_result_[ti][tj][po][vo] = result; \
vca1_result_prev_[ti][tj][po][vo] = result; \
vca1_state_[ti][tj][pi][po][vi] = true; \
break; \
} \
} \
}
void LowerNRC::first_virtual_channel_allocation() {
for (auto ti = 0; ti < H; ti++) {
for (auto tj = 0; tj < W; tj++) {
for (auto po = 0; po < H; po++) {
for (auto vo = 0; vo < V; vo++) {
FIRST_VCA_FOR_FLIT(ti, tj, po, vo);
}
}
}
}
}
#define SWITCH_ALLOC_FOR_PORT(ti, tj, po) \
{ \
auto r = sa1_result_[ti][tj][po] + 1, count = 0; \
for (; count < W * V; r++, count++) { \
auto result = r % (W * V); \
auto pi = result / V, vi = result % V; \
if (!vca1_state_[ti][tj][pi][po][vi]) \
continue; \
\
buf &source = swtbuf_[ti][tj][pi][po][vi]; \
if (source.empty()) \
continue; \
\
flit *f = source.front(); \
auto flit_po = f->getPort(); \
auto flit_vo = f->getVcid(); \
auto dest_ti = flit_po / W, dest_tj = flit_po % W; \
buf &target = colbuf_[dest_ti][dest_tj][ti][flit_vo]; \
if (target.size() == colbuf_capacity) \
continue; \
\
sa1_result_[ti][tj][po] = result; \
break; \
} \
if (count == W * V) \
sa1_result_[ti][tj][po] = -1; \
}
void LowerNRC::switch_allocation() {
for (auto ti = 0; ti < H; ti++) {
for (auto tj = 0; tj < W; tj++) {
for (auto po = 0; po < H; po++) {
SWITCH_ALLOC_FOR_PORT(ti, tj, po);
}
}
}
}
#define SWITCH_TRAV_FOR_PORT(ti, tj, po) \
{ \
auto result = sa1_result_[ti][tj][po]; \
if (result == -1) \
continue; \
\
auto pi = result / V, vi = result % V; \
buf &source = swtbuf_[ti][tj][pi][po][vi]; \
flit *f = source.front(); \
auto flit_po = f->getPort(); \
auto flit_vo = f->getVcid(); \
auto dest_ti = flit_po / W, dest_tj = flit_po % W; \
buf &target = colbuf_[dest_ti][dest_tj][ti][flit_vo]; \
target.push_back(f); \
source.pop_front(); \
if (f->getIs_tail()) { \
vca1_state_[ti][tj][pi][po][vi] = false; \
vca1_result_[ti][tj][po][flit_vo] = -1; \
} \
}
void LowerNRC::switch_traversal() {
for (auto ti = 0; ti < H; ti++) {
for (auto tj = 0; tj < W; tj++) {
for (auto po = 0; po < H; po++) {
SWITCH_TRAV_FOR_PORT(ti, tj, po);
}
}
}
}
#define SECOND_VCA_FOR_FLIT(ti, tj, vo) \
{ \
if (vca2_port_[ti][tj][vo] != -1) \
continue; \
\
auto p = vca2_port_prev_[ti][tj][vo] + 1, count = 0; \
for (; count < H; p++, count++) { \
auto port = p % H; \
buf &buffer = colbuf_[ti][tj][port][vo]; \
if (buffer.empty()) \
continue; \
\
if (credit_[ti * W + tj][vo] < packet_length) \
continue; \
\
vca2_port_[ti][tj][vo] = port; \
vca2_port_prev_[ti][tj][vo] = port; \
break; \
} \
}
void LowerNRC::lower_port_second_virtual_channel_allocation() {
for (auto ti = 0; ti < H / 2; ti++) {
for (auto tj = 0; tj < W; tj++) {
for (auto vo = 0; vo < V; vo++) {
SECOND_VCA_FOR_FLIT(ti, tj, vo);
}
}
}
}
void LowerNRC::lower_port_allocation() {
for (auto po = 0; po < P / 2; po++) {
auto v = sa2_vcid_[po] + 1, count = 0;
for (; count < V; v++, count++) {
auto vcid = v % V, ti = po / W, tj = po % W;
if (vca2_port_[ti][tj][vcid] == -1) {
continue;
}
if (credit_[po][vcid] == 0) {
continue;
}
sa2_vcid_[po] = vcid;
break;
}
if (count == V) {
sa2_vcid_[po] = -1;
}
}
}
void LowerNRC::lower_port_forward_flit() {
for (auto po = 0; po < P / 2; po++) {
auto vcid = sa2_vcid_[po];
if (vcid == -1)
continue;
auto ti = po / W;
auto tj = po % W;
auto pi = vca2_port_[ti][tj][vcid];
buf &source = colbuf_[ti][tj][pi][vcid];
if (source.empty())
continue;
flit *f = source.front();
auto vi = f->getVcid();
if (credit_[po][vi] == 0)
continue;
--credit_[po][vi];
auto next_pi = get_next_port(po);
f->setPort(next_pi);
char po_str[20];
sprintf(po_str, "port_%d$o", po);
assert(channel_is_available(po));
f->setHop_count(f->getHop_count() + 1);
send(f, po_str);
std::cerr << get_log(log_levels::info, std::string("forwarded flit: ") +
f->getName() + " at port " +
std::to_string(po));
source.pop_front();
if (f->getIs_tail()) // reset VA2 Vcid
vca2_port_[ti][tj][vcid] = -1;
}
}
void LowerNRC::upper_port_select_packet() {
for (auto po = P / 2; po < P; po++) {
auto ti = po / W;
auto tj = po % W;
for (auto v = 0; v < H * V; v++) {
auto k = v / V;
auto vc = v % V;
buf &buffer = colbuf_[ti][tj][k][vc];
if (buffer.size() < packet_length)
continue;
flit *f = buffer.front();
auto next_pi = get_next_port(po);
auto next_po = f->getNext_port();
auto switched_po = get_switched_port(next_pi);
if (is_matched(next_po, switched_po) && is_right_time()) {
next_po = switched_po;
auto os_id = getIndex() * P / 2 + (po - P / 2);
auto vc = f->getVcid();
int32_t *credit = nullptr;
if (next_po < P / 2)
credit = &(cabinet_local_credit_counter_[os_id][next_po][vc]);
else
credit =
&(cabinet_remote_credit_counter_[os_id][next_po - P / 2][vc]);
if (*credit < packet_length) {
std::cerr << get_log(log_levels::debug,
"cannot forward packet because downstream inbuf "
"credit at port " +
std::to_string(po) + " is " +
std::to_string(*credit));
continue;
}
if (!channel_is_available(po)) {
std::cerr << get_log(
log_levels::debug,
"cannot forward packet because channel is unavailable at port " +
std::to_string(po));
continue;
}
upper_port_forward_packet(po, buffer);
if (next_po < P / 2) {
cabinet_local_credit_counter_[os_id][next_po][vc] -= packet_length;
update_credit(local, os_id, next_po, vc, -packet_length);
} else {
cabinet_remote_credit_counter_[os_id][next_po - P / 2][vc] -=
packet_length;
update_credit(remote, os_id, next_po - P / 2, vc, -packet_length);
}
break;
} else {
std::cerr << get_log(
log_levels::debug,
"cannot forward packet to optical switch, switched po is " +
std::to_string(switched_po) + ", requested po is " +
std::to_string(next_po));
}
}
}
}
void LowerNRC::upper_port_forward_packet(int32_t po, buf &buffer) {
char po_cstr[20];
sprintf(po_cstr, "port_%d$o", po);
for (auto count = 0; count < packet_length; count++) {
auto f = buffer.front();
f->setPort(get_next_port(po));
std::cerr << get_log(log_levels::info, std::string("forwarded flit: ") +
f->getName() + " at port " +
std::to_string(po));
f->setHop_count(f->getHop_count() + 1);
sendDelayed(f, count * clk_cycle, po_cstr);
// sendDelayed(f, count * (clk_cycle + margin), po_cstr);
buffer.pop_front();
}
}
void LowerNRC::flit_cb(omnetpp::cMessage *msg) {
flit *f = omnetpp::check_and_cast<flit *>(msg);
auto p = f->getPort();
auto v = f->getVcid();
if (inbuf_[p][v].size() > inbuf_capacity)
std::cerr << get_log(log_levels::critical,
"router " + get_id() + " input buffer overflow");
// assert(inbuf_[p][v].size() <= inbuf_capacity);
inbuf_[p][v].push_back(f);
std::cerr << get_log(log_levels::info, std::string("received flit ") +
f->getName() + " from port " +
std::to_string(p));
}
void LowerNRC::credit_cb(omnetpp::cMessage *msg) {
credit *cdt = omnetpp::check_and_cast<credit *>(msg);
std::cerr << get_log(log_levels::debug,
"receiving credit " + credit_string(cdt));
auto os = cdt->getOs();
auto port = cdt->getPort();
auto vc = cdt->getVc();
delete cdt;
if (os == -1)
++credit_[port][vc];
else {
cabinet_remote_credit_counter_[os][port][vc] += 1;
update_credit(remote, os, port, vc, 1);
}
}
void LowerNRC::exchange_cb(omnetpp::cMessage *msg) {
exchange *exc = omnetpp::check_and_cast<exchange *>(msg);
std::cerr << get_log(log_levels::debug,
"receiving exchange message " + exchange_string(exc));
auto os = exc->getOs();
auto port = exc->getPort();
auto vc = exc->getVc();
auto credit = exc->getCredit();
if (exc->getType() == local) {
cabinet_local_credit_counter_[os][port][vc] = credit;
} else {
cabinet_remote_credit_counter_[os][port][vc] = credit;
}
delete exc;
}
bool LowerNRC::channel_is_available(int32_t port) {
char poCstr[20];
sprintf(poCstr, "port_%d$o", port);
omnetpp::cChannel *channel = gate(poCstr)->getTransmissionChannel();
omnetpp::simtime_t finishTime = channel->getTransmissionFinishTime();
return finishTime <= omnetpp::simTime();
}
inline std::string LowerNRC::get_id() {
char name[30];
sprintf(name, "(LowerNRC_%d,level_%d)", getIndex(), get_curr_level());
return std::string(name);
}
std::string LowerNRC::get_log(log_levels level, const std::string &msg) {
if (log_lvl < level)
return "";
std::string lvl_type[4] = {"CRI", "WARN", "INFO", "DBG"};
std::string log_msg = lvl_type[uint8_t(level)] + "|at " +
std::to_string(omnetpp::simTime().dbl() * 1e9) +
"ns in " + get_id() + ", ";
log_msg += msg + '\n';
return log_msg;
}
inline int32_t LowerNRC::get_switched_port(int32_t in_port) {
return ((clock_ / window) % 24 + in_port) % 24;
}
inline int32_t LowerNRC::get_cabinet_id() {
return getParentModule()->getIndex() / 12;
}
inline int32_t LowerNRC::get_nrm_id() {
return getParentModule()->getIndex() % 12;
}
inline bool LowerNRC::is_matched(int32_t request_po, int32_t switched_po) {
if (request_po >= P / 2 && switched_po >= P / 2)
return true;
if (request_po == switched_po)
return true;
return false;
}
inline bool LowerNRC::is_right_time() { return clock_ % window == 0; }
inline std::string LowerNRC::credit_string(credit *cdt) {
std::string str("os=");
str += std::to_string(cdt->getOs());
str += ",port=";
str += std::to_string(cdt->getPort());
str += ",vc=";
str += std::to_string(cdt->getVc());
return str;
}
inline std::string LowerNRC::exchange_string(exchange *exc) {
std::string str("os=");
str += std::to_string(exc->getOs());
str += ",port=";
str += std::to_string(exc->getPort());
str += ",vc=";
str += std::to_string(exc->getVc());
str += ",credit=";
str += std::to_string(exc->getCredit());
return str;
}
inline void LowerNRC::update_credit(int32_t type, int32_t os, int32_t port,
int32_t vc, int32_t credit) {
exchange *exc = new exchange("exchange");
exc->setType(type);
exc->setOs(os);
exc->setPort(port);
exc->setVc(vc);
exc->setCredit(credit);
send(exc, "port_24$o");
std::cerr << get_log(log_levels::debug,
"sending exchange message " + exchange_string(exc));
}
void LowerNRC::finish() {}
| [
"wangzhao_zju@hotmail.com"
] | wangzhao_zju@hotmail.com |
2b4738d8a592b3514e504f5d0b273de627bd13d9 | 47032f7d12ac71a283583e477e8701b1d75a9fc5 | /Top_K_Frequent_Elements/Top_K_Frequent_Elements.cpp | c17356d4bfae314ae7e0e1bdb2201bda4945571c | [] | no_license | zhangguof/LeetCode | 02f48bb30974d95ca7c88115c37c1bb6a7f78e34 | ad06a5312d4276e60b66097425750076c45c12ca | refs/heads/master | 2020-12-24T16:43:16.538747 | 2019-02-03T15:36:16 | 2019-02-03T15:36:16 | 34,612,237 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 3,783 | cpp | // Top K Frequent Elements
// Go to Discuss
// Given a non-empty array of integers, return the k most frequent elements.
// Example 1:
// Input: nums = [1,1,1,2,2,3], k = 2
// Output: [1,2]
// Example 2:
// Input: nums = [1], k = 1
// Output: [1]
// Note:
// You may assume k is always valid, 1 ≤ k ≤ number of unique elements.
// Your algorithm's time complexity must be better than O(n log n), where n is the array's size.
#include <iostream>
#include <algorithm>
#include <vector>
#include <string>
#include <stdlib.h>
#include <unordered_map>
using namespace std;
class Solution {
public:
struct Node
{
int val;
int freq;
Node(){val=-1;freq=-1;}
Node(int v,int f)
{
val = v;
freq = f;
}
bool operator<(const Node& a) const{
return freq<a.freq;
}
};
struct Heap
{
//min heap
vector<Node> data;
// unordered_map<int,int> val2idx;
int max_size;
int size;
Heap(int n){
data.resize(n);
max_size = n;
size = 0;
}
//min head, max down
void do_down(int i)
{
int L = 2*i+1;
int R = 2*i+2;
int min_i = i;
if(L<size && data[L] < data[min_i])
{
min_i = L;
}
if(R<size && data[R] < data[min_i])
{
min_i = R;
}
if(min_i!=i)
{
swap(data[i],data[min_i]);
// val2idx[data[i].val] = i;
// val2idx[data[min_i].val] = min_i;
do_down(min_i);
}
}
//min head , min up!
void do_up(int i)
{
if(i==0) return;
//i>0,p>=0
int p = (i-1)/2;
if(data[i]<data[p])
{
std::swap(data[p],data[i]);
// val2idx[data[p].val] = p;
// val2idx[data[i].val] = i;
do_up(p);
}
}
void push(int v,int f)
{
// auto it = val2idx.find(v);
// // printf("push %d,%d\n",v,f);
// if(it!=val2idx.end() && it->second!=-1)
// {
// int i = it->second;
// int tf = data[i].freq;
// // printf("find idx:%d\n",i);
// // data[i].val = v;
// data[i].freq = f;
// // printf("freq updata:%d,%d,%d->%d\n",v,i,tf,f);
// assert(f>tf);
// if(f>tf)
// {
// do_down(i);
// }
// return;
// }
if(size >= max_size)
{
if(data[0].freq < f)
{
// val2idx[data[0].val] = -1;
data[0].val = v;
data[0].freq = f;
// val2idx[v] = 0;
do_down(0);
// printf("change eletem:%d,%d,%d\n",v,f,val2idx[v]);
}
}
else
{
// data.push_back(Node(v,f));
data[size++] = Node(v,f);
// size++;
// printf("new eletem %d,%d\n",v,f);
// val2idx[v] = size-1;
do_up(size-1);
// printf("new eletem:%d,%d,%d\n",v,f,val2idx[v]);
}
}
vector<int> make_sort()
{
vector<int> a(max_size);
// a.push_back(data[0].val);
int n = size;
for(int i=n-1;i>=0;--i)
{
// a.push_back(data[0].val);
a[i] = data[0].val;
swap(data[0],data[size-1]);
// data.pop_back();
size--;
do_down(0);
}
return a;
}
void print()
{
for(int i=0;i<size;++i)
{
printf("(%d,%d) ",data[i].val,data[i].freq);
}
printf("\n");
}
};
vector<int> topKFrequent(vector<int>& nums, int k) {
std::unordered_map<int,int> freq;
int n = nums.size();
Heap heap(k);
for(int i=0;i<n;++i)
{
auto iter = freq.find(nums[i]);
if(iter == freq.end())
{
freq[nums[i]] = 1;
}
else
{
freq[nums[i]]++;
}
// heap.push(nums[i],freq[nums[i]]);
}
for(auto it:freq)
{
heap.push(it.first,it.second);
}
// heap.print();
return heap.make_sort();
// return topk;
}
};
int main()
{
Solution sol;
vector<int> nums = {1,1,1,2,2,3};
// vector<int> nums = {4,1,-1,2,-1,2,3};
auto r = sol.topKFrequent(nums,2);
for(auto i:r)
{
printf("%d,",i);
}
printf("\n");
return 0;
}
| [
"zhangguof@gmail.com"
] | zhangguof@gmail.com |
4f755d904f24d31193738cb6749f1f3cc33ea7f6 | f3c16bb4e658f081b3b803b49cc561d8734194fd | /envases.cpp | 33522012eff727df22e14bbfde717e65b403b1ea | [
"Unlicense"
] | permissive | Averdrian/Problema-de-los-envases--Ramificacion-y-poda | 8e34749cebb603a1b5eb67d64de0dd014d04f8e9 | 048e5681ffd073b27962cfbe836ac755d6dc2310 | refs/heads/master | 2020-08-07T20:55:08.372027 | 2019-10-08T08:09:32 | 2019-10-08T08:09:32 | 213,584,536 | 2 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 12,610 | cpp | #include <iostream>
#include <string>
#include <fstream>
#include <vector>
#include <algorithm>
#include <stdexcept>
#include <time.h>
#include <queue>
struct Nodo {
Nodo() : sol(NULL), capacidad(NULL), k(0), envases(0) {}
Nodo(std::vector<int> s, std::vector<int> c, int K, int env) : sol(s), capacidad(c), k(K), envases(env) {}
std::vector<int> sol;
std::vector<int> capacidad;
int k, envases;
};
struct Solucion {
std::vector<int> solucion;
unsigned long long int nodosExplorados = 0;
int envases_mejor;
};
void init(std::vector<int>&, int&);
int podaPesimistaIngenua(Nodo, std::vector<int> const&);
int podaPesimistaAjustada(Nodo, std::vector<int>);
int podaOptimistaIngenua(Nodo const&);
int podaOptimistaAjustada(Nodo const&, std::vector<int> const&, int const&);
Solucion envasesPodasIngenuas(std::vector<int> const&, int const&);
Solucion envasesPodasAjustadas(std::vector<int> const&, int const&);
Solucion envasesSinPoda(std::vector<int> const&, int const&);
bool operator<(Nodo const&, Nodo const&);
bool operator==(Nodo const&, Nodo const&);
bool operator>(Nodo const&, Nodo const&);
void main() {
std::vector<int> objetos;
int tamCaja;
try {
init(objetos, tamCaja);
double clk1, clk2, time;
clk1 = clock();
Solucion solucionSinPoda = envasesSinPoda(objetos, tamCaja);
clk2 = clock();
time = (clk2 - clk1) / CLOCKS_PER_SEC;
std::cout << "\nSolucion sin poda: " << solucionSinPoda.envases_mejor << "\n"
<< "Expansiones de nodo sin poda: " << solucionSinPoda.nodosExplorados << "\n"
<< "Tiempo de ejecucion: " << time << "s\n"
<< "Tiempo medio por expansion de Nodo: " << time / solucionSinPoda.nodosExplorados << "s\n";
std::cout << "Solucion: (";
for (int i = 0; i < solucionSinPoda.solucion.size(); ++i) {
std::cout << solucionSinPoda.solucion[i];
if (i < solucionSinPoda.solucion.size() - 1) std::cout << ", ";
}
std::cout << ")\n\n";
clk1 = clock();
Solucion solucionPodaIngenua = envasesPodasIngenuas(objetos, tamCaja);
clk2 = clock();
time = (clk2 - clk1) / CLOCKS_PER_SEC;
std::cout << "Solucion con podas ingenuas: " << solucionPodaIngenua.envases_mejor << "\n"
<< "Expansiones de nodo con poda ingenua: " << solucionPodaIngenua.nodosExplorados << "\n"
<< "Tiempo de ejecucion: " << time << "s\n"
<< "Tiempo medio por expansion de Nodo: " << time / solucionPodaIngenua.nodosExplorados << "s\n";
std::cout << "Solucion: (";
for (int i = 0; i < solucionPodaIngenua.solucion.size(); ++i) {
std::cout << solucionPodaIngenua.solucion[i];
if (i < solucionPodaIngenua.solucion.size() - 1) std::cout << ", ";
}
std::cout << ")\n\n";
clk1 = clock();
Solucion solucionPodaAjustada = envasesPodasAjustadas(objetos, tamCaja);
clk2 = clock();
time = (clk2 - clk1) / CLOCKS_PER_SEC;
std::cout << "Solucion podas ajustadas: " << solucionPodaAjustada.envases_mejor << "\n"
<< "Expansiones de nodo con poda ajustada: " << solucionPodaAjustada.nodosExplorados << "\n"
<< "Tiempo de ejecucion: " << time << "s\n"
<< "Tiempo medio por expansion de Nodo: " << time / solucionPodaAjustada.nodosExplorados << "s\n";
std::cout << "Solucion: (";
for (int i = 0; i < solucionPodaAjustada.solucion.size(); ++i) {
std::cout << solucionPodaAjustada.solucion[i];
if (i < solucionPodaAjustada.solucion.size() - 1) std::cout << ", ";
}
std::cout << ")\n\n";
if (solucionSinPoda.envases_mejor != solucionPodaIngenua.envases_mejor || solucionPodaIngenua.envases_mejor != solucionPodaAjustada.envases_mejor)
throw std::domain_error("Salida incorrecta"); //Claramente esto no deberia ocurrir, pero lo dejo por si en algun caso ocurriera.
else std::cout << "Todas las soluciones coinciden";
}
catch (std::exception & e) {
std::cout << e.what() << "\n";
}
std::cin.get();
std::cin.get();
}
Solucion envasesPodasIngenuas(std::vector<int> const& obj, int const& E) {
Solucion s;
Nodo X, Y;
//Cola de prioridad que ordena los Nodos segun el numero de envases de menor a mayor
std::priority_queue<Nodo, std::deque<Nodo>, std::greater<Nodo>> C;
int total = 0;
for (int i = 0; i < obj.size(); ++i) total += obj[i];
bool encontrado = false;
//Generamos la raiz del primer elemento
Y.capacidad = std::vector<int>(obj.size(), E);
Y.sol = std::vector<int>(obj.size(), -1);
Y.k = 0; Y.envases = 1; Y.sol[0] = 0;
Y.capacidad[0] -= obj[0];
C = std::priority_queue<Nodo, std::deque<Nodo>, std::greater<Nodo>>();
C.push(Y);
s.envases_mejor = podaPesimistaIngenua(Y, obj);
int optima = podaOptimistaAjustada(Y, obj, E);
while (!encontrado && !C.empty() && C.top().envases <= s.envases_mejor) {
Y = C.top();
C.pop();
X = Y;
++X.k;
++s.nodosExplorados;
int i = -1;
//Vas creando los nodos insertando el objeto en todos los envases que puedas hasta introducirlo en un nuevo envase vacio
while (++i <= Y.envases) {
if (X.capacidad[i] >= obj[X.k]) {
if (i == Y.envases) ++X.envases;
X.sol[X.k] = i;
X.capacidad[i] -= obj[X.k];
s.envases_mejor = std::min(podaPesimistaIngenua(X, obj), s.envases_mejor);
//Si se ha encontrado la solucion y dicha solucion es como minimo tan buena como los envases de la solucion actual se pone como solucion
if (X.k == obj.size() - 1 && X.envases <= s.envases_mejor) {
if (X.envases == optima) encontrado = true;
s.solucion = X.sol;
s.envases_mejor = X.envases;
}
//Si no se ha terminado la solucion y la cota optimista de dicho nodo es mas baja que la pesimista se vuelve a meter en la cola de prioridad
else if (X.k < obj.size() - 1 && podaOptimistaIngenua(X) <= s.envases_mejor) C.push(X);
X.capacidad[X.k] = Y.capacidad[X.k];
X.sol[X.k] = Y.sol[X.k];
X.envases = Y.envases;
}
}
}
return s;
}
Solucion envasesPodasAjustadas(std::vector<int> const& obj, int const& E) {
Solucion s;
Nodo X, Y;
//Cola de prioridad que ordena los Nodos segun el numero de envases de menor a mayor
std::priority_queue<Nodo, std::deque<Nodo>, std::greater<Nodo>> C;
int total = 0;
for (int i = 0; i < obj.size(); ++i) total += obj[i];
bool encontrado = false;
//Generamos la raiz del primer elemento
Y.capacidad = std::vector<int>(obj.size(), E);
Y.sol = std::vector<int>(obj.size(), -1);
Y.k = 0; Y.envases = 1; Y.sol[0] = 0;
Y.capacidad[0] -= obj[0];
int optima = podaOptimistaAjustada(Y, obj, E);
C = std::priority_queue<Nodo, std::deque<Nodo>, std::greater<Nodo>>();
C.push(Y);
s.envases_mejor = podaPesimistaAjustada(Y, obj);
while (!encontrado && !C.empty() && C.top().envases <= s.envases_mejor) {
Y = C.top();
C.pop();
X = Y;
++X.k;
++s.nodosExplorados;
int i = -1;
//Vas creando los nodos insertando el objeto en todos los envases que puedas hasta introducirlo en un nuevo envase vacio
while (++i <= Y.envases) {
if (X.capacidad[i] >= obj[X.k]) {
if (i == Y.envases) ++X.envases;
X.sol[X.k] = i;
X.capacidad[i] -= obj[X.k];
s.envases_mejor = std::min(podaPesimistaAjustada(X, obj), s.envases_mejor);
//Si se ha encontrado la solucion y dicha solucion es como minimo tan buena como los envases de la solucion actual se pone como solucion
if (X.k == obj.size() - 1 && X.envases <= s.envases_mejor) {
if (X.envases == optima) encontrado = true;
s.solucion = X.sol;
s.envases_mejor = X.envases;
}
//Si no se ha terminado la solucion y la cota optimista de dicho nodo es mas baja que la pesimista se vuelve a meter en la cola de prioridad
else if (X.k < obj.size() - 1 && podaOptimistaAjustada(X, obj, E) <= s.envases_mejor) C.push(X);
X.capacidad[X.k] = Y.capacidad[X.k];
X.sol[X.k] = Y.sol[X.k];
X.envases = Y.envases;
}
}
}
return s;
}
Solucion envasesSinPoda(std::vector<int> const& obj, int const& E) {
Solucion s;
Nodo X, Y;
//Cola de prioridad que ordena los Nodos segun el numero de envases de menor a mayor
std::priority_queue<Nodo, std::deque<Nodo>, std::greater<Nodo>> C;
s.envases_mejor = obj.size();
int total = 0;
for (int i = 0; i < obj.size(); ++i) total += obj[i];
//Generamos la raiz del primer elemento
Y.capacidad = std::vector<int>(obj.size(), E);
Y.sol = std::vector<int>(obj.size(), -1);
Y.k = 0; Y.envases = 1; Y.sol[0] = 0;
Y.capacidad[0] -= obj[0];
C = std::priority_queue<Nodo, std::deque<Nodo>, std::greater<Nodo>>();
C.push(Y);
while (!C.empty() && C.top().envases <= s.envases_mejor) {
Y = C.top();
C.pop();
X = Y;
++X.k;
++s.nodosExplorados;
int i = -1;
//Vas creando los nodos insertando el objeto en todos los envases que puedas hasta introducirlo en un nuevo envase vacio
while (++i <= Y.envases) {
if (X.capacidad[i] >= obj[X.k]) {
if (i == Y.envases) ++X.envases;
X.sol[X.k] = i;
X.capacidad[i] -= obj[X.k];
//Si se ha encontrado la solucion y dicha solucion es como minimo tan buena como los envases de la solucion actual se pone como solucion
if (X.k == obj.size() - 1 && X.envases <= s.envases_mejor) {
s.solucion = X.sol;
s.envases_mejor = X.envases;
}
//Si no se ha terminado la solucion se vuelve a meter en la cola de prioridad
else if (X.k < obj.size() - 1) C.push(X);
X.capacidad[X.k] = Y.capacidad[X.k];
X.sol[X.k] = Y.sol[X.k];
X.envases = Y.envases;
}
}
}
return s;
}
void init(std::vector<int> & obj, int& tam) {
obj = std::vector<int>();
std::ifstream in;
std::string fname;
std::cout << "Archivo de entrada de datos: ";
std::cin >> fname;
in.open(fname);
if (!in.is_open()) throw std::domain_error("Archivo no existente");
int aux, valMax = 0;
while (!in.eof()) {
in >> aux;
if (aux <= 0) throw std::domain_error("Datos de entrada no validos");
else if (aux > valMax) valMax = aux;
obj.push_back(aux);
}
do {
std::cout << "Introduce la capacidad de los envases (minimo " << valMax << "): ";
std::cin >> aux;
if (aux < valMax) std::cout << "Capacidad insuficiente\n\n";
} while (aux < valMax);
tam = aux;
}
//La primera poda pesimista consistira simplemente en que el resto de objetos que quedan tendran cada uno su propio envase
// y ninguno sera asignado en ningun envase ya existente, asi que se devuelve el numero de objetos que quedan sumado a los envases que ya tenemos
int podaPesimistaIngenua(Nodo n, std::vector<int> const& obj) {
return n.envases + (obj.size() - n.k);
}
//La poda pesimista ajustada trata de ordenar el vector de capacidades de menor a a mayor, y el de objetos restantes de mas grandes a menos, e ir rellenando los envases
//en orden, intentando meter los objetos de mayor volumen en los envases con menos capacidad posible
int podaPesimistaAjustada(Nodo n, std::vector<int> obj) {
//ordena de mayor a menor los envases asignados segun capacidad y los objetos restantes de menor a mayor por tamanyo
//std::sort(n.capacidad.begin(), n.capacidad.end());
//std::sort(obj.begin(), obj.end(), std::greater<int>());
for (unsigned int i = n.k + 1; i < obj.size(); ++i) {
int j = -1;
while (n.capacidad[++j] < obj[i]);
if (j == n.envases) ++n.envases;
n.capacidad[j] -= obj[i];
}
return n.envases;
}
//La primera poda optimista simplemente devolvera el mismo numero de envases que ya tengamos con algun objeto en el
int podaOptimistaIngenua(Nodo const& n) {
return n.envases;
}
//La segunda poda optimista consiste en, teniendo el volumen total de los objetos que aun quedan por envasar y la capacidad restante
//de los envases los cuales ya tienen objetos asignados, restar del volumen total dicha capacidad y el resto de lo que queda dividirlo
//por el volumen de los envases siempre redondeando para arriba
int podaOptimistaAjustada(Nodo const& n, std::vector<int> const& obj, int const& E) {
int restante = 0, disponible = 0;
for (unsigned int i = n.k + 1; i < obj.size(); ++i) restante += obj[i];
for (unsigned int i = 0; i < n.envases; ++i) disponible += n.capacidad[i];
int opt = n.envases + std::max(0, (restante - disponible) / E);
if (restante - disponible > 0 && (restante - disponible) % E != 0) ++opt;
return opt;
}
bool operator<(Nodo const& a, Nodo const& b) {
return a.envases < b.envases;
}
bool operator==(Nodo const& a, Nodo const& b) {
return a.envases == b.envases;
}
bool operator>(Nodo const& a, Nodo const& b) {
return a.envases > b.envases;
} | [
"noreply@github.com"
] | noreply@github.com |
42fc9691c328fcd542c6d00fa8075875e00d8440 | 778febe9a4fdac6987888c80d574f20aa5641a1b | /Third Day Task/Search_in_rotated_array.cpp | eb763fe2a3c14870d300ee23d61dbc6a580f2632 | [] | no_license | arunabh-alt/SDE_EdFoal | 989c251bb195c5d85b6c4733a942d80b902bda3a | 66eaa97dd9243b31c2008ff685f179f9c4e86b90 | refs/heads/main | 2023-08-15T11:20:04.594316 | 2021-10-20T16:26:36 | 2021-10-20T16:26:36 | 413,458,517 | 0 | 0 | null | 2021-10-05T08:07:52 | 2021-10-04T14:32:04 | C++ | UTF-8 | C++ | false | false | 1,110 | cpp | #include<iostream>
using namespace std;
int SearchinArray(int arr[], int key, int left, int right){
if (left>right){
return -1;
}
int mid = (left+right)/2;
if(arr[mid]==key){
return mid;
}
if(arr[left]<= arr[mid]){
if(key >= arr[left]&& key<=arr[mid]){
return SearchinArray(arr,key,left,mid-1);
}
return SearchinArray(arr,key,mid+1,right);
}
if(key>=arr[mid]&& key<= arr[right]){
return SearchinArray(arr,key,mid+1,right);
}
return SearchinArray(arr,key,left,mid-1);
}
int main(){
int arr[100];
int n,i;
int key;
cout<<"Enter the array size: \n";
cin>>n;
cout<<"Enter the rotated shorted array: \n";
for(i=0;i<n;i++){
cin>>arr[i];
}
cout<<"Enter the target: \n";
cin>>key;
int index= SearchinArray(arr,key,0,n-1);
if (index==-1){
cout<<"-1";
}
else{
cout<<index;
}
return 0;
}
| [
"noreply@github.com"
] | noreply@github.com |
e9341f5b4e1dd828205c6366d568549528560694 | 491aa8dd02da2ae8857a172cbed238e78767d502 | /puglin_list.cpp | 1a33666b46a5faf9d3cf70c0deb59113f43c2137 | [] | no_license | romgerman/Puglin | ad40599fbbfee1a18796f723d7d3c341f18e9c44 | 8ccea13db6017f2acaaf631534d7285fe56590a5 | refs/heads/master | 2021-06-27T20:21:34.861183 | 2017-09-15T17:33:37 | 2017-09-15T17:33:37 | 103,392,519 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 827 | cpp | #include "puglin_list.h"
bool puglin_sources_allocated = false;
struct obs_source_info** puglin_sources_list;
static int puglin_current_source_index = 0;
EXTERNC void puglin_alloc_list()
{
if (!puglin_sources_allocated)
{
//puglin_sources_list = (obs_source_info**)malloc(sizeof(struct obs_source_info*) * PUGLIN_MAX_SOURCES);
puglin_sources_list = new obs_source_info*[PUGLIN_MAX_SOURCES];
puglin_sources_allocated = true;
}
}
EXTERNC void puglin_dealloc_list()
{
if (puglin_sources_allocated)
//free(puglin_sources_list);
delete[] puglin_sources_list;
}
EXTERNC void puglin_add_info(struct obs_source_info* info)
{
puglin_sources_list[puglin_current_source_index] = info;
puglin_current_source_index++;
}
EXTERNC struct obs_source_info* puglin_get_info(int index)
{
return puglin_sources_list[index];
}
| [
"romgerman@users.noreply.github.com"
] | romgerman@users.noreply.github.com |
58064412e760829f26c6c29bad94c3c82da2ca71 | 189592ed899dd62da3d01a30b7ddda22ab40556f | /src/EffectTool/Dialog_CAnimation.cpp | 3b34706350918c242ebef0a82efc0f48f8c96acd | [] | no_license | awesombly/MyStudy | 3ddc3f66d786a1ceac9ce08d1989048c4bccf8b8 | 3bc180a46434b856c1b93af2b8795fabb69f87a2 | refs/heads/master | 2020-05-03T00:04:45.809278 | 2019-04-28T11:23:48 | 2019-04-28T11:23:48 | 178,299,523 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 777 | cpp | #include "stdafx.h"
#include "EffectTool.h"
#include "Dialog_CAnimation.h"
#include "afxdialogex.h"
Dialog_CAnimation* Dialog_CAnimation::Instance = nullptr;
// Dialog_Preset 대화 상자
IMPLEMENT_DYNAMIC(Dialog_CAnimation, CFormView)
Dialog_CAnimation::Dialog_CAnimation()
: CFormView(IDD_DIALOG_CAnimation)
{
Instance = this;
}
Dialog_CAnimation::~Dialog_CAnimation()
{}
void Dialog_CAnimation::DoDataExchange(CDataExchange* pDX)
{
CFormView::DoDataExchange(pDX);
}
Dialog_CAnimation* Dialog_CAnimation::CreateOne(CWnd* pParent)
{
Dialog_CAnimation* pForm = new Dialog_CAnimation();
pForm->Create(NULL, NULL, WS_CHILD | WS_VISIBLE, CRect(0, 0, 500, 500), pParent, 0, NULL);
return pForm;
}
BEGIN_MESSAGE_MAP(Dialog_CAnimation, CFormView)
END_MESSAGE_MAP() | [
"walckm11@gmail.com"
] | walckm11@gmail.com |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.